mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 11:41:38 -04:00
target: Minimize SCSI header #include directives
Only include SCSI initiator header files in target code that needs
these header files, namely the SCSI pass-through code and the tcm_loop
driver. Change SCSI_SENSE_BUFFERSIZE into TRANSPORT_SENSE_BUFFER in
target code because the former is intended for initiator code and the
latter for target code. With this patch the only initiator include
directives in target code that remain are as follows:
$ git grep -nHE 'include .scsi/(scsi.h|scsi_host.h|scsi_device.h|scsi_cmnd.h)' drivers/target drivers/infiniband/ulp/{isert,srpt} drivers/usb/gadget/legacy/tcm_*.[ch] drivers/{vhost,xen} include/{target,trace/events/target.h}
drivers/target/loopback/tcm_loop.c:29:#include <scsi/scsi.h>
drivers/target/loopback/tcm_loop.c:31:#include <scsi/scsi_host.h>
drivers/target/loopback/tcm_loop.c:32:#include <scsi/scsi_device.h>
drivers/target/loopback/tcm_loop.c:33:#include <scsi/scsi_cmnd.h>
drivers/target/target_core_pscsi.c:39:#include <scsi/scsi_device.h>
drivers/target/target_core_pscsi.c:40:#include <scsi/scsi_host.h>
drivers/xen/xen-scsiback.c:52:#include <scsi/scsi_host.h> /* SG_ALL */
Signed-off-by: Bart Van Assche <[email protected]>
Reviewed-by: Christoph Hellwig <[email protected]>
Signed-off-by: James Bottomley <[email protected]>
This commit is contained in:
parent
8d3a824891
commit
ba92999252
36 changed files with 32 additions and 74 deletions
|
|
@ -23,7 +23,7 @@
|
|||
#include <linux/module.h>
|
||||
#include <linux/idr.h>
|
||||
#include <asm/unaligned.h>
|
||||
#include <scsi/scsi_device.h>
|
||||
#include <scsi/scsi_proto.h>
|
||||
#include <scsi/iscsi_proto.h>
|
||||
#include <scsi/scsi_tcq.h>
|
||||
#include <target/target_core_base.h>
|
||||
|
|
|
|||
|
|
@ -17,7 +17,6 @@
|
|||
* GNU General Public License for more details.
|
||||
******************************************************************************/
|
||||
|
||||
#include <scsi/scsi_device.h>
|
||||
#include <target/target_core_base.h>
|
||||
#include <target/target_core_fabric.h>
|
||||
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@
|
|||
******************************************************************************/
|
||||
|
||||
#include <asm/unaligned.h>
|
||||
#include <scsi/scsi_device.h>
|
||||
#include <scsi/scsi_proto.h>
|
||||
#include <scsi/iscsi_proto.h>
|
||||
#include <target/target_core_base.h>
|
||||
#include <target/target_core_fabric.h>
|
||||
|
|
|
|||
|
|
@ -30,7 +30,7 @@
|
|||
#include <linux/ctype.h>
|
||||
#include <linux/firewire.h>
|
||||
#include <linux/firewire-constants.h>
|
||||
#include <scsi/scsi.h>
|
||||
#include <scsi/scsi_proto.h>
|
||||
#include <scsi/scsi_tcq.h>
|
||||
#include <target/target_core_base.h>
|
||||
#include <target/target_core_backend.h>
|
||||
|
|
|
|||
|
|
@ -28,8 +28,7 @@
|
|||
#include <linux/configfs.h>
|
||||
#include <linux/export.h>
|
||||
#include <linux/file.h>
|
||||
#include <scsi/scsi.h>
|
||||
#include <scsi/scsi_cmnd.h>
|
||||
#include <scsi/scsi_proto.h>
|
||||
#include <asm/unaligned.h>
|
||||
|
||||
#include <target/target_core_base.h>
|
||||
|
|
|
|||
|
|
@ -35,8 +35,8 @@
|
|||
#include <linux/export.h>
|
||||
#include <net/sock.h>
|
||||
#include <net/tcp.h>
|
||||
#include <scsi/scsi.h>
|
||||
#include <scsi/scsi_device.h>
|
||||
#include <scsi/scsi_common.h>
|
||||
#include <scsi/scsi_proto.h>
|
||||
|
||||
#include <target/target_core_base.h>
|
||||
#include <target/target_core_backend.h>
|
||||
|
|
|
|||
|
|
@ -29,8 +29,6 @@
|
|||
#include <linux/ctype.h>
|
||||
#include <linux/spinlock.h>
|
||||
#include <linux/export.h>
|
||||
#include <scsi/scsi.h>
|
||||
#include <scsi/scsi_cmnd.h>
|
||||
|
||||
#include <target/target_core_base.h>
|
||||
#include <target/target_core_fabric.h>
|
||||
|
|
|
|||
|
|
@ -31,8 +31,7 @@
|
|||
#include <linux/spinlock.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/falloc.h>
|
||||
#include <scsi/scsi.h>
|
||||
#include <scsi/scsi_host.h>
|
||||
#include <scsi/scsi_proto.h>
|
||||
#include <asm/unaligned.h>
|
||||
|
||||
#include <target/target_core_base.h>
|
||||
|
|
|
|||
|
|
@ -35,8 +35,7 @@
|
|||
#include <linux/genhd.h>
|
||||
#include <linux/file.h>
|
||||
#include <linux/module.h>
|
||||
#include <scsi/scsi.h>
|
||||
#include <scsi/scsi_host.h>
|
||||
#include <scsi/scsi_proto.h>
|
||||
#include <asm/unaligned.h>
|
||||
|
||||
#include <target/target_core_base.h>
|
||||
|
|
|
|||
|
|
@ -28,8 +28,7 @@
|
|||
#include <linux/spinlock.h>
|
||||
#include <linux/list.h>
|
||||
#include <linux/file.h>
|
||||
#include <scsi/scsi.h>
|
||||
#include <scsi/scsi_cmnd.h>
|
||||
#include <scsi/scsi_proto.h>
|
||||
#include <asm/unaligned.h>
|
||||
|
||||
#include <target/target_core_base.h>
|
||||
|
|
|
|||
|
|
@ -36,9 +36,7 @@
|
|||
#include <linux/module.h>
|
||||
#include <asm/unaligned.h>
|
||||
|
||||
#include <scsi/scsi.h>
|
||||
#include <scsi/scsi_device.h>
|
||||
#include <scsi/scsi_cmnd.h>
|
||||
#include <scsi/scsi_host.h>
|
||||
#include <scsi/scsi_tcq.h>
|
||||
|
||||
|
|
|
|||
|
|
@ -16,13 +16,13 @@
|
|||
#define PS_TIMEOUT_OTHER (500*HZ)
|
||||
|
||||
#include <linux/device.h>
|
||||
#include <scsi/scsi_driver.h>
|
||||
#include <scsi/scsi_device.h>
|
||||
#include <linux/kref.h>
|
||||
#include <linux/kobject.h>
|
||||
|
||||
struct scsi_device;
|
||||
|
||||
struct pscsi_plugin_task {
|
||||
unsigned char pscsi_sense[SCSI_SENSE_BUFFERSIZE];
|
||||
unsigned char pscsi_sense[TRANSPORT_SENSE_BUFFER];
|
||||
int pscsi_direction;
|
||||
int pscsi_result;
|
||||
u32 pscsi_resid;
|
||||
|
|
|
|||
|
|
@ -29,8 +29,7 @@
|
|||
#include <linux/timer.h>
|
||||
#include <linux/slab.h>
|
||||
#include <linux/spinlock.h>
|
||||
#include <scsi/scsi.h>
|
||||
#include <scsi/scsi_host.h>
|
||||
#include <scsi/scsi_proto.h>
|
||||
|
||||
#include <target/target_core_base.h>
|
||||
#include <target/target_core_backend.h>
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@
|
|||
#include <linux/ratelimit.h>
|
||||
#include <linux/crc-t10dif.h>
|
||||
#include <asm/unaligned.h>
|
||||
#include <scsi/scsi.h>
|
||||
#include <scsi/scsi_proto.h>
|
||||
#include <scsi/scsi_tcq.h>
|
||||
|
||||
#include <target/target_core_base.h>
|
||||
|
|
|
|||
|
|
@ -24,7 +24,8 @@
|
|||
#include <linux/module.h>
|
||||
#include <asm/unaligned.h>
|
||||
|
||||
#include <scsi/scsi.h>
|
||||
#include <scsi/scsi_proto.h>
|
||||
#include <scsi/scsi_common.h>
|
||||
#include <scsi/scsi_tcq.h>
|
||||
|
||||
#include <target/target_core_base.h>
|
||||
|
|
|
|||
|
|
@ -33,9 +33,6 @@
|
|||
#include <linux/proc_fs.h>
|
||||
#include <linux/seq_file.h>
|
||||
#include <linux/configfs.h>
|
||||
#include <scsi/scsi.h>
|
||||
#include <scsi/scsi_device.h>
|
||||
#include <scsi/scsi_host.h>
|
||||
|
||||
#include <target/target_core_base.h>
|
||||
#include <target/target_core_backend.h>
|
||||
|
|
|
|||
|
|
@ -27,8 +27,6 @@
|
|||
#include <linux/spinlock.h>
|
||||
#include <linux/list.h>
|
||||
#include <linux/export.h>
|
||||
#include <scsi/scsi.h>
|
||||
#include <scsi/scsi_cmnd.h>
|
||||
|
||||
#include <target/target_core_base.h>
|
||||
#include <target/target_core_backend.h>
|
||||
|
|
|
|||
|
|
@ -32,8 +32,7 @@
|
|||
#include <linux/export.h>
|
||||
#include <net/sock.h>
|
||||
#include <net/tcp.h>
|
||||
#include <scsi/scsi.h>
|
||||
#include <scsi/scsi_cmnd.h>
|
||||
#include <scsi/scsi_proto.h>
|
||||
|
||||
#include <target/target_core_base.h>
|
||||
#include <target/target_core_backend.h>
|
||||
|
|
|
|||
|
|
@ -37,9 +37,7 @@
|
|||
#include <asm/unaligned.h>
|
||||
#include <net/sock.h>
|
||||
#include <net/tcp.h>
|
||||
#include <scsi/scsi.h>
|
||||
#include <scsi/scsi_cmnd.h>
|
||||
#include <scsi/scsi_tcq.h>
|
||||
#include <scsi/scsi_proto.h>
|
||||
|
||||
#include <target/target_core_base.h>
|
||||
#include <target/target_core_backend.h>
|
||||
|
|
|
|||
|
|
@ -25,8 +25,7 @@
|
|||
|
||||
#include <linux/slab.h>
|
||||
#include <linux/spinlock.h>
|
||||
#include <scsi/scsi.h>
|
||||
#include <scsi/scsi_cmnd.h>
|
||||
#include <scsi/scsi_proto.h>
|
||||
|
||||
#include <target/target_core_base.h>
|
||||
#include <target/target_core_fabric.h>
|
||||
|
|
|
|||
|
|
@ -19,12 +19,13 @@
|
|||
#include <linux/spinlock.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/idr.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/timer.h>
|
||||
#include <linux/parser.h>
|
||||
#include <scsi/scsi.h>
|
||||
#include <scsi/scsi_host.h>
|
||||
#include <linux/uio_driver.h>
|
||||
#include <net/genetlink.h>
|
||||
#include <scsi/scsi_common.h>
|
||||
#include <scsi/scsi_proto.h>
|
||||
#include <target/target_core_base.h>
|
||||
#include <target/target_core_fabric.h>
|
||||
#include <target/target_core_backend.h>
|
||||
|
|
|
|||
|
|
@ -25,8 +25,7 @@
|
|||
#include <linux/spinlock.h>
|
||||
#include <linux/list.h>
|
||||
#include <linux/configfs.h>
|
||||
#include <scsi/scsi.h>
|
||||
#include <scsi/scsi_cmnd.h>
|
||||
#include <scsi/scsi_proto.h>
|
||||
#include <asm/unaligned.h>
|
||||
|
||||
#include <target/target_core_base.h>
|
||||
|
|
|
|||
|
|
@ -30,10 +30,6 @@
|
|||
#include <linux/hash.h>
|
||||
#include <linux/percpu_ida.h>
|
||||
#include <asm/unaligned.h>
|
||||
#include <scsi/scsi.h>
|
||||
#include <scsi/scsi_host.h>
|
||||
#include <scsi/scsi_device.h>
|
||||
#include <scsi/scsi_cmnd.h>
|
||||
#include <scsi/scsi_tcq.h>
|
||||
#include <scsi/libfc.h>
|
||||
#include <scsi/fc_encode.h>
|
||||
|
|
|
|||
|
|
@ -34,10 +34,6 @@
|
|||
#include <linux/kernel.h>
|
||||
#include <linux/ctype.h>
|
||||
#include <asm/unaligned.h>
|
||||
#include <scsi/scsi.h>
|
||||
#include <scsi/scsi_host.h>
|
||||
#include <scsi/scsi_device.h>
|
||||
#include <scsi/scsi_cmnd.h>
|
||||
#include <scsi/libfc.h>
|
||||
|
||||
#include <target/target_core_base.h>
|
||||
|
|
|
|||
|
|
@ -39,10 +39,6 @@
|
|||
#include <linux/hash.h>
|
||||
#include <linux/ratelimit.h>
|
||||
#include <asm/unaligned.h>
|
||||
#include <scsi/scsi.h>
|
||||
#include <scsi/scsi_host.h>
|
||||
#include <scsi/scsi_device.h>
|
||||
#include <scsi/scsi_cmnd.h>
|
||||
#include <scsi/libfc.h>
|
||||
#include <scsi/fc_encode.h>
|
||||
|
||||
|
|
|
|||
|
|
@ -32,10 +32,6 @@
|
|||
#include <linux/rculist.h>
|
||||
#include <linux/kref.h>
|
||||
#include <asm/unaligned.h>
|
||||
#include <scsi/scsi.h>
|
||||
#include <scsi/scsi_host.h>
|
||||
#include <scsi/scsi_device.h>
|
||||
#include <scsi/scsi_cmnd.h>
|
||||
#include <scsi/libfc.h>
|
||||
|
||||
#include <target/target_core_base.h>
|
||||
|
|
|
|||
Loading…
Reference in a new issue