diff options
Diffstat (limited to 'drivers/media/video/bt8xx/bttv-gpio.c')
-rw-r--r-- | drivers/media/video/bt8xx/bttv-gpio.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/media/video/bt8xx/bttv-gpio.c b/drivers/media/video/bt8xx/bttv-gpio.c index dce6dae5740e..74c325e594a2 100644 --- a/drivers/media/video/bt8xx/bttv-gpio.c +++ b/drivers/media/video/bt8xx/bttv-gpio.c | |||
@@ -42,7 +42,7 @@ static int bttv_sub_bus_match(struct device *dev, struct device_driver *drv) | |||
42 | struct bttv_sub_driver *sub = to_bttv_sub_drv(drv); | 42 | struct bttv_sub_driver *sub = to_bttv_sub_drv(drv); |
43 | int len = strlen(sub->wanted); | 43 | int len = strlen(sub->wanted); |
44 | 44 | ||
45 | if (0 == strncmp(dev->bus_id, sub->wanted, len)) | 45 | if (0 == strncmp(dev_name(dev), sub->wanted, len)) |
46 | return 1; | 46 | return 1; |
47 | return 0; | 47 | return 0; |
48 | } | 48 | } |
@@ -91,15 +91,14 @@ int bttv_sub_add_device(struct bttv_core *core, char *name) | |||
91 | sub->dev.parent = &core->pci->dev; | 91 | sub->dev.parent = &core->pci->dev; |
92 | sub->dev.bus = &bttv_sub_bus_type; | 92 | sub->dev.bus = &bttv_sub_bus_type; |
93 | sub->dev.release = release_sub_device; | 93 | sub->dev.release = release_sub_device; |
94 | snprintf(sub->dev.bus_id,sizeof(sub->dev.bus_id),"%s%d", | 94 | dev_set_name(&sub->dev, "%s%d", name, core->nr); |
95 | name, core->nr); | ||
96 | 95 | ||
97 | err = device_register(&sub->dev); | 96 | err = device_register(&sub->dev); |
98 | if (0 != err) { | 97 | if (0 != err) { |
99 | kfree(sub); | 98 | kfree(sub); |
100 | return err; | 99 | return err; |
101 | } | 100 | } |
102 | printk("bttv%d: add subdevice \"%s\"\n", core->nr, sub->dev.bus_id); | 101 | printk("bttv%d: add subdevice \"%s\"\n", core->nr, dev_name(&sub->dev)); |
103 | list_add_tail(&sub->list,&core->subs); | 102 | list_add_tail(&sub->list,&core->subs); |
104 | return 0; | 103 | return 0; |
105 | } | 104 | } |