Lannar Dean
1784072a0b
[state.uc] Prevent crash when devstats is null
...
In some (unknown) circumstances, devstats can be null, and attempting to reference devstats[port] causes a crash of state.uc
prevent unsafe access by checking if devstats is null
Signed-off-by: Lannar Dean <moracca@gmail.com >
2026-01-18 01:49:22 -05:00
Ivan Chvets
d26c4b0a1e
fix: Updated state.uc to fix issue with fingerprinting raw mode
...
Fixes: WIFI-15031
Signed-off-by: Ivan Chvets <ivan.chvets@kinarasystems.com >
2025-12-12 15:57:30 +01:00
Ian Chen
100c045af1
Fix cloud cannot show association list when WDS-AP in state.uc
...
Fixes: WIFI-14838
Signed-off-by: Ian Chen <ian77_chen@accton.com >
2025-09-24 13:05:47 +02:00
Lannar Dean
a1e7571a07
state: fix unassigned access
...
Fix potential exception in state.uc (NOTE: udevmand *was* running during this)
root@d4babaa310c8:~# /usr/share/ucentral/state.uc
Reference error: left-hand side expression is null
In /usr/share/ucentral/state.uc, line 1020, byte 35:
` state.counters = ports[iface].counters;`
Near here ------------------------------------^
Signed-off-by: Lannar Dean <ldd@rgnets.com >
2025-09-12 07:53:59 +02:00
Tanya Singh
1453f2ebf1
chanUtil per radio shall be obtained from the policy_chanutil.uc script
...
Fixes: WIFI-14837
Signed-off-by: Tanya Singh <tanya_singh@accton.com >
2025-07-24 13:27:06 +02:00
John Crispin
2b8a58bd52
dont crash if udevmand does not reply
...
Signed-off-by: John Crispin <john@phrozen.org >
2025-07-03 18:39:50 +02:00
Ian Chen
6faaa1f655
HaLow: Extend ucentral schema & state for HaLow
...
1. Extend ucentral schema & state for HaLow
2. Refine "system" into "sysinfo" to avoid confliction with system trace in state.uc
Fixes: WIFI-14436
Signed-off-by: Ian Chen <ian77_chen@accton.com >
2025-05-12 07:42:01 +02:00
Tanya Singh
048a53d4a6
state.uc: Fix the calculation of Channel Utilization (chanUtil) in statistics
...
Fixes: WIFI-14531
Signed-off-by: Tanya Singh <tanya_singh@accton.com >
2025-04-18 07:54:09 +02:00
Tanya Singh
0683d041e4
Add pdev_stats and channel utilization for each radio in the statistics
...
Signed-off-by: Tanya Singh <tanya_singh@accton.com >
2025-04-08 07:05:27 +02:00
Tanya Singh
d183922b77
WIFI-14477: Get switch carrier, speed & duplex info from swconfig command
...
Signed-off-by: Tanya Singh <tanya_singh@accton.com >
2025-03-24 08:12:26 +01:00
Tanya Singh
1c11c1bb67
WIFI-14284: Use swconfig to get the correct port to VLAN ID mapping for statistics
...
Signed-off-by: Tanya Singh <tanya_singh@accton.com >
2025-03-17 11:58:58 +01:00
Francisco Jose Alvarez
90aa0eefc9
system: Fix the delta_counters for dynamic vlan stations
...
Signed-off-by: Francisco Jose Alvarez <francisco.alvarez@galgus.ai >
2025-02-27 09:44:29 +01:00
John Crispin
61e5802789
add multi radio support
...
Signed-off-by: John Crispin <john@phrozen.org >
2024-12-09 08:34:39 +01:00
Paul White
f0dfb400b5
Include DHCP VSI information in state message
...
When the Vendor-Sepcific-Information (VSI) option is returned by the
DHCP server, include this information in the state message.
Fixes: WIFI-14271
Signed-off-by: Paul White <paul@shasta.cloud >
2024-11-11 07:50:06 +01:00
Venkat Chimata
658a29d248
state.uc: Fixing negative coutners
...
Index the port counters with names instead of sequential accessing.
With sequential accessing, there is no gurantee that we may get the
same counter in two consequent accesses
Signed-off-by: Venkat Chimata <venkata@shasta.cloud >
2024-09-02 16:09:11 +02:00
John Crispin
ce416682ba
fingerprint: add missing allow_wan option to render code
...
Signed-off-by: John Crispin <john@phrozen.org >
2024-06-07 09:05:49 +02:00
John Crispin
8045e6c51d
add full fingerprinting data model
...
Signed-off-by: John Crispin <john@phrozen.org >
2024-05-31 12:07:01 +02:00
John Crispin
ef09cf05ba
remove boottime fro state, it is in accurate without a RTC
...
Signed-off-by: John Crispin <john@phrozen.org >
2024-05-03 08:23:45 +02:00
John Crispin
cb1c18db70
add support for device fingerprinting
...
Signed-off-by: John Crispin <john@phrozen.org >
2024-03-25 11:14:16 +01:00
John Crispin
c544ab01e5
state: ignore non connected thermal zones
...
The QCA v5.4 kernel introduced thermal zones for PA. These will read
500C+ if not wired. Skip them.
Signed-off-by: John Crispin <john@phrozen.org >
2024-01-09 08:41:38 +01:00
John Crispin
2b884b3781
fix state messages on single port devices
...
the swconfig patches broke this
Signed-off-by: John Crispin <john@phrozen.org >
2023-11-07 11:27:17 +01:00
John Crispin
9d2312a510
ieee8021x: rework render code
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-11-03 08:44:53 +01:00
John Crispin
01e80a671e
add delta counters for upstream vlan interfaces
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-10-05 10:22:09 +02:00
John Crispin
d42d7c0ca0
add delta counters to state messages
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-10-03 09:15:34 +02:00
John Crispin
fdeb2b8b85
revert "public_ip_lookup" patch
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-09-28 14:52:40 +02:00
John Crispin
b2998010ad
unify the state uci file
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-09-28 14:52:40 +02:00
John Crispin
249788ea23
fix state messages when no devices are configured
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-07-19 16:58:58 +02:00
John Crispin
5255152b28
use logical names instead of linux netdev ones inside state messages
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-07-10 07:21:59 +02:00
John Crispin
48ee8f025d
fix cpu core utilisation
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-06-14 14:38:23 +02:00
John Crispin
04ce23b667
fix udevstats counters
...
root@78cb2c0005fa:~# /usr/share/ucentral/state.uc
Reference error: left-hand side expression is null
In iface_add_counters(), file /usr/share/ucentral/state.uc, line 274, byte 30:
called from function [anonymous function] (/usr/share/ucentral/state.uc:507:48)
called from function foreach ([C])
called from anonymous function (/usr/share/ucentral/state.uc:514:22)
` counters.tx_bytes += vid.tx.bytes;`
Near here --------------------------^
Signed-off-by: John Crispin <john@phrozen.org >
2023-06-14 06:47:26 +02:00
John Crispin
694fd64277
convert vlan_ifaces to an array
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-16 17:32:03 +02:00
John Crispin
11dff2ae46
add dynamic vlans to state messages
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-16 13:17:01 +02:00
John Crispin
5d8e9b0a42
add boot time to the state message
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-11 15:10:37 +02:00
John Crispin
bc91b18ed1
fix public_ip syntax error
...
Syntax error: Expecting expression
In line 39, byte 16:
` let result = system(sprintf("/usr/bin/curl -m 3 %s -o %s", cfg.public_ip_lookup, public_ip_file));`
Near here ------^
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-05 09:01:45 +02:00
John Crispin
37d7a26975
add per core cpu_load to the state message
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-05-05 08:50:15 +02:00
Satya-sc
0af4f34a4e
Added support of retrieval of public IP if not existed and reporting in state msg
...
Signed-off-by: Satya-sc <Satya@shasta.cloud >
2023-05-02 17:44:07 +02:00
John Crispin
b918e6aef2
state: some devices will report temperature in milli celssius
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-04-11 09:10:48 +02:00
John Crispin
204341fafb
state: add port_id and port_desc to lldp state
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-03-09 16:37:32 +01:00
John Crispin
bf8c3846fe
properly stream state in telemetry mode
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-02-20 08:42:44 +01:00
John Crispin
8c71638072
fix listing mesh interfaces inside state
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-02-13 10:36:36 +01:00
John Crispin
94543eeb61
state: cleanup and document the data model
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-02-13 09:02:09 +01:00
John Crispin
6056d32a90
state: add [ avg, max ] cpu thermal sensor
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-02-09 09:09:13 +01:00
John Crispin
bb84cc80cc
add support for reading udevstats counters
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-01-23 10:29:39 +01:00
John Crispin
ec657b513d
improve stability of reading counters
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-01-13 14:02:10 +01:00
John Crispin
ad84690d77
only set port counter if they are available
...
Signed-off-by: John Crispin <john@phrozen.org >
2023-01-09 08:24:04 +01:00
John Crispin
b5392037b4
include APVLAN associations inside state messages
...
Signed-off-by: John Crispin <john@phrozen.org >
2022-12-14 14:54:29 +01:00
John Crispin
6049cd75c2
various state improvements
...
Signed-off-by: John Crispin <john@phrozen.org >
2022-12-14 10:29:24 +01:00
John Crispin
53e3bb434a
radio.channel should not be an array
...
Signed-off-by: John Crispin <john@phrozen.org >
2022-12-12 08:37:10 +01:00
John Crispin
e336aa487f
add username to captive state
...
Signed-off-by: John Crispin <john@phrozen.org >
2022-12-12 08:19:56 +01:00
John Crispin
f3c99724dc
state: add ssid counters
...
Signed-off-by: John Crispin <john@phrozen.org >
2022-12-08 17:11:20 +01:00