diff options
author | Mathias Nyman <mathias.nyman@linux.intel.com> | 2013-05-23 17:14:29 +0300 |
---|---|---|
committer | Sarah Sharp <sarah.a.sharp@linux.intel.com> | 2013-06-05 16:47:21 -0700 |
commit | b6e76371c888f5cb677f190a28444ac8875359ad (patch) | |
tree | 99112834cb69e1c6c7d0e933fb19a7235d029d2c /drivers/usb/host/xhci.c | |
parent | b630d4b9d05ba2e66878ca4614946d0f950d4111 (diff) | |
download | lwn-b6e76371c888f5cb677f190a28444ac8875359ad.tar.gz lwn-b6e76371c888f5cb677f190a28444ac8875359ad.zip |
usb: xhci: define port register names and use them instead of magic numbers
Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com>
Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
Diffstat (limited to 'drivers/usb/host/xhci.c')
-rw-r--r-- | drivers/usb/host/xhci.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/usb/host/xhci.c b/drivers/usb/host/xhci.c index df5e881e3bc5..31ce422af00a 100644 --- a/drivers/usb/host/xhci.c +++ b/drivers/usb/host/xhci.c @@ -3911,7 +3911,7 @@ static int xhci_usb2_software_lpm_test(struct usb_hcd *hcd, * Check device's USB 2.0 extension descriptor to determine whether * HIRD or BESL shoule be used. See USB2.0 LPM errata. */ - pm_addr = port_array[port_num] + 1; + pm_addr = port_array[port_num] + PORTPMSC; hird = xhci_calculate_hird_besl(xhci, udev); temp = PORT_L1DS(udev->slot_id) | PORT_HIRD(hird); xhci_writel(xhci, temp, pm_addr); @@ -4009,7 +4009,7 @@ int xhci_set_usb2_hardware_lpm(struct usb_hcd *hcd, port_array = xhci->usb2_ports; port_num = udev->portnum - 1; - pm_addr = port_array[port_num] + 1; + pm_addr = port_array[port_num] + PORTPMSC; temp = xhci_readl(xhci, pm_addr); xhci_dbg(xhci, "%s port %d USB2 hardware LPM\n", |