staging: greybus: svc_watchdog: Modify char* array declaration.
PATCH 1/1 staging: greybus: svc_watchdog: Modify char* array declaration.
Modify "static char* array" to "static char* const array". Issue found using checkpatch.pl
WARNING:char* array declaration might be better as static constant
Signed-off-by Sanjana Sanikommu <[email protected]>
--- drivers/staging/greybus/svc_watchdog.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/greybus/svc_watchdog.c +2 -2
@@ -44,12 +44,12 @@ static int svc_watchdog_pm_notifier(struct notifier_block *notifier,static void greybus_reset (struct work_struct *work) {static char const start_path[] ="/system/bin/start" ; -static char *envp[] = { +static char const *envp[] = {"HOME=/" ,"PATH=/sbin:/vendor/bin:/system/sbin:/system/bin:/system/xbin" ,NULL , }; -static char *argv[] = { +static char const *argv[] = { (char *)start_path,"unipro_reset" ,NULL ,
Signature · 1 line
2.17.1
Greg KH
maintainerQuoted 32 lines · Sanjana Sanikommu
Modify "static char* array" to "static char* const array". Issue found using checkpatch.pl
WARNING:char* array declaration might be better as static constant
Signed-off-by Sanjana Sanikommu <[email protected]>--- drivers/staging/greybus/svc_watchdog.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)drivers/staging/greybus/svc_watchdog.c +2
-2@@ -44,12 +44,12 @@ static int svc_watchdog_pm_notifier(struct notifier_block *notifier,static void greybus_reset (struct work_struct *work) {static char const start_path[] ="/system/bin/start" ; -static char *envp[] = { +static char const *envp[] = {"HOME=/" ,"PATH=/sbin:/vendor/bin:/system/sbin:/system/bin:/system/xbin" ,NULL , }; -static char *argv[] = { +static char const *argv[] = { (char *)start_path,"unipro_reset" ,NULL ,Signature · 1 line
2.17.1
Always test-build your patches before sending them out. You did not do that here, why not? This blows up the build in horrible ways :(
greg k-h