X-Received: by 2002:a17:90a:9106:b0:1b9:115a:a2c1 with SMTP id k6-20020a17090a910600b001b9115aa2c1mr11997834pjo.80.1645663742606; Wed, 23 Feb 2022 16:49:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1645663742; cv=none; d=google.com; s=arc-20160816; b=hPGbC5kNWxnIshagVCNf7T8d2p41neMlQ3FYX+lEqEIlLVYyF6ShkF+Pn3/rIElLaR IsCW72WsoUf5EVrSk6q9b1vrriQZKct89rh7iF02Yrae2p4eT9GnEbcJCJBEphDCgSJP eida0pmkutMBwf4NaA4+KfFE26eXlTTUJGtRjlOyRseP2Lnis+4CG1wyErPeCtmllemI 2aPP+d3awvHcjHZfC/gfpnegHXojJIZiifzTbAEVIe3BqQDMiPtHna7Etnpccl4wzS8q QJRonBsPty/i5Mmq5xfUSmmDgqC8rcZa7YJAGtrmnN+Ggx7gLHIg3jgOrrRMIS+04c1D 1EIQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=eWEjgxuzLUJdI1tXyav+Ar1kvrfJ3zOac4aGgoigSM4=; b=F1WxCh4ad3KRXP/x4GYTp3dtM75pS9cYJGFgrFU5X9rsOY3iYGxqGEs0YXsg9BnHeI JEAaltKxxl1ozikk27OpEVGHMg441E8BzmcghRET+csPF+fpvdF/XceO57toE8hkT/ad r6RNDAhsCwWnryg1O0if0Mh+NH3xC+miNSuLrxX5z/11GgNR8ZE1WcMEtOAiRCbygXHi Q2aOJtbpDatYRLKeAjetHYEyV5V/GiTUINv34ljpdUq/i9ERSPdfpeMkIJtNQSZnalnQ cxBb6eyW8vITo/mjbn8lymLJ0xyBxxHutAXiBUpiWoZI9mkOBikYqt2y2x2Em+0g3Abu umBA== ARC-Authentication-Results: i=1; mx.google.com; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id n8si1102490plf.319.2022.02.23.16.49.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 23 Feb 2022 16:49:02 -0800 (PST) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id B1163B7159; Wed, 23 Feb 2022 16:44:08 -0800 (PST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S243638AbiBWSBL (ORCPT + 99 others); Wed, 23 Feb 2022 13:01:11 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56624 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S243738AbiBWSAo (ORCPT ); Wed, 23 Feb 2022 13:00:44 -0500 Received: from hostingweb31-40.netsons.net (hostingweb31-40.netsons.net [89.40.174.40]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 78EC54199C; Wed, 23 Feb 2022 10:00:14 -0800 (PST) Received: from [77.244.183.192] (port=62116 helo=melee.fritz.box) by hostingweb31.netsons.net with esmtpa (Exim 4.94.2) (envelope-from ) id 1nMvvw-00039p-MB; Wed, 23 Feb 2022 19:00:12 +0100 From: Luca Ceresoli To: linux-kernel@vger.kernel.org Cc: Luca Ceresoli , Lee Jones , Rob Herring , Chanwoo Choi , Krzysztof Kozlowski , Bartlomiej Zolnierkiewicz , Alessandro Zummo , Alexandre Belloni , Wim Van Sebroeck , Guenter Roeck , devicetree@vger.kernel.org, linux-rtc@vger.kernel.org, linux-watchdog@vger.kernel.org Subject: [PATCH v6 7/8] watchdog: max77620: add comment to clarify set_timeout procedure Date: Wed, 23 Feb 2022 18:59:07 +0100 Message-Id: <20220223175908.191618-8-luca@lucaceresoli.net> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220223175908.191618-1-luca@lucaceresoli.net> References: <20220223175908.191618-1-luca@lucaceresoli.net> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - hostingweb31.netsons.net X-AntiAbuse: Original Domain - vger.kernel.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - lucaceresoli.net X-Get-Message-Sender-Via: hostingweb31.netsons.net: authenticated_id: luca+lucaceresoli.net/only user confirmed/virtual account not confirmed X-Authenticated-Sender: hostingweb31.netsons.net: luca@lucaceresoli.net X-Source: X-Source-Args: X-Source-Dir: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RDNS_NONE, SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Clarify why we need to ping the watchdog before changing the timeout by quoting the MAX77714 datasheet. Signed-off-by: Luca Ceresoli Reviewed-by: Guenter Roeck --- Changes in v6: none Changes in v5: - improve comment to remove misleading ambiguous interpretation (Guenter Roeck) This patch is new in v4. It adds a clarification comment to the max77620 driver taken from v3 patch 7. --- drivers/watchdog/max77620_wdt.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/drivers/watchdog/max77620_wdt.c b/drivers/watchdog/max77620_wdt.c index cd321c7e0d59..b76ad6ba0915 100644 --- a/drivers/watchdog/max77620_wdt.c +++ b/drivers/watchdog/max77620_wdt.c @@ -123,6 +123,11 @@ static int max77620_wdt_set_timeout(struct watchdog_device *wdt_dev, break; } + /* + * "If the value of TWD needs to be changed, clear the system + * watchdog timer first [...], then change the value of TWD." + * (MAX77714 datasheet but applies to MAX77620 too) + */ ret = regmap_update_bits(wdt->rmap, wdt->drv_data->reg_cnfg_glbl3, wdt->drv_data->wdtc_mask, 0x1); if (ret < 0) -- 2.25.1