aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-05-04 18:33:11 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-05-04 18:33:11 -0400
commited2b2f2db2d52098bdda3877367d59984febdd9f (patch)
tree662cc19543a59cafd203f9223f96653b9fd9d395 /drivers/input
parent27c2597d455a24507f1d0be6991a0a84b5c1b035 (diff)
USB: input: kbtab.c: fix up dev_* messages
Previously I had made the struct device point to the input device, but after talking with Dmitry, he said that the USB device would make more sense for this driver to point to. So converted it to use that instead. CC: Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/input')
-rw-r--r--drivers/input/tablet/kbtab.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/drivers/input/tablet/kbtab.c b/drivers/input/tablet/kbtab.c
index a39d1761a6cb..3fba74b9b602 100644
--- a/drivers/input/tablet/kbtab.c
+++ b/drivers/input/tablet/kbtab.c
@@ -33,6 +33,7 @@ struct kbtab {
33 dma_addr_t data_dma; 33 dma_addr_t data_dma;
34 struct input_dev *dev; 34 struct input_dev *dev;
35 struct usb_device *usbdev; 35 struct usb_device *usbdev;
36 struct usb_interface *intf;
36 struct urb *irq; 37 struct urb *irq;
37 char phys[32]; 38 char phys[32];
38}; 39};
@@ -53,11 +54,13 @@ static void kbtab_irq(struct urb *urb)
53 case -ENOENT: 54 case -ENOENT:
54 case -ESHUTDOWN: 55 case -ESHUTDOWN:
55 /* this urb is terminated, clean up */ 56 /* this urb is terminated, clean up */
56 dev_dbg(&dev->dev, "%s - urb shutting down with status: %d\n", 57 dev_dbg(&kbtab->intf->dev,
58 "%s - urb shutting down with status: %d\n",
57 __func__, urb->status); 59 __func__, urb->status);
58 return; 60 return;
59 default: 61 default:
60 dev_dbg(&dev->dev, "%s - nonzero urb status received: %d\n", 62 dev_dbg(&kbtab->intf->dev,
63 "%s - nonzero urb status received: %d\n",
61 __func__, urb->status); 64 __func__, urb->status);
62 goto exit; 65 goto exit;
63 } 66 }
@@ -82,7 +85,7 @@ static void kbtab_irq(struct urb *urb)
82 exit: 85 exit:
83 retval = usb_submit_urb(urb, GFP_ATOMIC); 86 retval = usb_submit_urb(urb, GFP_ATOMIC);
84 if (retval) 87 if (retval)
85 dev_err(&dev->dev, 88 dev_err(&kbtab->intf->dev,
86 "%s - usb_submit_urb failed with result %d\n", 89 "%s - usb_submit_urb failed with result %d\n",
87 __func__, retval); 90 __func__, retval);
88} 91}
@@ -134,6 +137,7 @@ static int kbtab_probe(struct usb_interface *intf, const struct usb_device_id *i
134 goto fail2; 137 goto fail2;
135 138
136 kbtab->usbdev = dev; 139 kbtab->usbdev = dev;
140 kbtab->intf = intf;
137 kbtab->dev = input_dev; 141 kbtab->dev = input_dev;
138 142
139 usb_make_path(dev, kbtab->phys, sizeof(kbtab->phys)); 143 usb_make_path(dev, kbtab->phys, sizeof(kbtab->phys));