<feed xmlns='http://www.w3.org/2005/Atom'>
<title>tinyusb.git, branch copilot/fix-hil-tinyusb-job</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.</subtitle>
<id>http://cgit.235523.xyz/tinyusb.git/atom/?h=copilot%2Ffix-hil-tinyusb-job</id>
<link rel='self' href='http://cgit.235523.xyz/tinyusb.git/atom/?h=copilot%2Ffix-hil-tinyusb-job'/>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/tinyusb.git/'/>
<updated>2026-07-19T14:50:00Z</updated>
<entry>
<title>Initial plan</title>
<updated>2026-07-19T14:50:00Z</updated>
<author>
<name>copilot-swe-agent[bot]</name>
<email>198982749+Copilot@users.noreply.github.com</email>
</author>
<published>2026-07-19T14:50:00Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/tinyusb.git/commit/?id=be77d2c020a3b581303cb59d1a8edfe2ca3e004d'/>
<id>urn:sha1:be77d2c020a3b581303cb59d1a8edfe2ca3e004d</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Merge pull request #3775 from hathach/claude/add-usb-debug-sniff</title>
<updated>2026-07-18T17:33:14Z</updated>
<author>
<name>Ha Thach</name>
<email>thach@tinyusb.org</email>
</author>
<published>2026-07-18T17:33:14Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/tinyusb.git/commit/?id=50f30773522d21bc599f00c18980ae651f780ff8'/>
<id>urn:sha1:50f30773522d21bc599f00c18980ae651f780ff8</id>
<content type='text'>
usb-target-debug/usb-sniffer skills</content>
</entry>
<entry>
<title>Merge pull request #3763 from hathach/claude/migrate-khci-to-ci_fs</title>
<updated>2026-07-18T16:36:49Z</updated>
<author>
<name>Ha Thach</name>
<email>thach@tinyusb.org</email>
</author>
<published>2026-07-18T16:36:49Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/tinyusb.git/commit/?id=3b4544b974054ae95394401adc663a6bd17c7d33'/>
<id>urn:sha1:3b4544b974054ae95394401adc663a6bd17c7d33</id>
<content type='text'>
Migrate NXP Kinetis khci to chipidea ci_fs (device + host) + fixes</content>
</entry>
<entry>
<title>skill(usb-sniffer): make rig references generic, setup as a script</title>
<updated>2026-07-18T03:19:22Z</updated>
<author>
<name>hathach</name>
<email>thach@tinyusb.org</email>
</author>
<published>2026-07-18T03:19:22Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/tinyusb.git/commit/?id=03f764e5914a96573eee4dd288182deccc60a35a'/>
<id>urn:sha1:03f764e5914a96573eee4dd288182deccc60a35a</id>
<content type='text'>
- Drop the dated/host-specific tap topology; confirm the cabling each
  session instead (the tap gets re-cabled often), and read the DUT link
  speed from sysfs to pick --speed.
- Genericize the hub-upstream reset-visibility note.
- Rewrite "one-time setup" as a copy-paste shell block (udev + binary +
  Wireshark extcap symlink), keeping only the firmware-command caution.
</content>
</entry>
<entry>
<title>fix(ci_fs): address code-review findings in host/device drivers</title>
<updated>2026-07-17T17:18:27Z</updated>
<author>
<name>hathach</name>
<email>thach@tinyusb.org</email>
</author>
<published>2026-07-17T17:18:27Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/tinyusb.git/commit/?id=4782770e7f5f4a726f9739d940c110196807f15c'/>
<id>urn:sha1:4782770e7f5f4a726f9739d940c110196807f15c</id>
<content type='text'>
Host (hcd_ci_fs.c):
- Release the speculatively-armed sibling BDT on the NAK path (IN only) as
  well as on completion, so a NAKed multi-packet IN no longer leaks a BDT
  that stays own=1 and blocks every same-direction pipe. Both paths now go
  through a single release_sibling_bd() helper (was a copy-pasted disarm).
- Clear the ENTIRE shared BDT (both directions) on bus reset; clearing only
  the IN half left a stale OUT/SETUP descriptor after a disconnect mid-OUT,
  blocking the first control transfer on re-enumeration.
- Size bda[] to span the whole BDT (2*2*4) so STAT-indexed access is within
  the declared array bounds (was out-of-declared-bounds, benign via union).

