casaroli opened a new pull request, #4099: URL: https://github.com/apache/nuttx-apps/pull/4099
## Summary depends-on: apache/nuttx/pull/22129 A new case of `cmocka_net_tcp`, `test_tcp_sndtimeo_iob`: a TCP pair over 127.0.0.1 whose reader does not read, and a sender with `SO_SNDTIMEO` 100 ms. The sends fill the write buffers, then 10 sends time out in the wait for an I/O buffer. After both ends close, the free I/O buffers in `/proc/iobinfo` must come back to the number before the case (within 3 s). On NuttX master each such timeout keeps one I/O buffer on the committed list; apache/nuttx#22129 fixes it. The case is built with `CONFIG_NET_IPv4`, `CONFIG_NET_SOCKOPTS` and `CONFIG_NET_TCP_WRITE_BUFFERS`. It is skipped without `/proc/iobinfo`, and when a send fails with `ENOMEM`: with a fixed pool of devif callbacks, the connections of earlier cases in TIME_WAIT can keep the callbacks that the sender needs. ## Impact Only `testing/nettest`: one new source file and its lines in `Makefile` and `CMakeLists.txt`. No change to other cases. ## Testing qemu-armv8a:knsh under HVF, 96 IOBs of 196 bytes, `IOB_THROTTLE` 8, TCP write buffers: | | NuttX master | with apache/nuttx#22129 | |---|---|---| | `test_tcp_sndtimeo_iob`, first run after boot | FAIL: 61 free, 72 before | PASS | | the same, second run of `cmocka_net_tcp` in the same boot | SKIPPED (`ENOMEM`) | SKIPPED (`ENOMEM`) | | knsh, 4 CPUs | | PASS | | flat qemu-armv8a:nsh | FAIL: 85 free, 96 before | PASS | Builds in the NuttX CI image with `-Werror`, with apache/nuttx#22129, all OK with 0 warnings: qemu-armv8a:netnsh with the case (Make and CMake), sim:tcpblaster with the case, qemu-armv8a:netnsh without TCP write buffers (the case is not built). The knsh images of the runs above build the case at `make import` (`-Wall`, 0 warnings). `tools/checkpatch.sh -c -u -m -g` passes. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
