netdev
[Top] [All Lists]

Re: [patch 4/10] s390: network driver.

To: Jeff Garzik <jgarzik@xxxxxxxxx>
Subject: Re: [patch 4/10] s390: network driver.
From: Thomas Spatzier <thomas.spatzier@xxxxxxxxxx>
Date: Wed, 22 Dec 2004 11:56:06 +0100
Cc: "David S. Miller" <davem@xxxxxxxxxxxxx>, hadi@xxxxxxxxxx, Hasso Tepper <hasso@xxxxxxxxx>, Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx>, netdev@xxxxxxxxxxx, Paul Jakma <paul@xxxxxxxx>, Tommy Christensen <tommy.christensen@xxxxxxxxx>
In-reply-to: <41C71FFD.7090308@xxxxxxxxx>
Sender: netdev-bounce@xxxxxxxxxxx



Jeff Garzik <jgarzik@xxxxxxxxx> wrote on 20.12.2004 19:54:53:
> I haven't heard anything to convince me that the same change should be
> deployed across NNN drivers.  The drivers already signal the net core
> that the link is down; to me, that implies there should be code in _one_
> place that handles this condition, not NNN places.
>

This sounds plausible and I'm with Jeff here.
For me as the driver author it's the smallest change.
I will put it like this:
on cable gone:
      netif_stop_queue();
      netif_carrier_off();
on cable reconnected:
      netif_carrier_on();
      netif_wake_queue();

Is that ok, i.e. what all drivers do or should do?

For the problems that applications might have (i.e. sockets being
blocked etc.) another solution should be found.
And as Jeff pointed out, this should be a central solution and
not be implemented in drivers.

Regards,
Thomas.


<Prev in Thread] Current Thread [Next in Thread>