]> git.baikalelectronics.ru Git - kernel.git/commit
ACPI: EC: Simplify acpi_ec_ecdt_start() and acpi_ec_init()
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>
Thu, 5 Mar 2020 23:14:35 +0000 (00:14 +0100)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Sat, 14 Mar 2020 10:04:17 +0000 (11:04 +0100)
commitc858e18d29308cc25e80d9d6aaa0010be6e6619f
treed1ec50ff2c994687f3a463803ff64b66118eaf38
parent729afd408b652112d7de1b28681b7f99c5b42c31
ACPI: EC: Simplify acpi_ec_ecdt_start() and acpi_ec_init()

Notice that the return value of acpi_ec_init() is discarded anyway,
so it can be void and it doesn't need to check the return values of
acpi_bus_register_driver() and acpi_ec_ecdt_start() called by it.
Thus the latter can be void too and it really has nothing to do
if acpi_ec_add() has already found an EC matching the boot one in the
namespace.  Also, acpi_ec_ecdt_get_handle() can be folded into it.

Modify the code accordingly and while at it create a propoer kerneldoc
comment to document acpi_ec_ecdt_start() and move the remark regarding
ASUS X550ZE along with the related bug URL from acpi_ec_init() into
that comment.

Additionally, fix up a stale comment in acpi_ec_init().

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/acpi/ec.c
drivers/acpi/internal.h