lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20210512140415.GH1333995@roeck-us.net>
Date:   Wed, 12 May 2021 07:04:15 -0700
From:   Guenter Roeck <linux@...ck-us.net>
To:     shruthi.sanil@...el.com
Cc:     wim@...ux-watchdog.org, linux-watchdog@...r.kernel.org,
        linux-kernel@...r.kernel.org, andriy.shevchenko@...ux.intel.com,
        kris.pan@...ux.intel.com, mgross@...ux.intel.com,
        srikanth.thokala@...el.com, lakshmi.bai.raja.subramanian@...el.com,
        mallikarjunappa.sangannavar@...el.com
Subject: Re: [PATCH 08/10] watchdog: keembay: MACRO for WDT enable and
 disable values

On Wed, May 12, 2021 at 02:17:22PM +0530, shruthi.sanil@...el.com wrote:
> From: Shruthi Sanil <shruthi.sanil@...el.com>
> 
> Introduced MACRO's for WDT enable and disable values for better readability
> 
> Reviewed-by: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
> Tested-by: Kris Pan <kris.pan@...el.com>
> Signed-off-by: Shruthi Sanil <shruthi.sanil@...el.com>

Reviewed-by: Guenter Roeck <linux@...ck-us.net>

> ---
>  drivers/watchdog/keembay_wdt.c | 6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/watchdog/keembay_wdt.c b/drivers/watchdog/keembay_wdt.c
> index 10896415f8c7..63a7c5d719a3 100644
> --- a/drivers/watchdog/keembay_wdt.c
> +++ b/drivers/watchdog/keembay_wdt.c
> @@ -27,6 +27,8 @@
>  #define WDT_TO_INT_MASK		BIT(9)
>  #define WDT_ISR_CLEAR		0x8200ff18
>  #define WDT_UNLOCK		0xf1d0dead
> +#define WDT_DISABLE		0x0
> +#define WDT_ENABLE		0x1
>  #define WDT_LOAD_MAX		U32_MAX
>  #define WDT_LOAD_MIN		1
>  #define WDT_TIMEOUT		5
> @@ -84,7 +86,7 @@ static int keembay_wdt_start(struct watchdog_device *wdog)
>  {
>  	struct keembay_wdt *wdt = watchdog_get_drvdata(wdog);
>  
> -	keembay_wdt_writel(wdt, TIM_WDOG_EN, 1);
> +	keembay_wdt_writel(wdt, TIM_WDOG_EN, WDT_ENABLE);
>  
>  	return 0;
>  }
> @@ -93,7 +95,7 @@ static int keembay_wdt_stop(struct watchdog_device *wdog)
>  {
>  	struct keembay_wdt *wdt = watchdog_get_drvdata(wdog);
>  
> -	keembay_wdt_writel(wdt, TIM_WDOG_EN, 0);
> +	keembay_wdt_writel(wdt, TIM_WDOG_EN, WDT_DISABLE);
>  
>  	return 0;
>  }
> -- 
> 2.17.1
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