Mechanically convert if_hn(4) to IfAPI

Reviewed by:	zlei
Sponsored by:	Juniper Networks, Inc.
Differential Revision: https://reviews.freebsd.org/D37855
This commit is contained in:
Justin Hibbits 2022-09-26 10:34:28 -04:00
parent f766d1d5a7
commit 4db5958a06
2 changed files with 355 additions and 318 deletions

File diff suppressed because it is too large Load Diff

View File

@ -71,8 +71,8 @@ struct hn_rx_rsc {
}; };
struct hn_rx_ring { struct hn_rx_ring {
struct ifnet *hn_ifp; if_t hn_ifp;
struct ifnet *hn_rxvf_ifp; /* SR-IOV VF for RX */ if_t hn_rxvf_ifp; /* SR-IOV VF for RX */
struct hn_tx_ring *hn_txr; struct hn_tx_ring *hn_txr;
void *hn_pktbuf; void *hn_pktbuf;
int hn_pktbuf_len; int hn_pktbuf_len;
@ -192,7 +192,7 @@ struct hn_tx_ring {
* Device-specific softc structure * Device-specific softc structure
*/ */
struct hn_softc { struct hn_softc {
struct ifnet *hn_ifp; if_t hn_ifp;
struct ifmedia hn_media; struct ifmedia hn_media;
device_t hn_dev; device_t hn_dev;
int hn_if_flags; int hn_if_flags;
@ -204,7 +204,7 @@ struct hn_softc {
struct hn_rx_ring *hn_rx_ring; struct hn_rx_ring *hn_rx_ring;
struct rmlock hn_vf_lock; struct rmlock hn_vf_lock;
struct ifnet *hn_vf_ifp; /* SR-IOV VF */ if_t hn_vf_ifp; /* SR-IOV VF */
uint32_t hn_xvf_flags; /* transparent VF flags */ uint32_t hn_xvf_flags; /* transparent VF flags */
int hn_tx_ring_cnt; int hn_tx_ring_cnt;
@ -277,7 +277,7 @@ struct hn_softc {
* Saved information for VF under transparent mode. * Saved information for VF under transparent mode.
*/ */
void (*hn_vf_input) void (*hn_vf_input)
(struct ifnet *, struct mbuf *); (if_t, struct mbuf *);
int hn_saved_caps; int hn_saved_caps;
u_int hn_saved_tsomax; u_int hn_saved_tsomax;
u_int hn_saved_tsosegcnt; u_int hn_saved_tsosegcnt;