xref: /openbmc/linux/net/ieee802154/rdev-ops.h (revision ab0bd561)
14a9a816aSAlexander Aring #ifndef __CFG802154_RDEV_OPS
24a9a816aSAlexander Aring #define __CFG802154_RDEV_OPS
34a9a816aSAlexander Aring 
44a9a816aSAlexander Aring #include <net/cfg802154.h>
54a9a816aSAlexander Aring 
64a9a816aSAlexander Aring #include "core.h"
74a9a816aSAlexander Aring 
84a9a816aSAlexander Aring static inline struct net_device *
94a9a816aSAlexander Aring rdev_add_virtual_intf_deprecated(struct cfg802154_registered_device *rdev,
104a9a816aSAlexander Aring 				 const char *name, int type)
114a9a816aSAlexander Aring {
124a9a816aSAlexander Aring 	return rdev->ops->add_virtual_intf_deprecated(&rdev->wpan_phy, name,
134a9a816aSAlexander Aring 						      type);
144a9a816aSAlexander Aring }
154a9a816aSAlexander Aring 
164a9a816aSAlexander Aring static inline void
174a9a816aSAlexander Aring rdev_del_virtual_intf_deprecated(struct cfg802154_registered_device *rdev,
184a9a816aSAlexander Aring 				 struct net_device *dev)
194a9a816aSAlexander Aring {
204a9a816aSAlexander Aring 	rdev->ops->del_virtual_intf_deprecated(&rdev->wpan_phy, dev);
214a9a816aSAlexander Aring }
224a9a816aSAlexander Aring 
23ab0bd561SAlexander Aring static inline int
24ab0bd561SAlexander Aring rdev_set_channel(struct cfg802154_registered_device *rdev, const u8 page,
25ab0bd561SAlexander Aring 		 const u8 channel)
26ab0bd561SAlexander Aring {
27ab0bd561SAlexander Aring 	return rdev->ops->set_channel(&rdev->wpan_phy, page, channel);
28ab0bd561SAlexander Aring }
29ab0bd561SAlexander Aring 
304a9a816aSAlexander Aring #endif /* __CFG802154_RDEV_OPS */
31