Skip to content

Commit 2cbfae0

Browse files
andy-shevrafaeljw
authored andcommitted
ACPI: platform: Constify properties parameter in acpi_create_platform_device()
Properties are not and should not be changed in the callee, hence constify properties parameter in acpi_create_platform_device(). Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
1 parent 7e57714 commit 2cbfae0

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

drivers/acpi/acpi_platform.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ static void acpi_platform_fill_resource(struct acpi_device *adev,
9595
* Name of the platform device will be the same as @adev's.
9696
*/
9797
struct platform_device *acpi_create_platform_device(struct acpi_device *adev,
98-
struct property_entry *properties)
98+
const struct property_entry *properties)
9999
{
100100
struct platform_device *pdev = NULL;
101101
struct platform_device_info pdevinfo;

include/linux/acpi.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -691,7 +691,7 @@ int acpi_device_uevent_modalias(struct device *, struct kobj_uevent_env *);
691691
int acpi_device_modalias(struct device *, char *, int);
692692

693693
struct platform_device *acpi_create_platform_device(struct acpi_device *,
694-
struct property_entry *);
694+
const struct property_entry *);
695695
#define ACPI_PTR(_ptr) (_ptr)
696696

697697
static inline void acpi_device_set_enumerated(struct acpi_device *adev)
@@ -930,7 +930,7 @@ static inline int acpi_device_modalias(struct device *dev,
930930

931931
static inline struct platform_device *
932932
acpi_create_platform_device(struct acpi_device *adev,
933-
struct property_entry *properties)
933+
const struct property_entry *properties)
934934
{
935935
return NULL;
936936
}

0 commit comments

Comments
 (0)