Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 124136
b: refs/heads/master
c: af128a1
h: refs/heads/master
v: v3
  • Loading branch information
Kay Sievers authored and Mauro Carvalho Chehab committed Dec 29, 2008
1 parent 9e66c38 commit a6bc5b6
Show file tree
Hide file tree
Showing 15 changed files with 25 additions and 27 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 9b2fb337a1423be53c671c4937fd4651cb30618e
refs/heads/master: af128a102c4aee994b4ff6e422b3cfab17127578
7 changes: 3 additions & 4 deletions trunk/drivers/media/video/bt8xx/bttv-gpio.c
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ static int bttv_sub_bus_match(struct device *dev, struct device_driver *drv)
struct bttv_sub_driver *sub = to_bttv_sub_drv(drv);
int len = strlen(sub->wanted);

if (0 == strncmp(dev->bus_id, sub->wanted, len))
if (0 == strncmp(dev_name(dev), sub->wanted, len))
return 1;
return 0;
}
Expand Down Expand Up @@ -91,15 +91,14 @@ int bttv_sub_add_device(struct bttv_core *core, char *name)
sub->dev.parent = &core->pci->dev;
sub->dev.bus = &bttv_sub_bus_type;
sub->dev.release = release_sub_device;
snprintf(sub->dev.bus_id,sizeof(sub->dev.bus_id),"%s%d",
name, core->nr);
dev_set_name(&sub->dev, "%s%d", name, core->nr);

