From: Francois Romieu <romieu@fr.zoreil.com>
To: Felipe W Damasio <felipewd@terra.com.br>
Cc: torvalds@osdl.org, akpm@osdl.org, alan@redhat.com,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] drivers/char/riscom8.c: cli/sti removal
Date: Wed, 30 Jul 2003 21:05:50 +0200 [thread overview]
Message-ID: <20030730210550.A5015@electric-eye.fr.zoreil.com> (raw)
In-Reply-To: <3F2804CC.90602@terra.com.br>; from felipewd@terra.com.br on Wed, Jul 30, 2003 at 02:47:56PM -0300
Felipe W Damasio <felipewd@terra.com.br> :
[cli+restore/spinlock conversioni for riscom8]
> --- linux-2.6.0-test2/drivers/char/riscom8.c.orig Wed Jul 30 14:39:11 2003
> +++ linux-2.6.0-test2/drivers/char/riscom8.c Wed Jul 30 14:42:44 2003
[...]
> @@ -1084,7 +1090,7 @@
> if (!port || rc_paranoia_check(port, tty->name, "close"))
> return;
>
> - save_flags(flags); cli();
> + spin_lock_irqsave(&rc_lock, flags);
> if (tty_hung_up_p(filp))
> goto out;
>
1111 tty->closing = 1;
1112 if (port->closing_wait != ASYNC_CLOSING_WAIT_NONE)
1113 tty_wait_until_sent(tty, port->closing_wait);
^^^^^^^^^^^^^^^^^^^ -> may sleep
[...]
1132 while(port->IER & IER_TXEMPTY) {
1133 current->state = TASK_INTERRUPTIBLE;
1134 schedule_timeout(port->timeout);
^^^^^^^^^^^^^^^^ -> <blink>BOOM</blink>
If you haven't read Documentation/DocBook/kernel-locking.tmpl, please give
it a try. If you have, well, double-check your code.
Regards
--
Ueimor
prev parent reply other threads:[~2003-07-30 19:07 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-07-30 17:47 Felipe W Damasio
2003-07-30 19:05 ` Francois Romieu [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=20030730210550.A5015@electric-eye.fr.zoreil.com \
--to=romieu@fr.zoreil.com \
--cc=akpm@osdl.org \
--cc=alan@redhat.com \
--cc=felipewd@terra.com.br \
--cc=linux-kernel@vger.kernel.org \
--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
all inboxes | Powered by JetHome®