[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Sat, 2 Feb 2013 10:16:00 -0500 (EST)
From: Alan Stern <stern@...land.harvard.edu>
To: Stefan Richter <stefanr@...6.in-berlin.de>
cc: Mark Einon <mark.einon@...il.com>,
Peter Hurley <peter@...leysoftware.com>,
<linux1394-devel@...ts.sourceforge.net>,
<linux-kernel@...r.kernel.org>, <linux-pm@...r.kernel.org>
Subject: Re: [PATCH] firewire: Fix ohci free_irq() warning
On Sat, 2 Feb 2013, Stefan Richter wrote:
> On Feb 01 Mark Einon wrote:
> > On 1 February 2013 21:09, Peter Hurley <peter@...leysoftware.com> wrote:
> > >>>> On Jan 29 Alan Stern wrote:
> > >>>>> Why does the pci_suspend routine call free_irq() at all? As far as I
> > >>>>> know, it's not supposed to do that. Won't the device continue to use
> > >>>>> the same IRQ after it is resumed?
>
> As far as I can tell, it happened to be done that way as a side effect of
> how the probe() and resume() methods share code. It has remained like
> this since the initial implementation:
> http://git.kernel.org/linus/2aef469a35a2
At one point, quite a few years ago, Linus complained about drivers the
release IRQs during suspend only to reacquire them during resume. A
little refactoring should be able to separate out resource
acquisition/release (done only during probe and remove) from activation
and shutdown (also done during resume and suspend).
> Still, at this point I would like to learn whether .suspend() followed
> by .remove() is a valid order of sequence which drivers must support
> before I prepare myself to get comfortable with a refactoring of
> firewire-ohci's .probe()/.resume()/suspend()/remove(). Obviously, so far
> my assumption was that a successful .suspend() can only ever be followed
> by .resume().
It depends on the subsystem. Some subsystems do have suspend -> remove
transitions and others don't. In general, it's a good idea for drivers
to be prepared for removal while the system is asleep. Presumably any
hot-unpluggable bus (which includes most of the important buses these
days) would have to support it.
Alan Stern
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists