ch32: complete USBHS bus reset on the first SOF

BUS_RST can precede completion of speed negotiation, so it cannot reliably
report the negotiated bus speed. Waiting until the first SETUP reports reset
and SETUP together, allowing task-side reset processing to clear the queued
SETUP count before the request is handled.

Handle BUS_RST before transfer and SETUP flags, notify RESET_START, reset
EP0, and discard reset/transaction flags observed in the entry snapshot.
Temporarily enable SOF interrupts and mark reset completion pending. On the
first SOF, read SPEED_TYPE, report RESET_END once, and disable SOF interrupts.
Subsequent SOF events use the normal path when USBD enables them again.

This gives the USB task the interval before the first SETUP to process reset
without changing the core SETUP bookkeeping. It still requires the task to
run in that interval. Keep runtime speed selection and OUT toggle filtering
outside this commit.

Validation:
- Full example sets passed on NanoCH32V305 and CH32V307: 54 builds.
- NanoCH32V305 uac2_headset stack size: +96 bytes code, +1 byte BSS.
1 file changed