[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <1401204260.4346.11.camel@dcbw.local>
Date: Tue, 27 May 2014 10:24:20 -0500
From: Dan Williams <dcbw@...hat.com>
To: Balakumaran Kannan <kumaran.4353@...il.com>
Cc: David Miller <davem@...emloft.net>, stephen@...workplumber.org,
Avinash Kumar <avi.kp.137@...il.com>,
Eric Dumazet <edumazet@...gle.com>,
"netdev@...r.kernel.org" <netdev@...r.kernel.org>
Subject: Re: [PATCH 1/1] net: Set NOCARRIER bit of etherdev state at
initialization
On Sat, 2014-05-24 at 18:52 +0530, Balakumaran Kannan wrote:
> On Fri, May 23, 2014 at 11:45 PM, David Miller <davem@...emloft.net> wrote:
> > From: Dan Williams <dcbw@...hat.com>
> > Date: Fri, 23 May 2014 12:38:01 -0500
> >
> >> The current "carrier on until told otherwise" model is intentional,
> >> because not all drivers support carrier detection, and thus we must
> >> assume the carrier is on until the driver tells us it is not on.
> >>
> >> Would this patch break that model?
> >
> > Absolutely correct, this change is completely inappropriate.
>
> So it is driver's responsibility to maintain this flag appropriately.
> Thus if a driver supports carrier detection, it should set "carrier
> on" only after determining the carrier state. Then I'll add
> 'netif_carrier_off' call to smsc911x driver and send a new patch.
Correct. Carrier state starts with ON. If the driver knows it can
detect carrier state, then the driver should call netif_carrier_off()
early in the driver initialization, and then call on/off as appropriate
when it gets carrier change events.
Dan
> Thanks for the explanation.
>
> Regards,
> K.Balakumaran
> --
> 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
--
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