]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit - include/linux/property.h
device property: allow to constify properties
authorDmitry Torokhov <dmitry.torokhov@gmail.com>
Fri, 3 Feb 2017 01:41:25 +0000 (17:41 -0800)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Tue, 7 Feb 2017 12:21:15 +0000 (13:21 +0100)
commitbec84da8d1da6677c458e6eedd8e814eea91b9fc
treec78b997b7d47c5040f67fdabb3770e5dc0057c63
parentd5adbfcd5f7bcc6fa58a41c5c5ada0e5c826ce2c
device property: allow to constify properties

There is no reason why statically defined properties should be modifiable,
so let's make device_add_properties() and the rest of pset_*() functions to
take const pointers to properties.

This will allow us to mark properties as const/__initconst at definition
sites.

Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/base/property.c
include/linux/property.h