Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

USB: input: xpad.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>
CC: "Magnus Hörlin" <magnus@alefors.se>
CC: Rusty Russell <rusty@rustcorp.com.au>
CC: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

+5 -3
+5 -3
drivers/input/joystick/xpad.c
··· 252 252 struct usb_xpad { 253 253 struct input_dev *dev; /* input device interface */ 254 254 struct usb_device *udev; /* usb device */ 255 + struct usb_interface *intf; /* usb interface */ 255 256 256 257 int pad_present; 257 258 ··· 458 457 static void xpad_irq_in(struct urb *urb) 459 458 { 460 459 struct usb_xpad *xpad = urb->context; 461 - struct device *dev = &xpad->dev->dev; 460 + struct device *dev = &xpad->intf->dev; 462 461 int retval, status; 463 462 464 463 status = urb->status; ··· 501 500 static void xpad_bulk_out(struct urb *urb) 502 501 { 503 502 struct usb_xpad *xpad = urb->context; 504 - struct device *dev = &xpad->dev->dev; 503 + struct device *dev = &xpad->intf->dev; 505 504 506 505 switch (urb->status) { 507 506 case 0: ··· 524 523 static void xpad_irq_out(struct urb *urb) 525 524 { 526 525 struct usb_xpad *xpad = urb->context; 527 - struct device *dev = &xpad->dev->dev; 526 + struct device *dev = &xpad->intf->dev; 528 527 int retval, status; 529 528 530 529 status = urb->status; ··· 856 855 } 857 856 858 857 xpad->udev = udev; 858 + xpad->intf = intf; 859 859 xpad->mapping = xpad_device[i].mapping; 860 860 xpad->xtype = xpad_device[i].xtype; 861 861