X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=drivers%2Fscsi%2Fscsi_priv.h;h=c01580df4476bc1acc70a41bd23434cc067fdf67;hb=f7f1b0f1e2fbadeab12d24236000e778aa9b1ead;hp=4dfb3db639d5af105b4e2f5d28f1ce08ed96a316;hpb=9bf4aaab3e101692164d49b7ca357651eb691cb6;p=linux-2.6.git diff --git a/drivers/scsi/scsi_priv.h b/drivers/scsi/scsi_priv.h index 4dfb3db63..c01580df4 100644 --- a/drivers/scsi/scsi_priv.h +++ b/drivers/scsi/scsi_priv.h @@ -29,11 +29,6 @@ struct Scsi_Host; #define SCSI_CMND_MAGIC 0xE25C23A5 #define SCSI_REQ_MAGIC 0x75F6D354 -/* - * Flag bit for the internal_timeout array - */ -#define NORMAL_TIMEOUT 0 - /* * Scsi Error Handler Flags */ @@ -58,16 +53,6 @@ struct Scsi_Host; */ #define SCAN_WILD_CARD ~0 -/* - * scsi_target: representation of a scsi target, for now, this is only - * used for single_lun devices. If no one has active IO to the target, - * starget_sdev_user is NULL, else it points to the active sdev. - */ -struct scsi_target { - struct scsi_device *starget_sdev_user; - unsigned int starget_refcnt; -}; - /* hosts.c */ extern int scsi_init_hosts(void); extern void scsi_exit_hosts(void); @@ -96,7 +81,7 @@ static inline void scsi_log_completion(struct scsi_cmnd *cmd, int disposition) /* scsi_devinfo.c */ extern int scsi_get_device_flags(struct scsi_device *sdev, unsigned char *vendor, unsigned char *model); -extern int scsi_init_devinfo(void); +extern int __init scsi_init_devinfo(void); extern void scsi_exit_devinfo(void); /* scsi_error.c */ @@ -156,9 +141,20 @@ extern int scsi_sysfs_add_sdev(struct scsi_device *); extern int scsi_sysfs_add_host(struct Scsi_Host *); extern int scsi_sysfs_register(void); extern void scsi_sysfs_unregister(void); +extern void scsi_sysfs_device_initialize(struct scsi_device *); +extern int scsi_sysfs_target_initialize(struct scsi_device *); extern struct scsi_transport_template blank_transport_template; extern struct class sdev_class; extern struct bus_type scsi_bus_type; +/* + * internal scsi timeout functions: for use by mid-layer and transport + * classes. + */ + +#define SCSI_DEVICE_BLOCK_MAX_TIMEOUT (HZ*60) +extern int scsi_internal_device_block(struct scsi_device *sdev); +extern int scsi_internal_device_unblock(struct scsi_device *sdev); + #endif /* _SCSI_PRIV_H */