Re: [PATCH v1 1/1] ACPI: bus: Introduce acpi_dev_get() and reuse it in ACPI code

2021-04-12 Thread Rafael J. Wysocki
On Mon, Apr 12, 2021 at 8:10 PM Andy Shevchenko wrote: > > On Mon, Apr 12, 2021 at 9:05 PM Rafael J. Wysocki wrote: > > > > On Mon, Apr 12, 2021 at 7:47 PM Andy Shevchenko > > wrote: > > > > > > On Mon, Apr 12, 2021 at 8:32 PM Rafael J. Wysocki > > > wrote: > > > > On Sat, Apr 10, 2021 at

Re: [PATCH v1 1/1] ACPI: bus: Introduce acpi_dev_get() and reuse it in ACPI code

2021-04-12 Thread Andy Shevchenko
On Mon, Apr 12, 2021 at 9:05 PM Rafael J. Wysocki wrote: > > On Mon, Apr 12, 2021 at 7:47 PM Andy Shevchenko > wrote: > > > > On Mon, Apr 12, 2021 at 8:32 PM Rafael J. Wysocki wrote: > > > On Sat, Apr 10, 2021 at 3:47 PM Andy Shevchenko > > > wrote: > > > > ... > > > > > > static void

Re: [PATCH v1 1/1] ACPI: bus: Introduce acpi_dev_get() and reuse it in ACPI code

2021-04-12 Thread Rafael J. Wysocki
On Mon, Apr 12, 2021 at 7:47 PM Andy Shevchenko wrote: > > On Mon, Apr 12, 2021 at 8:32 PM Rafael J. Wysocki wrote: > > On Sat, Apr 10, 2021 at 3:47 PM Andy Shevchenko > > wrote: > > ... > > > > static void get_acpi_device(void *dev) > > > { > > > - if (dev) > > > -

Re: [PATCH v1 1/1] ACPI: bus: Introduce acpi_dev_get() and reuse it in ACPI code

2021-04-12 Thread Andy Shevchenko
On Mon, Apr 12, 2021 at 8:32 PM Rafael J. Wysocki wrote: > On Sat, Apr 10, 2021 at 3:47 PM Andy Shevchenko > wrote: ... > > static void get_acpi_device(void *dev) > > { > > - if (dev) > > - get_device(&((struct acpi_device *)dev)->dev); > > + acpi_dev_get(dev); > >

Re: [PATCH v1 1/1] ACPI: bus: Introduce acpi_dev_get() and reuse it in ACPI code

2021-04-12 Thread Rafael J. Wysocki
On Sat, Apr 10, 2021 at 3:47 PM Andy Shevchenko wrote: > > Introduce acpi_dev_get() to have a symmetrical API with acpi_dev_put() > and reuse both in ACPI code under drivers/acpi folder. > > While at it, use acpi_bus_put_acpi_device() in one place rather than above. > > Signed-off-by: Andy

[PATCH v1 1/1] ACPI: bus: Introduce acpi_dev_get() and reuse it in ACPI code

2021-04-10 Thread Andy Shevchenko
Introduce acpi_dev_get() to have a symmetrical API with acpi_dev_put() and reuse both in ACPI code under drivers/acpi folder. While at it, use acpi_bus_put_acpi_device() in one place rather than above. Signed-off-by: Andy Shevchenko --- drivers/acpi/device_sysfs.c | 4 ++-- drivers/acpi/glue.c