diff options
author | Kay Sievers <kay.sievers@vrfy.org> | 2007-05-25 05:50:53 -0400 |
---|---|---|
committer | Stefan Richter <stefanr@s5r6.in-berlin.de> | 2007-07-09 18:07:39 -0400 |
commit | dd7f2928d834f7ac67202bcdf24a44ba9b138f08 (patch) | |
tree | c24379bfcc628c3f46b14105baa7885e592e856e /drivers/ieee1394/hosts.c | |
parent | 59337087cb33db58aa0d4463892b4475cf66a50b (diff) |
ieee1394: convert ieee1394 from "struct class_device" to "struct device"
Here is a straightforward conversion to "struct device". The "struct
class_device" will be removed from the kernel.
It seems to work fine for me with and without CONFIG_SYSFS_DEPRECATED
set.
Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
Diffstat (limited to 'drivers/ieee1394/hosts.c')
-rw-r--r-- | drivers/ieee1394/hosts.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/ieee1394/hosts.c b/drivers/ieee1394/hosts.c index bd0755c789c5..7ea64eec2270 100644 --- a/drivers/ieee1394/hosts.c +++ b/drivers/ieee1394/hosts.c | |||
@@ -156,13 +156,13 @@ struct hpsb_host *hpsb_alloc_host(struct hpsb_host_driver *drv, size_t extra, | |||
156 | h->device.parent = dev; | 156 | h->device.parent = dev; |
157 | snprintf(h->device.bus_id, BUS_ID_SIZE, "fw-host%d", h->id); | 157 | snprintf(h->device.bus_id, BUS_ID_SIZE, "fw-host%d", h->id); |
158 | 158 | ||
159 | h->class_dev.dev = &h->device; | 159 | h->host_dev.parent = &h->device; |
160 | h->class_dev.class = &hpsb_host_class; | 160 | h->host_dev.class = &hpsb_host_class; |
161 | snprintf(h->class_dev.class_id, BUS_ID_SIZE, "fw-host%d", h->id); | 161 | snprintf(h->host_dev.bus_id, BUS_ID_SIZE, "fw-host%d", h->id); |
162 | 162 | ||
163 | if (device_register(&h->device)) | 163 | if (device_register(&h->device)) |
164 | goto fail; | 164 | goto fail; |
165 | if (class_device_register(&h->class_dev)) { | 165 | if (device_register(&h->host_dev)) { |
166 | device_unregister(&h->device); | 166 | device_unregister(&h->device); |
167 | goto fail; | 167 | goto fail; |
168 | } | 168 | } |
@@ -202,7 +202,7 @@ void hpsb_remove_host(struct hpsb_host *host) | |||
202 | host->driver = &dummy_driver; | 202 | host->driver = &dummy_driver; |
203 | highlevel_remove_host(host); | 203 | highlevel_remove_host(host); |
204 | 204 | ||
205 | class_device_unregister(&host->class_dev); | 205 | device_unregister(&host->host_dev); |
206 | device_unregister(&host->device); | 206 | device_unregister(&host->device); |
207 | } | 207 | } |
208 | 208 | ||