[media] ati_remote: parent input devices to usb interface
authorAnssi Hannula <anssi.hannula@iki.fi>
Sat, 6 Aug 2011 21:18:09 +0000 (18:18 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Thu, 22 Sep 2011 13:52:03 +0000 (10:52 -0300)
Parent the input devices to usb_interface instead of usb_device. This
fixes (at least) persistent input device nodes.

Signed-off-by: Anssi Hannula <anssi.hannula@iki.fi>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/rc/ati_remote.c

index 4b4509a6d9d5c756885cf45e4d7a07501cf6a850..7a47d7e73b57ddc88b523b347e6a77afb43ff1a8 100644 (file)
@@ -693,7 +693,7 @@ static void ati_remote_input_init(struct ati_remote *ati_remote)
        idev->phys = ati_remote->mouse_phys;
 
        usb_to_input_id(ati_remote->udev, &idev->id);
-       idev->dev.parent = &ati_remote->udev->dev;
+       idev->dev.parent = &ati_remote->interface->dev;
 }
 
 static void ati_remote_rc_init(struct ati_remote *ati_remote)
@@ -712,7 +712,7 @@ static void ati_remote_rc_init(struct ati_remote *ati_remote)
        rdev->input_phys = ati_remote->rc_phys;
 
        usb_to_input_id(ati_remote->udev, &rdev->input_id);
-       rdev->dev.parent = &ati_remote->udev->dev;
+       rdev->dev.parent = &ati_remote->interface->dev;
 
        rdev->map_name = RC_MAP_ATI_X10;
 }