[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <OF6BE4274E.3D881649-ONC12577D2.00564B05-C12577D2.00568E52@transmode.se>
Date: Fri, 5 Nov 2010 16:45:25 +0100
From: Joakim Tjernlund <joakim.tjernlund@...nsmode.se>
To: Thomas Graf <tgraf@...radead.org>
Cc: Eric Dumazet <eric.dumazet@...il.com>, netdev@...r.kernel.org,
Thomas Graf <tgr@...radead.org>
Subject: Re: ping -I eth1 ....
Thomas Graf <tgr@...radead.org> wrote on 2010/11/05 15:53:21:
>
> On Fri, Nov 05, 2010 at 03:34:25PM +0100, Eric Dumazet wrote:
> > Le vendredi 05 novembre 2010 à 10:25 -0400, Thomas Graf a écrit :
> > > On Fri, Nov 05, 2010 at 03:01:57PM +0100, Joakim Tjernlund wrote:
> > > > 1) I think you should include IFF_RUNNING too
> > >
> > > Probably even better to base it on the operational state of the link
> > >
> > > netif_running() && netif_oper_up() && netif_carrier_ok() && !netif_dormant()
> >
> > At this point we setup a route.
> >
> > Is a change of any of this status going to flush/cancel a previously
> > setup route ?
>
> No it won't.
>
> > There must be a reason why in many places we only test (dev->flags &
> > IFF_UP), and _never_ netif_oper_up() (only in dev_get_flags() to export
> > it at userspace)
>
> The reason is that while the device is not operational we queue all
> packets in the qdisc and hope for the link to become operational in the
> near future. This does make sense, especially if the link was once
> operational.
Hmm, perhaps one needs to treat user space differently from
internal kernel calls?
User space should always get an error if the link isn't functional.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists