The branch main has been updated by jhibbits:

URL: 
https://cgit.FreeBSD.org/src/commit/?id=96ab5e719955066730747da3c58b77c356e84afe

commit 96ab5e719955066730747da3c58b77c356e84afe
Author:     Justin Hibbits <[email protected]>
AuthorDate: 2023-02-06 20:45:02 +0000
Commit:     Justin Hibbits <[email protected]>
CommitDate: 2023-02-06 20:56:22 +0000

    mge(4): Fix build after IfAPI conversion
    
    Fixes:          98fe10c8fc08
    Sponsored by:   Juniper Networks, Inc.
---
 sys/dev/mge/if_mge.c | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/sys/dev/mge/if_mge.c b/sys/dev/mge/if_mge.c
index af244c590769..b3664eeb66a0 100644
--- a/sys/dev/mge/if_mge.c
+++ b/sys/dev/mge/if_mge.c
@@ -478,7 +478,7 @@ mge_set_prom_mode(struct mge_softc *sc, uint8_t queue)
        uint32_t reg_val, i;
 
        /* Enable or disable promiscuous mode as needed */
-       if (sc->if_getflags(ifp) & IFF_PROMISC) {
+       if (if_getflags(sc->ifp) & IFF_PROMISC) {
                port_config = MGE_READ(sc, MGE_PORT_CONFIG);
                port_config |= PORT_CONFIG_UPM;
                MGE_WRITE(sc, MGE_PORT_CONFIG, port_config);
@@ -1200,15 +1200,15 @@ mge_init_locked(void *arg)
         * * ...only if polling is not turned on. Disable interrupts explicitly
         * if polling is enabled.
         */
-       if (sc->if_getcapenable(ifp) & IFCAP_POLLING)
+       if (if_getcapenable(sc->ifp) & IFCAP_POLLING)
                mge_intrs_ctrl(sc, 0);
        else
 #endif /* DEVICE_POLLING */
        mge_intrs_ctrl(sc, 1);
 
        /* Activate network interface */
-       if_setdrvflagbits(ifp, IFF_DRV_RUNNING, 0);
-       if_setdrvflagbits(ifp, 0, IFF_DRV_OACTIVE);
+       if_setdrvflagbits(sc->ifp, IFF_DRV_RUNNING, 0);
+       if_setdrvflagbits(sc->ifp, 0, IFF_DRV_OACTIVE);
        sc->wd_timer = 0;
 
        /* Schedule watchdog timeout */
@@ -1226,7 +1226,7 @@ mge_intr_rxtx(void *arg)
        MGE_GLOBAL_LOCK(sc);
 
 #ifdef DEVICE_POLLING
-       if (sc->if_getcapenable(ifp) & IFCAP_POLLING) {
+       if (if_getcapenable(sc->ifp) & IFCAP_POLLING) {
                MGE_GLOBAL_UNLOCK(sc);
                return;
        }
@@ -1283,7 +1283,7 @@ mge_intr_rx(void *arg) {
        MGE_RECEIVE_LOCK(sc);
 
 #ifdef DEVICE_POLLING
-       if (sc->if_getcapenable(ifp) & IFCAP_POLLING) {
+       if (if_getcapenable(sc->ifp) & IFCAP_POLLING) {
                MGE_RECEIVE_UNLOCK(sc);
                return;
        }
@@ -1405,7 +1405,7 @@ mge_intr_tx(void *arg)
        MGE_TRANSMIT_LOCK(sc);
 
 #ifdef DEVICE_POLLING
-       if (sc->if_getcapenable(ifp) & IFCAP_POLLING) {
+       if (if_getcapenable(sc->ifp) & IFCAP_POLLING) {
                MGE_TRANSMIT_UNLOCK(sc);
                return;
        }
@@ -1625,7 +1625,7 @@ mge_shutdown(device_t dev)
        MGE_GLOBAL_LOCK(sc);
 
 #ifdef DEVICE_POLLING
-        if (sc->if_getcapenable(ifp) & IFCAP_POLLING)
+        if (if_getcapenable(sc->ifp) & IFCAP_POLLING)
                ether_poll_deregister(sc->ifp);
 #endif
 

Reply via email to