From: Russell King <rmk+lkml@arm.linux.org.uk>
To: "Hyok S. Choi" <hyok.choi@samsung.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2.6.17-rc1] [SERIAL] DCC(JTAG) serial and the console emulation support(revised#2)
Date: Tue, 4 Apr 2006 09:20:05 +0100 [thread overview]
Message-ID: <20060404082005.GB8573@flint.arm.linux.org.uk> (raw)
In-Reply-To: <200604041127.07290.hyok.choi@samsung.com>
On Tue, Apr 04, 2006 at 11:27:06AM +0900, Hyok S. Choi wrote:
> On Tuesday 04 April 2006 04:44 am, Russell King wrote:
> > On Mon, Apr 03, 2006 at 08:24:10PM +0900, Hyok S. Choi wrote:
> >
> > > +static void dcc_shutdown(struct uart_port *port)
> > > +{
> > > +#ifdef DCC_IRQ_USED /* real IRQ used */
> > > + free_irq(port->irq, port);
> > > +#else
> > > + spin_lock(&port->lock);
> > > + cancel_rearming_delayed_work(&dcc_poll_task);
> >
> > cancel_rearming_delayed_work() might sleep due to it calling
> > flush_workqueue. Therefore, you must not be holding a spinlock.
>
> Thus, I've just revised the code to lock around a counter variable
> operation, which is used for life control of the polling task.
> I've just posted the revised #3. :-)
Why do you think you need such complexity?
cancel_rearming_delayed_work() will wait until the poll task has
completed and has been removed from the system. It's explicitly
designed for work handlers which self-rearm.
--
Russell King
Linux kernel 2.6 ARM Linux - http://www.arm.linux.org.uk/
maintainer of: 2.6 Serial core
next prev parent reply other threads:[~2006-04-04 8:20 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-04-03 11:24 [PATCH 2.6.17-rc1] [SERIAL] DCC(JTAG) serial and the console emulation support(revised#2) Hyok S. Choi
2006-04-03 19:44 ` Russell King
2006-04-04 2:27 ` Hyok S. Choi
2006-04-04 8:20 ` Russell King [this message]
2006-04-04 9:46 ` Hyok S. Choi
2006-04-04 9:51 ` Russell King
-- strict thread matches above, loose matches on Subject: below --
2006-04-03 11:48 Hyok S. Choi
2006-04-03 11:54 Hyok S. Choi
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=20060404082005.GB8573@flint.arm.linux.org.uk \
--to=rmk+lkml@arm.linux.org.uk \
--cc=hyok.choi@samsung.com \
--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