Received: by 2002:a05:6a10:c7c6:0:0:0:0 with SMTP id h6csp2505508pxy; Tue, 3 Aug 2021 08:01:58 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxcpvuRhRZgDdi7avGRh3L/EMyGMwHT3q772dLVm8jdL0oCvIk2+kZo7m8oyL54HVD+0fML X-Received: by 2002:a02:866b:: with SMTP id e98mr20145046jai.48.1628002917687; Tue, 03 Aug 2021 08:01:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1628002917; cv=none; d=google.com; s=arc-20160816; b=R9htw49QMRbApv6O88E+oG4ebpCTqyXiZ68LIJVN6sZDcw/m4yiK65TtXy5G6DdJJ5 6/K4L2r8E43KYizqlIAQoESWeLAtD8BDApTb2MCck6nKZovnG8J4wEXmC7+mf8uOsbvK 8V+AF3uRZ73hzg27ZQf0jqQyUmAHG7QskU/6jw4Ply3TkwKHyUlhpgvwCCumWEwBJXPq SmpAuHUJoGeiJhgDZlsSKgQi4eDiENraBpJrnptBsvcINQH4ozvl4PNtqZzyjsLvRTuO UK7iumEwUsaAJcThk8AqimKAnskJ5xsIPEHE1f6XEBfj1qsMZ20fhz4C2JKdBKW7NCGj kKmw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject; bh=/b5hFxNSLoTnVyUdZeF6df8QMr38D4zHAuUAH6ixhp4=; b=Dmvbs10khWrTw5xxm5yc8mJ/iaBw6LKTtulT4DlD/X/m8cB5/+AIrwRBGGnRxw0NeX yIsrdjyu/WpFw84nV9x5FFz4lhyO+J9n3DeYNjQjfP7QsRNEs9ODNvFQx2+Qpcvha53l ZdaTCDiOCXJ7lNpnqZqcFmZ3lg/BK7fXRGtrAPS3ftB14hXU/xErvhS//JSD8eri/MYD S6wBQ3bCzi5iYttyQfm/brnQufw3ftC/Ed7cIgjQo00C3o46QRORFVQVOWUWD3l4TPpq LJFhAVkSL55aoJrBpoobkF4D0KMFyLyAObCcUlVTqqiGYSwfAYAhSTcpyzqXVQrwlzfb Banw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=siemens.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id h3si16027333ila.128.2021.08.03.08.01.44; Tue, 03 Aug 2021 08:01:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=siemens.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236855AbhHCO7i (ORCPT + 99 others); Tue, 3 Aug 2021 10:59:38 -0400 Received: from lizzard.sbs.de ([194.138.37.39]:43645 "EHLO lizzard.sbs.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236787AbhHCO7e (ORCPT ); Tue, 3 Aug 2021 10:59:34 -0400 Received: from mail2.sbs.de (mail2.sbs.de [192.129.41.66]) by lizzard.sbs.de (8.15.2/8.15.2) with ESMTPS id 173Ex3hJ016806 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 3 Aug 2021 16:59:03 +0200 Received: from [167.87.38.215] ([167.87.38.215]) by mail2.sbs.de (8.15.2/8.15.2) with ESMTP id 173Ex2AO002751; Tue, 3 Aug 2021 16:59:02 +0200 Subject: Re: Faulty commit "watchdog: iTCO_wdt: Account for rebooting on second timeout" To: Jean Delvare , linux-watchdog@vger.kernel.org, LKML , stable@vger.kernel.org Cc: Guenter Roeck , Wim Van Sebroeck , Michael Marley References: <20210803165108.4154cd52@endymion> From: Jan Kiszka Message-ID: Date: Tue, 3 Aug 2021 16:59:02 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.12.0 MIME-Version: 1.0 In-Reply-To: <20210803165108.4154cd52@endymion> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 03.08.21 16:51, Jean Delvare wrote: > Hi all, > > Commit cb011044e34c ("watchdog: iTCO_wdt: Account for rebooting on > second timeout") causes a regression on several systems. Symptoms are: > system reboots automatically after a short period of time if watchdog > is enabled (by systemd for example). This has been reported in bugzilla: > > https://bugzilla.kernel.org/show_bug.cgi?id=213809 > > Unfortunately this commit was backported to all stable kernel branches > (4.14, 4.19, 5.4, 5.10, 5.12 and 5.13). I'm not sure why that is the > case, BTW, as there is no Fixes tag and no Cc to stable@vger either. > And the fix is not trivial, has apparently not seen enough testing, > and addresses a problem that has a known and simple workaround. IMHO it > should never have been accepted as a stable patch in the first place. > Especially when the previous attempt to fix this issue already ended > with a regression and a revert. > > Anyway... After a glance at the patch, I see what looks like a nice > thinko: > > + if (p->smi_res && > + (SMI_EN(p) & (TCO_EN | GBL_SMI_EN)) != (TCO_EN | GBL_SMI_EN)) > > The author most certainly meant inl(SMI_EN(p)) (the register's value) > and not SMI_EN(p) (the register's address). > https://lkml.org/lkml/2021/7/26/349 Jan -- Siemens AG, T RDA IOT Corporate Competence Center Embedded Linux