Bug 211675

Summary: mac802154_hwsim: support net namespaces and phy flags
Product: Memory Management Reporter: Dmitry Vyukov (dvyukov)
Component: SanitizersAssignee: Dmitry Vyukov (dvyukov)
Status: NEW ---    
Severity: enhancement CC: kasan-dev
Priority: P3    
Hardware: All   
OS: Linux   
Kernel Version: ALL Subsystem:
Regression: No Bisected commit-id:

Description Dmitry Vyukov 2021-02-10 14:30:19 UTC
drivers/net/ieee802154/mac802154_hwsim.c is a 802.15.4 emulation device that is very useful for testing.
It would be useful to improve:
1. Support for network namespaces in ieee/mac802154 subsystem in general. Currently there are lots of checks for init_net namespace and nl802154_family netlink family can only be accessed from init_net namespace (no .netnsok flag). This does not allow to have isolated devices per test namespace, no isolation, not reproducibility, possibility of badly messing init net ns.
2. mac802154_hwsim does not support phy flags (WPAN_PHY_FLAG_TXPOWER, etc), this limits test coverage that can be achieved with mac802154_hwsim.