Merge commit 'v2.6.30' into for-2.6.31
[safe/jmp/linux-2.6] / include / scsi / scsi_device.h
index a37a814..3f566af 100644 (file)
@@ -159,8 +159,6 @@ struct scsi_device {
        atomic_t iodone_cnt;
        atomic_t ioerr_cnt;
 
-       int timeout;
-
        struct device           sdev_gendev,
                                sdev_dev;
 
@@ -342,6 +340,7 @@ extern int scsi_mode_select(struct scsi_device *sdev, int pf, int sp,
                            struct scsi_sense_hdr *);
 extern int scsi_test_unit_ready(struct scsi_device *sdev, int timeout,
                                int retries, struct scsi_sense_hdr *sshdr);
+extern unsigned char *scsi_get_vpd_page(struct scsi_device *, u8 page);
 extern int scsi_device_set_state(struct scsi_device *sdev,
                                 enum scsi_device_state state);
 extern struct scsi_event *sdev_evt_alloc(enum scsi_device_event evt_type,
@@ -367,16 +366,11 @@ extern int scsi_is_target_device(const struct device *);
 extern int scsi_execute(struct scsi_device *sdev, const unsigned char *cmd,
                        int data_direction, void *buffer, unsigned bufflen,
                        unsigned char *sense, int timeout, int retries,
-                       int flag);
+                       int flag, int *resid);
 extern int scsi_execute_req(struct scsi_device *sdev, const unsigned char *cmd,
                            int data_direction, void *buffer, unsigned bufflen,
-                           struct scsi_sense_hdr *, int timeout, int retries);
-extern int scsi_execute_async(struct scsi_device *sdev,
-                             const unsigned char *cmd, int cmd_len, int data_direction,
-                             void *buffer, unsigned bufflen, int use_sg,
-                             int timeout, int retries, void *privdata,
-                             void (*done)(void *, char *, int, int),
-                             gfp_t gfp);
+                           struct scsi_sense_hdr *, int timeout, int retries,
+                           int *resid);
 
 static inline int __must_check scsi_device_reprobe(struct scsi_device *sdev)
 {
@@ -401,7 +395,8 @@ static inline unsigned int sdev_id(struct scsi_device *sdev)
  */
 static inline int scsi_device_online(struct scsi_device *sdev)
 {
-       return sdev->sdev_state != SDEV_OFFLINE;
+       return (sdev->sdev_state != SDEV_OFFLINE &&
+               sdev->sdev_state != SDEV_DEL);
 }
 static inline int scsi_device_blocked(struct scsi_device *sdev)
 {