search for: offset_string

Displaying 1 result from an estimated 1 matches for "offset_string".

2018 Mar 30
0
[PATCH] resume: Use the kernel API from 4.17 for setting resume offset
...resumelib.c index e557b05..5fc2019 100644 --- a/usr/kinit/resume/resumelib.c +++ b/usr/kinit/resume/resumelib.c @@ -45,7 +45,9 @@ int resume(const char *resume_file, unsigned long long resume_offset) { dev_t resume_device; int powerfd = -1; + int offsetfd = -1; char device_string[64]; + char offset_string[64]; int len; resume_device = name_to_dev_t(resume_file); @@ -55,13 +57,23 @@ int resume(const char *resume_file, unsigned long long resume_offset) goto failure; } + /* Write the offset, this won't work on less than 4.17 */ + offsetfd = open("/sys/power/resume_offset", O_...