Message ID | CAE9FiQVNGpA9rE0Q7Lx2AB_+8dPEg=f98vqPx1PARkABLVYXqw@mail.gmail.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On 08/23/2011 05:04 AM, Yinghai Lu wrote: > On Mon, Aug 22, 2011 at 9:45 AM, Bjorn Helgaas <bhelgaas@google.com> wrote: >> On Mon, Aug 22, 2011 at 1:12 AM, Huang Ying <ying.huang@intel.com> wrote: >>> Do you have time to try the patch attached with the mail? >>> acpi_nvs.patch should go first. >> >> In this case, we have an ACPI NVS region, and the APEI code is >> essentially a driver for some registers that reside there. APEI is >> the entity that manages those registers, and it needs to enforce >> mutual exclusion so nobody else touches them behind its back, so I >> think it makes sense for it to request the register regions and mark >> them busy. >> >> My proposal is to change e820 so it either leaves ACPI NVS out of the >> iomem_resource tree or puts it in but leaves it non-busy. > > assume Huang Ying only tested with UEFI native boot? No. I tested it with legacy BIOS. But ACPI NVS is not used by APEI on my testing machine. > i have one local patch for legacy mode booting, and it's similar to > what Bjorn suggested. > > Please check the attached patch. I think we need help from ACPI guys on why ACPI NVS is marked as busy. If my understanding were correct, ACPI NVS should not be used by OS at all, so it is marked as busy. But for APEI, Linux interprets some code (instructions in ERST/EINJ table) from firmware. I think this is similar with AML code accessing ACPI NVS. Hi, Len, Do you think my understanding is correct? Best Regards, Huang Ying -- To unsubscribe from this list: send the line "unsubscribe linux-acpi" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Subject: [PATCH] x86: allow NVS can be accessed by driver APEI related... Signed-off-by: Yinghai Lu <yinghai@kernel.org> --- arch/x86/kernel/e820.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) Index: linux-2.6/arch/x86/kernel/e820.c =================================================================== --- linux-2.6.orig/arch/x86/kernel/e820.c +++ linux-2.6/arch/x86/kernel/e820.c @@ -995,7 +995,8 @@ void __init e820_reserve_resources(void) * pcibios_resource_survey() */ if (e820.map[i].type != E820_RESERVED || res->start < (1ULL<<20)) { - res->flags |= IORESOURCE_BUSY; + if (e820.map[i].type != E820_NVS) + res->flags |= IORESOURCE_BUSY; insert_resource(&iomem_resource, res); } res++;