blob: 44befc1501cd8f1da15fffe79a212b7b0f3e6b55 [file] [log] [blame]
--- a/src/shared/linux_osl.c
+++ b/src/shared/linux_osl.c
@@ -1080,7 +1080,11 @@ osl_os_get_image_block(char *buf, int le
if (!image)
return 0;
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 14, 0)
+ rdlen = kernel_read(fp, buf, len, &fp->f_pos);
+#else
rdlen = kernel_read(fp, fp->f_pos, buf, len);
+#endif
if (rdlen > 0)
fp->f_pos += rdlen;