Lines Matching refs:nfp_app
50 struct nfp_app;
118 int (*init)(struct nfp_app *app);
119 void (*clean)(struct nfp_app *app);
121 const char *(*extra_cap)(struct nfp_app *app, struct nfp_net *nn);
123 int (*ndo_init)(struct nfp_app *app, struct net_device *netdev);
124 void (*ndo_uninit)(struct nfp_app *app, struct net_device *netdev);
126 int (*vnic_alloc)(struct nfp_app *app, struct nfp_net *nn,
128 void (*vnic_free)(struct nfp_app *app, struct nfp_net *nn);
129 int (*vnic_init)(struct nfp_app *app, struct nfp_net *nn);
130 void (*vnic_clean)(struct nfp_app *app, struct nfp_net *nn);
132 int (*repr_init)(struct nfp_app *app, struct net_device *netdev);
133 void (*repr_preclean)(struct nfp_app *app, struct net_device *netdev);
134 void (*repr_clean)(struct nfp_app *app, struct net_device *netdev);
136 int (*repr_open)(struct nfp_app *app, struct nfp_repr *repr);
137 int (*repr_stop)(struct nfp_app *app, struct nfp_repr *repr);
139 int (*check_mtu)(struct nfp_app *app, struct net_device *netdev,
141 int (*repr_change_mtu)(struct nfp_app *app, struct net_device *netdev,
144 u64 *(*port_get_stats)(struct nfp_app *app,
146 int (*port_get_stats_count)(struct nfp_app *app, struct nfp_port *port);
147 u8 *(*port_get_stats_strings)(struct nfp_app *app,
150 int (*start)(struct nfp_app *app);
151 void (*stop)(struct nfp_app *app);
153 void (*ctrl_msg_rx)(struct nfp_app *app, struct sk_buff *skb);
154 void (*ctrl_msg_rx_raw)(struct nfp_app *app, const void *data,
157 int (*setup_tc)(struct nfp_app *app, struct net_device *netdev,
159 int (*bpf)(struct nfp_app *app, struct nfp_net *nn,
161 int (*xdp_offload)(struct nfp_app *app, struct nfp_net *nn,
165 int (*sriov_enable)(struct nfp_app *app, int num_vfs);
166 void (*sriov_disable)(struct nfp_app *app);
168 enum devlink_eswitch_mode (*eswitch_mode_get)(struct nfp_app *app);
169 int (*eswitch_mode_set)(struct nfp_app *app, u16 mode);
170 struct net_device *(*repr_get)(struct nfp_app *app, u32 id);
183 struct nfp_app { struct
198 static inline int nfp_app_init(struct nfp_app *app) in nfp_app_init() argument
205 static inline void nfp_app_clean(struct nfp_app *app) in nfp_app_clean()
214 static inline int nfp_app_vnic_alloc(struct nfp_app *app, struct nfp_net *nn, in nfp_app_vnic_alloc()
220 static inline void nfp_app_vnic_free(struct nfp_app *app, struct nfp_net *nn) in nfp_app_vnic_free()
226 static inline int nfp_app_vnic_init(struct nfp_app *app, struct nfp_net *nn) in nfp_app_vnic_init()
233 static inline void nfp_app_vnic_clean(struct nfp_app *app, struct nfp_net *nn) in nfp_app_vnic_clean()
239 static inline int nfp_app_repr_open(struct nfp_app *app, struct nfp_repr *repr) in nfp_app_repr_open()
246 static inline int nfp_app_repr_stop(struct nfp_app *app, struct nfp_repr *repr) in nfp_app_repr_stop()
254 nfp_app_repr_init(struct nfp_app *app, struct net_device *netdev) in nfp_app_repr_init()
262 nfp_app_repr_preclean(struct nfp_app *app, struct net_device *netdev) in nfp_app_repr_preclean()
269 nfp_app_repr_clean(struct nfp_app *app, struct net_device *netdev) in nfp_app_repr_clean()
276 nfp_app_check_mtu(struct nfp_app *app, struct net_device *netdev, int new_mtu) in nfp_app_check_mtu()
284 nfp_app_repr_change_mtu(struct nfp_app *app, struct net_device *netdev, in nfp_app_repr_change_mtu()
292 static inline int nfp_app_start(struct nfp_app *app, struct nfp_net *ctrl) in nfp_app_start()
300 static inline void nfp_app_stop(struct nfp_app *app) in nfp_app_stop()
307 static inline const char *nfp_app_name(struct nfp_app *app) in nfp_app_name()
314 static inline bool nfp_app_needs_ctrl_vnic(struct nfp_app *app) in nfp_app_needs_ctrl_vnic()
319 static inline bool nfp_app_ctrl_has_meta(struct nfp_app *app) in nfp_app_ctrl_has_meta()
324 static inline bool nfp_app_ctrl_uses_data_vnics(struct nfp_app *app) in nfp_app_ctrl_uses_data_vnics()
329 static inline const char *nfp_app_extra_cap(struct nfp_app *app, in nfp_app_extra_cap()
337 static inline bool nfp_app_has_tc(struct nfp_app *app) in nfp_app_has_tc()
342 static inline int nfp_app_setup_tc(struct nfp_app *app, in nfp_app_setup_tc()
351 static inline int nfp_app_bpf(struct nfp_app *app, struct nfp_net *nn, in nfp_app_bpf()
359 static inline int nfp_app_xdp_offload(struct nfp_app *app, struct nfp_net *nn, in nfp_app_xdp_offload()
368 static inline bool __nfp_app_ctrl_tx(struct nfp_app *app, struct sk_buff *skb) in __nfp_app_ctrl_tx()
376 static inline bool nfp_app_ctrl_tx(struct nfp_app *app, struct sk_buff *skb) in nfp_app_ctrl_tx()
384 static inline void nfp_app_ctrl_rx(struct nfp_app *app, struct sk_buff *skb) in nfp_app_ctrl_rx()
393 nfp_app_ctrl_rx_raw(struct nfp_app *app, const void *data, unsigned int len) in nfp_app_ctrl_rx_raw()
402 static inline int nfp_app_eswitch_mode_get(struct nfp_app *app, u16 *mode) in nfp_app_eswitch_mode_get()
412 static inline int nfp_app_eswitch_mode_set(struct nfp_app *app, u16 mode) in nfp_app_eswitch_mode_set()
419 static inline int nfp_app_sriov_enable(struct nfp_app *app, int num_vfs) in nfp_app_sriov_enable()
426 static inline void nfp_app_sriov_disable(struct nfp_app *app) in nfp_app_sriov_disable()
432 static inline struct net_device *nfp_app_repr_get(struct nfp_app *app, u32 id) in nfp_app_repr_get()
440 struct nfp_app *nfp_app_from_netdev(struct net_device *netdev);
447 nfp_reprs_get_locked(struct nfp_app *app, enum nfp_repr_type type);
449 nfp_app_reprs_set(struct nfp_app *app, enum nfp_repr_type type,
452 const char *nfp_app_mip_name(struct nfp_app *app);
454 nfp_app_ctrl_msg_alloc(struct nfp_app *app, unsigned int size, gfp_t priority);
456 struct nfp_app *nfp_app_alloc(struct nfp_pf *pf, enum nfp_app_id id);
457 void nfp_app_free(struct nfp_app *app);
461 int nfp_app_nic_vnic_alloc(struct nfp_app *app, struct nfp_net *nn,
463 int nfp_app_nic_vnic_init_phy_port(struct nfp_pf *pf, struct nfp_app *app,