Skip to content

Commit e0deed4

Browse files
tmon-nordicgithub-actions[bot]
authored andcommitted
[nrf fromtree] drivers: udc_dwc2: Stop OUT transfers on ZLP
The transfer is finished after ZLP is transmitted. Do not re-enable the endpoint waiting for more data. Signed-off-by: Tomasz Moń <[email protected]> (cherry picked from commit ea72b27) (cherry picked from commit a82f2fc)
1 parent bd889a2 commit e0deed4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/usb/udc/udc_dwc2.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2540,7 +2540,7 @@ static inline void dwc2_handle_out_xfercompl(const struct device *dev,
25402540
net_buf_add(buf, bcnt);
25412541
}
25422542

2543-
if (!is_iso && (bcnt % udc_mps_ep_size(ep_cfg)) == 0 &&
2543+
if (!is_iso && bcnt && (bcnt % udc_mps_ep_size(ep_cfg)) == 0 &&
25442544
net_buf_tailroom(buf)) {
25452545
dwc2_prep_rx(dev, buf, ep_cfg);
25462546
} else {

0 commit comments

Comments
 (0)