summaryrefslogtreecommitdiff
path: root/tests/accel-cmd/test_cmd_basic.py
diff options
context:
space:
mode:
authorDenys Fedoryshchenko <denys.f@collabora.com>2026-04-29 13:12:31 +0300
committerDenys Fedoryshchenko <denys.f@collabora.com>2026-05-04 03:09:49 +0300
commitd28a24252f0df8c8babf3a7321f303d3298029fc (patch)
tree89a9d98f99faa3eab43d8028dd4896e1e720a89f /tests/accel-cmd/test_cmd_basic.py
parent5b78328068085a8dc530978fd0b51f5c187a6aff (diff)
downloadaccel-ppp-d28a24252f0df8c8babf3a7321f303d3298029fc.tar.gz
accel-ppp-d28a24252f0df8c8babf3a7321f303d3298029fc.zip
pppoe: encapsulate statistics counters
Group the PPPoE statistics in struct pppoe_stat_t and keep the storage private to pppoe.c instead of exporting writable counter globals through pppoe.h. The CLI now reads a snapshot with pppoe_stat_get(), while the packet/control paths update the counters through the PPPoE-owned storage using relaxed atomic operations. Convert the PPPoE SNMP starting/active scalars from watched raw pointers to scalar handlers. This removes the old pppoe_get_stat() pointer escape hatch and makes SNMP read the counters through pppoe_stat_starting() and pppoe_stat_active(), so the synchronization policy is applied consistently outside the PPPoE module. This also fixes the long-standing PPPoE starting counter behavior. PPPoE used to expose starting in the CLI and ACCEL-PPP-MIB, but never updated it, so it always reported zero. Track a per-connection ppp_starting state, increment starting when the controller begins channel setup, move the session from starting to active after establish_ppp() succeeds, and decrement starting on setup failure before PPP becomes active. This matches the state accounting used by the other PPP controllers. Signed-off-by: Denys Fedoryshchenko <denys.f@collabora.com>
Diffstat (limited to 'tests/accel-cmd/test_cmd_basic.py')
0 files changed, 0 insertions, 0 deletions