Skip to content

Commit

Permalink
Merge pull request #2442 from cesanta/nerr
Browse files Browse the repository at this point in the history
honor ifp->nerr
  • Loading branch information
scaprile authored Oct 31, 2023
2 parents d6d2d75 + d63ec65 commit deab677
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/drivers/stm32h.c
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,7 @@ static size_t mg_tcpip_driver_stm32h_tx(const void *buf, size_t len,
MG_ERROR(("Frame too big, %ld", (long) len));
len = 0; // Frame is too big
} else if ((s_txdesc[s_txno][3] & BIT(31))) {
ifp->nerr++;
MG_ERROR(("No free descriptors: %u %08X %08X %08X", s_txno,
s_txdesc[s_txno][3], ETH->DMACSR, ETH->DMACTCR));
for (int i = 0; i < ETH_DESC_CNT; i++) MG_ERROR(("%08X", s_txdesc[i][3]));
Expand Down
1 change: 1 addition & 0 deletions src/drivers/tm4c.c
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,7 @@ static size_t mg_tcpip_driver_tm4c_tx(const void *buf, size_t len,
MG_ERROR(("Frame too big, %ld", (long) len));
len = 0; // fail
} else if ((s_txdesc[s_txno][0] & BIT(31))) {
ifp->nerr++;
MG_ERROR(("No descriptors available"));
// printf("D0 %lx SR %lx\n", (long) s_txdesc[0][0], (long)
// EMAC->EMACDMARIS);
Expand Down

0 comments on commit deab677

Please sign in to comment.