diff options
author | Randy Dunlap <randy.dunlap@oracle.com> | 2008-07-16 09:52:00 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-07-16 14:46:16 -0400 |
commit | 3c3622dcb64c76c9abd2e468f802db9ba523421c (patch) | |
tree | 0e1ad9be83fb88c9a3e11e4a215f5ec244241785 /fs/compat_ioctl.c | |
parent | e3621ee633810be1079d0fa65ac2c904f53b73fa (diff) |
Fix compile issues in fs/compat_ioctl.c when CONFIG_BLOCK is disabled
Fix fs/compat_ioctl.c to handle CONFIG_BLOCK=n, CONFIG_SCSI=n to avoid
build errors:
In file included from include/scsi/scsi.h:12,
from fs/compat_ioctl.c:71:
include/scsi/scsi_cmnd.h:27:25: warning: "BLK_MAX_CDB" is not defined
include/scsi/scsi_cmnd.h:28:3: error: #error MAX_COMMAND_SIZE can not be bigger than BLK_MAX_CDB
In file included from include/scsi/scsi.h:12,
from fs/compat_ioctl.c:71:
include/scsi/scsi_cmnd.h: In function 'scsi_bidi_cmnd':
include/scsi/scsi_cmnd.h:182: error: implicit declaration of function 'blk_bidi_rq'
include/scsi/scsi_cmnd.h:183: error: dereferencing pointer to incomplete type
include/scsi/scsi_cmnd.h: In function 'scsi_in':
include/scsi/scsi_cmnd.h:189: error: dereferencing pointer to incomplete type
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/compat_ioctl.c')
-rw-r--r-- | fs/compat_ioctl.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/fs/compat_ioctl.c b/fs/compat_ioctl.c index 97dba0d92348..c54eaab71a19 100644 --- a/fs/compat_ioctl.c +++ b/fs/compat_ioctl.c | |||
@@ -69,9 +69,11 @@ | |||
69 | #include <linux/capi.h> | 69 | #include <linux/capi.h> |
70 | #include <linux/gigaset_dev.h> | 70 | #include <linux/gigaset_dev.h> |
71 | 71 | ||
72 | #ifdef CONFIG_BLOCK | ||
72 | #include <scsi/scsi.h> | 73 | #include <scsi/scsi.h> |
73 | #include <scsi/scsi_ioctl.h> | 74 | #include <scsi/scsi_ioctl.h> |
74 | #include <scsi/sg.h> | 75 | #include <scsi/sg.h> |
76 | #endif | ||
75 | 77 | ||
76 | #include <asm/uaccess.h> | 78 | #include <asm/uaccess.h> |
77 | #include <linux/ethtool.h> | 79 | #include <linux/ethtool.h> |
@@ -2024,6 +2026,7 @@ COMPATIBLE_IOCTL(GIO_UNISCRNMAP) | |||
2024 | COMPATIBLE_IOCTL(PIO_UNISCRNMAP) | 2026 | COMPATIBLE_IOCTL(PIO_UNISCRNMAP) |
2025 | COMPATIBLE_IOCTL(PIO_FONTRESET) | 2027 | COMPATIBLE_IOCTL(PIO_FONTRESET) |
2026 | COMPATIBLE_IOCTL(PIO_UNIMAPCLR) | 2028 | COMPATIBLE_IOCTL(PIO_UNIMAPCLR) |
2029 | #ifdef CONFIG_BLOCK | ||
2027 | /* Big S */ | 2030 | /* Big S */ |
2028 | COMPATIBLE_IOCTL(SCSI_IOCTL_GET_IDLUN) | 2031 | COMPATIBLE_IOCTL(SCSI_IOCTL_GET_IDLUN) |
2029 | COMPATIBLE_IOCTL(SCSI_IOCTL_DOORLOCK) | 2032 | COMPATIBLE_IOCTL(SCSI_IOCTL_DOORLOCK) |
@@ -2033,6 +2036,7 @@ COMPATIBLE_IOCTL(SCSI_IOCTL_GET_BUS_NUMBER) | |||
2033 | COMPATIBLE_IOCTL(SCSI_IOCTL_SEND_COMMAND) | 2036 | COMPATIBLE_IOCTL(SCSI_IOCTL_SEND_COMMAND) |
2034 | COMPATIBLE_IOCTL(SCSI_IOCTL_PROBE_HOST) | 2037 | COMPATIBLE_IOCTL(SCSI_IOCTL_PROBE_HOST) |
2035 | COMPATIBLE_IOCTL(SCSI_IOCTL_GET_PCI) | 2038 | COMPATIBLE_IOCTL(SCSI_IOCTL_GET_PCI) |
2039 | #endif | ||
2036 | /* Big T */ | 2040 | /* Big T */ |
2037 | COMPATIBLE_IOCTL(TUNSETNOCSUM) | 2041 | COMPATIBLE_IOCTL(TUNSETNOCSUM) |
2038 | COMPATIBLE_IOCTL(TUNSETDEBUG) | 2042 | COMPATIBLE_IOCTL(TUNSETDEBUG) |
@@ -2103,6 +2107,7 @@ COMPATIBLE_IOCTL(SIOCGIFVLAN) | |||
2103 | COMPATIBLE_IOCTL(SIOCSIFVLAN) | 2107 | COMPATIBLE_IOCTL(SIOCSIFVLAN) |
2104 | COMPATIBLE_IOCTL(SIOCBRADDBR) | 2108 | COMPATIBLE_IOCTL(SIOCBRADDBR) |
2105 | COMPATIBLE_IOCTL(SIOCBRDELBR) | 2109 | COMPATIBLE_IOCTL(SIOCBRDELBR) |
2110 | #ifdef CONFIG_BLOCK | ||
2106 | /* SG stuff */ | 2111 | /* SG stuff */ |
2107 | COMPATIBLE_IOCTL(SG_SET_TIMEOUT) | 2112 | COMPATIBLE_IOCTL(SG_SET_TIMEOUT) |
2108 | COMPATIBLE_IOCTL(SG_GET_TIMEOUT) | 2113 | COMPATIBLE_IOCTL(SG_GET_TIMEOUT) |
@@ -2127,6 +2132,7 @@ COMPATIBLE_IOCTL(SG_SCSI_RESET) | |||
2127 | COMPATIBLE_IOCTL(SG_GET_REQUEST_TABLE) | 2132 | COMPATIBLE_IOCTL(SG_GET_REQUEST_TABLE) |
2128 | COMPATIBLE_IOCTL(SG_SET_KEEP_ORPHAN) | 2133 | COMPATIBLE_IOCTL(SG_SET_KEEP_ORPHAN) |
2129 | COMPATIBLE_IOCTL(SG_GET_KEEP_ORPHAN) | 2134 | COMPATIBLE_IOCTL(SG_GET_KEEP_ORPHAN) |
2135 | #endif | ||
2130 | /* PPP stuff */ | 2136 | /* PPP stuff */ |
2131 | COMPATIBLE_IOCTL(PPPIOCGFLAGS) | 2137 | COMPATIBLE_IOCTL(PPPIOCGFLAGS) |
2132 | COMPATIBLE_IOCTL(PPPIOCSFLAGS) | 2138 | COMPATIBLE_IOCTL(PPPIOCSFLAGS) |