Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

USB: Remove remnants of Wireless USB and UWB

Wireless USB has long been defunct, and kernel support for it was
removed in 2020 by commit caa6772db4c1 ("Staging: remove wusbcore and
UWB from the kernel tree.").

Nevertheless, some vestiges of the old implementation still clutter up
the USB subsystem and one or two other places. Let's get rid of them
once and for all.

The only parts still left are the user-facing APIs in
include/uapi/linux/usb/ch9.h. (There are also a couple of misleading
instances, such as the Sierra Wireless USB modem, which is a USB modem
made by Sierra Wireless.)

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Link: https://lore.kernel.org/r/b4f2710f-a2de-4fb0-b50f-76776f3a961b@rowland.harvard.edu
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Alan Stern and committed by
Greg Kroah-Hartman
1e4c5742 12e6ac69

+63 -249
+1 -2
drivers/net/wireless/mediatek/mt76/usb.c
··· 286 286 struct usb_device *udev = interface_to_usbdev(uintf); 287 287 288 288 return (!disable_usb_sg && udev->bus->sg_tablesize > 0 && 289 - (udev->bus->no_sg_constraint || 290 - udev->speed == USB_SPEED_WIRELESS)); 289 + udev->bus->no_sg_constraint); 291 290 } 292 291 293 292 static int
-3
drivers/usb/core/config.c
··· 1051 1051 } 1052 1052 1053 1053 switch (cap_type) { 1054 - case USB_CAP_TYPE_WIRELESS_USB: 1055 - /* Wireless USB cap descriptor is handled by wusb */ 1056 - break; 1057 1054 case USB_CAP_TYPE_EXT: 1058 1055 dev->bos->ext_cap = 1059 1056 (struct usb_ext_cap_descriptor *)buffer;
-1
drivers/usb/core/devices.c
··· 424 424 case USB_SPEED_UNKNOWN: /* usb 1.1 root hub code */ 425 425 case USB_SPEED_FULL: 426 426 speed = "12"; break; 427 - case USB_SPEED_WIRELESS: /* Wireless has no real fixed speed */ 428 427 case USB_SPEED_HIGH: 429 428 speed = "480"; break; 430 429 case USB_SPEED_SUPER:
+4 -36
drivers/usb/core/hcd.c
··· 156 156 0x01 /* __u8 bNumConfigurations; */ 157 157 }; 158 158 159 - /* usb 2.5 (wireless USB 1.0) root hub device descriptor */ 160 - static const u8 usb25_rh_dev_descriptor[18] = { 161 - 0x12, /* __u8 bLength; */ 162 - USB_DT_DEVICE, /* __u8 bDescriptorType; Device */ 163 - 0x50, 0x02, /* __le16 bcdUSB; v2.5 */ 164 - 165 - 0x09, /* __u8 bDeviceClass; HUB_CLASSCODE */ 166 - 0x00, /* __u8 bDeviceSubClass; */ 167 - 0x00, /* __u8 bDeviceProtocol; [ usb 2.0 no TT ] */ 168 - 0xFF, /* __u8 bMaxPacketSize0; always 0xFF (WUSB Spec 7.4.1). */ 169 - 170 - 0x6b, 0x1d, /* __le16 idVendor; Linux Foundation 0x1d6b */ 171 - 0x02, 0x00, /* __le16 idProduct; device 0x0002 */ 172 - KERNEL_VER, KERNEL_REL, /* __le16 bcdDevice */ 173 - 174 - 0x03, /* __u8 iManufacturer; */ 175 - 0x02, /* __u8 iProduct; */ 176 - 0x01, /* __u8 iSerialNumber; */ 177 - 0x01 /* __u8 bNumConfigurations; */ 178 - }; 179 - 180 159 /* usb 2.0 root hub device descriptor */ 181 160 static const u8 usb2_rh_dev_descriptor[18] = { 182 161 0x12, /* __u8 bLength; */ ··· 347 368 }; 348 369 349 370 /* authorized_default behaviour: 350 - * -1 is authorized for all devices except wireless (old behaviour) 371 + * -1 is authorized for all devices (leftover from wireless USB) 351 372 * 0 is unauthorized for all devices 352 373 * 1 is authorized for all devices 353 374 * 2 is authorized for internal devices ··· 362 383 MODULE_PARM_DESC(authorized_default, 363 384 "Default USB device authorization: 0 is not authorized, 1 is " 364 385 "authorized, 2 is authorized for internal devices, -1 is " 365 - "authorized except for wireless USB (default, old behaviour)"); 386 + "authorized (default, same as 1)"); 366 387 /*-------------------------------------------------------------------------*/ 367 388 368 389 /** ··· 557 578 case HCD_USB3: 558 579 bufp = usb3_rh_dev_descriptor; 559 580 break; 560 - case HCD_USB25: 561 - bufp = usb25_rh_dev_descriptor; 562 - break; 563 581 case HCD_USB2: 564 582 bufp = usb2_rh_dev_descriptor; 565 583 break; ··· 578 602 bufp = ss_rh_config_descriptor; 579 603 len = sizeof ss_rh_config_descriptor; 580 604 break; 581 - case HCD_USB25: 582 605 case HCD_USB2: 583 606 bufp = hs_rh_config_descriptor; 584 607 len = sizeof hs_rh_config_descriptor; ··· 2823 2848 hcd->dev_policy = USB_DEVICE_AUTHORIZE_NONE; 2824 2849 break; 2825 2850 2826 - case USB_AUTHORIZE_ALL: 2827 - hcd->dev_policy = USB_DEVICE_AUTHORIZE_ALL; 2828 - break; 2829 - 2830 2851 case USB_AUTHORIZE_INTERNAL: 2831 2852 hcd->dev_policy = USB_DEVICE_AUTHORIZE_INTERNAL; 2832 2853 break; 2833 2854 2855 + case USB_AUTHORIZE_ALL: 2834 2856 case USB_AUTHORIZE_WIRED: 2835 2857 default: 2836 - hcd->dev_policy = hcd->wireless ? 2837 - USB_DEVICE_AUTHORIZE_NONE : USB_DEVICE_AUTHORIZE_ALL; 2858 + hcd->dev_policy = USB_DEVICE_AUTHORIZE_ALL; 2838 2859 break; 2839 2860 } 2840 2861 ··· 2873 2902 break; 2874 2903 case HCD_USB2: 2875 2904 rhdev->speed = USB_SPEED_HIGH; 2876 - break; 2877 - case HCD_USB25: 2878 - rhdev->speed = USB_SPEED_WIRELESS; 2879 2905 break; 2880 2906 case HCD_USB3: 2881 2907 rhdev->speed = USB_SPEED_SUPER;
+46 -111
drivers/usb/core/hub.c
··· 2140 2140 * USB-3.0 buses the address is assigned by the controller hardware 2141 2141 * and it usually is not the same as the device number. 2142 2142 * 2143 - * WUSB devices are simple: they have no hubs behind, so the mapping 2144 - * device <-> virtual port number becomes 1:1. Why? to simplify the 2145 - * life of the device connection logic in 2146 - * drivers/usb/wusbcore/devconnect.c. When we do the initial secret 2147 - * handshake we need to assign a temporary address in the unauthorized 2148 - * space. For simplicity we use the first virtual port number found to 2149 - * be free [drivers/usb/wusbcore/devconnect.c:wusbhc_devconnect_ack()] 2150 - * and that becomes it's address [X < 128] or its unauthorized address 2151 - * [X | 0x80]. 2152 - * 2153 - * We add 1 as an offset to the one-based USB-stack port number 2154 - * (zero-based wusb virtual port index) for two reasons: (a) dev addr 2155 - * 0 is reserved by USB for default address; (b) Linux's USB stack 2156 - * uses always #1 for the root hub of the controller. So USB stack's 2157 - * port #1, which is wusb virtual-port #0 has address #2. 2158 - * 2159 2143 * Devices connected under xHCI are not as simple. The host controller 2160 2144 * supports virtualization, so the hardware assigns device addresses and 2161 2145 * the HCD must setup data structures before issuing a set address ··· 2152 2168 2153 2169 /* be safe when more hub events are proceed in parallel */ 2154 2170 mutex_lock(&bus->devnum_next_mutex); 2155 - if (udev->wusb) { 2156 - devnum = udev->portnum + 1; 2157 - BUG_ON(test_bit(devnum, bus->devmap.devicemap)); 2158 - } else { 2159 - /* Try to allocate the next devnum beginning at 2160 - * bus->devnum_next. */ 2161 - devnum = find_next_zero_bit(bus->devmap.devicemap, 128, 2162 - bus->devnum_next); 2163 - if (devnum >= 128) 2164 - devnum = find_next_zero_bit(bus->devmap.devicemap, 2165 - 128, 1); 2166 - bus->devnum_next = (devnum >= 127 ? 1 : devnum + 1); 2167 - } 2171 + 2172 + /* Try to allocate the next devnum beginning at bus->devnum_next. */ 2173 + devnum = find_next_zero_bit(bus->devmap.devicemap, 128, 2174 + bus->devnum_next); 2175 + if (devnum >= 128) 2176 + devnum = find_next_zero_bit(bus->devmap.devicemap, 128, 1); 2177 + bus->devnum_next = (devnum >= 127 ? 1 : devnum + 1); 2168 2178 if (devnum < 128) { 2169 2179 set_bit(devnum, bus->devmap.devicemap); 2170 2180 udev->devnum = devnum; ··· 2176 2198 2177 2199 static void update_devnum(struct usb_device *udev, int devnum) 2178 2200 { 2179 - /* The address for a WUSB device is managed by wusbcore. */ 2180 - if (!udev->wusb) 2181 - udev->devnum = devnum; 2201 + udev->devnum = devnum; 2182 2202 if (!udev->devaddr) 2183 2203 udev->devaddr = (u8)devnum; 2184 2204 } ··· 2669 2693 goto error_autoresume; 2670 2694 } 2671 2695 2672 - if (usb_dev->wusb) { 2673 - struct usb_device_descriptor *descr; 2674 - 2675 - descr = usb_get_device_descriptor(usb_dev); 2676 - if (IS_ERR(descr)) { 2677 - result = PTR_ERR(descr); 2678 - dev_err(&usb_dev->dev, "can't re-read device descriptor for " 2679 - "authorization: %d\n", result); 2680 - goto error_device_descriptor; 2681 - } 2682 - usb_dev->descriptor = *descr; 2683 - kfree(descr); 2684 - } 2685 - 2686 2696 usb_dev->authorized = 1; 2687 2697 /* Choose and set the configuration. This registers the interfaces 2688 2698 * with the driver core and lets interface drivers bind to them. ··· 2685 2723 } 2686 2724 dev_info(&usb_dev->dev, "authorized to connect\n"); 2687 2725 2688 - error_device_descriptor: 2689 2726 usb_autosuspend_device(usb_dev); 2690 2727 error_autoresume: 2691 2728 out_authorized: ··· 2766 2805 out: 2767 2806 return USB_SSP_GEN_UNKNOWN; 2768 2807 } 2769 - 2770 - /* Returns 1 if @hub is a WUSB root hub, 0 otherwise */ 2771 - static unsigned hub_is_wusb(struct usb_hub *hub) 2772 - { 2773 - struct usb_hcd *hcd; 2774 - if (hub->hdev->parent != NULL) /* not a root hub? */ 2775 - return 0; 2776 - hcd = bus_to_hcd(hub->hdev->bus); 2777 - return hcd->wireless; 2778 - } 2779 - 2780 2808 2781 2809 #ifdef CONFIG_USB_FEW_INIT_RETRIES 2782 2810 #define PORT_RESET_TRIES 2 ··· 2919 2969 udev->tx_lanes = 1; 2920 2970 udev->ssp_rate = USB_SSP_GEN_UNKNOWN; 2921 2971 } 2922 - if (hub_is_wusb(hub)) 2923 - udev->speed = USB_SPEED_WIRELESS; 2924 - else if (udev->ssp_rate != USB_SSP_GEN_UNKNOWN) 2972 + if (udev->ssp_rate != USB_SSP_GEN_UNKNOWN) 2925 2973 udev->speed = USB_SPEED_SUPER_PLUS; 2926 2974 else if (hub_is_superspeed(hub->hdev)) 2927 2975 udev->speed = USB_SPEED_SUPER; ··· 4828 4880 if (initial) { 4829 4881 /* USB 2.0 section 5.5.3 talks about ep0 maxpacket ... 4830 4882 * it's fixed size except for full speed devices. 4831 - * For Wireless USB devices, ep0 max packet is always 512 (tho 4832 - * reported as 0xff in the device descriptor). WUSB1.0[4.8.1]. 4833 4883 */ 4834 4884 switch (udev->speed) { 4835 4885 case USB_SPEED_SUPER_PLUS: 4836 4886 case USB_SPEED_SUPER: 4837 - case USB_SPEED_WIRELESS: /* fixed at 512 */ 4838 4887 udev->ep0.desc.wMaxPacketSize = cpu_to_le16(512); 4839 4888 break; 4840 4889 case USB_SPEED_HIGH: /* fixed at 64 */ ··· 4852 4907 } 4853 4908 } 4854 4909 4855 - if (udev->speed == USB_SPEED_WIRELESS) 4856 - speed = "variable speed Wireless"; 4857 - else 4858 - speed = usb_speed_string(udev->speed); 4910 + speed = usb_speed_string(udev->speed); 4859 4911 4860 4912 /* 4861 4913 * The controller driver may be NULL if the controller device ··· 4945 5003 } 4946 5004 } 4947 5005 4948 - /* 4949 - * If device is WUSB, we already assigned an 4950 - * unauthorized address in the Connect Ack sequence; 4951 - * authorization will assign the final address. 4952 - */ 4953 - if (udev->wusb == 0) { 4954 - for (operations = 0; operations < SET_ADDRESS_TRIES; ++operations) { 4955 - retval = hub_set_address(udev, devnum); 4956 - if (retval >= 0) 4957 - break; 4958 - msleep(200); 4959 - } 4960 - if (retval < 0) { 4961 - if (retval != -ENODEV) 4962 - dev_err(&udev->dev, "device not accepting address %d, error %d\n", 4963 - devnum, retval); 4964 - goto fail; 4965 - } 4966 - if (udev->speed >= USB_SPEED_SUPER) { 4967 - devnum = udev->devnum; 4968 - dev_info(&udev->dev, 4969 - "%s SuperSpeed%s%s USB device number %d using %s\n", 4970 - (udev->config) ? "reset" : "new", 4971 - (udev->speed == USB_SPEED_SUPER_PLUS) ? 4972 - " Plus" : "", 4973 - (udev->ssp_rate == USB_SSP_GEN_2x2) ? 4974 - " Gen 2x2" : 4975 - (udev->ssp_rate == USB_SSP_GEN_2x1) ? 4976 - " Gen 2x1" : 4977 - (udev->ssp_rate == USB_SSP_GEN_1x2) ? 4978 - " Gen 1x2" : "", 4979 - devnum, driver_name); 4980 - } 4981 - 4982 - /* cope with hardware quirkiness: 4983 - * - let SET_ADDRESS settle, some device hardware wants it 4984 - * - read ep0 maxpacket even for high and low speed, 4985 - */ 4986 - msleep(10); 4987 - if (do_new_scheme) 5006 + for (operations = 0; operations < SET_ADDRESS_TRIES; ++operations) { 5007 + retval = hub_set_address(udev, devnum); 5008 + if (retval >= 0) 4988 5009 break; 5010 + msleep(200); 5011 + } 5012 + if (retval < 0) { 5013 + if (retval != -ENODEV) 5014 + dev_err(&udev->dev, "device not accepting address %d, error %d\n", 5015 + devnum, retval); 5016 + goto fail; 5017 + } 5018 + if (udev->speed >= USB_SPEED_SUPER) { 5019 + devnum = udev->devnum; 5020 + dev_info(&udev->dev, 5021 + "%s SuperSpeed%s%s USB device number %d using %s\n", 5022 + (udev->config) ? "reset" : "new", 5023 + (udev->speed == USB_SPEED_SUPER_PLUS) ? 5024 + " Plus" : "", 5025 + (udev->ssp_rate == USB_SSP_GEN_2x2) ? 5026 + " Gen 2x2" : 5027 + (udev->ssp_rate == USB_SSP_GEN_2x1) ? 5028 + " Gen 2x1" : 5029 + (udev->ssp_rate == USB_SSP_GEN_1x2) ? 5030 + " Gen 1x2" : "", 5031 + devnum, driver_name); 4989 5032 } 4990 5033 4991 - /* !do_new_scheme || wusb */ 5034 + /* 5035 + * cope with hardware quirkiness: 5036 + * - let SET_ADDRESS settle, some device hardware wants it 5037 + * - read ep0 maxpacket even for high and low speed, 5038 + */ 5039 + msleep(10); 5040 + 5041 + if (do_new_scheme) 5042 + break; 5043 + 4992 5044 maxp0 = get_bMaxPacketSize0(udev, buf, 8, retries == 0); 4993 5045 if (maxp0 < 0) { 4994 5046 retval = maxp0; ··· 5064 5128 5065 5129 usb_detect_quirks(udev); 5066 5130 5067 - if (udev->wusb == 0 && le16_to_cpu(udev->descriptor.bcdUSB) >= 0x0201) { 5131 + if (le16_to_cpu(udev->descriptor.bcdUSB) >= 0x0201) { 5068 5132 retval = usb_get_bos_descriptor(udev); 5069 5133 if (!retval) { 5070 5134 udev->lpm_capable = usb_device_supports_lpm(udev); ··· 5340 5404 usb_set_device_state(udev, USB_STATE_POWERED); 5341 5405 udev->bus_mA = hub->mA_per_port; 5342 5406 udev->level = hdev->level + 1; 5343 - udev->wusb = hub_is_wusb(hub); 5344 5407 5345 5408 /* Devices connected to SuperSpeed hubs are USB 3.0 or later */ 5346 5409 if (hub_is_superspeed(hub->hdev))
-3
drivers/usb/core/sysfs.c
··· 161 161 case USB_SPEED_HIGH: 162 162 speed = "480"; 163 163 break; 164 - case USB_SPEED_WIRELESS: 165 - speed = "480"; 166 - break; 167 164 case USB_SPEED_SUPER: 168 165 speed = "5000"; 169 166 break;
+6 -21
drivers/usb/core/urb.c
··· 480 480 urb->iso_frame_desc[n].status = -EXDEV; 481 481 urb->iso_frame_desc[n].actual_length = 0; 482 482 } 483 - } else if (urb->num_sgs && !urb->dev->bus->no_sg_constraint && 484 - dev->speed != USB_SPEED_WIRELESS) { 483 + } else if (urb->num_sgs && !urb->dev->bus->no_sg_constraint) { 485 484 struct scatterlist *sg; 486 485 int i; 487 486 ··· 539 540 case USB_ENDPOINT_XFER_ISOC: 540 541 case USB_ENDPOINT_XFER_INT: 541 542 /* too small? */ 542 - switch (dev->speed) { 543 - case USB_SPEED_WIRELESS: 544 - if ((urb->interval < 6) 545 - && (xfertype == USB_ENDPOINT_XFER_INT)) 546 - return -EINVAL; 547 - fallthrough; 548 - default: 549 - if (urb->interval <= 0) 550 - return -EINVAL; 551 - break; 552 - } 543 + if (urb->interval <= 0) 544 + return -EINVAL; 545 + 553 546 /* too big? */ 554 547 switch (dev->speed) { 555 548 case USB_SPEED_SUPER_PLUS: ··· 550 559 if (urb->interval > (1 << 15)) 551 560 return -EINVAL; 552 561 max = 1 << 15; 553 - break; 554 - case USB_SPEED_WIRELESS: 555 - if (urb->interval > 16) 556 - return -EINVAL; 557 562 break; 558 563 case USB_SPEED_HIGH: /* units are microframes */ 559 564 /* NOTE usb handles 2^15 */ ··· 574 587 default: 575 588 return -EINVAL; 576 589 } 577 - if (dev->speed != USB_SPEED_WIRELESS) { 578 - /* Round down to a power of 2, no more than max */ 579 - urb->interval = min(max, 1 << ilog2(urb->interval)); 580 - } 590 + /* Round down to a power of 2, no more than max */ 591 + urb->interval = min(max, 1 << ilog2(urb->interval)); 581 592 } 582 593 583 594 return usb_hcd_submit_urb(urb, mem_flags);
-11
drivers/usb/core/usb.c
··· 602 602 #endif 603 603 }; 604 604 605 - 606 - /* Returns 1 if @usb_bus is WUSB, 0 otherwise */ 607 - static unsigned usb_bus_is_wusb(struct usb_bus *bus) 608 - { 609 - struct usb_hcd *hcd = bus_to_hcd(bus); 610 - return hcd->wireless; 611 - } 612 - 613 605 static bool usb_dev_authorized(struct usb_device *dev, struct usb_hcd *hcd) 614 606 { 615 607 struct usb_hub *hub; ··· 741 749 #endif 742 750 743 751 dev->authorized = usb_dev_authorized(dev, usb_hcd); 744 - if (!root_hub) 745 - dev->wusb = usb_bus_is_wusb(bus) ? 1 : 0; 746 - 747 752 return dev; 748 753 } 749 754 EXPORT_SYMBOL_GPL(usb_alloc_dev);
-3
drivers/usb/host/xhci-mem.c
··· 1108 1108 slot_ctx->dev_info |= cpu_to_le32(SLOT_SPEED_LS); 1109 1109 max_packets = MAX_PACKET(8); 1110 1110 break; 1111 - case USB_SPEED_WIRELESS: 1112 - xhci_dbg(xhci, "FIXME xHCI doesn't support wireless speeds\n"); 1113 - return -EINVAL; 1114 1111 default: 1115 1112 /* Speed was set earlier, this shouldn't happen. */ 1116 1113 return -EINVAL;
+2 -9
drivers/usb/host/xhci.c
··· 2194 2194 case USB_SPEED_SUPER_PLUS: 2195 2195 return SS_BLOCK; 2196 2196 case USB_SPEED_UNKNOWN: 2197 - case USB_SPEED_WIRELESS: 2198 2197 default: 2199 2198 /* Should never happen */ 2200 2199 return 1; ··· 2554 2555 case USB_SPEED_HIGH: 2555 2556 interval_bw->overhead[HS_OVERHEAD_TYPE] -= 1; 2556 2557 break; 2557 - case USB_SPEED_SUPER: 2558 - case USB_SPEED_SUPER_PLUS: 2559 - case USB_SPEED_UNKNOWN: 2560 - case USB_SPEED_WIRELESS: 2558 + default: 2561 2559 /* Should never happen because only LS/FS/HS endpoints will get 2562 2560 * added to the endpoint list. 2563 2561 */ ··· 2611 2615 case USB_SPEED_HIGH: 2612 2616 interval_bw->overhead[HS_OVERHEAD_TYPE] += 1; 2613 2617 break; 2614 - case USB_SPEED_SUPER: 2615 - case USB_SPEED_SUPER_PLUS: 2616 - case USB_SPEED_UNKNOWN: 2617 - case USB_SPEED_WIRELESS: 2618 + default: 2618 2619 /* Should never happen because only LS/FS/HS endpoints will get 2619 2620 * added to the endpoint list. 2620 2621 */
-12
include/linux/usb.h
··· 25 25 26 26 struct usb_device; 27 27 struct usb_driver; 28 - struct wusb_dev; 29 28 30 29 /*-------------------------------------------------------------------------*/ 31 30 ··· 424 425 struct usb_host_bos { 425 426 struct usb_bos_descriptor *desc; 426 427 427 - /* wireless cap descriptor is handled by wusb */ 428 428 struct usb_ext_cap_descriptor *ext_cap; 429 429 struct usb_ss_cap_descriptor *ss_cap; 430 430 struct usb_ssp_cap_descriptor *ssp_cap; ··· 610 612 * WUSB devices are not, until we authorize them from user space. 611 613 * FIXME -- complete doc 612 614 * @authenticated: Crypto authentication passed 613 - * @wusb: device is Wireless USB 614 615 * @lpm_capable: device supports LPM 615 616 * @lpm_devinit_allow: Allow USB3 device initiated LPM, exit latency is in range 616 617 * @usb2_hw_lpm_capable: device can perform USB2 hardware LPM ··· 631 634 * @do_remote_wakeup: remote wakeup should be enabled 632 635 * @reset_resume: needs reset instead of resume 633 636 * @port_is_suspended: the upstream port is suspended (L2 or U3) 634 - * @wusb_dev: if this is a Wireless USB device, link to the WUSB 635 - * specific data for the device. 636 637 * @slot_id: Slot ID assigned by xHCI 637 638 * @removable: Device can be physically removed from this port 638 639 * @l1_params: best effor service latency for USB2 L1 LPM state, and L1 timeout. ··· 691 696 unsigned have_langid:1; 692 697 unsigned authorized:1; 693 698 unsigned authenticated:1; 694 - unsigned wusb:1; 695 699 unsigned lpm_capable:1; 696 700 unsigned lpm_devinit_allow:1; 697 701 unsigned usb2_hw_lpm_capable:1; ··· 721 727 unsigned reset_resume:1; 722 728 unsigned port_is_suspended:1; 723 729 724 - struct wusb_dev *wusb_dev; 725 730 int slot_id; 726 731 struct usb2_lpm_parameters l1_params; 727 732 struct usb3_lpm_parameters u1_params; ··· 1735 1742 * encoding of the endpoint interval, and express polling intervals in 1736 1743 * microframes (eight per millisecond) rather than in frames (one per 1737 1744 * millisecond). 1738 - * 1739 - * Wireless USB also uses the logarithmic encoding, but specifies it in units of 1740 - * 128us instead of 125us. For Wireless USB devices, the interval is passed 1741 - * through to the host controller, rather than being translated into microframe 1742 - * units. 1743 1745 */ 1744 1746 static inline void usb_fill_int_urb(struct urb *urb, 1745 1747 struct usb_device *dev,
+1 -4
include/linux/usb/ch9.h
··· 3 3 * This file holds USB constants and structures that are needed for 4 4 * USB device APIs. These are used by the USB device model, which is 5 5 * defined in chapter 9 of the USB 2.0 specification and in the 6 - * Wireless USB 1.0 (spread around). Linux has several APIs in C that 6 + * Wireless USB 1.0 spec (now defunct). Linux has several APIs in C that 7 7 * need these: 8 8 * 9 9 * - the host side Linux-USB kernel driver API; ··· 13 13 * USB 2.0 adds an additional "On The Go" (OTG) mode, which lets systems 14 14 * act either as a USB host or as a USB device. That means the host and 15 15 * device side APIs benefit from working well together. 16 - * 17 - * There's also "Wireless USB", using low power short range radios for 18 - * peripheral interconnection but otherwise building on the USB framework. 19 16 * 20 17 * Note all descriptors are declared '__attribute__((packed))' so that: 21 18 *
-23
include/linux/usb/composite.h
··· 450 450 * 451 451 * One of these devices is allocated and initialized before the 452 452 * associated device driver's bind() is called. 453 - * 454 - * OPEN ISSUE: it appears that some WUSB devices will need to be 455 - * built by combining a normal (wired) gadget with a wireless one. 456 - * This revision of the gadget framework should probably try to make 457 - * sure doing that won't hurt too much. 458 - * 459 - * One notion for how to handle Wireless USB devices involves: 460 - * 461 - * (a) a second gadget here, discovery mechanism TBD, but likely 462 - * needing separate "register/unregister WUSB gadget" calls; 463 - * (b) updates to usb_gadget to include flags "is it wireless", 464 - * "is it wired", plus (presumably in a wrapper structure) 465 - * bandgroup and PHY info; 466 - * (c) presumably a wireless_ep wrapping a usb_ep, and reporting 467 - * wireless-specific parameters like maxburst and maxsequence; 468 - * (d) configurations that are specific to wireless links; 469 - * (e) function drivers that understand wireless configs and will 470 - * support wireless for (additional) function instances; 471 - * (f) a function to support association setup (like CBAF), not 472 - * necessarily requiring a wireless adapter; 473 - * (g) composite device setup that can create one or more wireless 474 - * configs, including appropriate association setup support; 475 - * (h) more, TBD. 476 453 */ 477 454 struct usb_composite_dev { 478 455 struct usb_gadget *gadget;
-2
include/linux/usb/hcd.h
··· 154 154 /* The next flag is a stopgap, to be removed when all the HCDs 155 155 * support the new root-hub polling mechanism. */ 156 156 unsigned uses_new_polling:1; 157 - unsigned wireless:1; /* Wireless USB HCD */ 158 157 unsigned has_tt:1; /* Integrated TT in root hub */ 159 158 unsigned amd_resume_bug:1; /* AMD remote wakeup quirk */ 160 159 unsigned can_do_streams:1; /* HC supports streams */ ··· 248 249 #define HCD_SHARED 0x0004 /* Two (or more) usb_hcds share HW */ 249 250 #define HCD_USB11 0x0010 /* USB 1.1 */ 250 251 #define HCD_USB2 0x0020 /* USB 2.0 */ 251 - #define HCD_USB25 0x0030 /* Wireless USB 1.0 (USB 2.5)*/ 252 252 #define HCD_USB3 0x0040 /* USB 3.0 */ 253 253 #define HCD_USB31 0x0050 /* USB 3.1 */ 254 254 #define HCD_USB32 0x0060 /* USB 3.2 */
+2 -4
include/uapi/linux/usb/ch11.h
··· 15 15 /* This is arbitrary. 16 16 * From USB 2.0 spec Table 11-13, offset 7, a hub can 17 17 * have up to 255 ports. The most yet reported is 10. 18 - * 19 - * Current Wireless USB host hardware (Intel i1480 for example) allows 20 - * up to 22 devices to connect. Upcoming hardware might raise that 21 - * limit. Because the arrays need to add a bit for hub status data, we 18 + * Upcoming hardware might raise that limit. 19 + * Because the arrays need to add a bit for hub status data, we 22 20 * use 31, so plus one evens out to four bytes. 23 21 */ 24 22 #define USB_MAXCHILDREN 31
+1 -4
include/uapi/linux/usb/ch9.h
··· 3 3 * This file holds USB constants and structures that are needed for 4 4 * USB device APIs. These are used by the USB device model, which is 5 5 * defined in chapter 9 of the USB 2.0 specification and in the 6 - * Wireless USB 1.0 (spread around). Linux has several APIs in C that 6 + * Wireless USB 1.0 spec (now defunct). Linux has several APIs in C that 7 7 * need these: 8 8 * 9 9 * - the master/host side Linux-USB kernel driver API; ··· 13 13 * USB 2.0 adds an additional "On The Go" (OTG) mode, which lets systems 14 14 * act either as a USB master/host or as a USB slave/device. That means 15 15 * the master and slave side APIs benefit from working well together. 16 - * 17 - * There's also "Wireless USB", using low power short range radios for 18 - * peripheral interconnection but otherwise building on the USB framework. 19 16 * 20 17 * Note all descriptors are declared '__attribute__((packed))' so that: 21 18 *