Handles from a DSDT are in fact permanent.
Once a SSDT is unloaded, however, those handles are invalid.
We are considering making these handles "real" handles instead of simply
pointers to catch the use of an invalid handle.
> -----Original Message-----
> From: lin...@vg... [mailto:linux-acpi-
> ow...@vg...] On Behalf Of Henrique de Moraes Holschuh
> Sent: Wednesday, February 07, 2007 11:44 AM
> To: lin...@vg...
> Cc: ibm...@li...
> Subject: Caching the results of acpi_get_handle() in a driver: is it
> valid?
>=20
> The code I inherited in ibm-acpi does heavy caching of
acpi_get_handle()
> results. It stores the results of acpi_get_handle() for a number of
nodes
> at module init, and uses the stored results during its lifetime.
>=20
> Is that a valid use of the handles returned by acpi_get_handle()? In
> particular, what happens to handlers when a SSDT gets loaded or
unloaded
> at
> runtime? Do handles that came from the DSDT change? What if the
handler
> was to a node in the SSDT being unloaded? What if the handler is
> overriden
> by a new loaded SSDT?
>=20
> While the vast majority of the handlers ibm-acpi caches are in the
DSDT
> and
> very unlikely to change through a SSDT load, I'd still like to make
sure
> the
> driver is doing the right thing...
>=20
> PS: not caching the results is always possible, but that will mean
various
> calls to acpi_get_handle() per second.
>=20
> --
> "One disk to rule them all, One disk to find them. One disk to bring
> them all and in the darkness grind them. In the Land of Redmond
> where the shadows lie." -- The Silicon Valley Tarot
> Henrique Holschuh
> -
> To unsubscribe from this list: send the line "unsubscribe linux-acpi"
in
> the body of a message to maj...@vg...
> More majordomo info at http://vger.kernel.org/majordomo-info.html
|