]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - include/scsi/scsi_device.h
[SCSI] move the mid-layer printk's over to shost/starget/sdev_printk
[linux-2.6-omap-h63xx.git] / include / scsi / scsi_device.h
index da63722c0123b8e77feadd5cd6ee118c757c153e..7f621ab2865d87be0213c453a37614803fb5f9ba 100644 (file)
@@ -148,6 +148,9 @@ struct scsi_device {
 #define transport_class_to_sdev(class_dev) \
        to_scsi_device(class_dev->dev)
 
+#define sdev_printk(prefix, sdev, fmt, a...)   \
+       dev_printk(prefix, &(sdev)->sdev_gendev, fmt, ##a)
+
 /*
  * 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,
@@ -163,6 +166,7 @@ struct scsi_target {
        unsigned int            id; /* target id ... replace
                                     * scsi_device.id eventually */
        unsigned long           create:1; /* signal that it needs to be added */
+       char                    scsi_level;
        void                    *hostdata; /* available to low-level driver */
        unsigned long           starget_data[0]; /* for the transport */
        /* starget_data must be the last element!!!! */
@@ -176,10 +180,13 @@ static inline struct scsi_target *scsi_target(struct scsi_device *sdev)
 #define transport_class_to_starget(class_dev) \
        to_scsi_target(class_dev->dev)
 
+#define starget_printk(prefix, starget, fmt, a...)     \
+       dev_printk(prefix, &(starget)->dev, fmt, ##a)
+
 extern struct scsi_device *__scsi_add_device(struct Scsi_Host *,
                uint, uint, uint, void *hostdata);
-#define scsi_add_device(host, channel, target, lun) \
-       __scsi_add_device(host, channel, target, lun, NULL)
+extern int scsi_add_device(struct Scsi_Host *host, uint channel,
+                          uint target, uint lun);
 extern void scsi_remove_device(struct scsi_device *);
 extern int scsi_device_cancel(struct scsi_device *, int);