Lines Matching refs:wIndex
339 u16 wIndex, __le32 __iomem *addr, u32 port_status) in xhci_disable_port() argument
352 wIndex, port_status); in xhci_disable_port()
356 u16 wIndex, __le32 __iomem *addr, u32 port_status) in xhci_clear_port_change_bit() argument
402 port_change_bit, wIndex, port_status); in xhci_clear_port_change_bit()
541 u16 wIndex) in xhci_del_comp_mod_timer() argument
550 xhci->port_status_u0 |= 1 << wIndex; in xhci_del_comp_mod_timer()
574 u16 wIndex, u32 raw_port_status, in xhci_get_port_status() argument
620 bus_state->resume_done[wIndex])) { in xhci_get_port_status()
624 wIndex + 1); in xhci_get_port_status()
625 bus_state->resume_done[wIndex] = 0; in xhci_get_port_status()
626 clear_bit(wIndex, &bus_state->resuming_ports); in xhci_get_port_status()
628 set_bit(wIndex, &bus_state->rexit_ports); in xhci_get_port_status()
629 xhci_set_link_state(xhci, port_array, wIndex, in xhci_get_port_status()
634 &bus_state->rexit_done[wIndex], in xhci_get_port_status()
641 xhci, wIndex + 1); in xhci_get_port_status()
648 int port_status = readl(port_array[wIndex]); in xhci_get_port_status()
653 clear_bit(wIndex, &bus_state->rexit_ports); in xhci_get_port_status()
656 bus_state->port_c_suspend |= 1 << wIndex; in xhci_get_port_status()
657 bus_state->suspended_ports &= ~(1 << wIndex); in xhci_get_port_status()
670 && (bus_state->suspended_ports & (1 << wIndex))) { in xhci_get_port_status()
671 bus_state->suspended_ports &= ~(1 << wIndex); in xhci_get_port_status()
673 bus_state->port_c_suspend |= 1 << wIndex; in xhci_get_port_status()
698 xhci_del_comp_mod_timer(xhci, raw_port_status, wIndex); in xhci_get_port_status()
702 if (bus_state->port_c_suspend & (1 << wIndex)) in xhci_get_port_status()
709 u16 wIndex, char *buf, u16 wLength) in xhci_hub_control() argument
771 if (!wIndex || wIndex > max_ports) in xhci_hub_control()
773 wIndex--; in xhci_hub_control()
774 temp = readl(port_array[wIndex]); in xhci_hub_control()
780 wIndex, temp, flags); in xhci_hub_control()
785 wIndex, temp); in xhci_hub_control()
792 link_state = (wIndex & 0xff00) >> 3; in xhci_hub_control()
794 wake_mask = wIndex & 0xff00; in xhci_hub_control()
796 timeout = (wIndex & 0xff00) >> 8; in xhci_hub_control()
797 wIndex &= 0xff; in xhci_hub_control()
798 if (!wIndex || wIndex > max_ports) in xhci_hub_control()
800 wIndex--; in xhci_hub_control()
801 temp = readl(port_array[wIndex]); in xhci_hub_control()
810 temp = readl(port_array[wIndex]); in xhci_hub_control()
813 xhci_set_link_state(xhci, port_array, wIndex, in xhci_hub_control()
823 temp = readl(port_array[wIndex]); in xhci_hub_control()
832 wIndex + 1); in xhci_hub_control()
842 xhci_set_link_state(xhci, port_array, wIndex, XDEV_U3); in xhci_hub_control()
848 temp = readl(port_array[wIndex]); in xhci_hub_control()
849 bus_state->suspended_ports |= 1 << wIndex; in xhci_hub_control()
852 temp = readl(port_array[wIndex]); in xhci_hub_control()
856 xhci_dbg(xhci, "Disable port %d\n", wIndex); in xhci_hub_control()
865 writel(temp | PORT_PE, port_array[wIndex]); in xhci_hub_control()
866 temp = readl(port_array[wIndex]); in xhci_hub_control()
872 xhci_dbg(xhci, "Enable port %d\n", wIndex); in xhci_hub_control()
873 xhci_set_link_state(xhci, port_array, wIndex, in xhci_hub_control()
875 temp = readl(port_array[wIndex]); in xhci_hub_control()
891 wIndex + 1); in xhci_hub_control()
902 xhci_set_link_state(xhci, port_array, wIndex, in xhci_hub_control()
909 temp = readl(port_array[wIndex]); in xhci_hub_control()
911 bus_state->suspended_ports |= 1 << wIndex; in xhci_hub_control()
920 writel(temp | PORT_POWER, port_array[wIndex]); in xhci_hub_control()
922 temp = readl(port_array[wIndex]); in xhci_hub_control()
923 xhci_dbg(xhci, "set port power, actual port %d status = 0x%x\n", wIndex, temp); in xhci_hub_control()
927 wIndex); in xhci_hub_control()
930 wIndex, true); in xhci_hub_control()
935 writel(temp, port_array[wIndex]); in xhci_hub_control()
937 temp = readl(port_array[wIndex]); in xhci_hub_control()
938 xhci_dbg(xhci, "set port reset, actual port %d status = 0x%x\n", wIndex, temp); in xhci_hub_control()
942 wIndex, wake_mask); in xhci_hub_control()
943 temp = readl(port_array[wIndex]); in xhci_hub_control()
946 wIndex, temp); in xhci_hub_control()
950 writel(temp, port_array[wIndex]); in xhci_hub_control()
952 temp = readl(port_array[wIndex]); in xhci_hub_control()
957 temp = readl(port_array[wIndex] + PORTPMSC); in xhci_hub_control()
960 writel(temp, port_array[wIndex] + PORTPMSC); in xhci_hub_control()
965 temp = readl(port_array[wIndex] + PORTPMSC); in xhci_hub_control()
968 writel(temp, port_array[wIndex] + PORTPMSC); in xhci_hub_control()
974 temp = readl(port_array[wIndex]); in xhci_hub_control()
977 if (!wIndex || wIndex > max_ports) in xhci_hub_control()
979 wIndex--; in xhci_hub_control()
980 temp = readl(port_array[wIndex]); in xhci_hub_control()
989 temp = readl(port_array[wIndex]); in xhci_hub_control()
998 xhci_set_link_state(xhci, port_array, wIndex, in xhci_hub_control()
1003 xhci_set_link_state(xhci, port_array, wIndex, in xhci_hub_control()
1006 bus_state->port_c_suspend |= 1 << wIndex; in xhci_hub_control()
1009 wIndex + 1); in xhci_hub_control()
1017 bus_state->port_c_suspend &= ~(1 << wIndex); in xhci_hub_control()
1025 xhci_clear_port_change_bit(xhci, wValue, wIndex, in xhci_hub_control()
1026 port_array[wIndex], temp); in xhci_hub_control()
1029 xhci_disable_port(hcd, xhci, wIndex, in xhci_hub_control()
1030 port_array[wIndex], temp); in xhci_hub_control()
1033 writel(temp & ~PORT_POWER, port_array[wIndex]); in xhci_hub_control()
1037 wIndex); in xhci_hub_control()
1040 wIndex, false); in xhci_hub_control()