* RE: [PATCH/RFC 0/4]Bind physical devices with ACPI devices
@ 2004-11-08 16:08 Yu, Luming
2004-11-08 16:38 ` Matthew Wilcox
0 siblings, 1 reply; 5+ messages in thread
From: Yu, Luming @ 2004-11-08 16:08 UTC (permalink / raw)
To: Matthew Wilcox
Cc: Li, Shaohua, ACPI-DEV, lkml, Brown, Len, Greg, Patrick Mochel
>On Mon, Nov 08, 2004 at 10:46:30PM +0800, Yu, Luming wrote:
>> >All we need is an acpi_get_gendev_handle that takes a
>struct device and
>> >returns the acpi_handle for it. Now, maybe that'd be best
>> >done by placing
>> >a pointer in the struct device, but I bet it'd be just as
>good to walk
>> >the namespace looking for the corresponding device.
>>
>> It will fail if you just simply walk namespace to find out
>> the corresponding acpi object, because there are NO
>> hardware id or compatible id can be passed in.
>> Please check function acpi_bus_match.
>
>It doesn't need the HID or CID. Look at Shaohua's patches --
>they don't
>use HID or CID either.
>
Yes, I made a mistake, please forget that point.
But another statement I made should be valid.
That is how to use geographical address to
locate corresponding acpi object.
For example, ACPI define IDE as the following:
Device (IDE0){ /* primary controller */
Name (_ADR, 0)
Method (_GTM )
...
Device(PRIM) /* primary adapter */
Name (_ADR, 0)
Method(_GTM)
...
Device(MSTR) /* master channel */
Name (_ADR,0)
Method(_GTF)
We need not only able to locate acpi object IDE0
but also we need to locate object PRIM underneath
IDE0, and MSTR underneath PRIM. Thus, IDE driver
can fully take advantage from ACPI, in terms of
configuration and power management.
Maybe we need to invent a method called
map_device_addr_to_acpi_handle to be generic solution.
Thanks,
Luming
-------------------------------------------------------
This SF.Net email is sponsored by:
Sybase ASE Linux Express Edition - download now for FREE
LinuxWorld Reader's Choice Award Winner for best database on Linux.
http://ads.osdn.com/?ad_idU88&alloc_id\x12065&op=click
^ permalink raw reply [flat|nested] 5+ messages in thread* Re: [PATCH/RFC 0/4]Bind physical devices with ACPI devices
2004-11-08 16:08 [PATCH/RFC 0/4]Bind physical devices with ACPI devices Yu, Luming
@ 2004-11-08 16:38 ` Matthew Wilcox
0 siblings, 0 replies; 5+ messages in thread
From: Matthew Wilcox @ 2004-11-08 16:38 UTC (permalink / raw)
To: Yu, Luming
Cc: Matthew Wilcox, Li, Shaohua, ACPI-DEV, lkml, Brown, Len, Greg,
Patrick Mochel
On Tue, Nov 09, 2004 at 12:08:03AM +0800, Yu, Luming wrote:
> >On Mon, Nov 08, 2004 at 10:46:30PM +0800, Yu, Luming wrote:
> >> >All we need is an acpi_get_gendev_handle that takes a
> >struct device and
> >> >returns the acpi_handle for it. Now, maybe that'd be best
> >> >done by placing
> >> >a pointer in the struct device, but I bet it'd be just as
> >good to walk
> >> >the namespace looking for the corresponding device.
>
> We need not only able to locate acpi object IDE0
> but also we need to locate object PRIM underneath
> IDE0, and MSTR underneath PRIM. Thus, IDE driver
> can fully take advantage from ACPI, in terms of
> configuration and power management.
>
> Maybe we need to invent a method called
> map_device_addr_to_acpi_handle to be generic solution.
I think we're saying the same thing in different words here ...
Note that an acpi_get_gendev_handle() or map_device_addr_to_acpi_handle()
function doesn't *preclude* putting a void * in struct device. It does
let us choose whether or not to do so.
--
"Next the statesmen will invent cheap lies, putting the blame upon
the nation that is attacked, and every man will be glad of those
conscience-soothing falsities, and will diligently study them, and refuse
to examine any refutations of them; and thus he will by and by convince
himself that the war is just, and will thank God for the better sleep
he enjoys after this process of grotesque self-deception." -- Mark Twain
-------------------------------------------------------
This SF.Net email is sponsored by:
Sybase ASE Linux Express Edition - download now for FREE
LinuxWorld Reader's Choice Award Winner for best database on Linux.
http://ads.osdn.com/?ad_id=5588&alloc_id=12065&op=click
^ permalink raw reply [flat|nested] 5+ messages in thread
* RE: [PATCH/RFC 0/4]Bind physical devices with ACPI devices
@ 2004-11-08 14:46 Yu, Luming
2004-11-08 14:59 ` Matthew Wilcox
0 siblings, 1 reply; 5+ messages in thread
From: Yu, Luming @ 2004-11-08 14:46 UTC (permalink / raw)
To: Matthew Wilcox, Li, Shaohua
Cc: ACPI-DEV, lkml, Brown, Len, Greg, Patrick Mochel
>All we need is an acpi_get_gendev_handle that takes a struct device and
>returns the acpi_handle for it. Now, maybe that'd be best
>done by placing
>a pointer in the struct device, but I bet it'd be just as good to walk
>the namespace looking for the corresponding device.
It will fail if you just simply walk namespace to find out
the corresponding acpi object, because there are NO
hardware id or compatible id can be passed in.
Please check function acpi_bus_match.
The fundamental problem here is how to use device's geographical
address( or other information ) to locate the corresponding
acpi object in namespace.
Thanks,
Luming
-------------------------------------------------------
This SF.Net email is sponsored by:
Sybase ASE Linux Express Edition - download now for FREE
LinuxWorld Reader's Choice Award Winner for best database on Linux.
http://ads.osdn.com/?ad_idU88&alloc_id\x12065&op=click
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH/RFC 0/4]Bind physical devices with ACPI devices
2004-11-08 14:46 Yu, Luming
@ 2004-11-08 14:59 ` Matthew Wilcox
0 siblings, 0 replies; 5+ messages in thread
From: Matthew Wilcox @ 2004-11-08 14:59 UTC (permalink / raw)
To: Yu, Luming
Cc: Matthew Wilcox, Li, Shaohua, ACPI-DEV, lkml, Brown, Len, Greg,
Patrick Mochel
On Mon, Nov 08, 2004 at 10:46:30PM +0800, Yu, Luming wrote:
> >All we need is an acpi_get_gendev_handle that takes a struct device and
> >returns the acpi_handle for it. Now, maybe that'd be best
> >done by placing
> >a pointer in the struct device, but I bet it'd be just as good to walk
> >the namespace looking for the corresponding device.
>
> It will fail if you just simply walk namespace to find out
> the corresponding acpi object, because there are NO
> hardware id or compatible id can be passed in.
> Please check function acpi_bus_match.
It doesn't need the HID or CID. Look at Shaohua's patches -- they don't
use HID or CID either.
--
"Next the statesmen will invent cheap lies, putting the blame upon
the nation that is attacked, and every man will be glad of those
conscience-soothing falsities, and will diligently study them, and refuse
to examine any refutations of them; and thus he will by and by convince
himself that the war is just, and will thank God for the better sleep
he enjoys after this process of grotesque self-deception." -- Mark Twain
-------------------------------------------------------
This SF.Net email is sponsored by:
Sybase ASE Linux Express Edition - download now for FREE
LinuxWorld Reader's Choice Award Winner for best database on Linux.
http://ads.osdn.com/?ad_id=5588&alloc_id=12065&op=click
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH/RFC 0/4]Bind physical devices with ACPI devices
@ 2004-11-08 4:11 Li Shaohua
0 siblings, 0 replies; 5+ messages in thread
From: Li Shaohua @ 2004-11-08 4:11 UTC (permalink / raw)
To: ACPI-DEV, lkml; +Cc: Len Brown, Greg, Patrick Mochel
Hi,
ACPI provides many functionalities for physical devices. Such as for
suspend/resume, ACPI can tell us correct devices D-state for S3. There
are tons of devices enhancement for both realtime and boot time from
ACPI. To utilize ACPI, physical devices like PCI devices must know its
partner. The patches try to do this. After this is done, we can enhance
many features, such as improve suspend/resume.
These patches are against 2.6.10-rc1, please give your comments.
Thanks,
Shaohua
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2004-11-08 16:38 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-11-08 16:08 [PATCH/RFC 0/4]Bind physical devices with ACPI devices Yu, Luming
2004-11-08 16:38 ` Matthew Wilcox
-- strict thread matches above, loose matches on Subject: below --
2004-11-08 14:46 Yu, Luming
2004-11-08 14:59 ` Matthew Wilcox
2004-11-08 4:11 Li Shaohua
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox