[PATCH 2/5] raid6: guard the tables.c include of <linux/export.h> with __KERNEL__

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: WANG Xuerui <git@xxxxxxxxxx>

The export directives for the tables are already emitted with __KERNEL__
guards, but the <linux/export.h> include is not, causing errors when
building the raid6test program. Guard this include too to fix the
raid6test build.

Signed-off-by: WANG Xuerui <git@xxxxxxxxxx>
---
 lib/raid6/mktables.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/lib/raid6/mktables.c b/lib/raid6/mktables.c
index f02e10fa62381..3be03793237c2 100644
--- a/lib/raid6/mktables.c
+++ b/lib/raid6/mktables.c
@@ -56,7 +56,9 @@ int main(int argc, char *argv[])
 	uint8_t v;
 	uint8_t exptbl[256], invtbl[256];
 
+	printf("#ifdef __KERNEL__\n");
 	printf("#include <linux/export.h>\n");
+	printf("#endif\n");
 	printf("#include <linux/raid/pq.h>\n");
 
 	/* Compute multiplication table */
-- 
2.40.0




[Index of Archives]     [Linux RAID Wiki]     [ATA RAID]     [Linux SCSI Target Infrastructure]     [Linux Block]     [Linux IDE]     [Linux SCSI]     [Linux Hams]     [Device Mapper]     [Device Mapper Cryptographics]     [Kernel]     [Linux Admin]     [Linux Net]     [GFS]     [RPM]     [git]     [Yosemite Forum]


  Powered by Linux