public inbox for linux-acpi@vger.kernel.org
 help / color / mirror / Atom feed
* why do drivers evaluate _INI?
@ 2009-06-22 23:32 Bjorn Helgaas
  2009-06-22 23:59 ` Jonathan Woithe
                   ` (3 more replies)
  0 siblings, 4 replies; 10+ messages in thread
From: Bjorn Helgaas @ 2009-06-22 23:32 UTC (permalink / raw)
  To: Len Brown
  Cc: Eric Piel, Pavel Machek, Jonathan Woithe, Mattia Dongili,
	linux-acpi

[Sorry for the duplicate; I meant to CC: linux-acpi, so I added it here.]

Why do we have ACPI device drivers evaluating _INI?  That seems
like something that should be done by Linux/ACPI, not by the driver.

I see the following drivers using _INI:
  drivers/hwmon/hp_accel.c
  drivers/platform/x86/fujitsu-laptop.c
  drivers/platform/x86/sony-laptop.c

I looked at the git logs where the _INI usage was introduced in
these drivers, but none gives enough information for me to understand
why.

If running _INI in the driver makes a difference, I think it's
really telling us about a problem in Linux/ACPI, and we should
fix that problem rather than sprinkling _INI evaluation around
in drivers.

I do see _INI evaluation in this path:

    acpi_init
        acpi_bus_init
            acpi_initialize_objects(ACPI_FULL_INITIALIZATION)
                acpi_ns_initialize_devices
                    acpi_ns_walk_namespace .. acpi_ns_init_one_device

The spec (section 6.5.1) says OSPM should run _INI when a
description table is loaded.  I assume the above path does
this for the DSDT, at least, but I'm not smart enough about
the ACPI CA to know whether we also handle SSDTs and dynamic
LoadTables correctly.

Bjorn

P.S.  I'm about to go on vacation for a couple weeks, so I'll
be slow in responding to any discussion here.

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2009-06-26 15:09 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-06-22 23:32 why do drivers evaluate _INI? Bjorn Helgaas
2009-06-22 23:59 ` Jonathan Woithe
2009-06-23 15:17   ` nokos
2009-06-24  0:15     ` Jonathan Woithe
2009-06-24  9:19       ` nokos
2009-06-23  0:01 ` Tony Vroon
2009-06-23  0:28   ` Jonathan Woithe
2009-06-23  2:05 ` Mattia Dongili
2009-06-23  8:53 ` Corentin Chary
2009-06-23 15:01   ` Bjorn Helgaas

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox