Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 303594
b: refs/heads/master
c: b883052
h: refs/heads/master
v: v3
  • Loading branch information
Greg Kroah-Hartman committed Apr 24, 2012
1 parent c80350b commit 6cf265e
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 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: 17122545d71e71ceb2da73ecdd05021f8e341c8b
refs/heads/master: b883052e0176d8c0c3b9375d19749c3897ad1bc2
13 changes: 7 additions & 6 deletions trunk/drivers/staging/media/lirc/lirc_ttusbir.c
Original file line number Diff line number Diff line change
Expand Up @@ -113,8 +113,9 @@ static int set_use_inc(void *data)
for (i = 0; i < num_urbs; i++) {
retval = usb_submit_urb(ttusbir->urb[i], GFP_KERNEL);
if (retval) {
err("%s: usb_submit_urb failed on urb %d",
__func__, i);
dev_err(&ttusbir->interf->dev,
"%s: usb_submit_urb failed on urb %d\n",
__func__, i);
return retval;
}
}
Expand Down Expand Up @@ -278,7 +279,7 @@ static int probe(struct usb_interface *intf, const struct usb_device_id *id)
if (ttusbir->alt_setting != -1)
DPRINTK("alt setting: %d\n", ttusbir->alt_setting);
else {
err("Could not find alternate setting\n");
dev_err(&intf->dev, "Could not find alternate setting\n");
kfree(ttusbir);
return -EINVAL;
}
Expand All @@ -291,7 +292,7 @@ static int probe(struct usb_interface *intf, const struct usb_device_id *id)

/* Register as a LIRC driver */
if (lirc_buffer_init(&ttusbir->rbuf, sizeof(int), 256) < 0) {
err("Could not get memory for LIRC data buffer\n");
dev_err(&intf->dev, "Could not get memory for LIRC data buffer\n");
usb_set_intfdata(intf, NULL);
kfree(ttusbir);
return -ENOMEM;
Expand All @@ -310,7 +311,7 @@ static int probe(struct usb_interface *intf, const struct usb_device_id *id)
ttusbir->driver.features = LIRC_CAN_REC_MODE2;
ttusbir->minor = lirc_register_driver(&ttusbir->driver);
if (ttusbir->minor < 0) {
err("Error registering as LIRC driver\n");
dev_err(&intf->dev, "Error registering as LIRC driver\n");
usb_set_intfdata(intf, NULL);
lirc_buffer_free(&ttusbir->rbuf);
kfree(ttusbir);
Expand All @@ -321,7 +322,7 @@ static int probe(struct usb_interface *intf, const struct usb_device_id *id)
for (i = 0; i < num_urbs; i++) {
ttusbir->urb[i] = usb_alloc_urb(8, GFP_KERNEL);
if (!ttusbir->urb[i]) {
err("Could not allocate memory for the URB\n");
dev_err(&intf->dev, "Could not allocate memory for the URB\n");
for (j = i - 1; j >= 0; j--)
kfree(ttusbir->urb[j]);
lirc_buffer_free(&ttusbir->rbuf);
Expand Down

0 comments on commit 6cf265e

Please sign in to comment.