aboutsummaryrefslogtreecommitdiff
path: root/lib/libusb/libusb20.c
diff options
context:
space:
mode:
authorHans Petter Selasky <hselasky@FreeBSD.org>2013-05-03 07:44:58 +0000
committerHans Petter Selasky <hselasky@FreeBSD.org>2013-05-03 07:44:58 +0000
commitc77a24c24a844f32150345c9967c026a5a50da4c (patch)
treebae81f1e85342c7dae2df723f345aafb486ea339 /lib/libusb/libusb20.c
parent3b48e348d5c2e70f071a75e37edac8c5eba8d478 (diff)
downloadsrc-c77a24c24a844f32150345c9967c026a5a50da4c.tar.gz
src-c77a24c24a844f32150345c9967c026a5a50da4c.zip
Add new USB API to get the port path of a USB device.
MFC after: 2 weeks Requested by: emaste @
Notes
Notes: svn path=/head/; revision=250201
Diffstat (limited to 'lib/libusb/libusb20.c')
-rw-r--r--lib/libusb/libusb20.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/libusb/libusb20.c b/lib/libusb/libusb20.c
index 644eda4f5498..ed332a6a93c1 100644
--- a/lib/libusb/libusb20.c
+++ b/lib/libusb/libusb20.c
@@ -75,6 +75,7 @@ dummy_callback(struct libusb20_transfer *xfer)
#define dummy_check_connected (void *)dummy_int
#define dummy_set_power_mode (void *)dummy_int
#define dummy_get_power_mode (void *)dummy_int
+#define dummy_get_port_path (void *)dummy_int
#define dummy_get_power_usage (void *)dummy_int
#define dummy_kernel_driver_active (void *)dummy_int
#define dummy_detach_kernel_driver (void *)dummy_int
@@ -722,6 +723,12 @@ libusb20_dev_get_power_mode(struct libusb20_device *pdev)
return (power_mode);
}
+int
+libusb20_dev_get_port_path(struct libusb20_device *pdev, uint8_t *buf, uint8_t bufsize)
+{
+ return (pdev->methods->get_port_path(pdev, buf, bufsize));
+}
+
uint16_t
libusb20_dev_get_power_usage(struct libusb20_device *pdev)
{