* Re: [linux-pm] [PATCH v2] Add suspend/resume for HPET
@ 2007-04-02 14:16 Alan Stern
2007-04-02 17:09 ` Linus Torvalds
2007-04-02 19:16 ` David Brownell
0 siblings, 2 replies; 17+ messages in thread
From: Alan Stern @ 2007-04-02 14:16 UTC (permalink / raw)
To: David Brownell
Cc: Maxim Levitsky, Ingo Molnar, Linus Torvalds, Greg KH,
Thomas Gleixner, Kernel development list, Linux-pm mailing list
On Saturday March 31, 2007, David Brownell wrote:
> I'm about ready to test the appended patch... a "move one device" call
> might be safest at this point in the release cycle though.
>
> - Dave
>
> ======================== SNIP!
> Change how the PM list is constructed, so that devices are added right
> after their parents (when they have one) rather than at the end of the
> list. This preserves sequencing guarantees, but enables sequencing of
> suspend/resume operations by more important characteristics than "when
> device happened to enumerate" ... e.g. clocksources and clockevents
> at a clearly defined point during suspend and resume.
>
> This patch has a potential downside for devices that have multiple
> power dependencies and which "just happened to work" before.
Dave:
Would you mind retracting this patch? It will interfere with some work
I've been doing in USB, work that relies on exactly the sort of multiple
power dependency you mention.
The problem is this: When a low- or full-speed USB device is resumed
following a power loss (this is part of the "persistent USB" patch), it's
necessary for the corresponding EHCI root hub to be resumed first so that
the port's OWNER bit can be set properly.
It works fine as long as devices are resumed in order of registration,
because a low- or full-speed USB device can't be registered before the
high-speed root hub. (If it was, it would be disconnected when the
high-speed root hub initialized and took control of the port.) So this
isn't a "just happened to work" situation; it really is a critical
ordering dependency.
The clock source problem can be solved in other ways. For instance, right
now things are set up so that clock sources are registered at various
random times and the clockevents code adapts to use the best available
device, right?. So simply arrange for a clock source to "depart" as it is
suspended; then clockevents can fall back to using other lower-precision
sources. As long as devices suspend in reverse order of discovery, the
system should always function properly.
Alan Stern
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [linux-pm] [PATCH v2] Add suspend/resume for HPET
2007-04-02 14:16 [linux-pm] [PATCH v2] Add suspend/resume for HPET Alan Stern
@ 2007-04-02 17:09 ` Linus Torvalds
2007-04-02 19:16 ` David Brownell
1 sibling, 0 replies; 17+ messages in thread
From: Linus Torvalds @ 2007-04-02 17:09 UTC (permalink / raw)
To: Alan Stern
Cc: David Brownell, Maxim Levitsky, Ingo Molnar, Greg KH,
Thomas Gleixner, Kernel development list, Linux-pm mailing list
On Mon, 2 Apr 2007, Alan Stern wrote:
>
> Would you mind retracting this patch? It will interfere with some work
> I've been doing in USB, work that relies on exactly the sort of multiple
> power dependency you mention.
I agree. We should just make the damn timers be added at the right point.
We can for example *add* the devices early, even if we then actually start
using them at some later date.
Linus
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [PATCH v2] Add suspend/resume for HPET
@ 2007-04-02 17:09 ` Linus Torvalds
0 siblings, 0 replies; 17+ messages in thread
From: Linus Torvalds @ 2007-04-02 17:09 UTC (permalink / raw)
To: Alan Stern
Cc: Maxim Levitsky, Ingo Molnar, Linux-pm mailing list,
Thomas Gleixner, Kernel development list
On Mon, 2 Apr 2007, Alan Stern wrote:
>
> Would you mind retracting this patch? It will interfere with some work
> I've been doing in USB, work that relies on exactly the sort of multiple
> power dependency you mention.
I agree. We should just make the damn timers be added at the right point.
We can for example *add* the devices early, even if we then actually start
using them at some later date.
Linus
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [linux-pm] [PATCH v2] Add suspend/resume for HPET
2007-04-02 14:16 [linux-pm] [PATCH v2] Add suspend/resume for HPET Alan Stern
@ 2007-04-02 19:16 ` David Brownell
2007-04-02 19:16 ` David Brownell
1 sibling, 0 replies; 17+ messages in thread
From: David Brownell @ 2007-04-02 19:16 UTC (permalink / raw)
To: Alan Stern
Cc: Maxim Levitsky, Ingo Molnar, Linus Torvalds, Greg KH,
Thomas Gleixner, Kernel development list, Linux-pm mailing list
On Monday 02 April 2007 7:16 am, Alan Stern wrote:
> On Saturday March 31, 2007, David Brownell wrote:
>
> > Change how the PM list is constructed, so that devices are added right
> > after their parents (when they have one) rather than at the end of the
> > list. ...
> >
> > This patch has a potential downside for devices that have multiple
> > power dependencies and which "just happened to work" before.
>
> Dave:
>
> Would you mind retracting this patch? It will interfere with some work
> I've been doing in USB, work that relies on exactly the sort of multiple
> power dependency you mention.
It's out there for discussion right now more than merging.
What the driver model does now is problematic. Even if the clockevent
stuff gets different fixes, those driver model issues still exist: the
existence of dependencies that are not part of the device tree.
> The problem is this: When a low- or full-speed USB device is resumed
> following a power loss (this is part of the "persistent USB" patch), it's
Yeah, that "persistent USB" stuff that I don't like at all! Power off
is power off, and should be treated just like any other case of the USB
circuit being broken. (Offtopic here, of course.)
> necessary for the corresponding EHCI root hub to be resumed first so that
> the port's OWNER bit can be set properly.
>
> It works fine as long as devices are resumed in order of registration,
> because a low- or full-speed USB device can't be registered before the
> high-speed root hub. (If it was, it would be disconnected when the
> high-speed root hub initialized and took control of the port.) So this
> isn't a "just happened to work" situation; it really is a critical
> ordering dependency.
No, it's a "just happened to work" because the only ordering promise
that was explicitly made is that the parent/child relationships will
be obeyed. Any additional ordering dependency is out-of-scope of the
current driver model -- and that's a proble that eventually needs to
be fixed.
This is the kind of thing that the pm_parent relationship was (AFAICT)
originally supposed to handle. Of course, it doesn't/can't, given the
current implementation ... that relationship is never used.
> The clock source problem can be solved in other ways. For instance, right
> now things are set up so that clock sources are registered at various
> random times and the clockevents code adapts to use the best available
> device, right?.
Clocksource ~= counter, clockevent ~= timer irq ... you're mixing the
two, they're different! Both can be registered at various times; and
the best available instance of both is used. (Unfortunately "best" is
not a static policy on x86 hardware.)
> So simply arrange for a clock source to "depart" as it is
> suspended; then clockevents can fall back to using other lower-precision
> sources. As long as devices suspend in reverse order of discovery, the
> system should always function properly.
It's not that simple though, especially with HPET. The BIOS may expect
the PIT to work, but Linux currently (and problematically!) uses HPET in
"legacy replacement mode". And ISTR the problems are coming up when the
system is already in a low-functionality state: IRQs off everywhere,
even timer ticks have stopped.
- Dave
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [PATCH v2] Add suspend/resume for HPET
@ 2007-04-02 19:16 ` David Brownell
0 siblings, 0 replies; 17+ messages in thread
From: David Brownell @ 2007-04-02 19:16 UTC (permalink / raw)
To: Alan Stern
Cc: Linux-pm mailing list, Maxim Levitsky, Ingo Molnar,
Linus Torvalds, Thomas Gleixner, Kernel development list
On Monday 02 April 2007 7:16 am, Alan Stern wrote:
> On Saturday March 31, 2007, David Brownell wrote:
>
> > Change how the PM list is constructed, so that devices are added right
> > after their parents (when they have one) rather than at the end of the
> > list. ...
> >
> > This patch has a potential downside for devices that have multiple
> > power dependencies and which "just happened to work" before.
>
> Dave:
>
> Would you mind retracting this patch? It will interfere with some work
> I've been doing in USB, work that relies on exactly the sort of multiple
> power dependency you mention.
It's out there for discussion right now more than merging.
What the driver model does now is problematic. Even if the clockevent
stuff gets different fixes, those driver model issues still exist: the
existence of dependencies that are not part of the device tree.
> The problem is this: When a low- or full-speed USB device is resumed
> following a power loss (this is part of the "persistent USB" patch), it's
Yeah, that "persistent USB" stuff that I don't like at all! Power off
is power off, and should be treated just like any other case of the USB
circuit being broken. (Offtopic here, of course.)
> necessary for the corresponding EHCI root hub to be resumed first so that
> the port's OWNER bit can be set properly.
>
> It works fine as long as devices are resumed in order of registration,
> because a low- or full-speed USB device can't be registered before the
> high-speed root hub. (If it was, it would be disconnected when the
> high-speed root hub initialized and took control of the port.) So this
> isn't a "just happened to work" situation; it really is a critical
> ordering dependency.
No, it's a "just happened to work" because the only ordering promise
that was explicitly made is that the parent/child relationships will
be obeyed. Any additional ordering dependency is out-of-scope of the
current driver model -- and that's a proble that eventually needs to
be fixed.
This is the kind of thing that the pm_parent relationship was (AFAICT)
originally supposed to handle. Of course, it doesn't/can't, given the
current implementation ... that relationship is never used.
> The clock source problem can be solved in other ways. For instance, right
> now things are set up so that clock sources are registered at various
> random times and the clockevents code adapts to use the best available
> device, right?.
Clocksource ~= counter, clockevent ~= timer irq ... you're mixing the
two, they're different! Both can be registered at various times; and
the best available instance of both is used. (Unfortunately "best" is
not a static policy on x86 hardware.)
> So simply arrange for a clock source to "depart" as it is
> suspended; then clockevents can fall back to using other lower-precision
> sources. As long as devices suspend in reverse order of discovery, the
> system should always function properly.
It's not that simple though, especially with HPET. The BIOS may expect
the PIT to work, but Linux currently (and problematically!) uses HPET in
"legacy replacement mode". And ISTR the problems are coming up when the
system is already in a low-functionality state: IRQs off everywhere,
even timer ticks have stopped.
- Dave
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [linux-pm] [PATCH v2] Add suspend/resume for HPET
2007-04-02 19:16 ` David Brownell
@ 2007-04-02 20:04 ` Alan Stern
-1 siblings, 0 replies; 17+ messages in thread
From: Alan Stern @ 2007-04-02 20:04 UTC (permalink / raw)
To: David Brownell
Cc: Maxim Levitsky, Ingo Molnar, Linus Torvalds, Greg KH,
Thomas Gleixner, Kernel development list, Linux-pm mailing list
On Mon, 2 Apr 2007, David Brownell wrote:
> What the driver model does now is problematic. Even if the clockevent
> stuff gets different fixes, those driver model issues still exist: the
> existence of dependencies that are not part of the device tree.
> No, it's a "just happened to work" because the only ordering promise
> that was explicitly made is that the parent/child relationships will
> be obeyed. Any additional ordering dependency is out-of-scope of the
> current driver model -- and that's a proble that eventually needs to
> be fixed.
>
> This is the kind of thing that the pm_parent relationship was (AFAICT)
> originally supposed to handle. Of course, it doesn't/can't, given the
> current implementation ... that relationship is never used.
Just so. In fact, there almost certainly are other dependencies that
nobody is aware of, simply because they have never had a chance to bite.
Such things can be rather difficult to pin down when they occur. I would
be happy enough to leave matters as they are, with a strict LIFO approach.
If someone ever tries to parallelize suspend/resume in multiple threads,
they will have their work cut out for them -- even probing ran into
trouble when attempts were made to parallelize it, and it's a lot simpler.
> It's not that simple though, especially with HPET. The BIOS may expect
> the PIT to work, but Linux currently (and problematically!) uses HPET in
> "legacy replacement mode". And ISTR the problems are coming up when the
> system is already in a low-functionality state: IRQs off everywhere,
> even timer ticks have stopped.
I know nothing about the workings of the HPET and other clock code. My
point was this: Suspend passes through various intermediate stages in
which some devices are available and others aren't. So long as those
stages are exact duplicates (in reverse order) of the stages that occurred
during startup, it should be possible to make them all work.
Alan Stern
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [PATCH v2] Add suspend/resume for HPET
@ 2007-04-02 20:04 ` Alan Stern
0 siblings, 0 replies; 17+ messages in thread
From: Alan Stern @ 2007-04-02 20:04 UTC (permalink / raw)
To: David Brownell
Cc: Linux-pm mailing list, Maxim Levitsky, Ingo Molnar,
Linus Torvalds, Thomas Gleixner, Kernel development list
On Mon, 2 Apr 2007, David Brownell wrote:
> What the driver model does now is problematic. Even if the clockevent
> stuff gets different fixes, those driver model issues still exist: the
> existence of dependencies that are not part of the device tree.
> No, it's a "just happened to work" because the only ordering promise
> that was explicitly made is that the parent/child relationships will
> be obeyed. Any additional ordering dependency is out-of-scope of the
> current driver model -- and that's a proble that eventually needs to
> be fixed.
>
> This is the kind of thing that the pm_parent relationship was (AFAICT)
> originally supposed to handle. Of course, it doesn't/can't, given the
> current implementation ... that relationship is never used.
Just so. In fact, there almost certainly are other dependencies that
nobody is aware of, simply because they have never had a chance to bite.
Such things can be rather difficult to pin down when they occur. I would
be happy enough to leave matters as they are, with a strict LIFO approach.
If someone ever tries to parallelize suspend/resume in multiple threads,
they will have their work cut out for them -- even probing ran into
trouble when attempts were made to parallelize it, and it's a lot simpler.
> It's not that simple though, especially with HPET. The BIOS may expect
> the PIT to work, but Linux currently (and problematically!) uses HPET in
> "legacy replacement mode". And ISTR the problems are coming up when the
> system is already in a low-functionality state: IRQs off everywhere,
> even timer ticks have stopped.
I know nothing about the workings of the HPET and other clock code. My
point was this: Suspend passes through various intermediate stages in
which some devices are available and others aren't. So long as those
stages are exact duplicates (in reverse order) of the stages that occurred
during startup, it should be possible to make them all work.
Alan Stern
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [linux-pm] [PATCH v2] Add suspend/resume for HPET
2007-04-02 20:04 ` Alan Stern
@ 2007-04-03 5:54 ` Thomas Gleixner
-1 siblings, 0 replies; 17+ messages in thread
From: Thomas Gleixner @ 2007-04-03 5:54 UTC (permalink / raw)
To: Alan Stern
Cc: David Brownell, Maxim Levitsky, Ingo Molnar, Linus Torvalds,
Greg KH, Kernel development list, Linux-pm mailing list
On Mon, 2007-04-02 at 16:04 -0400, Alan Stern wrote:
> > It's not that simple though, especially with HPET. The BIOS may expect
> > the PIT to work, but Linux currently (and problematically!) uses HPET in
> > "legacy replacement mode". And ISTR the problems are coming up when the
> > system is already in a low-functionality state: IRQs off everywhere,
> > even timer ticks have stopped.
>
> I know nothing about the workings of the HPET and other clock code. My
> point was this: Suspend passes through various intermediate stages in
> which some devices are available and others aren't. So long as those
> stages are exact duplicates (in reverse order) of the stages that occurred
> during startup, it should be possible to make them all work.
Unfortunately it is not a fully linear problem. Devices are initialized
late and put the system into a more complex state (i.e. dynticks,
highres) which needs to be suspended and resumed. If we want to do this
completely linear we need to do a full reverse rollback of the system
states, which moves even more complexity into such systems.
Also the linear approach is not working with other devices, as one can
see with the still unresolved "IRQ#X nobody cared" issues at resume,
which break my laptop. It works nice on startup of the system, but
breaks on resume.
tglx
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [PATCH v2] Add suspend/resume for HPET
@ 2007-04-03 5:54 ` Thomas Gleixner
0 siblings, 0 replies; 17+ messages in thread
From: Thomas Gleixner @ 2007-04-03 5:54 UTC (permalink / raw)
To: Alan Stern
Cc: Linux-pm mailing list, Maxim Levitsky, Ingo Molnar,
Linus Torvalds, Kernel development list
On Mon, 2007-04-02 at 16:04 -0400, Alan Stern wrote:
> > It's not that simple though, especially with HPET. The BIOS may expect
> > the PIT to work, but Linux currently (and problematically!) uses HPET in
> > "legacy replacement mode". And ISTR the problems are coming up when the
> > system is already in a low-functionality state: IRQs off everywhere,
> > even timer ticks have stopped.
>
> I know nothing about the workings of the HPET and other clock code. My
> point was this: Suspend passes through various intermediate stages in
> which some devices are available and others aren't. So long as those
> stages are exact duplicates (in reverse order) of the stages that occurred
> during startup, it should be possible to make them all work.
Unfortunately it is not a fully linear problem. Devices are initialized
late and put the system into a more complex state (i.e. dynticks,
highres) which needs to be suspended and resumed. If we want to do this
completely linear we need to do a full reverse rollback of the system
states, which moves even more complexity into such systems.
Also the linear approach is not working with other devices, as one can
see with the still unresolved "IRQ#X nobody cared" issues at resume,
which break my laptop. It works nice on startup of the system, but
breaks on resume.
tglx
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [linux-pm] [PATCH v2] Add suspend/resume for HPET
2007-04-02 20:04 ` Alan Stern
@ 2007-04-04 15:06 ` David Brownell
-1 siblings, 0 replies; 17+ messages in thread
From: David Brownell @ 2007-04-04 15:06 UTC (permalink / raw)
To: Alan Stern
Cc: Maxim Levitsky, Ingo Molnar, Linus Torvalds, Greg KH,
Thomas Gleixner, Kernel development list, Linux-pm mailing list
On Monday 02 April 2007 1:04 pm, Alan Stern wrote:
> On Mon, 2 Apr 2007, David Brownell wrote:
> > This is the kind of thing that the pm_parent relationship was (AFAICT)
> > originally supposed to handle. Of course, it doesn't/can't, given the
> > current implementation ... that relationship is never used.
>
> Just so. In fact, there almost certainly are other dependencies that
> nobody is aware of, simply because they have never had a chance to bite.
In any given system, yes there are bugs lurking. But I was more concerned
with a provably wrong assumption made by the current framework. Such things
cause cascading fragility.
As Thomas mentioned, HPET isn't the only place where a "linear" model fails.
> Such things can be rather difficult to pin down when they occur. I would
> be happy enough to leave matters as they are, with a strict LIFO approach.
I wouldn't. Much better to have a solid handle on the interdependencies
than to need to cope, long term, with a framework that doesn't allow that.
Remember also that a LIFO model assumes that there's only one sequence by
which the hardware powers up/down ... i.e. that there's no runtime PM going
on, whereby large chunks are regularly powered down/up based on usage.
Better runtime PM becomes more important as system complexity rises.
- Dave
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [PATCH v2] Add suspend/resume for HPET
@ 2007-04-04 15:06 ` David Brownell
0 siblings, 0 replies; 17+ messages in thread
From: David Brownell @ 2007-04-04 15:06 UTC (permalink / raw)
To: Alan Stern
Cc: Linux-pm mailing list, Maxim Levitsky, Ingo Molnar,
Linus Torvalds, Thomas Gleixner, Kernel development list
On Monday 02 April 2007 1:04 pm, Alan Stern wrote:
> On Mon, 2 Apr 2007, David Brownell wrote:
> > This is the kind of thing that the pm_parent relationship was (AFAICT)
> > originally supposed to handle. Of course, it doesn't/can't, given the
> > current implementation ... that relationship is never used.
>
> Just so. In fact, there almost certainly are other dependencies that
> nobody is aware of, simply because they have never had a chance to bite.
In any given system, yes there are bugs lurking. But I was more concerned
with a provably wrong assumption made by the current framework. Such things
cause cascading fragility.
As Thomas mentioned, HPET isn't the only place where a "linear" model fails.
> Such things can be rather difficult to pin down when they occur. I would
> be happy enough to leave matters as they are, with a strict LIFO approach.
I wouldn't. Much better to have a solid handle on the interdependencies
than to need to cope, long term, with a framework that doesn't allow that.
Remember also that a LIFO model assumes that there's only one sequence by
which the hardware powers up/down ... i.e. that there's no runtime PM going
on, whereby large chunks are regularly powered down/up based on usage.
Better runtime PM becomes more important as system complexity rises.
- Dave
^ permalink raw reply [flat|nested] 17+ messages in thread
* Linux 2.6.21-rc4
@ 2007-03-16 16:33 Linus Torvalds
2007-03-31 16:33 ` [PATCH v2] Add suspend/resume for HPET Thomas Gleixner
0 siblings, 1 reply; 17+ messages in thread
From: Linus Torvalds @ 2007-03-16 16:33 UTC (permalink / raw)
To: Linux Kernel Mailing List
[-- Attachment #1: Type: TEXT/PLAIN, Size: 18693 bytes --]
I pushed out the -git trees yesterday, but then got distracted, so the
patches and tar-balls and the announcement got delayed until this morning.
Oops. I'm a scatter-brain.
Anyway, the good news about -rc4 is that there's just lots of random
fixes. I'm hoping that we've seriously cut down on the regression list,
and I'd ask everybody who is on Adrian's list to please re-verify their
regression, and in case it's one of the "patches available" ones but I
haven't merged (maybe because it hasn't been sent to me!), make sure I do.
Shortlog appended. Nothing really stands out.
Linus
---
Adrian Bunk (2):
[DLM] fs/dlm/user.c should #include "user.h"
asus-laptop: make code static
Adrian Hunter (2):
[MTD] Correct partition failed erase address
[MTD] [OneNAND] add Nokia Copyright and a credit
Aji Srinivas (1):
[BRIDGE]: adding new device to bridge should enable if up
Akiyama, Nobuyuki (1):
[IA64] add missing syscall trace clear
Al Viro (31):
fix deadlock in audit_log_task_context()
sanitize security_getprocattr() API
ibmtr probe is __devinit, not __init
const file_operations fallout
appldata build fix
(uml) sparse flags for userland glue are missing $(CF)
zatm __init abuse
stacktrace doesn't work on uml
fix ipath_dma_free_coherent() prototype
m32r dma-mapping.h should simply include generic/dma-mapping-broken.h
include of asm/pgtable.h in nfsfh is bogus
BLK_DEV_IDE_CELLEB dependency fix
sparc: have dma-mapping.h include generic/dma-mapping-broken in non-PCI case
rtc-cmos needs RTC_ALWAYS_BCD known
misc NULL noise
fastcall still doesn't make sense in paravirt
dmfe trivial endianness annotations
constant should be long
pasemi trivial iomem annotations
sparc: nr_free_pages() is unsigned long
trivial ATA iomem annotations
cciss endian annotations
qeth gfp_t annotations
C99 initializers, proper use of const in drivers/ps3
cifs endianness annotations
hid-core endianness annotations
ANSIfy powerpc floppy.h
atl1 trivial endianness misannotations
kill bogus casts in amd64 uaccess.h
paride endianness annotations
m68k dma-mapping: gfp_t annotations
Alan Cox (4):
[MTD] [MAPS] dilnetpc: Fix printk warning
libata-acpi: Try and stop all the non PCI devices crashing
ata_piix: Remove ugly layering violation
z85230: Fix FIFO handling
Alan Stern (4):
USB: set the correct interval for interrupt URBs
UHCI: fix port resume problem
sysfs and driver core: add callback helper, used by SCSI and S390
sysfs: reinstate exclusion between method calls and attribute unregistration
Alexey Starikovskiy (2):
ACPICA: Fix ACPI Global Lock re-entrancy
ACPI: ec: fix race in status register access
Andre Spahlinger (1):
USB: ipaq.c: Additional devices
Andrew Morton (1):
sony-laptop: fix uninitialised variable
Andrew Nayenko (1):
USB storage: Nokia 6288 unusual_devs entry
Anthony Godshall, Ampro Computers, Inc (1):
ACPI: make blacklist more verbose
Arnd Bergmann (2):
[POWERPC] spufs: fix possible memory corruption is spufs_mem_write
[POWERPC] update cell_defconfig
Artem Bityutskiy (1):
[JFFS2] print a message when marking bad block
Benjamin Herrenschmidt (4):
[POWERPC] Fix warning in prom_parse.c of_irq_map_oldworld()
[POWERPC] Fix warning in powermac feature.c
[POWERPC] Fix warning in powermac pci.c
[POWERPC] Fix spu SLB invalidations
Bernhard Walle (1):
ACPI: Add kernel-parameters hint that acpi=off doesn't work on IA64.
Brice Goglin (4):
myri10ge: fix error checking and return value in myri10ge_allocate_rings
myri10ge: use pci_map_page to prepare the dmatest buffer
myri10ge: prevent 4k rdma on SGI TIOCE chipset
myri10ge: add a wc_enabled flag to myri10ge_priv
Chris Dearman (1):
[MIPS] Oprofile: Reset all performance registers for MIPS_MT_SMP configs
Chris Wright (1):
[IPV6] fix ipv6_getsockopt_sticky copy_to_user leak
Christoph Hellwig (1):
[POWERPC] avoid SPU_ACTIVATE_NOWAKE optimization
Cyrill Gorcunov (2):
[MTD] ESB2 check for closed ROM window
USB Elan FTDI: check for workqueue creation
Dale Farnsworth (1):
mv643xx: Clear pending interrupts before calling request_irq
Dan Williams (1):
[ARM] 4248/1: lh7a40x: fix missing definitions for get_irqnr_preamble
Dave Jones (2):
update 'getting sparse' info.
build fix for i386 earlyquirk.c
David Brownell (1):
USB: at91_udc, fix more modpost bogosity (rename driver struct)
David Miller (1):
RDMA/cxgb3: Fix build on sparc64
David S. Miller (5):
[IPV6]: Handle np->opt being NULL in ipv6_getsockopt_sticky().
[SPARC64]: Fix PARPORT build (again).
[SPARC]: We do not need OLD_GETRLIMIT.
[SPARC]: Hook up missing syscalls.
[SPARC64]: Add missing HPAGE_MASK masks on address parameters.
David Woodhouse (2):
[JFFS2] Use yield() between GC passes in background thread.
[JFFS2] Check for all-zero node headers
Davide Libenzi (1):
Add epoll compat_ code to fs/compat.c
Dirk Behme (1):
ARM: OMAP: Fix missing workqueue include in board-h2.c
Dmitriy Monakhov (1):
kobject: new_device->kref wasn't putted after error in kobject_move()
Dmitry Torokhov (1):
Input: i8042 - another attempt to fix AUX delivery checks
Eric Paris (3):
[IPSEC]: xfrm_policy delete security check misplaced
[IPSEC]: Add xfrm policy change auditing to pfkey_spdget
[IPSEC]: xfrm audit hook misplaced in pfkey_delete and xfrm_del_sa
Eric W. Biederman (2):
msi: Safer state caching.
pci: Repair pci_save/restore_state so we can restore one save many times.
Evgeniy Polyakov (1):
[IPV4]: Fix rtm_to_ifaddr() error handling.
Fenghua Yu (1):
[IA64] fsys_getcpu for IA64
Francois Romieu (2):
r8169: revert bogus BMCR reset
r8169: fix a race between PCI probe and dev_open
Gard Spreemann (1):
USB: Product ID for FT232RL in ftdi_sio
Gary Zambrano (1):
avr32: dma-mapping.h
Geert Uytterhoeven (2):
[POWERPC] ps3: always make sure were running on a PS3
[IPV4]: Fix warning in ip_mc_rejoin_group.
Gerrit Renker (2):
[DCCP]: Revert patch which disables bidirectional mode
[DCCP]: Initialise write_xmit_timer also on passive sockets
Greg Kroah-Hartman (2):
Revert "driver core: refcounting fix"
Driver core: add device symlink back to sysfs
Haavard Skinnemoen (5):
[AVR32] at32_spi_setup_slaves should be __init
[AVR32] show_trace: Only walk valid stack addresses
[AVR32] Fix typo in include/asm-avr32/Kbuild
[AVR32] Fix bogus ti->flags manipulation in debug handler
[AVR32] Don't use kmap() in flush_icache_page()
Henrique de Moraes Holschuh (3):
ACPI: ibm-acpi: fix initial status of backlight device
ACPI: ibm-acpi: make ibm-acpi bay support optional
ACPI: ibm-acpi: improve backlight power handling
Herbert Xu (2):
[UDP]: Reread uh pointer after pskb_trim
[IPV6]: Do not set IF_READY if device is down
Hideo Saito (1):
sh: Fix kernel thread stack corruption with preempt.
Hoang-Nam Nguyen (1):
IB/ehca: Fix sync between completion handler and destroy cq
Horms (3):
[IA64] remove duplicate declaration of efi_initialize_iomem_resources
[IA64] whitespace fixes for include/asm-ia64/sal.h
[IA64] put kdump_find_rsvd_region in __init
Ingo Molnar (1):
CPU hotplug: call check_tsc_sync_source() with irqs off
Ishizaki Kou (1):
[POWERPC] Celleb: bug fix caused by not casting pointer types
Jarek Poplawski (1):
[SCTP] ipv6: inconsistent lock state ipv6_add_addr/sctp_v6_copy_addrlist
Jeff Dike (1):
uml: arch_prctl should set thread fs
Jim Radford (2):
usb-serial: fix shutdown / device_unregister order
USB: ftdi_sio: use port_probe / port_remove thereby fixing access to the latency_timer
Jiri Kosina (3):
bluetooth: fix socket locking in hci_sock_dev_event()
HID: allocate hid_parser in a proper way
HID: zeroing of bytes in output fields is bogus
Joel Becker (4):
ocfs2: Proper cleanup in case of error in ocfs2_register_hb_callbacks()
ocfs2: Concurrent access of o2hb_region->hr_task was not locked
ocfs2: add some missing address space callbacks
configfs: add missing mutex_unlock()
Joerg Sommer (1):
bcm43xx: Fix bug in frequency to channel conversion
Johannes Berg (1):
driver core: export device_rename
John Keller (2):
ACPI: Altix: cannot register acpi bus driver before bus scan
ACPI: Altix: reinitialize acpi tables
Jon K Hellan (1):
USB: New device IDs for cp2101 driver
Josef Whiter (2):
[GFS2] fix locking mistake
[GFS2] fix hangup when multiple processes are trying to write to the same file
Joy Latten (1):
[XFRM]: Fix missing protocol comparison of larval SAs.
Julius Volz (1):
ACPI: video: Fix spelling and grammar mistakes
Jörn Engel (1):
Remove devfs from MAINTAINERS
KAMEZAWA Hiroyuki (1):
[IA64] fix NULL pointer in ia64/irq_chip-mask/unmask function
Keith Owens (1):
[IA64] Remove sparse warning from unwind code
Konstantin Karasyov (2):
ACPI: fix S3 fan resume issue
ACPI: ThinkPad Z60m: usb mouse stops working after suspend to RAM
Kristen Accardi (1):
libata-acpi: allow _GTF on SATA, but disable on PATA for now
Kumar Gala (1):
[POWERPC] 85xx: Enable CONFIG_SERIAL_8250_SHARE_IRQ
Kyungmin Park (4):
[MTD] [OneNAND] Use oob buffer instead of main one in oob functions
[MTD] [OneNAND] Fix typo & wrong comments
[MTD] [OneNAND] Exit the loop when transferring/filling of the oob is finished
[MTD] [OneNAND] Classify the page data and oob buffer
Larry Finger (1):
bcm43xx: Fix errors in specs to code translation in B6PHY init
Len Brown (3):
ACPI: fix Thinkpad 600/600E/600X interrupts
ACPI: repair nvidia early quirk breakage on x86_64
ACPI: repair nvidia early quirk breakage on x86_64
Li Yang (1):
[POWERPC] 83xx: Minor fixes for 834x_mds USB setup code
Linsys Contractor Mithlesh Thukral (2):
NetXen: Bug fix for Jumbo frames on XG card
NetXen: Fix softlockup seen during hardware access
Linus Torvalds (3):
Revert "USB: pxa2xx_udc: fix hardcoded irq number"
Disable NMI watchdog by default properly
Linux 2.6.21-rc4
Martin Schiller (1):
USB: RTS/DTR signal patch for airprime driver
Mathieu Desnoyers (1):
[SPARC64]: Fix atomicity of TIF update in flush_thread()
Max Dmitrichenko (1):
USB: fix Unaligned access in EHCI driver
Michael Ellerman (1):
[POWERPC] Add missing newline in xmon help output
Michael Karcher (1):
ACPI: fix parallel port IRQ after resume from S3
Michael Olberg (1):
USB: add QL355P power supply ids to fdti_sio
Milan Svoboda (2):
USB: pxa2xx_udc: fix hardcoded irq number
[ARM] 4263/1: fix IXP4XX_NPE[ABC]_BASE_VIRT address
Olaf Kirch (1):
[IPV6]: Fix for ipv6_setsockopt NULL dereference
Oliver Neukum (5):
USB: ratelimit debounce error messages
USB: kill dead code from hub.c
USB: fix usb-serial device naming bug
USB: further fix for usb-serial
USB: fix spinlock recursion in cdc-acm.c
Olof Johansson (1):
[POWERPC] No DEEPNAP on 970MP 1.0
Paolo 'Blaisorblade' Giarrusso (9):
uml: hostfs: fix double free
uml: hostfs: make hostfs= option work as a jail, as intended.
um: fix a memory leak in the multicast driver
um: remove dead code about os_usr1_signal() and os_usr1_process()
um: mark both consoles as CON_ANYTIME
um: fix confusion irq early reenabling
uml: activate_fd: return ENOMEM only when appropriate
um: fix errno usage
x86_64: fix 2.6.18 regression - PTRACE_OLDSETOPTIONS should be accepted
Pat Gefre (1):
2.6 Altix: console fix for CONFIG_DEBUG_SHIRQ usage
Patrick McHardy (3):
[NETFILTER]: nf_conntrack_ipv6: fix incorrect classification of IPv6 fragments as ESTABLISHED
[NETFILTER]: nfnetlink_log: zero-terminate prefix
[NETFILTER]: nfnetlink_log: fix crash on bridged packet
Paul Moore (1):
[NetLabel]: parse the CIPSO ranged tag on incoming packets
Paul Mundt (6):
doc: Add SH to vdso and earlyprintk in kernel-parameters.txt
sysctl: Support vdso_enabled sysctl on SH.
sh: Use L1_CACHE_BYTES for .data.cacheline_aligned.
sh: Enable SM501 support for RTS7751R2D.
sh: Revert lazy dcache writeback changes.
sh: Kill off I/O cruft for R7780RP.
Pavel Pisa (3):
[ARM] 4254/1: i.MX/MX1 CPU Frequency scaling honor boot loader set BCLK_DIV.
[ARM] 4255/1: i.MX/MX1 Correct MPU PLL reference clock value.
[ARM] 4256/1: i.MX/MX1 SDHC fix/workaround of SD card recognition problems
Pavel Roskin (1):
bcm43xx: Fix assertion failures in interrupt handler
Peter Zijlstra (1):
ecryptfs: nested locking annotation
Petr Vandrovec (1):
Fix simplex adapters with libata
Phil Dibowitz (1):
USB storage: Removed duplicate supertop unusual_dev entry
Philipp Reisner (1):
[CONNECTOR]: Bugfix for cn_call_callback()
Ralf Baechle (14):
[CHAR] ds1286: Fix handling of seconds in RTC_ALM_SET ioctl.
[MIPS] ISA: Fix typo
[MIPS] ARC: Fix several compiler warnings.
[MIPS] DEC: Remove call to register_prom_console.
netxen: fix warnings
3c59x: Fix several modpost warnings
ibmtr: Drain rich supply of modpost warnings.
[MIPS] Sibyte: Do not allow enabling LDT support if PCI is disabled.
[MIPS] Sibyte: Fix ZBbus profiler
USB: goku_udc: Remove crude cache coherency code
[ROSE]: Remove ourselves from waitqueue when receiving a signal
[ROSE]: Socket locking is a great invention.
[MIPS] Viper2: Remove defective support.
[MIPS] kspd: ioctl needs a translation entry.
Richard Fearn (1):
[GFS2] add newline to printk message
Richard Purdie (3):
[ARM] 4249/1: Fix tosa compile failure
[ARM] 4250/1: Fix locomo backlight conversion error/compile failure
[ARM] 4251/1: Fix sharpsl_pm dependency
Richard Woodruff (1):
ARM: OMAP: Fix OMAP2 dss2 so clk_set_parent works
Robert Hancock (1):
sata_nv: revert use of notifiers for now
Robert P. J. Day (3):
[MTD] [NAND] Correct misspelled preprocessor variable.
ACPI: Kconfig: hide ACPI menu when CONFIG_PM=n
[WANROUTER]: Delete superfluous source file "net/wanrouter/af_wanpipe.c".
Robert Reif (2):
[CG14]: Fix section mismatch warnings.
[BW2]: Fix section mismatch warnings.
Roger Luethi (1):
via-rhine: set avoid_D3 for broken BIOSes
Roland Dreier (2):
IPoIB: Only handle async events for one port
IB/mthca: Fix error path in mthca_alloc_memfree()
Russ Anderson (2):
[IA64] Proper handling of TLB errors from duplicate itr.d dropins
[IA64] Cache error recovery
Ryusuke Sakato (1):
sh: Fix sigmask trampling in signal delivery.
Sam Ravnborg (3):
pcie: fix section mismatch warning
PCI: aer: fix section mismatch warning
pci: fix section mismatch warning
Sean Hefty (2):
RDMA/cma: Initialize rdma_bind_list in cma_alloc_any_port()
RDMA/ucma: Avoid sending reject if backlog is full
Segher Boessenkool (1):
[POWERPC] Select u-image as default image for Linkstation
Shaohua Li (1):
ACPI: fix boot hang w/o "noapic" on MSI MS-6390-L
Shirley Ma (1):
IPoIB: Turn on interface's carrier after broadcast group is joined
Simon Horman (2):
[IA64] kexec: declare ia64_mca_pal_base in mca.h rather than kexec.h
[IA64] Cleanup in crash.c
Stephen Hemminger (2):
sky2: turn off Rx checksum on bad hardware
skge: set mac address bonding fix
Stephen Rothwell (3):
[POWERPC] Allocate syscall number for sys_getcpu
[POWERPC] Wire up sys_epoll_pwait
[POWERPC] sys_move_pages should be callable from an SPU
Steve Wise (8):
RDMA/cxgb3: Start ep timer on a MPA reject
RDMA/cxgb3: Don't use mm after it's freed in iwch_mmap()
RDMA/cxgb3: Fixes for "normal close" failures
RDMA/cxgb3: Move QP to error on destroy if the state is IDLE
RDMA/cxgb3: Stop EP timer when MPA exchange is aborted by peer
RDMA/cxgb3: Squelch logging AE errors
RDMA/cxgb3: Don't reuse skbs that are non-linear or cloned
RDMA/cxgb3: Fix MR permission problems
Steven Whitehouse (5):
[GFS2] Fix bz 230143, incorrect flushing of rgrps
[GFS2] Fix bz 229831, lookup returns wrong inode
[GFS2] Remove unused variable
[GFS2] go_drop_bh is never used, so remove it
[GFS2] Fix bz 229873, alternate test: assertion "!ip->i_inode.i_mapping->nrpages" failed
Stuart Menefy (1):
sh: Clear UBC when not in use.
Sunil Mushran (2):
ocfs2_dlm: Missing get/put lockres in dlm_run_purge_lockres
ocfs2_dlm: Add missing locks in dlm_empty_lockres
Tejun Heo (3):
libata: fix ata_host_release() free order
devres: release resources on device_del()
PCI: allow multiple calls to pcim_pin_device()
Thomas Schleusener (1):
USB: add Additional PIDs in ftdi_sio
Tony Lindgren (1):
ARM: OMAP: Include missing header
Tony Luck (2):
[IA64] Pick highest possible saved_max_pfn for crash_dump
[IA64] refresh config files
Uwe Kleine-König (1):
[ARM] 4247/1: Fix long name for cc9p9360dev
Vijay Sampath (1):
[MTD] [NOR] Fix oops in cfi_amdstd_sync
Vitaly Wool (2):
[MTD] [NAND] make oobavail public
[JFFS2] Fix writebuffer recovery in the first page of a block
Wendy Cheng (2):
[GFS2] NFS filehandle check
[GFS2] pass formal ino in do_filldir_main
William Lee Irwin III (1):
[SPARC]: Fix TIF_USEDFPU flag atomicity
Wim Van Sebroeck (1):
[WATCHDOG] i8xx TCO driver - mark for removal
YOSHIFUJI Hideaki (1):
USBNET: DM9501: Add Corega FEther USB-TXC support.
Zachary Amsden (2):
Fix VMI and COMPAT_VDSO for 2.6.21
Fix vmi time header bug
Zhang, Yanmin (1):
[IA64] pci_get_legacy_ide_irq should return irq (not GSI)
akpm@linux-foundation.org (1):
[GFS2] build fix
broonie@sirena.org.uk (3):
natsemi: Consistently use interrupt enable/disable functions
natsemi: Fix NAPI for interrupt sharing
natsemi: Avoid IntrStatus lossage if RX state machine resets.
suzuki (1):
check_partition(): fix error check
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [PATCH v2] Add suspend/resume for HPET
@ 2007-03-31 16:33 ` Thomas Gleixner
2007-03-31 16:53 ` Linus Torvalds
0 siblings, 1 reply; 17+ messages in thread
From: Thomas Gleixner @ 2007-03-31 16:33 UTC (permalink / raw)
To: Linus Torvalds
Cc: Maxim Levitsky, Sergei Shtylyov, Ingo Molnar, Jeff Chua,
Adrian Bunk, Andrew Morton, Linux Kernel Mailing List,
Eric W. Biederman, Rafael J. Wysocki, pavel, linux-pm, gregkh,
linux-pci, Jens Axboe, Len Brown, linux-acpi, jgarzik, linux-ide,
Michael S. Tsirkin
On Sat, 2007-03-31 at 09:09 -0700, Linus Torvalds wrote:
>
> On Sat, 31 Mar 2007, Thomas Gleixner wrote:
> >
> > While I agree in principle with the patch, I'm a bit uncomfortable. The
> > sys device suspend / resume ordering is not guaranteed and relies on the
> > registering order.
>
> Well, this is why we probably should try to get away from the "system
> device" issue, exactly because system devices are totally outside the
> normal ordering and only have a random linear order.
>
> If the clocksources were actually in the device tree, you'd get all the
> normal guarantees about hierarchical ordering..
Right, but clock - sources/events need to be extremly late suspended and
early resumed. How can we ensure this ?
tglx
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [PATCH v2] Add suspend/resume for HPET
2007-03-31 16:33 ` [PATCH v2] Add suspend/resume for HPET Thomas Gleixner
@ 2007-03-31 16:53 ` Linus Torvalds
2007-03-31 17:02 ` Ingo Molnar
2007-03-31 17:55 ` David Brownell
0 siblings, 2 replies; 17+ messages in thread
From: Linus Torvalds @ 2007-03-31 16:53 UTC (permalink / raw)
To: Thomas Gleixner
Cc: Maxim Levitsky, Jeff Chua, linux-ide, Sergei Shtylyov, gregkh,
linux-pm, Linux Kernel Mailing List, Adrian Bunk, linux-acpi,
linux-pci, Eric W. Biederman, Jens Axboe, Michael S. Tsirkin,
Ingo Molnar, jgarzik, Andrew Morton
On Sat, 31 Mar 2007, Thomas Gleixner wrote:
>
> Right, but clock - sources/events need to be extremly late suspended and
> early resumed. How can we ensure this ?
Make them be at the top of the device tree by adding them early. That's
the whole point of the device tree after all - we have an ordering that is
enforced by its topology, and that we sort by when things were added.
Right now the way things work is (iirc - somebody like Greg should
double-check me) is that we add all devices to the power list at
device_add() time by traversing the devices fromt he root all the way out,
and doing a device_add() which does a device_pm_add(), which in turn adds
it to the power-management list - so that the list is always topologically
sorted.
So the only thing that needs to be done is to make sure that we add the
timer devices early during bootup - something we have to do *anyway*. If a
device is added early in bootup, that automatically means that it will be
suspended late, and resumed early - because we maintain that order all the
way through..
Linus
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [PATCH v2] Add suspend/resume for HPET
2007-03-31 16:53 ` Linus Torvalds
@ 2007-03-31 17:02 ` Ingo Molnar
2007-03-31 18:18 ` [linux-pm] " David Brownell
2007-03-31 17:55 ` David Brownell
1 sibling, 1 reply; 17+ messages in thread
From: Ingo Molnar @ 2007-03-31 17:02 UTC (permalink / raw)
To: Linus Torvalds
Cc: Maxim Levitsky, Jeff Chua, linux-ide, Sergei Shtylyov, gregkh,
linux-pm, Linux Kernel Mailing List, Adrian Bunk, linux-acpi,
linux-pci, Eric W. Biederman, Jens Axboe, Michael S. Tsirkin,
Thomas Gleixner, jgarzik, Andrew Morton
* Linus Torvalds <torvalds@linux-foundation.org> wrote:
> On Sat, 31 Mar 2007, Thomas Gleixner wrote:
> >
> > Right, but clock - sources/events need to be extremly late suspended and
> > early resumed. How can we ensure this ?
[...]
> So the only thing that needs to be done is to make sure that we add
> the timer devices early during bootup - something we have to do
> *anyway*. If a device is added early in bootup, that automatically
> means that it will be suspended late, and resumed early - because we
> maintain that order all the way through..
IIRC hpet is particularly hard to initialize early on in the bootup
sequence. So the way the clockevents code works is that it will always
try to make the best out of all available devices, and dynamically
adapts things as devices 'arrive' or 'depart' - no matter how late that
happens. (That way there's no dependency on how late a device gets
registered - it will only delay the switch to high-res mode for
example.) A given time device might 'depart' because for example the
watchdog mechanism finds that its quality is not good enough, or because
someone initiated cpufreq which breaks the TSC clocksource.
i dont think there's any particular problem here because suspend/resume
wont be done during bootup - but we might need a way to move a device to
earlier spots in the device tree, even if they got registered later on -
instead of forcing the time devices to be registered very early?
Ingo
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [linux-pm] [PATCH v2] Add suspend/resume for HPET
2007-03-31 17:02 ` Ingo Molnar
@ 2007-03-31 18:18 ` David Brownell
2007-03-31 19:32 ` David Brownell
0 siblings, 1 reply; 17+ messages in thread
From: David Brownell @ 2007-03-31 18:18 UTC (permalink / raw)
To: linux-pm
Cc: Adrian Bunk, Andrew Morton, Eric W. Biederman, gregkh,
Ingo Molnar, Jeff Chua, Jens Axboe, jgarzik, Linus Torvalds,
linux-acpi, linux-ide, Linux Kernel Mailing List, linux-pci,
Maxim Levitsky, Michael S. Tsirkin, Sergei Shtylyov,
Thomas Gleixner
( please remove obsolute linux-pm@lists.osdl.org from further messages!! )
On Saturday 31 March 2007 10:02 am, Ingo Molnar wrote:
>
> i dont think there's any particular problem here because suspend/resume
> wont be done during bootup - but we might need a way to move a device to
> earlier spots in the device tree, even if they got registered later on -
> instead of forcing the time devices to be registered very early?
I'm about ready to test the appended patch... a "move one device" call
might be safest at this point in the release cycle though.
- Dave
======================== SNIP!
Change how the PM list is constructed, so that devices are added right
after their parents (when they have one) rather than at the end of the
list. This preserves sequencing guarantees, but enables sequencing of
suspend/resume operations by more important characteristics than "when
device happened to enumerate" ... e.g. clocksources and clockevents
at a clearly defined point during suspend and resume.
This patch has a potential downside for devices that have multiple
power dependencies and which "just happened to work" before.
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
--- g26.orig/drivers/base/power/main.c 2006-07-02 12:30:30.000000000 -0700
+++ g26/drivers/base/power/main.c 2007-03-31 11:02:28.000000000 -0700
@@ -52,12 +52,17 @@ EXPORT_SYMBOL_GPL(device_pm_set_parent);
int device_pm_add(struct device * dev)
{
int error;
+ struct device *parent = dev->parent;
- pr_debug("PM: Adding info for %s:%s\n",
- dev->bus ? dev->bus->name : "No Bus", dev->kobj.name);
+ pr_debug("PM: Adding info for %s:%s, after %s\n",
+ dev->bus ? dev->bus->name : "No Bus", dev->kobj.name,
+ parent ? parent->bus_id : "(no parent)");
down(&dpm_list_sem);
- list_add_tail(&dev->power.entry, &dpm_active);
- device_pm_set_parent(dev, dev->parent);
+ if (parent)
+ list_add(&dev->power.entry, &parent->power.entry);
+ else
+ list_add_tail(&dev->power.entry, &dpm_active);
+ device_pm_set_parent(dev, parent);
if ((error = dpm_sysfs_add(dev)))
list_del(&dev->power.entry);
up(&dpm_list_sem);
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [linux-pm] [PATCH v2] Add suspend/resume for HPET
2007-03-31 18:18 ` [linux-pm] " David Brownell
@ 2007-03-31 19:32 ` David Brownell
2007-04-01 3:13 ` Jeff Chua
0 siblings, 1 reply; 17+ messages in thread
From: David Brownell @ 2007-03-31 19:32 UTC (permalink / raw)
To: linux-pm
Cc: Adrian Bunk, Andrew Morton, Eric W. Biederman, gregkh,
Ingo Molnar, Jeff Chua, Jens Axboe, jgarzik, Linus Torvalds,
linux-acpi, linux-ide, Linux Kernel Mailing List, linux-pci,
Maxim Levitsky, Michael S. Tsirkin, Sergei Shtylyov,
Thomas Gleixner
On Saturday 31 March 2007 11:18 am, David Brownell wrote:
> ( please remove obsolute linux-pm@lists.osdl.org from further messages!! )
>
> On Saturday 31 March 2007 10:02 am, Ingo Molnar wrote:
> >
> > i dont think there's any particular problem here because suspend/resume
> > wont be done during bootup - but we might need a way to move a device to
> > earlier spots in the device tree, even if they got registered later on -
> > instead of forcing the time devices to be registered very early?
>
> I'm about ready to test the appended patch... a "move one device" call
> might be safest at this point in the release cycle though.
As expected, this behaved OK on an x86 laptop. I'll see if it breaks
some of the ARM boards I have handy.
To be clear, what this means is that if "clockevent" and "clocksource"
devices get registered "very early", and the various clockevent and
clock source devices get registered, then the suspend/resume methods
for those will all get grouped together ... suspended "very late" and
resumed "very early", regardless of when they get registered. Pretty
much the driver model parts of what Linus was suggesting; clockevent
bits would still be needed.
- Dave
> - Dave
>
> ======================== SNIP!
> Change how the PM list is constructed, so that devices are added right
> after their parents (when they have one) rather than at the end of the
> list. This preserves sequencing guarantees, but enables sequencing of
> suspend/resume operations by more important characteristics than "when
> device happened to enumerate" ... e.g. clocksources and clockevents
> at a clearly defined point during suspend and resume.
>
> This patch has a potential downside for devices that have multiple
> power dependencies and which "just happened to work" before.
>
> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
>
> --- g26.orig/drivers/base/power/main.c 2006-07-02 12:30:30.000000000 -0700
> +++ g26/drivers/base/power/main.c 2007-03-31 11:02:28.000000000 -0700
> @@ -52,12 +52,17 @@ EXPORT_SYMBOL_GPL(device_pm_set_parent);
> int device_pm_add(struct device * dev)
> {
> int error;
> + struct device *parent = dev->parent;
>
> - pr_debug("PM: Adding info for %s:%s\n",
> - dev->bus ? dev->bus->name : "No Bus", dev->kobj.name);
> + pr_debug("PM: Adding info for %s:%s, after %s\n",
> + dev->bus ? dev->bus->name : "No Bus", dev->kobj.name,
> + parent ? parent->bus_id : "(no parent)");
> down(&dpm_list_sem);
> - list_add_tail(&dev->power.entry, &dpm_active);
> - device_pm_set_parent(dev, dev->parent);
> + if (parent)
> + list_add(&dev->power.entry, &parent->power.entry);
> + else
> + list_add_tail(&dev->power.entry, &dpm_active);
> + device_pm_set_parent(dev, parent);
> if ((error = dpm_sysfs_add(dev)))
> list_del(&dev->power.entry);
> up(&dpm_list_sem);
>
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [linux-pm] [PATCH v2] Add suspend/resume for HPET
2007-03-31 19:32 ` David Brownell
@ 2007-04-01 3:13 ` Jeff Chua
2007-04-01 4:13 ` David Brownell
0 siblings, 1 reply; 17+ messages in thread
From: Jeff Chua @ 2007-04-01 3:13 UTC (permalink / raw)
To: David Brownell
Cc: linux-pm, Adrian Bunk, Andrew Morton, Eric W. Biederman, gregkh,
Ingo Molnar, Jens Axboe, jgarzik, Linus Torvalds, linux-acpi,
linux-ide, Linux Kernel Mailing List, linux-pci, Maxim Levitsky,
Michael S. Tsirkin, Sergei Shtylyov, Thomas Gleixner
On 4/1/07, David Brownell <david-b@pacbell.net> wrote:
> for those will all get grouped together ... suspended "very late" and
> resumed "very early", regardless of when they get registered. Pretty
> much the driver model parts of what Linus was suggesting; clockevent
> bits would still be needed.
I tested your patch with CONFIG_NO_HZ=y, but it still hangs while
suspending to disk (before the percent saving).
But one discovery. I get tired of all these hangs, so I decided to
press some keys and the power button. Accidentally, the suspend
proceeded and successfully suspended!
I tried many more times, and discovered that to proceed with the
suspend, hit any 4 keys slowly. (e.g. "F1 F2 F3 F4", or "1 2 3 4").
My .config has CONFIG_NO_HZ=y and CONFIG_HIGH_RES_TIMERS=y, but I
suppose CONFIG_HIGH_RES_TIMERS=y gots nothing to do with the hang.
I went back with my vanilla 2.6.21-rc5 with Maxim's patch, and with
hitting the keys, I could suspend to disk with CONFIG_NO_HZ=y and
CONFIG_HIGH_RES_TIMERS=y.
Jeff.
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [linux-pm] [PATCH v2] Add suspend/resume for HPET
2007-04-01 3:13 ` Jeff Chua
@ 2007-04-01 4:13 ` David Brownell
0 siblings, 0 replies; 17+ messages in thread
From: David Brownell @ 2007-04-01 4:13 UTC (permalink / raw)
To: Jeff Chua
Cc: linux-pm, Adrian Bunk, Andrew Morton, Eric W. Biederman, gregkh,
Ingo Molnar, Jens Axboe, jgarzik, Linus Torvalds, linux-acpi,
linux-ide, Linux Kernel Mailing List, linux-pci, Maxim Levitsky,
Michael S. Tsirkin, Sergei Shtylyov, Thomas Gleixner
On Saturday 31 March 2007 8:13 pm, Jeff Chua wrote:
> On 4/1/07, David Brownell <david-b@pacbell.net> wrote:
> > for those will all get grouped together ... suspended "very late" and
> > resumed "very early", regardless of when they get registered. Pretty
> > much the driver model parts of what Linus was suggesting; clockevent
> > bits would still be needed.
>
> I tested your patch with CONFIG_NO_HZ=y, but it still hangs while
> suspending to disk (before the percent saving).
Of course. No clockevent updates...
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [linux-pm] [PATCH v2] Add suspend/resume for HPET
2007-03-31 16:53 ` Linus Torvalds
@ 2007-03-31 17:55 ` David Brownell
2007-03-31 17:55 ` David Brownell
1 sibling, 0 replies; 17+ messages in thread
From: David Brownell @ 2007-03-31 17:55 UTC (permalink / raw)
To: linux-pm
Cc: Linus Torvalds, Thomas Gleixner, Maxim Levitsky, Jeff Chua,
linux-ide, Sergei Shtylyov, gregkh, linux-pm,
Linux Kernel Mailing List, Adrian Bunk, linux-acpi, linux-pci,
Eric W. Biederman, Jens Axboe, Michael S. Tsirkin, Ingo Molnar,
jgarzik, Andrew Morton
On Saturday 31 March 2007 9:53 am, Linus Torvalds wrote:
>
> On Sat, 31 Mar 2007, Thomas Gleixner wrote:
> >
> > Right, but clock - sources/events need to be extremly late suspended and
> > early resumed. How can we ensure this ?
>
> Make them be at the top of the device tree by adding them early. That's
> the whole point of the device tree after all - we have an ordering that is
> enforced by its topology, and that we sort by when things were added.
Right, but "when things get added" doesn't correlate well to
"when they should get suspended/resumed". It's also in basic
conflict with runtime PM models, where devices may be suspended
at essentially any time. And sysdevs are even stranger.
One way out: rather than constructing that list as devices get
enumerated, it could be constructed by a (linear-time, non-recursive)
walk of the device tree(s) before they get suspended.
(Or equivalently: construct lists at enumeration time, but just
adding them *right after their parent* rather than at the end of
the list.)
Would that solve the problem here? Potentially ... if the tree is
structured to meet Thomas' rules:
> > The required resume order is:
> >
> > clocksources
> > timekeeping
> > clockevents
> > tick management
> So the only thing that needs to be done is to make sure that we add the
> timer devices early during bootup - something we have to do *anyway*. If a
> device is added early in bootup, that automatically means that it will be
> suspended late, and resumed early - because we maintain that order all the
> way through..
> -- "clocksource" -- +-- HPET
> |
> +-- TSC
> |
> +-- i8259
> |
> +-- lapic timer
> |
> .. whatever else
If each of those were a device node, with "clocksource" suspend/resume
methods handling Thomas' "timekeeping" item, and simlarly for "clockevent"
devices ... I could see that all working neatly.
- Dave
-
To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 17+ messages in thread
* Re: [linux-pm] [PATCH v2] Add suspend/resume for HPET
@ 2007-03-31 17:55 ` David Brownell
0 siblings, 0 replies; 17+ messages in thread
From: David Brownell @ 2007-03-31 17:55 UTC (permalink / raw)
To: linux-pm
Cc: Linus Torvalds, Thomas Gleixner, Maxim Levitsky, Jeff Chua,
linux-ide, Sergei Shtylyov, gregkh, linux-pm,
Linux Kernel Mailing List, Adrian Bunk, linux-acpi, linux-pci,
Eric W. Biederman, Jens Axboe, Michael S. Tsirkin, Ingo Molnar,
jgarzik, Andrew Morton
On Saturday 31 March 2007 9:53 am, Linus Torvalds wrote:
>
> On Sat, 31 Mar 2007, Thomas Gleixner wrote:
> >
> > Right, but clock - sources/events need to be extremly late suspended and
> > early resumed. How can we ensure this ?
>
> Make them be at the top of the device tree by adding them early. That's
> the whole point of the device tree after all - we have an ordering that is
> enforced by its topology, and that we sort by when things were added.
Right, but "when things get added" doesn't correlate well to
"when they should get suspended/resumed". It's also in basic
conflict with runtime PM models, where devices may be suspended
at essentially any time. And sysdevs are even stranger.
One way out: rather than constructing that list as devices get
enumerated, it could be constructed by a (linear-time, non-recursive)
walk of the device tree(s) before they get suspended.
(Or equivalently: construct lists at enumeration time, but just
adding them *right after their parent* rather than at the end of
the list.)
Would that solve the problem here? Potentially ... if the tree is
structured to meet Thomas' rules:
> > The required resume order is:
> >
> > clocksources
> > timekeeping
> > clockevents
> > tick management
> So the only thing that needs to be done is to make sure that we add the
> timer devices early during bootup - something we have to do *anyway*. If a
> device is added early in bootup, that automatically means that it will be
> suspended late, and resumed early - because we maintain that order all the
> way through..
> -- "clocksource" -- +-- HPET
> |
> +-- TSC
> |
> +-- i8259
> |
> +-- lapic timer
> |
> .. whatever else
If each of those were a device node, with "clocksource" suspend/resume
methods handling Thomas' "timekeeping" item, and simlarly for "clockevent"
devices ... I could see that all working neatly.
- Dave
^ permalink raw reply [flat|nested] 17+ messages in thread
end of thread, other threads:[~2007-04-04 16:33 UTC | newest]
Thread overview: 17+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-04-02 14:16 [linux-pm] [PATCH v2] Add suspend/resume for HPET Alan Stern
2007-04-02 17:09 ` Linus Torvalds
2007-04-02 17:09 ` Linus Torvalds
2007-04-02 19:16 ` [linux-pm] " David Brownell
2007-04-02 19:16 ` David Brownell
2007-04-02 20:04 ` [linux-pm] " Alan Stern
2007-04-02 20:04 ` Alan Stern
2007-04-03 5:54 ` [linux-pm] " Thomas Gleixner
2007-04-03 5:54 ` Thomas Gleixner
2007-04-04 15:06 ` [linux-pm] " David Brownell
2007-04-04 15:06 ` David Brownell
-- strict thread matches above, loose matches on Subject: below --
2007-03-16 16:33 Linux 2.6.21-rc4 Linus Torvalds
2007-03-31 16:33 ` [PATCH v2] Add suspend/resume for HPET Thomas Gleixner
2007-03-31 16:53 ` Linus Torvalds
2007-03-31 17:02 ` Ingo Molnar
2007-03-31 18:18 ` [linux-pm] " David Brownell
2007-03-31 19:32 ` David Brownell
2007-04-01 3:13 ` Jeff Chua
2007-04-01 4:13 ` David Brownell
2007-03-31 17:55 ` David Brownell
2007-03-31 17:55 ` David Brownell
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.