diff options
author | Andy Shevchenko <andriy.shevchenko@linux.intel.com> | 2023-06-26 14:00:23 +0300 |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2023-06-29 11:40:55 +0200 |
commit | 86fca926c042138c7defc94e1b55b5f29ca4fa13 (patch) | |
tree | 922eaa5e684ea8a8988e81d2ca3700f7dc3b8eda /drivers/acpi/bus.c | |
parent | bb6950556d4b1dd1226c1f09e84b53cb37e5340f (diff) | |
download | linux-stable-86fca926c042138c7defc94e1b55b5f29ca4fa13.tar.gz linux-stable-86fca926c042138c7defc94e1b55b5f29ca4fa13.tar.bz2 linux-stable-86fca926c042138c7defc94e1b55b5f29ca4fa13.zip |
ACPI: bus: Constify acpi_companion_match() returned value
acpi_companion_match() doesn't alter the contents of the passed
parameter, so we don't expect that returned value can be altered
either. So constify it.
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/acpi/bus.c')
-rw-r--r-- | drivers/acpi/bus.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/acpi/bus.c b/drivers/acpi/bus.c index e3e0bd0c5a50..20cdfb37da79 100644 --- a/drivers/acpi/bus.c +++ b/drivers/acpi/bus.c @@ -682,7 +682,7 @@ bool acpi_device_is_first_physical_node(struct acpi_device *adev, * resources available from it but they will be matched normally using functions * provided by their bus types (and analogously for their modalias). */ -struct acpi_device *acpi_companion_match(const struct device *dev) +const struct acpi_device *acpi_companion_match(const struct device *dev) { struct acpi_device *adev; @@ -706,7 +706,7 @@ struct acpi_device *acpi_companion_match(const struct device *dev) * identifiers and a _DSD object with the "compatible" property, use that * property to match against the given list of identifiers. */ -static bool acpi_of_match_device(struct acpi_device *adev, +static bool acpi_of_match_device(const struct acpi_device *adev, const struct of_device_id *of_match_table, const struct of_device_id **of_id) { @@ -808,7 +808,7 @@ static bool __acpi_match_device_cls(const struct acpi_device_id *id, return true; } -static bool __acpi_match_device(struct acpi_device *device, +static bool __acpi_match_device(const struct acpi_device *device, const struct acpi_device_id *acpi_ids, const struct of_device_id *of_ids, const struct acpi_device_id **acpi_id, |