From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Return-path: Received: from mail-pg0-f67.google.com ([74.125.83.67]:38649 "EHLO mail-pg0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752286AbeBKRik (ORCPT ); Sun, 11 Feb 2018 12:38:40 -0500 Date: Sun, 11 Feb 2018 09:38:37 -0800 From: Guenter Roeck To: Marcus Folkesson Cc: Wim Van Sebroeck , Rob Herring , Mark Rutland , Carlo Caione , Kevin Hilman , Matthias Brugger , Barry Song , Maxime Ripard , Chen-Yu Tsai , Linus Walleij , Vladimir Zapolskiy , Sylvain Lemieux , Nicolas Ferre , Alexandre Belloni , linux-watchdog@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-amlogic@lists.infradead.org, linux-kernel@vger.kernel.org, linux-mediatek@lists.infradead.org Subject: Re: [1/7] watchdog: sama5d4: make use of timeout-secs provided in devicetree Message-ID: <20180211173837.GA18566@roeck-us.net> References: <20180209192724.1227-2-marcus.folkesson@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180209192724.1227-2-marcus.folkesson@gmail.com> Sender: linux-watchdog-owner@vger.kernel.org List-Id: linux-watchdog@vger.kernel.org On Fri, Feb 09, 2018 at 08:27:18PM +0100, Marcus Folkesson wrote: > watchdog_init_timeout() will allways pick timeout_param since it > defaults to a valid timeout. > > Following best practice described in > Documentation/watchdog/watchdog-kernel-api.txt to make use of > the parameter logic. > > Signed-off-by: Marcus Folkesson > Reviewed-by: Guenter Roeck Unfortunately I'll have to withdraw the Reviewed-by:. wdt_timeout is used at the end of the probe function to display the selected timeout. This will have to be changed to display the actual timeout. Guenter > --- > drivers/watchdog/sama5d4_wdt.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/drivers/watchdog/sama5d4_wdt.c b/drivers/watchdog/sama5d4_wdt.c > index 0ae947c3d7bc..e6c679383734 100644 > --- a/drivers/watchdog/sama5d4_wdt.c > +++ b/drivers/watchdog/sama5d4_wdt.c > @@ -33,7 +33,7 @@ struct sama5d4_wdt { > unsigned long last_ping; > }; > > -static int wdt_timeout = WDT_DEFAULT_TIMEOUT; > +static int wdt_timeout; > static bool nowayout = WATCHDOG_NOWAYOUT; > > module_param(wdt_timeout, int, 0); > @@ -212,7 +212,7 @@ static int sama5d4_wdt_probe(struct platform_device *pdev) > return -ENOMEM; > > wdd = &wdt->wdd; > - wdd->timeout = wdt_timeout; > + wdd->timeout = WDT_DEFAULT_TIMEOUT; > wdd->info = &sama5d4_wdt_info; > wdd->ops = &sama5d4_wdt_ops; > wdd->min_timeout = MIN_WDT_TIMEOUT;