net: remove usage of device_pm_control_nop
If device PM is not implemented just use NULL. Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
This commit is contained in:
parent
e25dc6ff80
commit
3daf9f2d97
5 changed files with 11 additions and 13 deletions
|
@ -2235,7 +2235,7 @@ struct net_if_api {
|
|||
* the system.
|
||||
* @param init_fn Address to the init function of the driver.
|
||||
* @param pm_control_fn Pointer to device_pm_control function.
|
||||
* Can be empty function (device_pm_control_nop) if not implemented.
|
||||
* Can be NULL if not implemented.
|
||||
* @param data Pointer to the device's private data.
|
||||
* @param cfg The address to the structure containing the
|
||||
* configuration information for this instance of the driver.
|
||||
|
@ -2262,7 +2262,7 @@ struct net_if_api {
|
|||
* @param node_id The devicetree node identifier.
|
||||
* @param init_fn Address to the init function of the driver.
|
||||
* @param pm_control_fn Pointer to device_pm_control function.
|
||||
* Can be empty function (device_pm_control_nop) if not implemented.
|
||||
* Can be NULL if not implemented.
|
||||
* @param data Pointer to the device's private data.
|
||||
* @param cfg The address to the structure containing the
|
||||
* configuration information for this instance of the driver.
|
||||
|
@ -2317,7 +2317,7 @@ struct net_if_api {
|
|||
* @param instance Instance identifier.
|
||||
* @param init_fn Address to the init function of the driver.
|
||||
* @param pm_control_fn Pointer to device_pm_control function.
|
||||
* Can be empty function (device_pm_control_nop) if not implemented.
|
||||
* Can be NULL if not implemented.
|
||||
* @param data Pointer to the device's private data.
|
||||
* @param cfg The address to the structure containing the
|
||||
* configuration information for this instance of the driver.
|
||||
|
@ -2349,7 +2349,7 @@ struct net_if_api {
|
|||
* @param instance Instance identifier.
|
||||
* @param init_fn Address to the init function of the driver.
|
||||
* @param pm_control_fn Pointer to device_pm_control function.
|
||||
* Can be empty function (device_pm_control_nop) if not implemented.
|
||||
* Can be NULL if not implemented.
|
||||
* @param data Pointer to the device's private data.
|
||||
* @param cfg The address to the structure containing the
|
||||
* configuration information for this instance of the driver.
|
||||
|
@ -2401,7 +2401,7 @@ struct net_if_api {
|
|||
* the system.
|
||||
* @param init_fn Address to the init function of the driver.
|
||||
* @param pm_control_fn Pointer to device_pm_control function.
|
||||
* Can be empty function (device_pm_control_nop) if not implemented.
|
||||
* Can be NULL if not implemented.
|
||||
* @param data Pointer to the device's private data.
|
||||
* @param cfg The address to the structure containing the
|
||||
* configuration information for this instance of the driver.
|
||||
|
@ -2427,7 +2427,7 @@ struct net_if_api {
|
|||
* @param node_id The devicetree node identifier.
|
||||
* @param init_fn Address to the init function of the driver.
|
||||
* @param pm_control_fn Pointer to device_pm_control function.
|
||||
* Can be empty function (device_pm_control_nop) if not implemented.
|
||||
* Can be NULL if not implemented.
|
||||
* @param data Pointer to the device's private data.
|
||||
* @param cfg The address to the structure containing the
|
||||
* configuration information for this instance of the driver.
|
||||
|
|
|
@ -295,7 +295,7 @@ net_virtual_get_iface_capabilities(struct net_if *iface)
|
|||
* the system.
|
||||
* @param init_fn Address to the init function of the driver.
|
||||
* @param pm_control_fn Pointer to device_pm_control function.
|
||||
* Can be empty function (device_pm_control_nop) if not implemented.
|
||||
* Can be NULL if not implemented.
|
||||
* @param data Pointer to the device's private data.
|
||||
* @param cfg The address to the structure containing the
|
||||
* configuration information for this instance of the driver.
|
||||
|
|
|
@ -630,8 +630,7 @@ NET_MGMT_REGISTER_REQUEST_HANDLER(NET_REQUEST_BT_SCAN, bt_scan);
|
|||
NET_MGMT_REGISTER_REQUEST_HANDLER(NET_REQUEST_BT_DISCONNECT, bt_disconnect);
|
||||
#endif
|
||||
|
||||
DEVICE_DEFINE(net_bt, "net_bt", net_bt_init, device_pm_control_nop,
|
||||
&bt_context_data, NULL, POST_KERNEL,
|
||||
CONFIG_KERNEL_INIT_PRIORITY_DEFAULT, &bt_if_api);
|
||||
DEVICE_DEFINE(net_bt, "net_bt", net_bt_init, NULL, &bt_context_data, NULL,
|
||||
POST_KERNEL, CONFIG_KERNEL_INIT_PRIORITY_DEFAULT, &bt_if_api);
|
||||
NET_L2_DATA_INIT(net_bt, 0, NET_L2_GET_CTX_TYPE(BLUETOOTH_L2));
|
||||
NET_IF_INIT(net_bt, 0, BLUETOOTH_L2, L2CAP_IPSP_MTU, CONFIG_BT_MAX_CONN);
|
||||
|
|
|
@ -564,8 +564,7 @@ static const struct virtual_interface_api ipip_iface_api = {
|
|||
|
||||
#define NET_IPIP_INTERFACE_INIT(x, _) \
|
||||
NET_VIRTUAL_INTERFACE_INIT(ipip##x, "IP_TUNNEL" #x, ipip_init, \
|
||||
device_pm_control_nop, \
|
||||
&ipip_context_data_##x, NULL, \
|
||||
NULL, &ipip_context_data_##x, NULL, \
|
||||
CONFIG_KERNEL_INIT_PRIORITY_DEFAULT, \
|
||||
&ipip_iface_api, IPIPV4_MTU);
|
||||
|
||||
|
|
|
@ -700,7 +700,7 @@ static const struct net_capture_interface_api capture_interface_api = {
|
|||
DEVICE_DEFINE(net_capture_##x, \
|
||||
"NET_CAPTURE" #x, \
|
||||
&capture_dev_init, \
|
||||
device_pm_control_nop, \
|
||||
NULL, \
|
||||
&capture_dev_data_##x, \
|
||||
NULL, \
|
||||
POST_KERNEL, \
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue