From: Andrew Morton <akpm@osdl.org>
To: Francois Romieu <romieu@fr.zoreil.com>
Cc: a.nielsen@optushome.com.au, linux-kernel@vger.kernel.org,
torvalds@osdl.org, degger@tarantel.rz.fh-muenchen.de
Subject: Re: [PATCH] Fix kernel lockup in RTL-8169 gigabit ethernet driver
Date: Sat, 3 Apr 2004 02:07:40 -0800 [thread overview]
Message-ID: <20040403020740.33ef375f.akpm@osdl.org> (raw)
In-Reply-To: <20040403112755.A19308@electric-eye.fr.zoreil.com>
Francois Romieu <romieu@fr.zoreil.com> wrote:
>
> Adam Nielsen <a.nielsen@optushome.com.au> :
> [...]
> > in the Realtek 8169 gigabit ethernet driver. Due to a logic error,
> > there is a loop in an interrupt handler that often goes infinite, thus
> > locking up the entire computer. The attached patch fixes the problem.
>
> - until there is an explanation on _why_ this condition happens, this is a
> band-aid for an unexplained condition, not a fix for a "logic error" (it
> may have interesting performance effects though);
>
The logic is faulty, or at least very odd.
tx_left = tp->cur_tx - dirty_tx;
while (tx_left > 0) {
int entry = dirty_tx % NUM_TX_DESC;
if (!(le32_to_cpu(tp->TxDescArray[entry].status) & OWNbit)) {
...
}
}
Why is that `if' test there at all? If it ever returns false, the box
locks up. A BUG_ON(le32_to_cpu(tp->TxDescArray[entry].status) & OWNbit)
might make more sense.
next prev parent reply other threads:[~2004-04-03 10:07 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-04-03 5:02 [PATCH] Fix kernel lockup in RTL-8169 gigabit ethernet driver Adam Nielsen
2004-04-03 9:27 ` Francois Romieu
2004-04-03 10:07 ` Andrew Morton [this message]
2004-04-03 12:13 ` Francois Romieu
-- strict thread matches above, loose matches on Subject: below --
2004-04-03 11:30 Manfred Spraul
2004-04-03 12:45 ` Francois Romieu
2004-04-04 0:55 ` Malvineous
2004-04-04 9:15 ` Francois Romieu
2004-04-05 21:51 ` Adam Nielsen
2004-04-06 17:11 ` Manfred Spraul
2004-04-06 20:50 ` Francois Romieu
2004-04-05 23:08 Dieter Nützel
2004-04-06 7:47 ` Francois Romieu
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=20040403020740.33ef375f.akpm@osdl.org \
--to=akpm@osdl.org \
--cc=a.nielsen@optushome.com.au \
--cc=degger@tarantel.rz.fh-muenchen.de \
--cc=linux-kernel@vger.kernel.org \
--cc=romieu@fr.zoreil.com \
--cc=torvalds@osdl.org \
/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