From: Giuseppe Di Natale Date: Tue, 10 Apr 2018 00:20:06 +0000 (-0700) Subject: Linux compat 4.16: SECTOR_SIZE X-Git-Tag: zfs-0.8.0-rc1~152^2~4 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=9125f8f5bdb36bfbd2d816d30b6b29b9f89ae3d8;p=zfs Linux compat 4.16: SECTOR_SIZE As of https://github.com/torvalds/linux/commit/233bde21, SECTOR_SIZE is defined in linux/blkdev.h. Define SECTOR_SIZE in sunldi.h only if it's not already defined. Reviewed-by: Brian Behlendorf Reviewed-by: George Melikov Signed-off-by: Giuseppe Di Natale Closes #697 --- diff --git a/include/sys/sunldi.h b/include/sys/sunldi.h index 43462efad..a5045f891 100644 --- a/include/sys/sunldi.h +++ b/include/sys/sunldi.h @@ -32,6 +32,12 @@ #include #include +/* + * SECTOR_SIZE can be defined in blkdev.h. See + * https://github.com/torvalds/linux/commit/233bde21. + */ +#ifndef SECTOR_SIZE #define SECTOR_SIZE 512 +#endif #endif /* SPL_SUNLDI_H */