On 09/21/2011 12:26 AM, Bjorn Helgaas wrote: > On Mon, Sep 19, 2011 at 8:34 PM, Huang Ying <ying.huang@xxxxxxxxx> wrote: >> On 09/20/2011 10:09 AM, Bjorn Helgaas wrote: >>> On Mon, Sep 19, 2011 at 7:38 PM, Huang Ying <ying.huang@xxxxxxxxx> wrote: >>>> Some firmware will access memory in ACPI NVS region via APEI. That >>>> is, instructions in APEI ERST/EINJ table will read/write ACPI NVS >>>> region. The original resource conflict checking in APEI code will >>>> check memory/ioport accessed by APEI via general resource management >>>> mech. But ACPI NVS region is marked as busy already, so that the >>>> false resource conflict will prevent APEI ERST/EINJ to work. >>>> >>>> To fix this, this patch excludes ACPI NVS regions when APEI components >>>> request resources. So that they will not conflict with ACPI NVS >>>> regions. >>> >>> I think this is much, much too complicated. >>> >>> Yinghai's three-line e820.c patch to leave ACPI NVS regions in the >>> iomem_resource tree, but as not busy, is far better. >> >> ACPI NVS should only be used by firmware or firmware interpreter instead >> of the ordinary drivers. So I think that is reasonable to make it busy >> in iomem resource tree. > > "My driver is not like ordinary drivers" is a common excuse for adding > special cases. I don't buy it. > > These patches (3 and 4) add a lot of complexity but I don't believe > they add any real protection. > > Regions are marked busy by their owners, i.e., by drivers that claim > devices and know how to operate them. The e820 code is not an owner > of ACPI NVS regions, so it should not mark them busy. > > I don't really think we have a problem here that needs to be solved. > Ordinary drivers have no way of learning an address in ACPI NVS, so > they aren't even going to try to use it. So what resource conflict checking is for? If something wrong with driver configuration, resource description in ACPI table etc, the driver may request iomem inside ACPI NVS regions. ACPI NVS regions already have a user, that is the ACPI AML interpreter, so it is always busy. Best Regards, Huang Ying -- To unsubscribe from this list: send the line "unsubscribe linux-acpi" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html