Skip to contentSkip to conversation

Voltage Framework

RFC dmitry pervushin 1 participant 1 message Apr 6, 2007 3 messages not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): 1174469715.19019.65.camel@amit-laptop

A message that is not in the archive (sent off-list or not yet received): [email protected]

A message that is not in the archive (sent off-list or not yet received): [email protected]

#3 lore raw

On Птн, 2007-04-06 at 19:43 +0400, Dmitry Krivoschokov wrote:
[skipped]

Quoted 4 lines

The struct resource was initially intended for IO resources only, (which looks wrong to me, at least its naming, it could be called as io_resources). But voltage is not an IO resource, so struct resource is not appropriate place for that

You object on naming of the structure (have you ever tried to do output on interrupt line :) )?

The struct resource layout is not well suitable to keep information about clocks/voltage and ever gpio lines, but all of these things are resources. Resources of device. Well, resources that belongs to platform_device.

I don't like idea to keep two separate lists of resources - one for I/O ports/memory windows/IRQ lines and the another one to keep pm resources. Why should they be separated ?

Quoted 21 lines
Quoted 3 lines

This might sound odd, but after all, why not look at power [voltage] as a resource just loke memory, IO ports, GPIO or IRQ lines?

I'd consider voltage and clocks as a power resources, every computer (say CMOS) system (or device) consumes (requires for) voltage and clocks, so it looks natural that device driver will check what resources are needed for device on this particular platform.

Quoted 4 lines

This keeps the drivers clean from having to know any device specifics.

Yep.

Quoted 7 lines

It also keeps the actual device driver of any peripheral independent of the PMU driver, since the latter would sit behind the 'struct resource' abstraction.
A device driver would then just call something like requrest_power(struct resource *) whic hides all the magic of calling back into the individual PMU driver.

Quoted 6 lines

It assumes some infrastructure to deal with power resources, like we have for interrupts now.

Actually, all Linux PM-related problems are discussed on [email protected] list, here it's offtopic. Continue the discassion on linux-pm, if you will.

I added linux-pm to Cc, so let's continue there.

Quoted 10 lines

Thanks,
Dmitry

-------------------------------------------------------------------

List admin: http://lists.arm.linux.org.uk/mailman/listinfo/linux-arm-kernel
FAQ:        http://www.arm.linux.org.uk/mailinglists/faq.php
Etiquette:  http://www.arm.linux.org.uk/mailinglists/etiquette.php

_______________________________________________
linux-pm mailing list
[email protected]
https://lists.linux-foundation.org/mailman/listinfo/linux-pm