Thread (53 messages) 53 messages, 11 authors, 2006-01-13

Re: [linux-pm] [patch] pm: fix runtime powermanagement's /sys interface

From: Pavel Machek <hidden>
Date: 2006-01-06 00:07:24
Also in: lkml

On Čt 05-01-06 15:54:15, Patrick Mochel wrote:
On Thu, 5 Jan 2006, Pavel Machek wrote:
quoted
On Čt 05-01-06 14:15:39, Patrick Mochel wrote:
quoted
quoted
It should be replaced with a file exported by the bus driver that exports
the actual states that the device supports. The parsing can easily happen
at this point, because the bus knows what a good value is.
(1) would change core<->driver interface
It's broken anyway for runtime power management.
Please explain. As far as I can see, it is fairly simple, but good
enough. pm_message_t.flags indicating it is runtime suspend would be
nice, but I do not think it is broken.
quoted
(2) is quite a lot of work
In the long run, it's not.
Nobody fixed it in a year, so apparently it is a lot of work.
quoted
(3) ...with very little benefit, until drivers support >2 states
Without it, you are preventing drivers from being able to support > 2
states.
0 drivers support > 2 states. So it is indeed very little benefit.
quoted
If you want to rewrite driver model for >2 states, great, but that is
going to take at least a year AFAICS, so please let me at least fix
the bugs in meantime.
It's a band-aid; it is not a long-term solution.
But band-aid is apparently neccessary unless you want drivers to see
invalid values.
quoted
quoted
The userspace interface is broken. We can keep it for compatability
reasons, but there needs to be a new interface.
I assumed we could fix the interface without actually introducing >2
states support. That can be done in reasonable ammount of code.
The interface is irreparably broken. You can't fix it with an infinite
number of band aids.
Without "band aids", you'll get BUG()s all over the kernel.
quoted
quoted
I don't understand what you're saying. If I have a driver that Iwant to
                                         ~~~~~~~~~~~~~~~~~~
quoted
make support another power state and I'm willing to write that code, then
there is a clear benefit to having the infrastructure for it to "just
work".
I do not see such drivers around me, that's all. It seems fair to me
that first driver author wanting that is the one who introduces >2
states support to generic infrastructure.
Just because you personally have not seen such things does not mean they
do not exist.
Just because you claim they exist does not mean they exist.
quoted
Passing "on"/"off" down to radeon lets the driver decide what power
state it should enter.
Driver implements power state policy? Sounds like that policy would find a
much more comfortable home in userspace.
Userspace can't know that driver does not support D3 on this
particular hardware version because of hardware problems... or simply
because it is not yet implemented.
								Pavel
-- 
Thanks, Sharp!
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help