Commit 334698d435b4446d796a2059284256b9d28a0d19

Authored by Greg Kroah-Hartman
1 parent ab943ca894

USB: input: acecad.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>

Showing 1 changed file with 6 additions and 3 deletions Side-by-side Diff

drivers/input/tablet/acecad.c
... ... @@ -51,6 +51,7 @@
51 51 char name[128];
52 52 char phys[64];
53 53 struct usb_device *usbdev;
  54 + struct usb_interface *intf;
54 55 struct input_dev *input;
55 56 struct urb *irq;
56 57  
... ... @@ -63,6 +64,7 @@
63 64 struct usb_acecad *acecad = urb->context;
64 65 unsigned char *data = acecad->data;
65 66 struct input_dev *dev = acecad->input;
  67 + struct usb_interface *intf = acecad->intf;
66 68 int prox, status;
67 69  
68 70 switch (urb->status) {
69 71  
... ... @@ -73,11 +75,11 @@
73 75 case -ENOENT:
74 76 case -ESHUTDOWN:
75 77 /* this urb is terminated, clean up */
76   - dev_dbg(&dev->dev, "%s - urb shutting down with status: %d\n",
  78 + dev_dbg(&intf->dev, "%s - urb shutting down with status: %d\n",
77 79 __func__, urb->status);
78 80 return;
79 81 default:
80   - dev_dbg(&dev->dev, "%s - nonzero urb status received: %d\n",
  82 + dev_dbg(&intf->dev, "%s - nonzero urb status received: %d\n",
81 83 __func__, urb->status);
82 84 goto resubmit;
83 85 }
... ... @@ -107,7 +109,7 @@
107 109 resubmit:
108 110 status = usb_submit_urb(urb, GFP_ATOMIC);
109 111 if (status)
110   - dev_err(&dev->dev,
  112 + dev_err(&intf->dev,
111 113 "can't resubmit intr, %s-%s/input0, status %d\n",
112 114 acecad->usbdev->bus->bus_name,
113 115 acecad->usbdev->devpath, status);
... ... @@ -172,6 +174,7 @@
172 174 }
173 175  
174 176 acecad->usbdev = dev;
  177 + acecad->intf = intf;
175 178 acecad->input = input_dev;
176 179  
177 180 if (dev->manufacturer)