Shared (ci_fs_type.h):
- Hoist buffer_descriptor_t and the TOK_PID enum out of the device and host
  drivers into the shared header so the identical definitions cannot drift.

Board (kinetis_k):
- Drop a redundant local in board_get_unique_id.

Build-verified: host + kinetis k/kl/k32l + MCX. HIL: frdm_k64f host 2/2
(cdc_msc_hid + device_info); frdm_kl25z device core suite green with the
relocated definitions.
</content>
</entry>
<entry>
<title>docs, udev: address Copilot review nits on PR #3775</title>
<updated>2026-07-17T17:15:54Z</updated>
<author>
<name>hathach</name>
<email>thach@tinyusb.org</email>
</author>
<published>2026-07-17T17:15:54Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/tinyusb.git/commit/?id=277e61818638795b9d0f7b2ddc076036dda06d4e'/>
<id>urn:sha1:277e61818638795b9d0f7b2ddc076036dda06d4e</id>
<content type='text'>
- getting_started.rst: the reST inline-link markup rendered literally
  inside the code-block (not a runnable command) and lacked sudo — use a
  plain `sudo cp examples/device/99-tinyusb-examples.rules ...`.
- tools/88-tinyusb.rules: normalize the six MODE="666" entries to the
  4-digit octal MODE="0666" used everywhere else in the file.
</content>
</entry>
<entry>
<title>dcd_lpc17_40: address review findings in the iso paths</title>
<updated>2026-07-17T17:15:53Z</updated>
<author>
<name>hathach</name>
<email>thach@tinyusb.org</email>
</author>
<published>2026-07-17T10:58:25Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/tinyusb.git/commit/?id=cb224400931b7fbc3477a87a258c0602092abe6b'/>
<id>urn:sha1:cb224400931b7fbc3477a87a258c0602092abe6b</id>
<content type='text'>
From a second max-effort review of the branch:

- Drop the dead TUSB_XFER_ISOCHRONOUS case in dcd_edpt_open: iso endpoints
  are armed via dcd_edpt_iso_alloc/activate (TUP_DCD_EDPT_ISO_ALLOC is
  defined for this IP), never through dcd_edpt_open, so the case and its
  dd-&gt;isochronous assignment were unreachable and asserted a false
  invariant. Only bulk/interrupt reach the switch now.

- Extend the iso compile gate to the classes that actually arm an iso
  endpoint: DCD_ISO_ENABLED now includes CFG_TUD_BTH (bth_device.c opens
  an iso voice endpoint). Without it a BTH build would compile the iso
  machinery out and fail SET_INTERFACE at runtime.

- Un-skip LPC175X_6X in the usbtest example: it shares dcd_lpc17_40.c with
  LPC40XX verbatim, so the "DCD has no isochronous support" skip reason no
  longer holds. Build-verified for lpcxpresso1769 (previously blocked by
  the skip).

- TU_ATTR_UNUSED on the ep_id_is_iso helper: every caller is under
  #if DCD_ISO_ENABLED, so non-iso builds don't reference it and clang's
  -Wunused-function (fatal in CI) rejected the build — gcc stays quiet.
  Verified with the full lpc17 and lpc40 example sets under arm-clang.

A fifth finding — bounding control_ep_read's PACKET_READY spin with a
timeout — was implemented and REVERTED: a naive 100k-iteration bound fires
on legitimately-slow control reads and intermittently drops the device
(hardware-proven by interleaved A/B testing against the pre-fix binary).
The infinite wait is retained; the read is only reached once out_received/
out_queued signal data is present, so the theoretical IRQ-off hang is not
reachable in practice.

Re-verified on ea4088_quickstart: usbtest 30/30 (repeated) + HIL 14/14.
</content>
</entry>
<entry>
<title>skill: add usb-sniffer — wire-level capture with the ataradov hardware tap</title>
<updated>2026-07-17T10:32:47Z</updated>
<author>
<name>hathach</name>
<email>thach@tinyusb.org</email>
</author>
<published>2026-07-16T07:11:43Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/tinyusb.git/commit/?id=e5b47c9306471b41bd2d2ecbbe9ea8932028b380'/>
<id>urn:sha1:e5b47c9306471b41bd2d2ecbbe9ea8932028b380</id>
<content type='text'>
Fourth view in the USB debugging toolset (usbmon = host URBs, usb-debug =
host reasoning, usb-target-debug = device firmware, usb-sniffer = what
actually crossed D+/D-). Covers the ataradov/usb-sniffer analyzer:
headless pcapng capture (--speed ls/fs/hs, --fold, --limit self-exit),
Wireshark/tshark analysis recipes, and the wire realities that bite:
downstream broadcast, sniffer self-capture noise, xHCI devnum != wire
address, tap-point-dependent reset visibility (hub choreography anchors),
FS-behind-HS-hub splits. Every recipe hardware-validated on the rig,
including the capture-window floor (a 3 s window provably misses the
enumeration ladder; 3M packets minimum).

