Skip to content

Commit 76021c7

Browse files
committed
rename tud_edpt_stream_write_xfer
1 parent b3e63c3 commit 76021c7

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/class/cdc/cdc_host.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ bool tu_edpt_stream_clear(tu_edpt_stream_t* s)
7676
return tu_fifo_clear(&s->ff);
7777
}
7878

79-
uint32_t tud_edpt_stream_write_flush(uint8_t dev_addr, tu_edpt_stream_t* s)
79+
uint32_t tud_edpt_stream_write_xfer(uint8_t dev_addr, tu_edpt_stream_t* s)
8080
{
8181
// No data to send
8282
if ( !tu_fifo_count(&s->ff) ) return 0;
@@ -114,7 +114,7 @@ uint32_t tu_edpt_stream_write(uint8_t daddr, tu_edpt_stream_t* s, void const *bu
114114
if ( (tu_fifo_count(&s->ff) >= bulk_packet_size)
115115
/* || ((CFG_TUD_CDC_TX_BUFSIZE < BULK_PACKET_SIZE) && tu_fifo_full(&p_cdc->tx_ff)) */ )
116116
{
117-
tud_edpt_stream_write_flush(daddr, s);
117+
tud_edpt_stream_write_xfer(daddr, s);
118118
}
119119

120120
return ret;
@@ -302,7 +302,7 @@ uint32_t tuh_cdc_write_flush(uint8_t idx)
302302
cdch_interface_t* p_cdc = get_itf(idx);
303303
TU_VERIFY(p_cdc);
304304

305-
return tud_edpt_stream_write_flush(p_cdc->daddr, &p_cdc->stream.tx);
305+
return tud_edpt_stream_write_xfer(p_cdc->daddr, &p_cdc->stream.tx);
306306
}
307307

308308
uint32_t tuh_cdc_read (uint8_t idx, void* buffer, uint32_t bufsize)
@@ -435,7 +435,7 @@ bool cdch_xfer_cb(uint8_t daddr, uint8_t ep_addr, xfer_result_t event, uint32_t
435435

436436
if ( ep_addr == p_cdc->stream.tx.ep_addr )
437437
{
438-
if ( 0 == tud_edpt_stream_write_flush(daddr, &p_cdc->stream.tx) )
438+
if ( 0 == tud_edpt_stream_write_xfer(daddr, &p_cdc->stream.tx) )
439439
{
440440
// If there is no data left, a ZLP should be sent if
441441
// xferred_bytes is multiple of EP Packet size and not zero

0 commit comments

Comments
 (0)