public inbox for linux-acpi@vger.kernel.org
 help / color / mirror / Atom feed
From: Bjorn Helgaas <helgaas@kernel.org>
To: Hans de Goede <hdegoede@redhat.com>
Cc: "Rafael J . Wysocki" <rjw@rjwysocki.net>,
	Len Brown <lenb@kernel.org>, Bjorn Helgaas <bhelgaas@google.com>,
	Mika Westerberg <mika.westerberg@linux.intel.com>,
	Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
	Linus Walleij <linus.walleij@linaro.org>,
	linux-acpi@vger.kernel.org, linux-pci@vger.kernel.org,
	linux-gpio@vger.kernel.org
Subject: Re: [PATCH 2/3] ACPI / hotplug / PCI: Use the new acpi_evaluate_reg() helper
Date: Tue, 5 May 2020 11:45:06 -0500	[thread overview]
Message-ID: <20200505164506.GA365569@bjorn-Precision-5520> (raw)
In-Reply-To: <20200505132128.19476-3-hdegoede@redhat.com>

On Tue, May 05, 2020 at 03:21:27PM +0200, Hans de Goede wrote:
> Use the new acpi_evaluate_reg() helper in the acpiphp_glue.c code.
> 
> Signed-off-by: Hans de Goede <hdegoede@redhat.com>

Acked-by: Bjorn Helgaas <bhelgaas@google.com>

OK by me if this is merged with the first.

> ---
>  drivers/pci/hotplug/acpiphp_glue.c | 17 ++++-------------
>  1 file changed, 4 insertions(+), 13 deletions(-)
> 
> diff --git a/drivers/pci/hotplug/acpiphp_glue.c b/drivers/pci/hotplug/acpiphp_glue.c
> index b3869951c0eb..fd77eb1d460c 100644
> --- a/drivers/pci/hotplug/acpiphp_glue.c
> +++ b/drivers/pci/hotplug/acpiphp_glue.c
> @@ -385,20 +385,11 @@ static unsigned char acpiphp_max_busnr(struct pci_bus *bus)
>  static void acpiphp_set_acpi_region(struct acpiphp_slot *slot)
>  {
>  	struct acpiphp_func *func;
> -	union acpi_object params[2];
> -	struct acpi_object_list arg_list;
>  
> -	list_for_each_entry(func, &slot->funcs, sibling) {
> -		arg_list.count = 2;
> -		arg_list.pointer = params;
> -		params[0].type = ACPI_TYPE_INTEGER;
> -		params[0].integer.value = ACPI_ADR_SPACE_PCI_CONFIG;
> -		params[1].type = ACPI_TYPE_INTEGER;
> -		params[1].integer.value = 1;
> -		/* _REG is optional, we don't care about if there is failure */
> -		acpi_evaluate_object(func_to_handle(func), "_REG", &arg_list,
> -				     NULL);
> -	}
> +	list_for_each_entry(func, &slot->funcs, sibling)
> +		acpi_evaluate_reg(func_to_handle(func),
> +				  ACPI_ADR_SPACE_PCI_CONFIG,
> +				  ACPI_REG_CONNECT);
>  }
>  
>  static void check_hotplug_bridge(struct acpiphp_slot *slot, struct pci_dev *dev)
> -- 
> 2.26.0
> 

  parent reply	other threads:[~2020-05-05 16:45 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-05 13:21 [PATCH 0/3] ACPI / utils: Add acpi_evaluate_reg() helper Hans de Goede
2020-05-05 13:21 ` [PATCH 1/3] " Hans de Goede
2020-05-05 15:42   ` Andy Shevchenko
2020-05-07 10:30     ` Hans de Goede
2020-05-05 15:43   ` Andy Shevchenko
2020-05-05 16:44   ` Bjorn Helgaas
2020-05-05 13:21 ` [PATCH 2/3] ACPI / hotplug / PCI: Use the new " Hans de Goede
2020-05-05 15:41   ` Andy Shevchenko
2020-05-05 16:45   ` Bjorn Helgaas [this message]
2020-05-05 13:21 ` [PATCH 3/3] pinctrl: cherryview: " Hans de Goede
2020-05-05 15:44   ` Andy Shevchenko
2020-05-05 15:44 ` [PATCH 0/3] ACPI / utils: Add " Andy Shevchenko
2020-05-07 10:22   ` Hans de Goede

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200505164506.GA365569@bjorn-Precision-5520 \
    --to=helgaas@kernel.org \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=bhelgaas@google.com \
    --cc=hdegoede@redhat.com \
    --cc=lenb@kernel.org \
    --cc=linus.walleij@linaro.org \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=mika.westerberg@linux.intel.com \
    --cc=rjw@rjwysocki.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox