public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Bill Davidsen <davidsen@tmr.com>
To: Russell Miller <rmiller@duskglow.com>
Cc: "Doug McNaught" <doug@mcnaught.org>,
	"Jim Nelson" <james4765@verizon.net>,
	DervishD <lkml@dervishd.net>,
	"Gene Heskett" <gene.heskett@verizon.net>,
	linux-kernel@vger.kernel.org, "Måns Rullgård" <mru@inprovide.com>
Subject: Re: is killing zombies possible w/o a reboot?
Date: Thu, 04 Nov 2004 15:06:23 -0500	[thread overview]
Message-ID: <418A8BBF.8040901@tmr.com> (raw)
In-Reply-To: <200411031733.30469.rmiller@duskglow.com>

Russell Miller wrote:
> On Wednesday 03 November 2004 17:03, Doug McNaught wrote:
> 
> 
>>It was already mentioned in this thread that the bookkeeping required
>>to clean up properly from such an abort would add a lot of overhead
>>and slow down the normal, non-buggy case.
>>
> 
> I am going to continue pursuing this at the risk of making a bigger fool of 
> myself than I already am, but I want to make sure that I understand the 
> issues - and I did read the message you are referring to.
> 
> I think what you are saying is that there is kind of a race condition here.

At least in the usual sense, no. There is a condition from which there 
is no graceful way back, only forward.

> When something is on the wait queue, it has to be followed through to 
> completion.  An interrupt could be received at any time, and if it's taken 
> off of the wait queue prematurely, it'll crash the kernel, because the 
> interrupt has no way of telling that.

That's part of it, but in some cases there's also i/o in progress, the 
hardware may not have a way to HALT the transfer, so the memory in 
question can't be used for something else.
> 
> That's fine as it goes, I understand that.  But I submit that this is a 
> horrible design.  I've been bitten by this more than once - usually regarding 
> broken NFS connections.
> 
> But what I don't understand is why the bookkeeping would be so inefficient.  
> It seems to me that all that would be required is a bitfield of some sort.  
> If that position in the qait queue becomes invalid, when the interrupt is 
> received to process it, the kernel notes that a flag is set invalidating that 
> part of the wait queue, dumps the output to dave null, and goes on to the 
> next.  This doesn't seem inefficient to me, unless I'm missing something.
> A little more inefficient, yes, but not to near the cost that seems to be 
> implied.
> 
> And I also have to ask this question:  what is more inefficient, slowing down 
> processing of output waiting on the queue, or having to reboot when a process 
> gets stuck due to faulty drivers?  At the very least, a compile option seems 
> like it would be worthwhile for those that would like this behavior.
> 
> And I probably am.  Missing something, that is.

You are asking to program around a problem rather than fix it. These 
hangs (usually) happen because the hardware behaviour is either 
undocumented, incorrectly documented, or flat out broken. Second likely 
cause is a bug in the driver.

In the case of a real bug, adding code to bypass the error instead of 
fixing it is more effort, more complex in most cases, and therefore less 
reliable. Where the hardware does something unexpected, the driver needs 
to fit the behaviour rather than the spec. And where the hardware is 
broken, you fix or replace it. None of those cases suggest "pretend it 
didn't happen," because in most cases you can't.

What I think you are missing:

Processes hung in D state are the result of real problems, and ignoring 
rather than fixing them is like giving a cancer patient a face lift; it 
doesn't fix the problem, it just gives you a good looking corpse.

-- 
    -bill davidsen (davidsen@tmr.com)
"The secret to procrastination is to put things off until the
  last possible moment - but no longer"  -me

  parent reply	other threads:[~2004-11-04 20:11 UTC|newest]

