···28072807 if (priv->link) {28082808 priv->link = 0;28092809 printk(KERN_DEBUG "TLAN: %s has lost link\n", dev->name);28102810- dev->flags &= ~IFF_RUNNING;28102810+ netif_carrier_off(dev);28112811 TLan_SetTimer( dev, (2*HZ), TLAN_TIMER_LINK_BEAT );28122812 return;28132813 }···28172817 if ((phy_status & MII_GS_LINK) && !priv->link) {28182818 priv->link = 1;28192819 printk(KERN_DEBUG "TLAN: %s has reestablished link\n", dev->name);28202820- dev->flags |= IFF_RUNNING;28202820+ netif_carrier_on(dev);28212821 }2822282228232823 /* Setup a new monitor */
+3-8
drivers/net/tokenring/ibmtr.c
···888888 ti->sap_status = CLOSED; /* CLOSED or OPEN */889889 ti->open_failure = NO; /* NO or YES */890890 ti->open_mode = MANUAL; /* MANUAL or AUTOMATIC */891891- /* 12/2000 not typical Linux, but we can use RUNNING to let us know when892892- the network has crapped out or cables are disconnected. Useful because893893- the IFF_UP flag stays up the whole time, until ifconfig tr0 down.894894- */895895- dev->flags &= ~IFF_RUNNING;896891897892 ti->sram_phys &= ~1; /* to reverse what we do in tok_close */898893 /* init the spinlock */···12371242 ti->open_status = CLOSED;12381243 ti->sap_status = CLOSED;12391244 ti->open_mode = AUTOMATIC;12401240- dev->flags &= ~IFF_RUNNING;12451245+ netif_carrier_off(dev);12411246 netif_stop_queue(dev);12421247 ti->open_action = RESTART;12431248 outb(0, dev->base_addr + ADAPTRESET);···13181323 break;13191324 }13201325 netif_wake_queue(dev);13211321- dev->flags |= IFF_RUNNING;/*BMS 12/2000*/13261326+ netif_carrier_on(dev);13221327 break;13231328 case DIR_INTERRUPT:13241329 case DIR_MOD_OPEN_PARAMS:···14221427 ring_status);14231428 if(ring_status& (REMOVE_RECV|AUTO_REMOVAL|LOBE_FAULT)){14241429 netif_stop_queue(dev);14251425- dev->flags &= ~IFF_RUNNING;/*not typical Linux*/14301430+ netif_carrier_off(dev);14261431 DPRINTK("Remove received, or Auto-removal error"14271432 ", or Lobe fault\n");14281433 DPRINTK("We'll try to reopen the closed adapter"
+2-6
drivers/net/wan/lmc/lmc_main.c
···723723 /* lmc_reset (sc); Why reset??? The link can go down ok */724724725725 /* Inform the world that link has been lost */726726- dev->flags &= ~IFF_RUNNING;726726+ netif_carrier_off(dev);727727 }728728729729 /*···736736 /* lmc_reset (sc); Again why reset??? */737737738738 /* Inform the world that link protocol is back up. */739739- dev->flags |= IFF_RUNNING;739739+ netif_carrier_on(dev);740740741741 /* Now we have to tell the syncppp that we had an outage742742 * and that it should deal. Calling sppp_reopen here···11681168 sc->lmc_media->set_link_status (sc, 1);11691169 sc->lmc_media->set_status (sc, NULL);1170117011711171- //dev->flags |= IFF_RUNNING;11721172-11731171 netif_wake_queue(dev);1174117211751173 sc->lmc_txfull = 0;···12301232 csr6 &= ~LMC_DEC_ST; /* Turn off the Transmission bit */12311233 csr6 &= ~LMC_DEC_SR; /* Turn off the Receive bit */12321234 LMC_CSR_WRITE (sc, csr_command, csr6);12331233-12341234- dev->flags &= ~IFF_RUNNING;1235123512361236 sc->stats.rx_missed_errors +=12371237 LMC_CSR_READ (sc, csr_missed_frames) & 0xffff;
+1-1
include/linux/if.h
···3333#define IFF_LOOPBACK 0x8 /* is a loopback net */3434#define IFF_POINTOPOINT 0x10 /* interface is has p-p link */3535#define IFF_NOTRAILERS 0x20 /* avoid use of trailers */3636-#define IFF_RUNNING 0x40 /* resources allocated */3636+#define IFF_RUNNING 0x40 /* interface running and carrier ok */3737#define IFF_NOARP 0x80 /* no ARP protocol */3838#define IFF_PROMISC 0x100 /* receive all packets */3939#define IFF_ALLMULTI 0x200 /* receive all multicast packets*/