Debian Codegraph @

drivers/net/ethernet/intel/ice/ice_sf_eth.h

raw
1 /* SPDX-License-Identifier: GPL-2.0 */
2 /* Copyright (c) 2024, Intel Corporation. */
3
4 #ifndef _ICE_SF_ETH_H_
5 #define _ICE_SF_ETH_H_
6
7 #include <linux/auxiliary_bus.h>
8 #include "ice.h"
9
10 struct ice_sf_dev {
11 struct auxiliary_device adev;
12 struct ice_dynamic_port *dyn_port;
13 struct ice_sf_priv *priv;
14 };
15
16 struct ice_sf_priv {
17 struct ice_sf_dev *dev;
18 struct devlink_port devlink_port;
19 };
20
21 static inline struct
22 ice_sf_dev *ice_adev_to_sf_dev(struct auxiliary_device *adev)
23 {
24 return container_of(adev, struct ice_sf_dev, adev);
25 }
26
27 int ice_sf_driver_register(void);
28 void ice_sf_driver_unregister(void);
29
30 int ice_sf_eth_activate(struct ice_dynamic_port *dyn_port,
31 struct netlink_ext_ack *extack);
32 void ice_sf_eth_deactivate(struct ice_dynamic_port *dyn_port);
33 #endif /* _ICE_SF_ETH_H_ */