mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: David Huggins-Daines <dhd@eradicator.org>
To: linux-kernel@vger.kernel.org
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Subject: [PATCH] cs46xx deadlocks in non-blocking read
Date: 01 Jan 2001 14:17:02 -0500	[thread overview]
Message-ID: <87y9wvhykx.fsf@monolith.cepstral.com> (raw)

Without this patch, the cs46xx driver in 2.4-prelease (well, in
-test12, at least) will hang the machine as soon as someone tries to
read from it in non-blocking mode.

The cs_read() function already removes the wait queue on exit, so it's
basically a correctness fix.

I've already sent this to Nils/Thomas but since it hasn't materialized
in prerelease or ac1, and since it's quite small and needed for a
number of things to function correctly, I'm sending it again in the
hopes that it will get applied before 2.4 final.

Cheers

--- linux-2.4/drivers/sound/cs46xx.c~	Sun Dec 31 18:24:54 2000
+++ linux-2.4/drivers/sound/cs46xx.c	Mon Jan  1 14:03:19 2001
@@ -1971,7 +1971,6 @@
 			start_adc(state);
 			if (file->f_flags & O_NONBLOCK) {
 				if (!ret) ret = -EAGAIN;
-				remove_wait_queue(&state->dmabuf.wait, &wait);
 				break;
  			}
 			schedule();

-- 
David Huggins-Daines		-		dhd@eradicator.org
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

             reply	other threads:[~2001-01-01 19:48 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-01-01 19:17 David Huggins-Daines [this message]
2001-01-01 19:34 ` Alan Cox

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=87y9wvhykx.fsf@monolith.cepstral.com \
    --to=dhd@eradicator.org \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=linux-kernel@vger.kernel.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

all inboxes | Powered by JetHome®