Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp723223ybi; Fri, 14 Jun 2019 02:13:28 -0700 (PDT) X-Google-Smtp-Source: APXvYqyuwnUW6jXx4cgJjTQssAB4c0H2+ffU8ha5sEASznE8FPb92C6NW063PZCzsCgNKS5I/MYq X-Received: by 2002:a62:585:: with SMTP id 127mr95288118pff.231.1560503608101; Fri, 14 Jun 2019 02:13:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1560503608; cv=none; d=google.com; s=arc-20160816; b=UztA+39178Gr1FsEdYYkuF9b68uvwLSmTrfrYxrDVVBhcihyXidZmbDBuCbdtH8bza 4qznZZx3g5mHtgvBH3Vn0RHMn1sKqbw/kWLASKep6zeH4ghJAAotH7DWcqPDraPrTKUb N0b21RhdIPqh/evEVO8hFUGXi6ZQWVg5EkFYrgBbMszV4GNKHT75fOWqLORKnzPzVn7v /Lrfp81ISah3xobHvG+oSnk4Bb/L1n6eG9C+1IVGWe7t02SE8+B9DI4yATEeyBRjd47c 7IF1oyfS1SCE9wwJT0qBvO+5QxgaHErqcJf4pGzZXq4+HtGxQDnbKleuU6klhxmAG0wt HIKQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version; bh=iQKOlho3IePwEIN90jAdwdDwovI9WsnmIGTODVgkjRA=; b=D/J8euECNcXFtpS1duCS3QCLdtVPQ70lx2Mtgj0uqkl4QhURv8DddCwNZw8YfwpLre /kKRsuDDwSZWN1rJVB7jWJUpMgN4S7Xd4eb4G/f3aMZdVaKWz8RPe/puuDDqo2bXAO5b 8Wu9C6/2Sr/vQ9jYq1iqDL1yW7gOcXqfP+aED7AOYW5mXZjw32aHkvu+FcPhQqXV6VT2 hRt8VL5Rdsbo1LVOKUuL9vdL7bb+rLDReBCkHCBIjiugM4o+D9WjoiQ89xOZRGgbhFMR 3CmYwlwfJDPSrORoZSfDLwZz+WYgi1aLK1f/U4Gdp5qzGsL6KHx9Tstm3K1exNTi8BoB Nh9A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t14si1243544pgh.51.2019.06.14.02.13.10; Fri, 14 Jun 2019 02:13:28 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726744AbfFNJNF (ORCPT + 99 others); Fri, 14 Jun 2019 05:13:05 -0400 Received: from mail-ot1-f66.google.com ([209.85.210.66]:32773 "EHLO mail-ot1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725859AbfFNJNE (ORCPT ); Fri, 14 Jun 2019 05:13:04 -0400 Received: by mail-ot1-f66.google.com with SMTP id p4so2016299oti.0; Fri, 14 Jun 2019 02:13:04 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=iQKOlho3IePwEIN90jAdwdDwovI9WsnmIGTODVgkjRA=; b=WBt42ZFsjkB1h+W59AEmW0p5Z4PbncLAzeV7iKPVlD7QvQ9y2IT96iXNMvAaPvBZ9T kRypHl/oFlCIe9FQwmX2HizCmXz1mn7xXMMBTgmWJwP5zhs0xdc5J8+A3J0zzmjITFgy YXwY53hLE3WZY2zcjfJt0pECB/c4SFYu4lkEHDr+ViYw0Z73lawdd1XkJDJIiojbhg19 IM0VlvJkQuGKP73ImtI2UpZVMxw/VIYTU2yj90HdX2qnxEX+mMQLiVCpvdMGICkDUsSk 5AVj2BjxWjA1TK6dpx6Ixr4qzMFPp+1k/nO5Rhd5Wmfqaxy6t2KeNpr3mJK1h9DlTgIy tE8w== X-Gm-Message-State: APjAAAXF07kaErJ4haKJqz+S1idWeYEYZed0uniVnjQ9T0lCeNSeuNFW N4axdw0modMa5gQJ3NmPag31s54hLH+9NlVD9A0= X-Received: by 2002:a05:6830:1516:: with SMTP id k22mr2077918otp.189.1560503583969; Fri, 14 Jun 2019 02:13:03 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: "Rafael J. Wysocki" Date: Fri, 14 Jun 2019 11:12:53 +0200 Message-ID: Subject: Re: [PATCH v2 1/3] ACPI: Resolve objects on host-directed table loads To: Nikolaus Voss Cc: "Rafael J. Wysocki" , Len Brown , Robert Moore , Erik Schmauss , Jacek Anaszewski , Pavel Machek , Dan Murphy , Thierry Reding , ACPI Devel Maling List , "open list:ACPI COMPONENT ARCHITECTURE (ACPICA)" , linux-leds@vger.kernel.org, Linux PWM List , Linux Kernel Mailing List , nv@vosn.de Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jun 12, 2019 at 10:36 AM Nikolaus Voss wrote: > > If an ACPI SSDT overlay is loaded after built-in tables > have been loaded e.g. via configfs or efivar_ssdt_load() > it is necessary to rewalk the namespace to resolve > references. Without this, relative and absolute paths > like ^PCI0.SBUS or \_SB.PCI0.SBUS are not resolved > correctly. > > Make configfs load use the same method as efivar_ssdt_load(). > > Signed-off-by: Nikolaus Voss This is fine by me, so Acked-by: Rafael J. Wysocki Or if you want me to take this patch (without the other two in the series), please let me know. As for the other two patches, someone else needs to review them for you as I'm not particularly familiar with the PWM subsystem. > --- > drivers/acpi/acpi_configfs.c | 6 +----- > drivers/acpi/acpica/tbxfload.c | 11 +++++++++++ > 2 files changed, 12 insertions(+), 5 deletions(-) > > diff --git a/drivers/acpi/acpi_configfs.c b/drivers/acpi/acpi_configfs.c > index f92033661239..663f0d88f912 100644 > --- a/drivers/acpi/acpi_configfs.c > +++ b/drivers/acpi/acpi_configfs.c > @@ -56,11 +56,7 @@ static ssize_t acpi_table_aml_write(struct config_item *cfg, > if (!table->header) > return -ENOMEM; > > - ACPI_INFO(("Host-directed Dynamic ACPI Table Load:")); > - ret = acpi_tb_install_and_load_table( > - ACPI_PTR_TO_PHYSADDR(table->header), > - ACPI_TABLE_ORIGIN_EXTERNAL_VIRTUAL, FALSE, > - &table->index); > + ret = acpi_load_table(table->header); > if (ret) { > kfree(table->header); > table->header = NULL; > diff --git a/drivers/acpi/acpica/tbxfload.c b/drivers/acpi/acpica/tbxfload.c > index 4f30f06a6f78..ef8f8a9f3c9c 100644 > --- a/drivers/acpi/acpica/tbxfload.c > +++ b/drivers/acpi/acpica/tbxfload.c > @@ -297,6 +297,17 @@ acpi_status acpi_load_table(struct acpi_table_header *table) > status = acpi_tb_install_and_load_table(ACPI_PTR_TO_PHYSADDR(table), > ACPI_TABLE_ORIGIN_EXTERNAL_VIRTUAL, > FALSE, &table_index); > + > + if (ACPI_SUCCESS(status)) { > + /* Complete the initialization/resolution of package objects */ > + > + status = acpi_ns_walk_namespace(ACPI_TYPE_PACKAGE, > + ACPI_ROOT_OBJECT, > + ACPI_UINT32_MAX, 0, > + acpi_ns_init_one_package, > + NULL, NULL, NULL); > + } > + > return_ACPI_STATUS(status); > } > > -- > 2.17.1 >