From ee959b00c335d7780136c5abda37809191fe52c3 Mon Sep 17 00:00:00 2001 From: Tony Jones Date: Fri, 22 Feb 2008 00:13:36 +0100 Subject: SCSI: convert struct class_device to struct device It's big, but there doesn't seem to be a way to split it up smaller... Signed-off-by: Tony Jones Signed-off-by: Kay Sievers Cc: Roland Dreier Cc: Sean Hefty Cc: Hal Rosenstock Cc: James Bottomley Signed-off-by: Greg Kroah-Hartman --- include/scsi/scsi_device.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'include/scsi/scsi_device.h') diff --git a/include/scsi/scsi_device.h b/include/scsi/scsi_device.h index ab7acbe8096..b8b19e2f57b 100644 --- a/include/scsi/scsi_device.h +++ b/include/scsi/scsi_device.h @@ -156,8 +156,8 @@ struct scsi_device { int timeout; - struct device sdev_gendev; - struct class_device sdev_classdev; + struct device sdev_gendev, + sdev_dev; struct execute_work ew; /* used to get process context on put */ @@ -167,9 +167,9 @@ struct scsi_device { #define to_scsi_device(d) \ container_of(d, struct scsi_device, sdev_gendev) #define class_to_sdev(d) \ - container_of(d, struct scsi_device, sdev_classdev) + container_of(d, struct scsi_device, sdev_dev) #define transport_class_to_sdev(class_dev) \ - to_scsi_device(class_dev->dev) + to_scsi_device(class_dev->parent) #define sdev_printk(prefix, sdev, fmt, a...) \ dev_printk(prefix, &(sdev)->sdev_gendev, fmt, ##a) @@ -220,7 +220,7 @@ static inline struct scsi_target *scsi_target(struct scsi_device *sdev) return to_scsi_target(sdev->sdev_gendev.parent); } #define transport_class_to_starget(class_dev) \ - to_scsi_target(class_dev->dev) + to_scsi_target(class_dev->parent) #define starget_printk(prefix, starget, fmt, a...) \ dev_printk(prefix, &(starget)->dev, fmt, ##a) -- cgit v1.2.3