mirror of
https://github.com/RT-Thread/rt-thread.git
synced 2026-08-28 00:28:38 +08:00
rt_hw_eth_init() clears ENET descriptor tables using element size times count, but the RX/TX data buffers used sizeof(size), which only covers the width of the size field. Use the configured buffer count and size so the whole RX/TX buffer areas are initialized before handing them to the ENET descriptor configuration. Make the Cppcheck intent explicit for the HPM placement macros and the LPI_CSR register read so the touched file passes static analysis. Signed-off-by: Old-Ding <35417409+Old-Ding@users.noreply.github.com>