From 08ff4cbe10da402e7c493ac72e298975f62a9e78 Mon Sep 17 00:00:00 2001 From: Srinivas Pandruvada Date: Mon, 4 Nov 2013 08:53:10 -0800 Subject: PowerCap: Fix build error with option -Werror=format-security Fix compile error with gcc option: -Werror=format-security for dev_set_name(&control_type->dev, name). Changed to dev_set_name(&control_type->dev, "%s", name). Signed-off-by: Srinivas Pandruvada Acked-by: Kees Cook Signed-off-by: Rafael J. Wysocki --- drivers/powercap/powercap_sys.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/powercap/powercap_sys.c') diff --git a/drivers/powercap/powercap_sys.c b/drivers/powercap/powercap_sys.c index 21814f90a44b..8d0fe431dbdd 100644 --- a/drivers/powercap/powercap_sys.c +++ b/drivers/powercap/powercap_sys.c @@ -625,7 +625,7 @@ struct powercap_control_type *powercap_register_control_type( control_type->ops = ops; INIT_LIST_HEAD(&control_type->node); control_type->dev.class = &powercap_class; - dev_set_name(&control_type->dev, name); + dev_set_name(&control_type->dev, "%s", name); result = device_register(&control_type->dev); if (result) { if (control_type->allocated) -- cgit v1.2.1