Two udev files with distinct audiences, not one:
- examples/device/99-tinyusb-examples.rules (renamed from 99-tinyusb.rules):
  the user-facing rules the examples need — cafe VID access, hidraw, the
  ModemManager blacklist, a couple of board probes. getting_started.rst,
  the webusb_serial README and its source comment point here.
- tools/88-tinyusb.rules: the HIL rig's private probe/analyzer allowlist,
  now with the sniffer (6666:6620 + blank FX2LP 04b4:8613). Installed on
  the rig only; the usb-sniffer skill references it.
</content>
</entry>
<entry>
<title>fix(ci_fs host): release stale sibling BDT on multi-packet completion</title>
<updated>2026-07-17T10:26:05Z</updated>
<author>
<name>hathach</name>
<email>thach@tinyusb.org</email>
</author>
<published>2026-07-10T02:15:22Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/tinyusb.git/commit/?id=7d7444bd8924fce9e60364893265bd2451e115e7'/>
<id>urn:sha1:7d7444bd8924fce9e60364893265bd2451e115e7</id>
<content type='text'>
hcd_ci_fs shares a single BDT set across all pipes. prepare_packets()
speculatively arms the sibling (odd^1) BDT of a multi-packet transfer so it
can ping-pong without NAKs. When such a transfer ends early (a short IN
packet) or fails, the still-owned sibling was never released, permanently
blocking the shared BDT for every other pipe.

This deadlocked a 2nd device enumerating behind a hub while another device
issued descriptor reads (host/device_info with CDC+MSC): the MSC's control
transfers could never acquire the BDT, so it never got Set Address.

Release the sibling in process_tokdne()'s completion path, but ONLY for a
multi-packet transfer (length &gt; max_packet_size): a single-packet transfer
never arms a sibling, so that BDT slot may legitimately belong to another
pipe's in-flight transfer and must not be disturbed (doing so unconditionally
corrupts concurrent transfers, e.g. the CDC bulk-IN vs MSC enum in
host/cdc_msc_hid).

Mirrors the equivalent device-side fix in dcd_ci_fs.c; the host needs the
multi-packet guard because its BDT set is shared across pipes.

Verified on frdm_k64f (HIL): host/device_info now enumerates both CDC+MSC
behind a hub, host/cdc_msc_hid still mounts the MSC (no regression).

Co-Authored-By: Claude Opus 4.8 (1M context) &lt;noreply@anthropic.com&gt;
Claude-Session: https://claude.ai/code/session_01ExGPLP5eU43LR7o6yYLpNi
</content>
</entry>
<entry>
<title>hil: add frdm_k64f host test (cdc + msc) to tinyusb.json</title>
<updated>2026-07-17T10:26:04Z</updated>
<author>
<name>hathach</name>
<email>thach@tinyusb.org</email>
</author>
<published>2026-07-09T17:17:56Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/tinyusb.git/commit/?id=d155273ce44f6bcf72494cce396188c90279c6a1'/>
<id>urn:sha1:d155273ce44f6bcf72494cce396188c90279c6a1</id>
<content type='text'>
frdm_k64f as a USB host with a CH9102 CDC (TX-RX loopback) and a Lexar MSC
drive behind a hub; flasher = onboard OpenSDA J-Link. host/cdc_msc_hid passes
(CDC mount+echo, MSC mount + disk-size check). device_info remains a known
device_info/usbh limitation (its synchronous descriptor dump starves a 2nd
device's enumeration) and is not ci_fs-specific.

Co-Authored-By: Claude Opus 4.8 (1M context) &lt;noreply@anthropic.com&gt;
Claude-Session: https://claude.ai/code/session_01ExGPLP5eU43LR7o6yYLpNi
</content>
</entry>
</feed>
