summaryrefslogtreecommitdiffstats
path: root/sys/dev/usb2/core/usb2_hub.c
diff options
context:
space:
mode:
authorthompsa <thompsa@FreeBSD.org>2009-01-13 19:03:12 +0000
committerthompsa <thompsa@FreeBSD.org>2009-01-13 19:03:12 +0000
commit4a6646160afda48ebd262b9548fc477b9629a141 (patch)
tree519a4c63c1a67b3734b84daa7d5a69bd66415caa /sys/dev/usb2/core/usb2_hub.c
parent1263247651c133a3702a35f9c27c6e1b72dca6cf (diff)
downloadFreeBSD-src-4a6646160afda48ebd262b9548fc477b9629a141.zip
FreeBSD-src-4a6646160afda48ebd262b9548fc477b9629a141.tar.gz
MFp4: //depot/projects/usb@155839
This change is about removing three fields from "struct usb2_xfer" which can be reached from "struct usb2_xfer_root" instead and cleaning up the code after this change. The fields are "xfer->udev", "xfer->xfer_mtx" and "xfer->usb2_sc". In this process the following changes were also made: Rename "usb2_root" to "xroot" which is short for "xfer root". Rename "priv_mtx" to "xfer_mtx" in USB core. The USB_XFER_LOCK and USB_XFER_UNLOCK macros should only be used in the USB core due to dependency towards "xroot". Substitute macros for the real lock in two USB device drivers. Submitted by: Hans Petter Selasky
Diffstat (limited to 'sys/dev/usb2/core/usb2_hub.c')
-rw-r--r--sys/dev/usb2/core/usb2_hub.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/dev/usb2/core/usb2_hub.c b/sys/dev/usb2/core/usb2_hub.c
index e5c9c8d..cbc1763 100644
--- a/sys/dev/usb2/core/usb2_hub.c
+++ b/sys/dev/usb2/core/usb2_hub.c
@@ -1429,7 +1429,7 @@ usb2_transfer_power_ref(struct usb2_xfer *xfer, int val)
uint8_t needs_hw_power;
uint8_t xfer_type;
- udev = xfer->udev;
+ udev = xfer->xroot->udev;
if (udev->device_index == USB_ROOT_HUB_ADDR) {
/* no power save for root HUB */
OpenPOWER on IntegriCloud