Xiang Xiao
015e30a866
drivers/net: Remove HAVE_ATOMICS and use CONFIG_HAVE_ATOMICS directly
...
since OpenAMP never support to compile in c89 only mode
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-07-05 13:43:17 +03:00
Petro Karashchenko
46facd44b3
drivers/net/netdev: improve granularity of 'quota' locking
...
There is no need to use global spinlock to protect netdev
specific data counters. Allocate per-netdev specific spinlock
to get better locking granularity.
Move C/C++ atomic support checking to compiler.h
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-07-01 15:27:09 -03:00
Zhe Weng
f80539b6a8
netdev/upper: Use atomic when we have atomic support from compiler
...
Ref: How to test atomic support https://beej.us/guide/bgc/html/split/chapter-atomics.html
Signed-off-by: Zhe Weng <wengzhe@xiaomi.com>
2023-06-15 19:31:59 -03:00
Zhe Weng
483eb10f37
netdev/upper: Make quota_load public
...
Signed-off-by: Zhe Weng <wengzhe@xiaomi.com>
2023-06-15 19:31:59 -03:00
Zhe Weng
f21742899f
net/netdev: Use upper half of netdev to simplify sim driver
...
Signed-off-by: Zhe Weng <wengzhe@xiaomi.com>
2023-04-22 01:41:01 +08:00
Zhe Weng
72b77d36e2
net/netdev: Add upper half of netdev to simplify driver logic
...
Signed-off-by: Zhe Weng <wengzhe@xiaomi.com>
2023-04-22 01:41:01 +08:00