summaryrefslogtreecommitdiffstats
path: root/tools/usb
diff options
context:
space:
mode:
authorYuyang Du <yuyang.du@intel.com>2017-06-08 13:04:08 +0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2017-06-13 10:51:10 +0200
commitdff3565b8e1c0be6fc83ba47dcab45c149dcab5b (patch)
treeeecdc8e61cba37461c7711a55b7725620ec1a38e /tools/usb
parent89a73d281fa4f58942474ada19d34d7ea39af2f4 (diff)
downloadlinux-dff3565b8e1c0be6fc83ba47dcab45c149dcab5b.tar.gz
linux-dff3565b8e1c0be6fc83ba47dcab45c149dcab5b.tar.bz2
linux-dff3565b8e1c0be6fc83ba47dcab45c149dcab5b.zip
usbip: vhci-hcd: Rework vhci_hcd_init
A vhci struct is added as the platform-specific data to the vhci platform device, in order to get the vhci by its platform device. This is done in vhci_hcd_init(). Signed-off-by: Yuyang Du <yuyang.du@intel.com> Acked-by: Shuah Khan <shuahkh@osg.samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'tools/usb')
-rw-r--r--tools/usb/usbip/libsrc/vhci_driver.c2
-rw-r--r--tools/usb/usbip/libsrc/vhci_driver.h1
2 files changed, 2 insertions, 1 deletions
diff --git a/tools/usb/usbip/libsrc/vhci_driver.c b/tools/usb/usbip/libsrc/vhci_driver.c
index f519c73c6d99..3d8189b4f539 100644
--- a/tools/usb/usbip/libsrc/vhci_driver.c
+++ b/tools/usb/usbip/libsrc/vhci_driver.c
@@ -248,7 +248,7 @@ int usbip_vhci_driver_open(void)
vhci_driver->hc_device =
udev_device_new_from_subsystem_sysname(udev_context,
USBIP_VHCI_BUS_TYPE,
- USBIP_VHCI_DRV_NAME);
+ USBIP_VHCI_DEVICE_NAME);
if (!vhci_driver->hc_device) {
err("udev_device_new_from_subsystem_sysname failed");
goto err;
diff --git a/tools/usb/usbip/libsrc/vhci_driver.h b/tools/usb/usbip/libsrc/vhci_driver.h
index 33add142c46e..dfe19c1c0245 100644
--- a/tools/usb/usbip/libsrc/vhci_driver.h
+++ b/tools/usb/usbip/libsrc/vhci_driver.h
@@ -11,6 +11,7 @@
#include "usbip_common.h"
#define USBIP_VHCI_BUS_TYPE "platform"
+#define USBIP_VHCI_DEVICE_NAME "vhci_hcd.0"
#define MAXNPORT 128
struct usbip_imported_device {