Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1703999

Re: [PATCH 1/2] watchdog: cadence_wdt: Enable access to module parameters

From Guenter Roeck <linux@roeck-us.net>
Newsgroups linux.kernel
Subject Re: [PATCH 1/2] watchdog: cadence_wdt: Enable access to module parameters
Date 2017-08-04 15:50 +0200
Message-ID <uaL9f-7DN-13@gated-at.bofh.it> (permalink)
References <uaFnb-42L-13@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On 08/04/2017 12:39 AM, Michal Simek wrote:
> Give read access to module parameters to all and write access to root.
> This change also improves driver error path testing.
> 
> Signed-off-by: Michal Simek <michal.simek@xilinx.com>
> ---
> 
> Please let me know what you think - I can use macros from stat.h if
> required
> 

Seems to be quite pointless and misleading, since the values are only read
at probe time. Am I missing something ?

Guenter

> ---
>   drivers/watchdog/cadence_wdt.c | 4 ++--
>   1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/watchdog/cadence_wdt.c b/drivers/watchdog/cadence_wdt.c
> index 05c000081e9d..dadd3b0c2d49 100644
> --- a/drivers/watchdog/cadence_wdt.c
> +++ b/drivers/watchdog/cadence_wdt.c
> @@ -52,12 +52,12 @@
>   static int wdt_timeout;
>   static int nowayout = WATCHDOG_NOWAYOUT;
>   
> -module_param(wdt_timeout, int, 0);
> +module_param(wdt_timeout, int, 0644);
>   MODULE_PARM_DESC(wdt_timeout,
>   		 "Watchdog time in seconds. (default="
>   		 __MODULE_STRING(CDNS_WDT_DEFAULT_TIMEOUT) ")");
>   
> -module_param(nowayout, int, 0);
> +module_param(nowayout, int, 0644);
>   MODULE_PARM_DESC(nowayout,
>   		 "Watchdog cannot be stopped once started (default="
>   		 __MODULE_STRING(WATCHDOG_NOWAYOUT) ")");
> 

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH 1/2] watchdog: cadence_wdt: Enable access to module parameters Michal Simek <michal.simek@xilinx.com> - 2017-08-04 09:40 +0200
  Re: [PATCH 1/2] watchdog: cadence_wdt: Enable access to module  parameters Guenter Roeck <linux@roeck-us.net> - 2017-08-04 15:50 +0200
    Re: [PATCH 1/2] watchdog: cadence_wdt: Enable access to module  parameters Michal Simek <monstr@monstr.eu> - 2017-08-04 16:00 +0200

csiph-web