err = device_register(&sub->dev);
if (0 != err) {
kfree(sub);
return err;
}
printk("bttv%d: add subdevice \"%s\"\n", core->nr, sub->dev.bus_id);
printk("bttv%d: add subdevice \"%s\"\n", core->nr, dev_name(&sub->dev));
list_add_tail(&sub->list,&core->subs);
return 0;
}
Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/media/video/bt8xx/bttv.h
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,7 @@ struct bttv_sub_device {

struct bttv_sub_driver {
struct device_driver drv;
char wanted[BUS_ID_SIZE];
char wanted[20];
int (*probe)(struct bttv_sub_device *sub);
void (*remove)(struct bttv_sub_device *sub);
};
Expand Down
4 changes: 2 additions & 2 deletions trunk/drivers/media/video/em28xx/em28xx-video.c
Original file line number Diff line number Diff line change
Expand Up @@ -1271,7 +1271,7 @@ static int vidioc_querycap(struct file *file, void *priv,

strlcpy(cap->driver, "em28xx", sizeof(cap->driver));
strlcpy(cap->card, em28xx_boards[dev->model].name, sizeof(cap->card));
strlcpy(cap->bus_info, dev->udev->dev.bus_id, sizeof(cap->bus_info));
strlcpy(cap->bus_info, dev_name(&dev->udev->dev), sizeof(cap->bus_info));

cap->version = EM28XX_VERSION_CODE;

Expand Down Expand Up @@ -1424,7 +1424,7 @@ static int radio_querycap(struct file *file, void *priv,

strlcpy(cap->driver, "em28xx", sizeof(cap->driver));
strlcpy(cap->card, em28xx_boards[dev->model].name, sizeof(cap->card));
strlcpy(cap->bus_info, dev->udev->dev.bus_id, sizeof(cap->bus_info));
strlcpy(cap->bus_info, dev_name(&dev->udev->dev), sizeof(cap->bus_info));

cap->version = EM28XX_VERSION_CODE;
cap->capabilities = V4L2_CAP_TUNER;
Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/media/video/et61x251/et61x251_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -1581,7 +1581,7 @@ et61x251_vidioc_querycap(struct et61x251_device* cam, void __user * arg)

strlcpy(cap.card, cam->v4ldev->name, sizeof(cap.card));
if (usb_make_path(cam->usbdev, cap.bus_info, sizeof(cap.bus_info)) < 0)
strlcpy(cap.bus_info, cam->usbdev->dev.bus_id,
strlcpy(cap.bus_info, dev_name(&cam->usbdev->dev),
sizeof(cap.bus_info));

if (copy_to_user(arg, &cap, sizeof(cap)))
Expand Down
6 changes: 3 additions & 3 deletions trunk/drivers/media/video/ir-kbd-i2c.c
Original file line number Diff line number Diff line change
Expand Up @@ -385,10 +385,10 @@ static int ir_attach(struct i2c_adapter *adap, int addr,
goto err_out_detach;
}

/* Phys addr can only be set after attaching (for ir->c.dev.bus_id) */
/* Phys addr can only be set after attaching (for ir->c.dev) */
snprintf(ir->phys, sizeof(ir->phys), "%s/%s/ir0",
ir->c.adapter->dev.bus_id,
ir->c.dev.bus_id);
dev_name(&ir->c.adapter->dev),
dev_name(&ir->c.dev));

/* init + register input device */
ir_input_init(input_dev, &ir->ir, ir_type, ir->ir_codes);
Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/media/video/pvrusb2/pvrusb2-hdw.c
Original file line number Diff line number Diff line change
Expand Up @@ -2395,7 +2395,7 @@ struct pvr2_hdw *pvr2_hdw_create(struct usb_interface *intf,

scnprintf(hdw->bus_info,sizeof(hdw->bus_info),
"usb %s address %d",
hdw->usb_dev->dev.bus_id,
dev_name(&hdw->usb_dev->dev),
hdw->usb_dev->devnum);

ifnum = hdw->usb_intf->cur_altsetting->desc.bInterfaceNumber;
Expand Down
4 changes: 2 additions & 2 deletions trunk/drivers/media/video/pvrusb2/pvrusb2-sysfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -628,10 +628,10 @@ static void class_dev_create(struct pvr2_sysfs *sfp,

class_dev->class = &class_ptr->class;
if (pvr2_hdw_get_sn(sfp->channel.hdw)) {
snprintf(class_dev->bus_id, BUS_ID_SIZE, "sn-%lu",
dev_set_name(class_dev, "sn-%lu",
pvr2_hdw_get_sn(sfp->channel.hdw));
} else if (pvr2_hdw_get_unit_number(sfp->channel.hdw) >= 0) {
snprintf(class_dev->bus_id, BUS_ID_SIZE, "unit-%c",
dev_set_name(class_dev, "unit-%c",
pvr2_hdw_get_unit_number(sfp->channel.hdw) + 'a');
} else {
kfree(class_dev);
Expand Down
6 changes: 3 additions & 3 deletions trunk/drivers/media/video/sh_mobile_ceu_camera.c
Original file line number Diff line number Diff line change
Expand Up @@ -616,7 +616,7 @@ static int sh_mobile_ceu_probe(struct platform_device *pdev)

/* request irq */
err = request_irq(pcdev->irq, sh_mobile_ceu_irq, IRQF_DISABLED,
pdev->dev.bus_id, pcdev);
dev_name(&pdev->dev), pcdev);
if (err) {
dev_err(&pdev->dev, "Unable to register CEU interrupt.\n");
goto exit_release_mem;
Expand All @@ -633,8 +633,8 @@ static int sh_mobile_ceu_probe(struct platform_device *pdev)
pcdev->ici.priv = pcdev;
pcdev->ici.dev.parent = &pdev->dev;
pcdev->ici.nr = pdev->id;
pcdev->ici.drv_name = pdev->dev.bus_id,
pcdev->ici.ops = &sh_mobile_ceu_host_ops,
pcdev->ici.drv_name = dev_name(&pdev->dev);
pcdev->ici.ops = &sh_mobile_ceu_host_ops;

err = soc_camera_host_register(&pcdev->ici);
if (err)
Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/media/video/sn9c102/sn9c102_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -2162,7 +2162,7 @@ sn9c102_vidioc_querycap(struct sn9c102_device* cam, void __user * arg)

strlcpy(cap.card, cam->v4ldev->name, sizeof(cap.card));
if (usb_make_path(cam->usbdev, cap.bus_info, sizeof(cap.bus_info)) < 0)
strlcpy(cap.bus_info, cam->usbdev->dev.bus_id,
strlcpy(cap.bus_info, dev_name(&cam->usbdev->dev),
sizeof(cap.bus_info));

if (copy_to_user(arg, &cap, sizeof(cap)))
Expand Down
5 changes: 2 additions & 3 deletions trunk/drivers/media/video/soc_camera.c
Original file line number Diff line number Diff line change
Expand Up @@ -783,7 +783,7 @@ int soc_camera_host_register(struct soc_camera_host *ici)
return -EINVAL;

/* Number might be equal to the platform device ID */
sprintf(ici->dev.bus_id, "camera_host%d", ici->nr);
dev_set_name(&ici->dev, "camera_host%d", ici->nr);

mutex_lock(&list_lock);
list_for_each_entry(ix, &hosts, list) {
Expand Down Expand Up @@ -867,8 +867,7 @@ int soc_camera_device_register(struct soc_camera_device *icd)

icd->devnum = num;
icd->dev.bus = &soc_camera_bus_type;
snprintf(icd->dev.bus_id, sizeof(icd->dev.bus_id),
"%u-%u", icd->iface, icd->devnum);
dev_set_name(&icd->dev, "%u-%u", icd->iface, icd->devnum);

icd->dev.release = dummy_release;

Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/media/video/usbvision/usbvision-video.c
Original file line number Diff line number Diff line change
Expand Up @@ -523,7 +523,7 @@ static int vidioc_querycap (struct file *file, void *priv,
strlcpy(vc->card,
usbvision_device_data[usbvision->DevModel].ModelString,
sizeof(vc->card));
strlcpy(vc->bus_info, usbvision->dev->dev.bus_id,
strlcpy(vc->bus_info, dev_name(&usbvision->dev->dev),
sizeof(vc->bus_info));
vc->version = USBVISION_DRIVER_VERSION;
vc->capabilities = V4L2_CAP_VIDEO_CAPTURE |
Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/media/video/v4l2-dev.c
Original file line number Diff line number Diff line change
Expand Up @@ -339,7 +339,7 @@ int video_register_device_index(struct video_device *vfd, int type, int nr,
vfd->dev.devt = MKDEV(VIDEO_MAJOR, vfd->minor);
if (vfd->parent)
vfd->dev.parent = vfd->parent;
sprintf(vfd->dev.bus_id, "%s%d", name_base, nr);
dev_set_name(&vfd->dev, "%s%d", name_base, nr);
ret = device_register(&vfd->dev);
if (ret < 0) {
printk(KERN_ERR "%s: device_register failed\n", __func__);
Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/media/video/zc0301/zc0301_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -1020,7 +1020,7 @@ zc0301_vidioc_querycap(struct zc0301_device* cam, void __user * arg)

strlcpy(cap.card, cam->v4ldev->name, sizeof(cap.card));
if (usb_make_path(cam->usbdev, cap.bus_info, sizeof(cap.bus_info)) < 0)
strlcpy(cap.bus_info, cam->usbdev->dev.bus_id,
strlcpy(cap.bus_info, dev_name(&cam->usbdev->dev),
sizeof(cap.bus_info));

if (copy_to_user(arg, &cap, sizeof(cap)))
Expand Down
4 changes: 2 additions & 2 deletions trunk/include/media/soc_camera.h
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ struct soc_camera_host {
struct device dev;
unsigned char nr; /* Host number */
void *priv;
char *drv_name;
const char *drv_name;
struct soc_camera_host_ops *ops;
};

Expand Down Expand Up @@ -107,7 +107,7 @@ extern int soc_camera_video_start(struct soc_camera_device *icd);
extern void soc_camera_video_stop(struct soc_camera_device *icd);

struct soc_camera_data_format {
char *name;
const char *name;
unsigned int depth;
__u32 fourcc;
enum v4l2_colorspace colorspace;
Expand Down

0 comments on commit a6bc5b6

Please sign in to comment.