zephyr/samples
Tomasz Moń 2f24adbe0f usb: device: Do not claim to be USB 3.2 device
The bcdUSB value 0x0210 defined in USB 3.2 Specification indicates USB
3.2 device operating in one of the USB 2.0 modes. USB 2.0 Link Power
Management Addendum defines bcdUSB value 0x0201 to indicate that USB 2.0
device supports the request to read the BOS Descriptor.

The main difference between bcdUSB 0x0210 and 0x0201 is that the USB 3.2
device must support LPM, while USB 2.0 devices can (but are not required
to) support LPM.

The difference is respected by USB 3 Gen X Command Verifier (2.3.0.0)
Chapter 9 Tests [USB 2 devices], where the test behaves as follows:
  * For bcdUSB 0x0200:
      Checking Device Under Test for LPM L1 Compatibility...
      USB version of device is 2.00.
      DUT is NOT compatible with LPM.
      LPM is NOT required for DUT
      LPM is only supported in USB version 2.01 and above.

  * For bcdUSB 0x0201:
      Checking Device Under Test for LPM L1 Compatibility...
      USB version of device is 2.01.
      DUT IS compatible with LPM.
      LPM is NOT required for DUT
      USB 2.0 Extension Descriptor bmAttributes:
        LPM Capable = 0
        BESL and Alternate HIRD Supported = 0
        Baseline BESL Valid = 0
        Deep BESL Valid = 0
        Baseline BESL: 0d
        Deep BESL:  0d
      LPM is not supported

  * For bcdUSB 0x0210:
      Checking Device Under Test for LPM L1 Compatibility...
      USB version of device is 2.10.
      DUT IS compatible with LPM.
      LPM IS required for DUT
      USB 2.0 Extension Descriptor bmAttributes:
        LPM Capable = 0
        BESL and Alternate HIRD Supported = 0
        Baseline BESL Valid = 0
        Deep BESL Valid = 0
        Baseline BESL: 0d
        Deep BESL:  0d
      (USB: 9.6.2.1.6) Bit 1 in Attributes field of a USB 2.0 Extension
      descriptor returned in response to a GetDescriptor(BOS) request
      must be 1 for LS/FS/HS devices that support LPM L1.

The test fails when LPM bit is not set in USB 2.0 Extension Descriptor
only when bcdUSB is 0x0210. The test failure was incorrectly fixed in
commit 312429be3c ("usb: samples: Add Extension descriptor to webUSB
sample."). Properly fix the issue by changing bcdUSB to 0x0201 and
removing the false LPM support claim.

The false LPM claim was leading to device ceasing to work after some
time if there was no traffic from host to device (when the host is
likely to have executed the LPM L1 transition that was not properly
handled by the device).

Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
2024-05-06 14:54:23 +01:00
..
application_development hwmv2: Introduce Hardware model version 2 and convert devices 2024-03-02 16:56:33 -05:00
arch samples: use appropriate sys_randX_get() 2024-04-05 10:57:45 -05:00
basic boards: rename and update esp32 related conf and overlay files 2024-04-23 15:36:13 +02:00
bluetooth Bluetooth: BAP: Unicast server depend on PACS 2024-04-30 14:30:45 -04:00
boards scripts: twister: Remove harness repeat field 2024-04-30 18:23:23 +02:00
compression hwmv2: Introduce Hardware model version 2 and convert devices 2024-03-02 16:56:33 -05:00
cpp samples: cpp: add a Hello, world! C++ app 2024-01-17 09:56:34 +01:00
drivers drivers: ht16k33: convert from kscan to input 2024-05-06 14:53:36 +01:00
fuel_gauge hwmv2: Introduce Hardware model version 2 and convert devices 2024-03-02 16:56:33 -05:00
hello_world samples: hello_world: Use full board target string for hwmv2 boards 2024-03-21 20:10:46 +01:00
kernel arch: move arch_interface.h under zephyr/arch 2024-03-25 09:58:35 +00:00
modules boards: rename and update esp32 related conf and overlay files 2024-04-23 15:36:13 +02:00
net tests: net: tls: fix failures 2024-05-06 11:09:49 +02:00
philosophers samples: philosophers: remove redundant items in prj.conf 2024-02-01 05:26:24 -05:00
posix samples/posix: Use hwmv2 native targets identifiers 2024-03-15 16:13:12 +01:00
sensor test: mcux_acmp: remove hwv1 overlay which conflicts with hwv2 2024-04-24 15:05:01 -04:00
shields samples: shields: x_nucleo_iks01a3: Fix deprecated config fragment 2024-03-22 10:06:04 +01:00
subsys usb: device: Do not claim to be USB 3.2 device 2024-05-06 14:54:23 +01:00
synchronization samples: synchronization: add static thread 2023-11-16 09:25:33 +01:00
tfm_integration samples: tfm_integration: psa_crypto: improve the MbedTLS configuration 2024-05-03 14:47:52 -07:00
userspace boards: arm: stm32f756 with all mpu regions when testing in userspace 2024-04-30 15:11:57 +02:00
classic.rst
index.rst doc: samples: Fix incorrect maxdepth for some toctrees 2023-09-26 12:02:54 +02:00
sample_definition_and_criteria.rst docs: Sample definition: Replace native_posix with native_sim 2023-11-20 12:02:48 +01:00