diff options
author | Dmitry Torokhov <dtor_core@ameritech.net> | 2005-09-15 03:01:36 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2005-10-28 12:52:51 -0400 |
commit | d8539d81aeee4dbdc0624a798321e822fb2df7ae (patch) | |
tree | 3fc46e80f2fdec0a7ca714dfa3fb8f08648d3bb8 /drivers/scsi | |
parent | 7bd7b091429705eb281d60c553cc643aada8045a (diff) |
[PATCH] Driver core: pass interface to class interface methods
Driver core: pass interface to class intreface methods
Pass interface as argument to add() and remove() class interface
methods. This way a subsystem can implement generic add/remove
handlers and then call interface-specific ones.
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/scsi')
-rw-r--r-- | drivers/scsi/sg.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/scsi/sg.c b/drivers/scsi/sg.c index ad94367df430..f0d8b4eda5ad 100644 --- a/drivers/scsi/sg.c +++ b/drivers/scsi/sg.c | |||
@@ -104,8 +104,8 @@ static int sg_allow_dio = SG_ALLOW_DIO_DEF; | |||
104 | 104 | ||
105 | #define SG_DEV_ARR_LUMP 32 /* amount to over allocate sg_dev_arr by */ | 105 | #define SG_DEV_ARR_LUMP 32 /* amount to over allocate sg_dev_arr by */ |
106 | 106 | ||
107 | static int sg_add(struct class_device *); | 107 | static int sg_add(struct class_device *, struct class_interface *); |
108 | static void sg_remove(struct class_device *); | 108 | static void sg_remove(struct class_device *, struct class_interface *); |
109 | 109 | ||
110 | static Scsi_Request *dummy_cmdp; /* only used for sizeof */ | 110 | static Scsi_Request *dummy_cmdp; /* only used for sizeof */ |
111 | 111 | ||
@@ -1506,7 +1506,7 @@ static int sg_alloc(struct gendisk *disk, struct scsi_device *scsidp) | |||
1506 | } | 1506 | } |
1507 | 1507 | ||
1508 | static int | 1508 | static int |
1509 | sg_add(struct class_device *cl_dev) | 1509 | sg_add(struct class_device *cl_dev, struct class_interface *cl_intf) |
1510 | { | 1510 | { |
1511 | struct scsi_device *scsidp = to_scsi_device(cl_dev->dev); | 1511 | struct scsi_device *scsidp = to_scsi_device(cl_dev->dev); |
1512 | struct gendisk *disk; | 1512 | struct gendisk *disk; |
@@ -1582,7 +1582,7 @@ out: | |||
1582 | } | 1582 | } |
1583 | 1583 | ||
1584 | static void | 1584 | static void |
1585 | sg_remove(struct class_device *cl_dev) | 1585 | sg_remove(struct class_device *cl_dev, struct class_interface *cl_intf) |
1586 | { | 1586 | { |
1587 | struct scsi_device *scsidp = to_scsi_device(cl_dev->dev); | 1587 | struct scsi_device *scsidp = to_scsi_device(cl_dev->dev); |
1588 | Sg_device *sdp = NULL; | 1588 | Sg_device *sdp = NULL; |