diff options
Diffstat (limited to 'drivers/media/rc')
-rw-r--r-- | drivers/media/rc/ati_remote.c | 11 | ||||
-rw-r--r-- | drivers/media/rc/mceusb.c | 6 | ||||
-rw-r--r-- | drivers/media/rc/rc-main.c | 9 |
3 files changed, 16 insertions, 10 deletions
diff --git a/drivers/media/rc/ati_remote.c b/drivers/media/rc/ati_remote.c index 3f61d77d4147..9f5b59706741 100644 --- a/drivers/media/rc/ati_remote.c +++ b/drivers/media/rc/ati_remote.c @@ -873,13 +873,10 @@ static int ati_remote_probe(struct usb_interface *interface, strlcat(ati_remote->rc_phys, "/input0", sizeof(ati_remote->rc_phys)); strlcat(ati_remote->mouse_phys, "/input1", sizeof(ati_remote->mouse_phys)); - if (udev->manufacturer) - strlcpy(ati_remote->rc_name, udev->manufacturer, - sizeof(ati_remote->rc_name)); - - if (udev->product) - snprintf(ati_remote->rc_name, sizeof(ati_remote->rc_name), - "%s %s", ati_remote->rc_name, udev->product); + snprintf(ati_remote->rc_name, sizeof(ati_remote->rc_name), "%s%s%s", + udev->manufacturer ?: "", + udev->manufacturer && udev->product ? " " : "", + udev->product ?: ""); if (!strlen(ati_remote->rc_name)) snprintf(ati_remote->rc_name, sizeof(ati_remote->rc_name), diff --git a/drivers/media/rc/mceusb.c b/drivers/media/rc/mceusb.c index 35155ae500c7..5cf2e749b9eb 100644 --- a/drivers/media/rc/mceusb.c +++ b/drivers/media/rc/mceusb.c @@ -188,6 +188,7 @@ #define VENDOR_TWISTEDMELON 0x2596 #define VENDOR_HAUPPAUGE 0x2040 #define VENDOR_PCTV 0x2013 +#define VENDOR_ADAPTEC 0x03f3 enum mceusb_model_type { MCE_GEN2 = 0, /* Most boards */ @@ -302,6 +303,9 @@ static struct usb_device_id mceusb_dev_table[] = { /* SMK/I-O Data GV-MC7/RCKIT Receiver */ { USB_DEVICE(VENDOR_SMK, 0x0353), .driver_info = MCE_GEN2_NO_TX }, + /* SMK RXX6000 Infrared Receiver */ + { USB_DEVICE(VENDOR_SMK, 0x0357), + .driver_info = MCE_GEN2_NO_TX }, /* Tatung eHome Infrared Transceiver */ { USB_DEVICE(VENDOR_TATUNG, 0x9150) }, /* Shuttle eHome Infrared Transceiver */ @@ -405,6 +409,8 @@ static struct usb_device_id mceusb_dev_table[] = { .driver_info = HAUPPAUGE_CX_HYBRID_TV }, { USB_DEVICE(VENDOR_PCTV, 0x025e), .driver_info = HAUPPAUGE_CX_HYBRID_TV }, + /* Adaptec / HP eHome Receiver */ + { USB_DEVICE(VENDOR_ADAPTEC, 0x0094) }, /* Terminating entry */ { } diff --git a/drivers/media/rc/rc-main.c b/drivers/media/rc/rc-main.c index 4e9bbe735ae9..7dfc7c2188f0 100644 --- a/drivers/media/rc/rc-main.c +++ b/drivers/media/rc/rc-main.c @@ -1263,6 +1263,9 @@ unlock: static void rc_dev_release(struct device *device) { + struct rc_dev *dev = to_rc_dev(device); + + kfree(dev); } #define ADD_HOTPLUG_VAR(fmt, val...) \ @@ -1384,7 +1387,9 @@ void rc_free_device(struct rc_dev *dev) put_device(&dev->dev); - kfree(dev); + /* kfree(dev) will be called by the callback function + rc_dev_release() */ + module_put(THIS_MODULE); } EXPORT_SYMBOL_GPL(rc_free_device); @@ -1492,9 +1497,7 @@ int rc_register_device(struct rc_dev *dev) } /* Allow the RC sysfs nodes to be accessible */ - mutex_lock(&dev->lock); atomic_set(&dev->initialized, 1); - mutex_unlock(&dev->lock); IR_dprintk(1, "Registered rc%u (driver: %s, remote: %s, mode %s)\n", dev->minor, |