Re: [PATCH 2.6.12.4] ACPI oops during ipmi_si driver init

From: Bjorn Helgaas
Date: Wed Aug 17 2005 - 16:13:52 EST


On Wednesday 17 August 2005 2:30 pm, Corey Minyard wrote:
> Basically, the IPMI system interface needs information from a specific
> IPMI table to know how to configure itself. Those tables can reference
> GPEs, so the driver can use those (though AFAIK it has never been tested).

The information in the SPMI table *should* also be in the ACPI
namespace. In general, drivers should claim devices based on the
namespace, not based on tables like SPMI. The tables are mainly
there for the times when you need a device before the ACPI namespace
is available.

drivers/serial/8250_pnp.c is a basic example of claiming PNP
devices. In particular, see serial_pnp_probe(), which gets
called for every device with a PNP ID found in pnp_dev_table[].

drivers/serial/8250_acpi.c is an example of claiming a device
directly from the ACPI namespace. It claims everything with
PNP ID "PNP0501".

If you need to handle GPEs, you probably would need the
8250_acpi.c style, since I don't think PNP can deal with
those. You would use acpi_register_driver(), and pass it
an acpi_driver struct containing '.ids = "IPI0001"'. The
add() function you supply will get called for every active
IPI0001 device in the namespace. Use acpi_walk_resources()
on its _CRS to extract the I/O port or MMIO address of the
controller and its interrupt information. If the _CRS
contains no interrupt information, look for a _GPE method.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/