Thread overview: 99+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-11-03 12:51 is killing zombies possible w/o a reboot? Gene Heskett
2004-11-03 14:33 ` bert hubert
2004-11-03 14:49   ` Måns Rullgård
2004-11-03 15:25     ` DervishD
2004-11-03 15:25       ` Måns Rullgård
2004-11-03 17:49         ` DervishD
2004-11-03 16:47       ` Gene Heskett
2004-11-03 17:44         ` DervishD
2004-11-03 18:53           ` Gene Heskett
2004-11-03 19:01             ` Doug McNaught
2004-11-03 19:03             ` Måns Rullgård
2004-11-03 19:24               ` Gene Heskett
2004-11-03 19:33                 ` Doug McNaught
2004-11-03 19:34                 ` Måns Rullgård
2004-11-03 19:06             ` Valdis.Kletnieks
2004-11-03 19:26               ` Gene Heskett
2004-11-03 19:33                 ` Valdis.Kletnieks
2004-11-03 20:09                   ` Gene Heskett
2004-11-04 19:24                     ` Bill Davidsen
2004-11-03 19:42                 ` DervishD
2004-11-03 23:12                   ` Bill Davidsen
2004-11-04 10:26                     ` DervishD
2004-11-04 14:23                       ` Paul Slootman
2004-11-04 14:56                         ` Gene Heskett
2004-11-04 18:24                         ` DervishD
2004-11-04 19:22                       ` Bill Davidsen
2004-11-04 20:53                         ` DervishD
2004-11-03 19:26             ` DervishD
2004-11-03 20:18               ` Gene Heskett
2004-11-03 22:15               ` Jim Nelson
2004-11-03 22:44                 ` Russell Miller
2004-11-03 23:03                   ` Doug McNaught
2004-11-03 23:33                     ` Russell Miller
2004-11-03 23:47                       ` Mathieu Segaud
2004-11-03 23:56                         ` Russell Miller
2004-11-04  0:05                           ` Mathieu Segaud
2004-11-04  6:39                       ` Denis Vlasenko
2004-11-05  2:38                         ` Elladan
2004-11-05  3:10                           ` Tim Connors
2004-11-05  3:17                             ` Russell Miller
2004-11-05  4:38                             ` Elladan
2004-11-05  5:00                             ` Kyle Moffett
2004-11-04 20:06                       ` Bill Davidsen [this message]
2004-11-03 23:06                   ` vlobanov
2004-11-04 10:04                   ` Helge Hafting
2004-11-04 17:16                     ` Alex Bennee
2004-11-04 16:30                 ` Pedro Venda (SYSADM)
2004-11-04 22:28                   ` Helge Hafting
2004-11-03 23:07               ` Bill Davidsen
2004-11-04  1:19                 ` Michael Clark
2004-11-04 16:01         ` kernel
2004-11-04 16:18           ` Gene Heskett
2004-11-04 16:47             ` kernel
2004-11-04 17:58               ` Gene Heskett
2004-11-03 22:58       ` Bill Davidsen
2004-11-04 10:23         ` DervishD
2004-11-04 19:32           ` Bill Davidsen
2004-11-04 21:11             ` DervishD
2004-11-09 23:31               ` Bill Davidsen
2004-11-10  9:11                 ` DervishD
2004-11-03 23:18       ` Adam Heath
2004-11-03 16:38     ` Gene Heskett
2004-11-03 16:24   ` Gene Heskett
2004-11-03 16:46     ` linux-os
2004-11-03 19:12       ` Gene Heskett
2004-11-03 19:56       ` Måns Rullgård
2004-11-03 20:13     ` Helge Hafting
2004-11-03 20:40       ` Gene Heskett
2004-11-04  0:43         ` Kurt Wall
2004-11-04  1:01           ` Russell Miller
2004-11-04  1:38             ` Doug McNaught
2004-11-04  1:45               ` Russell Miller
2004-11-04  1:56                 ` Doug McNaught
2004-11-04  1:59                 ` Mitchell Blank Jr
2004-11-04 20:10                   ` Bill Davidsen
2004-11-04 10:07         ` Matthias Andree
2004-11-04 22:31           ` Peter Chubb
2004-11-04 23:33           ` Benno
2004-11-03 20:48 ` Tom Felker
2004-11-03 21:08   ` Gene Heskett
2004-11-04  7:19     ` Jan Knutar
2004-11-04 11:57       ` Gene Heskett
2004-11-04 12:12         ` Jan Knutar
2004-11-04 12:18           ` Gene Heskett
2004-11-04 12:29             ` Jan Knutar
2004-11-04 13:56               ` Gene Heskett
2004-11-04 12:39           ` Gene Heskett
2004-11-04 13:01             ` Ian Campbell
2004-11-04 14:07               ` Gene Heskett
2004-11-04 14:24                 ` Ian Campbell
2004-11-04 15:10                   ` Gene Heskett
2004-11-04 14:26                 ` DervishD
2004-11-04 15:13                   ` Gene Heskett
2004-11-04 13:10             ` Doug McNaught
2004-11-04 14:11               ` Gene Heskett
2004-11-04 14:42                 ` tlaurent
2004-11-04 15:14                   ` Gene Heskett
2004-11-04 20:18             ` Bill Davidsen
2004-11-05  0:29   ` Gene Heskett

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=418A8BBF.8040901@tmr.com \
    --to=davidsen@tmr.com \
    --cc=doug@mcnaught.org \
    --cc=gene.heskett@verizon.net \
    --cc=james4765@verizon.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lkml@dervishd.net \
    --cc=mru@inprovide.com \
    --cc=rmiller@duskglow.com \
    /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