On 7/20/26 9:32 AM, Carlo Caione wrote:
Hello Carlo,
@@ -261,8 +290,14 @@ void mtu3_ep_stall_set(struct mtu3_ep *mep, bool set)
set ? "SEND STALL" : "CLEAR STALL, with EP RESET");
}
-void mtu3_dev_on_off(struct mtu3 *mtu, int is_on)
+int mtu3_dev_on_off(struct mtu3 *mtu, int is_on)
{
+ int ret = 0;
+
+ /* QMU completion may precede transmission from the TX FIFO. */
+ if (!is_on)
+ ret = mtu3_wait_for_tx_fifo_empty(mtu);
Shouldn't this bail early on ret != 0 ?
No, disconnect must still be forced after resetting a timed-out endpoint
(we still want to disconnect it, even forcefully)
Can you please include a code comment that clarifies this ?