nuttx-apps/system/iptables
zhanghongyu 2b0a4a20f5 iptables: add file lock to prevent concurrent overwrite
the kernel can only prevent the concurrency of s/getsockopt, but
iptables will call these interfaces multiple times at a time. We
need to wait for one iptables to complete before executing the second
one, otherwise the data will be overwritten.

iptables flow:
get current iptables entries [1] -> add new entry 2 [1,2] -> set to kernel [1,2]
get current iptables entries [1] -> add new entry 3 [1,3] -> set to kernel [1,3]
entry 2 is lost

Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2026-01-15 17:20:03 +08:00
..
CMakeLists.txt system: migrate to SPDX identifier 2024-12-30 18:02:50 +08:00
ip6tables.c system: migrate to SPDX identifier 2024-12-30 18:02:50 +08:00
iptables.c iptables: add file lock to prevent concurrent overwrite 2026-01-15 17:20:03 +08:00
iptables.h system: migrate to SPDX identifier 2024-12-30 18:02:50 +08:00
iptables_utils.c iptables: fix the ipv4 mask conversion error 2026-01-15 17:12:03 +08:00
Kconfig iptables: add file lock to prevent concurrent overwrite 2026-01-15 17:20:03 +08:00
Make.defs system: migrate to SPDX identifier 2024-12-30 18:02:50 +08:00
Makefile system: migrate to SPDX identifier 2024-12-30 18:02:50 +08:00