Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 362192
b: refs/heads/master
c: 30b2953
h: refs/heads/master
v: v3
  • Loading branch information
Alexey Klimov authored and Jiri Kosina committed Mar 29, 2013
1 parent a26a372 commit 34028ed
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 5b4617d82020addf244c8c5206270e49ef9933d6
refs/heads/master: 30b29537bcba070b3df8d7d24c1975676a1a6a4f
11 changes: 11 additions & 0 deletions trunk/drivers/media/radio/radio-ma901.c
Original file line number Diff line number Diff line change
Expand Up @@ -347,9 +347,20 @@ static void usb_ma901radio_release(struct v4l2_device *v4l2_dev)
static int usb_ma901radio_probe(struct usb_interface *intf,
const struct usb_device_id *id)
{
struct usb_device *dev = interface_to_usbdev(intf);
struct ma901radio_device *radio;
int retval = 0;

/* Masterkit MA901 usb radio has the same USB ID as many others
* Atmel V-USB devices. Let's make additional checks to be sure
* that this is our device.
*/

if (dev->product && dev->manufacturer &&
(strncmp(dev->product, "MA901", 5) != 0
|| strncmp(dev->manufacturer, "www.masterkit.ru", 16) != 0))
return -ENODEV;

radio = kzalloc(sizeof(struct ma901radio_device), GFP_KERNEL);
if (!radio) {
dev_err(&intf->dev, "kzalloc for ma901radio_device failed\n");
Expand Down

0 comments on commit 34028ed

Please sign in to comment.