Skip to contentSkip to conversation

BLOCK: Hide the contents of linux/bio.h if CONFIG_BLOCK=n [try #2]

PATCH New David Howells 1 participant 1 message Aug 1, 2007 Block layer

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 BLOCK: Hide the contents of linux/bio.h if CONFIG_BLOCK=n [try #2]

From: David Howells <[email protected]>

Hide the contents of linux/bio.h if CONFIG_BLOCK=n as there shouldn't be compiled that uses it.

---

 include/linux/bio.h |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
include/linux/bio.h +3 -0
index 4d85262..1ddef34 100644
@@ -24,6 +24,8 @@
 #include <linux/mempool.h>
 #include <linux/ioprio.h>
 
+#ifdef CONFIG_BLOCK
+
 /* Platforms may set this to teach the BIO layer about IOMMU hardware. */
 #include <asm/io.h>
 
@@ -361,4 +363,5 @@ static inline char *__bio_kmap_irq(struct bio *bio, unsigned short idx,
 	__bio_kmap_irq((bio), (bio)->bi_idx, (flags))
 #define bio_kunmap_irq(buf,flags)	__bio_kunmap_irq(buf, flags)
 
+#endif /* CONFIG_BLOCK */
 #endif /* __LINUX_BIO_H */