From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751345AbdJ1QO0 (ORCPT ); Sat, 28 Oct 2017 12:14:26 -0400 Received: from mail-pg0-f65.google.com ([74.125.83.65]:57246 "EHLO mail-pg0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751189AbdJ1QOY (ORCPT ); Sat, 28 Oct 2017 12:14:24 -0400 X-Google-Smtp-Source: ABhQp+Qh/kUEM3imL8U8i4R22HXX83RTualB/AgmMYv0rYFlOyymEvmDrqIBt+FvLP6Ly16x7zhDxA== Date: Sat, 28 Oct 2017 09:14:22 -0700 From: Guenter Roeck To: Andrey Smirnov Cc: linux-kernel@vger.kernel.org, linux-watchdog@vger.kernel.org, cphealy@gmail.com, Lucas Stach , Nikita Yushchenko , Lee Jones , Greg Kroah-Hartman , Pavel Machek , Andy Shevchenko , Rob Herring , Johan Hovold Subject: Re: [v9,4/5] watchdog: Add RAVE SP watchdog driver Message-ID: <20171028161422.GA6263@roeck-us.net> References: <20171025190421.18415-5-andrew.smirnov@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20171025190421.18415-5-andrew.smirnov@gmail.com> User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Oct 25, 2017 at 12:04:20PM -0700, Andrey Smirnov wrote: > This driver provides access to RAVE SP watchdog functionality. > > Cc: linux-kernel@vger.kernel.org > Cc: linux-watchdog@vger.kernel.org > Cc: cphealy@gmail.com > Cc: Lucas Stach > Cc: Nikita Yushchenko > Cc: Lee Jones > Cc: Greg Kroah-Hartman > Cc: Pavel Machek > Cc: Andy Shevchenko > Cc: Guenter Roeck > Cc: Rob Herring > Cc: Johan Hovold > Signed-off-by: Nikita Yushchenko > Signed-off-by: Andrey Smirnov > --- > > Guenter: > > In our previous discussion you noted that relying on the state of > WDOG_HW_RUNNING was not correct (that should be fixed now), please let > me know if using watchdog_hw_running() the way I do in > rave_sp_wdt_set_timeout() is incorrect as well. > You could as well have used watchdog_active(), but it is ok. > Thanks, > Andrey Smirnov > > drivers/watchdog/Kconfig | 7 + > drivers/watchdog/Makefile | 1 + > drivers/watchdog/rave-sp-wdt.c | 343 +++++++++++++++++++++++++++++++++++++++++ > 3 files changed, 351 insertions(+) > create mode 100644 drivers/watchdog/rave-sp-wdt.c > [ ... ] > + > +static int rave_sp_wdt_probe(struct platform_device *pdev) > +{ > + struct device *dev = &pdev->dev; > + const struct of_device_id *id; > + struct watchdog_device *wdd; > + struct rave_sp_wdt *sp_wd; > + struct nvmem_cell *cell; > + __le16 timeout = 0; > + int ret; > + > + id = of_match_device(rave_sp_wdt_variants, dev->parent); > + if (WARN_ON(!id)) > + return -ENODEV; > + I could understand an error message here, but why a traceback ? Guenter