From patchwork Sat Feb 10 09:19:05 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marcus Folkesson X-Patchwork-Id: 10210395 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 35F7F60247 for ; Sat, 10 Feb 2018 09:19:46 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 3B3182999D for ; Sat, 10 Feb 2018 09:19:46 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 2C76F294BF; Sat, 10 Feb 2018 09:19:46 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, DKIM_VALID, FREEMAIL_FROM, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id A668C294BF for ; Sat, 10 Feb 2018 09:19:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:Message-Id:Date: Subject:To:From:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To: References:List-Owner; bh=L6hAmvRZ3vAtyHfg1UdeLiKIq8dHHXv8G9DOL0nBOnA=; b=cMJ ELE2IFC5tkMCX8pMkRROigCyaJmrrcdgcq/THifEjaFAzl8B8IO8di5jzWQcKlhpUg7Y7MnzU5DL+ ZngitxfOqTchb82WVGHoLy4c5+DJMaRSrU9vE0iUprvcGR8FhtD62XSDa4gQESynlFQF9oM85UhpX GuguTyqJ6fS6TeZwNN4ohK7iJViwIEHQGFEZSUfAslLy+lSIgIpRcri8ydLKsP2Xd24a6yf3MCVn1 uYD10rSrxJOwQI/b6Eq9BZTgYGnoCW3DIXFu1buhND8zMjFKeCk5BnwtFOdEVpblSgKt+X2ARomGP O++MFsOA9ufHzoeEhDT8JpmPSkAOXtw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.89 #1 (Red Hat Linux)) id 1ekRJu-00058F-4t; Sat, 10 Feb 2018 09:19:42 +0000 Received: from mail-lf0-x241.google.com ([2a00:1450:4010:c07::241]) by bombadil.infradead.org with esmtps (Exim 4.89 #1 (Red Hat Linux)) id 1ekRJq-00056p-S6; Sat, 10 Feb 2018 09:19:40 +0000 Received: by mail-lf0-x241.google.com with SMTP id q194so14351614lfe.13; Sat, 10 Feb 2018 01:19:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=g7Rb9scUjH6WY2ooNjKyKkhPY0Sz7KX83XiIvEa9qe4=; b=kA5ZklstmdijfEHe9bRBuRPtau6fKWn/qfRamrH8fUpvVnk5Vjx95ZsNUee6L+5LSt f3c7UcM5qk3KD7TRuRTQQ1B49O6SA82Hxh5nMuNLBRE1n1fADQaDRnT+Z9/mbcxHbM2a +ZzJnqorUfDkb3xF6SKFbVrcPulJBNnldUeMhRQ56Gfq6GqLRv4VlF96tx2d7qHkxN/I wW8S4zentB+w1B+mwBLTqRzNhj/SaMuyENKSuYCm+oiVTbXDIV7M4Dp2nnIUr7O6lRY4 KJqkBm4soHUiSGF5ZXnCCzVHfIpqQFeRzvETENXPg+zQ0m8saD9/UnvVOjVCqyu4oRcI lnuQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=g7Rb9scUjH6WY2ooNjKyKkhPY0Sz7KX83XiIvEa9qe4=; b=h/5Pn6+0GatidQP5VfCvQFEuKq1DluOdmfTRinnCf8urC1giKc2hjlJrAkAVN1sMpC AN0+JcG43DBf3zXMGCos16EC6p0TzzlwVswqAwZwy5dp+m82sNpQNr+bax2WkFhR3Pjd XMR1a3HP/JHpgVoVrvwdAB8OQwWJ+UerntW/7ritzKWjViRP4bCHGkRYCfPsXDT825K9 yDZfxePRj1p4WAfgoHHD2eKP0Ts2MIQfnoX0EaGAQe/mOyX3rwE9qnDjEelxU/JbltyW Kt9WQP/439ToSf6TZEXwHzPsdY2e9lLby5ObXlh0t8Kpk7uiDocZl9Zz+wVGiipgdzau vz5A== X-Gm-Message-State: APf1xPBUgnECQj+jOz1tMqT4Kr+Sr2ADNtotB2XC+1meJTPwWeyFm2Gk k/Gk8PuowQ8YlQj1CFCk7KA= X-Google-Smtp-Source: AH8x226suoG4b+ry9OOgjn0iPfdt/758YTnr0J1YZNJoGwv4pVvv3mVqAHloGFolbuodKq6O3WcU8w== X-Received: by 10.25.178.207 with SMTP id t76mr3808615lfk.111.1518254367038; Sat, 10 Feb 2018 01:19:27 -0800 (PST) Received: from localhost.localdomain ([46.194.112.145]) by smtp.gmail.com with ESMTPSA id s9sm794551lfe.48.2018.02.10.01.19.24 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 10 Feb 2018 01:19:25 -0800 (PST) From: Marcus Folkesson To: Wim Van Sebroeck , Guenter Roeck , 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 Subject: [PATCH v2 1/7] watchdog: sama5d4: make use of timeout-secs provided in devicetree Date: Sat, 10 Feb 2018 10:19:05 +0100 Message-Id: <20180210091911.3644-1-marcus.folkesson@gmail.com> X-Mailer: git-send-email 2.15.1 X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, Marcus Folkesson , linux-watchdog@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mediatek@lists.infradead.org, linux-amlogic@lists.infradead.org, linux-arm-kernel@lists.infradead.org MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP 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 Reviewed-by: Alexandre Belloni --- 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;