Netdev List
 help / color / mirror / Atom feed
From: David Miller <davem@davemloft.net>
To: oskar@linutronix.de
Cc: netdev@vger.kernel.org, dan@embeddedalley.com,
	bigeasy@linutronix.de, hjk@linutronix.de
Subject: Re: [PATCH] net/fec: fix link/queue interaction, wake queue iff link is up
Date: Wed, 06 Oct 2010 14:15:40 -0700 (PDT)	[thread overview]
Message-ID: <20101006.141540.260064338.davem@davemloft.net> (raw)
In-Reply-To: <1286364718-20070-1-git-send-email-oskar@linutronix.de>

From: Oskar Schirmer <oskar@linutronix.de>
Date: Wed,  6 Oct 2010 13:31:58 +0200

> with hardware slow in negotiation, the system did freeze
> while trying to mount root on nfs at boot time.
> 
> while the driver did report being busy when the link is down
> or no transmission buffers are available, it did not stop the
> queue, causing instant retries. furthermore, transmission being
> triggered with link down was caused by unconditional queue
> wakes, especially on timeouts.
> 
> now, wake queue only iff link is up and transmission
> buffers are available, and dont forget to wake queue
> when link has been adjusted. next, add stop queue notification
> upon driver induced transmission problems, so network stack has
> a chance to handle the situation.
> 
> Signed-off-by: Oskar Schirmer <oskar@linutronix.de>

You should never have to do this.

As long as netif_carrier_on() and netif_carrier_off() are invoked
properly by the driver, the core networking will never send you
packets when netif_carrier_ok() is false.

I am not applying this patch, drivers should not manage tx queue
state using link status as a condition, that's the job of the
core networking.

      reply	other threads:[~2010-10-06 21:15 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-06 11:31 [PATCH] net/fec: fix link/queue interaction, wake queue iff link is up Oskar Schirmer
2010-10-06 21:15 ` David Miller [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20101006.141540.260064338.davem@davemloft.net \
    --to=davem@davemloft.net \
    --cc=bigeasy@linutronix.de \
    --cc=dan@embeddedalley.com \
    --cc=hjk@linutronix.de \
    --cc=netdev@vger.kernel.org \
    --cc=oskar@linutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox