mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git
synced 2026-04-23 05:56:14 -04:00
powercap: constify powercap_zone_ops and powercap_zone_constraint_ops structures
The powercap_zone_ops and powercap_zone_constraint_ops structures are never modified, so declare them as const. Most of the actual changes adjust indentation to accomodate the const keyword. Done with the help of Coccinelle. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
This commit is contained in:
committed by
Rafael J. Wysocki
parent
74bf8efb5f
commit
600c395bf6
@@ -293,8 +293,8 @@ err_alloc:
|
||||
}
|
||||
|
||||
static int create_constraints(struct powercap_zone *power_zone,
|
||||
int nr_constraints,
|
||||
struct powercap_zone_constraint_ops *const_ops)
|
||||
int nr_constraints,
|
||||
const struct powercap_zone_constraint_ops *const_ops)
|
||||
{
|
||||
int i;
|
||||
int ret = 0;
|
||||
@@ -492,13 +492,13 @@ static struct class powercap_class = {
|
||||
};
|
||||
|
||||
struct powercap_zone *powercap_register_zone(
|
||||
struct powercap_zone *power_zone,
|
||||
struct powercap_control_type *control_type,
|
||||
const char *name,
|
||||
struct powercap_zone *parent,
|
||||
const struct powercap_zone_ops *ops,
|
||||
int nr_constraints,
|
||||
struct powercap_zone_constraint_ops *const_ops)
|
||||
struct powercap_zone *power_zone,
|
||||
struct powercap_control_type *control_type,
|
||||
const char *name,
|
||||
struct powercap_zone *parent,
|
||||
const struct powercap_zone_ops *ops,
|
||||
int nr_constraints,
|
||||
const struct powercap_zone_constraint_ops *const_ops)
|
||||
{
|
||||
int result;
|
||||
int nr_attrs;
|
||||
|
||||
Reference in New Issue
Block a user