Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756363AbbKRQYI (ORCPT ); Wed, 18 Nov 2015 11:24:08 -0500 Received: from bh-25.webhostbox.net ([208.91.199.152]:45337 "EHLO bh-25.webhostbox.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756249AbbKRQYF (ORCPT ); Wed, 18 Nov 2015 11:24:05 -0500 Subject: Re: [PATCH] watchdog: mtk_wdt: Use MODE_KEY when stopping the watchdog To: Nicolas Boichat , Matthias Brugger References: <1447814701-23504-1-git-send-email-drinkcat@chromium.org> Cc: Wim Van Sebroeck , linux-watchdog@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org From: Guenter Roeck Message-ID: <564CA620.7080700@roeck-us.net> Date: Wed, 18 Nov 2015 08:24:00 -0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0 MIME-Version: 1.0 In-Reply-To: <1447814701-23504-1-git-send-email-drinkcat@chromium.org> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-Authenticated_sender: linux@roeck-us.net X-OutGoing-Spam-Status: No, score=-1.0 X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - bh-25.webhostbox.net X-AntiAbuse: Original Domain - vger.kernel.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - roeck-us.net X-Get-Message-Sender-Via: bh-25.webhostbox.net: authenticated_id: linux@roeck-us.net X-Source: X-Source-Args: X-Source-Dir: Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1059 Lines: 32 On 11/17/2015 06:45 PM, Nicolas Boichat wrote: > WDT_MODE value need to be or-ed with MODE_KEY when setting > watchdog mode. Add it to mtk_wdt_stop function, so that the > watchdog can be stopped (e.g. during suspend). > > Signed-off-by: Nicolas Boichat Reviewed-by: Guenter Roeck > --- > drivers/watchdog/mtk_wdt.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/drivers/watchdog/mtk_wdt.c b/drivers/watchdog/mtk_wdt.c > index 6ad9df9..b751f43 100644 > --- a/drivers/watchdog/mtk_wdt.c > +++ b/drivers/watchdog/mtk_wdt.c > @@ -123,6 +123,7 @@ static int mtk_wdt_stop(struct watchdog_device *wdt_dev) > > reg = readl(wdt_base + WDT_MODE); > reg &= ~WDT_MODE_EN; > + reg |= WDT_MODE_KEY; > iowrite32(reg, wdt_base + WDT_MODE); > > return 0; > -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/