diff options
| author | Justin Hibbits <jhibbits@FreeBSD.org> | 2021-10-20 20:49:00 +0000 |
|---|---|---|
| committer | Justin Hibbits <jhibbits@FreeBSD.org> | 2022-12-21 14:20:06 +0000 |
| commit | 402810d32e5f7525c61ef70c6af24817227e1649 (patch) | |
| tree | 00aaa1ab2daebe3d6285926cf7d01732f0877526 /sys/dev/ixl | |
| parent | 7ebc4c9bf76d1ea62e2ccd3020ff8e6e293b499c (diff) | |
Diffstat (limited to 'sys/dev/ixl')
| -rw-r--r-- | sys/dev/ixl/if_ixl.c | 12 | ||||
| -rw-r--r-- | sys/dev/ixl/ixl.h | 2 | ||||
| -rw-r--r-- | sys/dev/ixl/ixl_iw.c | 2 | ||||
| -rw-r--r-- | sys/dev/ixl/ixl_pf_iflib.c | 4 | ||||
| -rw-r--r-- | sys/dev/ixl/ixl_pf_main.c | 10 |
5 files changed, 15 insertions, 15 deletions
diff --git a/sys/dev/ixl/if_ixl.c b/sys/dev/ixl/if_ixl.c index 352a35d95512..9df1d9792e51 100644 --- a/sys/dev/ixl/if_ixl.c +++ b/sys/dev/ixl/if_ixl.c @@ -905,14 +905,14 @@ ixl_if_suspend(if_ctx_t ctx) static int ixl_if_resume(if_ctx_t ctx) { - struct ifnet *ifp = iflib_get_ifp(ctx); + if_t ifp = iflib_get_ifp(ctx); INIT_DEBUGOUT("ixl_if_resume: begin"); /* Read & clear wake-up registers */ /* Required after D3->D0 transition */ - if (ifp->if_flags & IFF_UP) + if (if_getflags(ifp) & IFF_UP) ixl_if_init(ctx); return (0); @@ -924,7 +924,7 @@ ixl_if_init(if_ctx_t ctx) struct ixl_pf *pf = iflib_get_softc(ctx); struct ixl_vsi *vsi = &pf->vsi; struct i40e_hw *hw = &pf->hw; - struct ifnet *ifp = iflib_get_ifp(ctx); + if_t ifp = iflib_get_ifp(ctx); device_t dev = iflib_get_dev(ctx); u8 tmpaddr[ETHER_ADDR_LEN]; int ret; @@ -943,7 +943,7 @@ ixl_if_init(if_ctx_t ctx) } /* Get the latest mac address... User might use a LAA */ - bcopy(IF_LLADDR(vsi->ifp), tmpaddr, ETH_ALEN); + bcopy(if_getlladdr(vsi->ifp), tmpaddr, ETH_ALEN); if (!ixl_ether_is_equal(hw->mac.addr, tmpaddr) && (i40e_validate_mac_addr(tmpaddr) == I40E_SUCCESS)) { ixl_del_all_vlan_filters(vsi, hw->mac.addr); @@ -1013,7 +1013,7 @@ void ixl_if_stop(if_ctx_t ctx) { struct ixl_pf *pf = iflib_get_softc(ctx); - struct ifnet *ifp = iflib_get_ifp(ctx); + if_t ifp = iflib_get_ifp(ctx); struct ixl_vsi *vsi = &pf->vsi; INIT_DEBUGOUT("ixl_if_stop: begin\n"); @@ -1639,7 +1639,7 @@ ixl_if_promisc_set(if_ctx_t ctx, int flags) { struct ixl_pf *pf = iflib_get_softc(ctx); struct ixl_vsi *vsi = &pf->vsi; - struct ifnet *ifp = iflib_get_ifp(ctx); + if_t ifp = iflib_get_ifp(ctx); struct i40e_hw *hw = vsi->hw; int err; bool uni = FALSE, multi = FALSE; diff --git a/sys/dev/ixl/ixl.h b/sys/dev/ixl/ixl.h index 9828760e4ea6..641ce6b10fcc 100644 --- a/sys/dev/ixl/ixl.h +++ b/sys/dev/ixl/ixl.h @@ -422,7 +422,7 @@ LIST_HEAD(ixl_ftl_head, ixl_mac_filter); struct ixl_vsi { if_ctx_t ctx; if_softc_ctx_t shared; - struct ifnet *ifp; + if_t ifp; device_t dev; struct i40e_hw *hw; struct ifmedia *media; diff --git a/sys/dev/ixl/ixl_iw.c b/sys/dev/ixl/ixl_iw.c index 5e2d7cfcb30b..d4129808cc28 100644 --- a/sys/dev/ixl/ixl_iw.c +++ b/sys/dev/ixl/ixl_iw.c @@ -165,7 +165,7 @@ ixl_iw_pf_init(struct ixl_pf *pf) pf_info->dev = pf->dev; pf_info->pci_mem = pf->pci_mem; pf_info->pf_id = pf->hw.pf_id; - pf_info->mtu = pf->vsi.ifp->if_mtu; + pf_info->mtu = pf->vsi.if_getmtu(ifp); pf_info->iw_msix.count = IXL_IW_VEC_COUNT(pf); pf_info->iw_msix.base = IXL_IW_VEC_BASE(pf); diff --git a/sys/dev/ixl/ixl_pf_iflib.c b/sys/dev/ixl/ixl_pf_iflib.c index 6ea20389c547..eeb8f28393c2 100644 --- a/sys/dev/ixl/ixl_pf_iflib.c +++ b/sys/dev/ixl/ixl_pf_iflib.c @@ -352,14 +352,14 @@ ixl_setup_interface(device_t dev, struct ixl_pf *pf) struct ixl_vsi *vsi = &pf->vsi; if_ctx_t ctx = vsi->ctx; struct i40e_hw *hw = &pf->hw; - struct ifnet *ifp = iflib_get_ifp(ctx); + if_t ifp = iflib_get_ifp(ctx); struct i40e_aq_get_phy_abilities_resp abilities; enum i40e_status_code aq_error = 0; INIT_DBG_DEV(dev, "begin"); vsi->shared->isc_max_frame_size = - ifp->if_mtu + ETHER_HDR_LEN + ETHER_CRC_LEN + if_getmtu(ifp) + ETHER_HDR_LEN + ETHER_CRC_LEN + ETHER_VLAN_ENCAP_LEN; if (IXL_PF_IN_RECOVERY_MODE(pf)) diff --git a/sys/dev/ixl/ixl_pf_main.c b/sys/dev/ixl/ixl_pf_main.c index 0b1604cc4918..7b1bf78dac09 100644 --- a/sys/dev/ixl/ixl_pf_main.c +++ b/sys/dev/ixl/ixl_pf_main.c @@ -530,7 +530,7 @@ ixl_add_maddr(void *arg, struct sockaddr_dl *sdl, u_int cnt) void ixl_add_multi(struct ixl_vsi *vsi) { - struct ifnet *ifp = vsi->ifp; + if_t ifp = vsi->ifp; struct i40e_hw *hw = vsi->hw; int mcnt = 0; struct ixl_add_maddr_arg cb_arg; @@ -571,7 +571,7 @@ void ixl_del_multi(struct ixl_vsi *vsi, bool all) { struct ixl_ftl_head to_del; - struct ifnet *ifp = vsi->ifp; + if_t ifp = vsi->ifp; struct ixl_mac_filter *f, *fn; int mcnt = 0; @@ -597,7 +597,7 @@ void ixl_link_up_msg(struct ixl_pf *pf) { struct i40e_hw *hw = &pf->hw; - struct ifnet *ifp = pf->vsi.ifp; + if_t ifp = pf->vsi.ifp; char *req_fec_string, *neg_fec_string; u8 fec_abilities; @@ -618,7 +618,7 @@ ixl_link_up_msg(struct ixl_pf *pf) neg_fec_string = ixl_fec_string[2]; log(LOG_NOTICE, "%s: Link is up, %s Full Duplex, Requested FEC: %s, Negotiated FEC: %s, Autoneg: %s, Flow Control: %s\n", - ifp->if_xname, + if_name(ifp), ixl_link_speed_string(hw->phy.link_info.link_speed), req_fec_string, neg_fec_string, (hw->phy.link_info.an_info & I40E_AQ_AN_COMPLETED) ? "True" : "False", @@ -1919,7 +1919,7 @@ void ixl_handle_empr_reset(struct ixl_pf *pf) { struct ixl_vsi *vsi = &pf->vsi; - bool is_up = !!(vsi->ifp->if_drv_flags & IFF_DRV_RUNNING); + bool is_up = !!(if_getdrvflags(vsi->ifp) & IFF_DRV_RUNNING); ixl_prepare_for_reset(pf, is_up); /* |
