From: "Rafael J. Wysocki" <rjw@rjwysocki.net>
To: Rob Herring <robh@kernel.org>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
LKML <linux-kernel@vger.kernel.org>,
Linux ACPI <linux-acpi@vger.kernel.org>,
Jiri Slaby <jirislaby@kernel.org>,
linux-serial@vger.kernel.org
Subject: [PATCH] tty: Replace acpi_bus_get_device()
Date: Wed, 26 Jan 2022 20:55:39 +0100 [thread overview]
Message-ID: <7355105.EvYhyI6sBW@kreacher> (raw)
From: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Replace acpi_bus_get_device() that is going to be dropped with
acpi_fetch_acpi_dev().
No intentional functional impact.
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
---
drivers/tty/serdev/core.c | 7 ++-----
1 file changed, 2 insertions(+), 5 deletions(-)
Index: linux-pm/drivers/tty/serdev/core.c
===================================================================
--- linux-pm.orig/drivers/tty/serdev/core.c
+++ linux-pm/drivers/tty/serdev/core.c
@@ -704,13 +704,10 @@ static const struct acpi_device_id serde
static acpi_status acpi_serdev_add_device(acpi_handle handle, u32 level,
void *data, void **return_value)
{
+ struct acpi_device *adev = acpi_fetch_acpi_dev(handle);
struct serdev_controller *ctrl = data;
- struct acpi_device *adev;
- if (acpi_bus_get_device(handle, &adev))
- return AE_OK;
-
- if (acpi_device_enumerated(adev))
+ if (!adev || acpi_device_enumerated(adev))
return AE_OK;
/* Skip if black listed */
next reply other threads:[~2022-01-26 19:55 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-26 19:55 Rafael J. Wysocki [this message]
2022-01-27 7:39 ` Jiri Slaby
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=7355105.EvYhyI6sBW@kreacher \
--to=rjw@rjwysocki.net \
--cc=gregkh@linuxfoundation.org \
--cc=jirislaby@kernel.org \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-serial@vger.kernel.org \
--cc=robh@kernel.org \
/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
all inboxes | Powered by JetHome®