Received: by 2002:ac0:98c7:0:0:0:0:0 with SMTP id g7-v6csp5076007imd; Tue, 30 Oct 2018 11:34:37 -0700 (PDT) X-Google-Smtp-Source: AJdET5fIv6XLbXgWJN4zjYb/23MA+K5koVHTKesAxNAhnAXuy2K9ebVoAc5PdO85Yns7Cf/tsOU6 X-Received: by 2002:a62:43cd:: with SMTP id l74-v6mr4236156pfi.240.1540924477754; Tue, 30 Oct 2018 11:34:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1540924477; cv=none; d=google.com; s=arc-20160816; b=l2xuCmLM7exkdOzldEuYxgwGLFTDQR8mr1d8kA1DTIa1J+yxtYKSOIfAfmD40JKR9U oRsc8FjjhsAtlgyHzDPwBp4DoyULjPHBSeUYJR+owKaBK7sTplDVOz58e/oIBMp7BPt4 Xh40qOL+FgJh8OJEYJYqX5j2rEO45tJBpVsQmm1isjq8xGQNjWIPZ3a3zrKGJq81r89v JfgbwqRknVM0tR6cSJZO+gjhsxerKQNfvIVaWwFjXJ5GrcogJG6n/nsp8Kgd90sy493K vWp86y+ce19PUkVPd4me6wAMDOrCiM+zoS1Rf8eduhYUUrPeWfnk+BV8MOA3KKs6bEeC xp2w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:from:subject:cc:to:message-id:date; bh=mBD4m4Ts8ZoArH6owCghsxtbUUm1qkVR/MEgfIHphT8=; b=YtvU2ajof233s3UBM8hHnR3AMTfcaJWXYROt3pfrhbUdHbkufdCOyCGepVlZuHC2bM wEhCLHd/fwQD+sZSRQjnx20RMIo0mh1otMQ4n6yoKtoD4zkCLY/qqm0TeeYiqHFUw3r0 6y+3gAJ1YaBgdWwDadXzIig2TbRan1DMdcMaamKITWgZFOOfVXDm+aZAAVKnd91+LNJ7 0WoY/DiFFoSjmyXIrSXuOQvxoZAjHtsPm7f9yshyK3K3xLakfbuoeRhRIn5QHfWAvJVm 8PiHv6xguQQqVP1hFxWeSMLUAkjNL+T3A6xhoLZFFIs0q3JJb2opARIn1tLaP0fk1Fy4 TvUw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t1-v6si24635253pgg.541.2018.10.30.11.34.14; Tue, 30 Oct 2018 11:34:37 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728138AbeJaDUC (ORCPT + 99 others); Tue, 30 Oct 2018 23:20:02 -0400 Received: from shards.monkeyblade.net ([23.128.96.9]:58108 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725988AbeJaDUC (ORCPT ); Tue, 30 Oct 2018 23:20:02 -0400 Received: from localhost (unknown [IPv6:2601:601:9f80:35cd::cf9]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) (Authenticated sender: davem-davemloft) by shards.monkeyblade.net (Postfix) with ESMTPSA id 9472E140A72ED; Tue, 30 Oct 2018 11:25:28 -0700 (PDT) Date: Tue, 30 Oct 2018 11:25:28 -0700 (PDT) Message-Id: <20181030.112528.308459967263600648.davem@davemloft.net> To: kurt@linutronix.de Cc: anirudh@xilinx.com, John.Linn@xilinx.com, michal.simek@xilinx.com, radhey.shyam.pandey@xilinx.com, andrew@lunn.ch, yuehaibing@huawei.com, netdev@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 2/2] net: xilinx_emaclite: recheck condition after timeout in mdio_wait() From: David Miller In-Reply-To: <20181030093139.10226-3-kurt@linutronix.de> References: <20181030093139.10226-1-kurt@linutronix.de> <20181030093139.10226-3-kurt@linutronix.de> X-Mailer: Mew version 6.7 on Emacs 26 / Mule 6.0 (HANACHIRUSATO) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.5.12 (shards.monkeyblade.net [149.20.54.216]); Tue, 30 Oct 2018 11:25:28 -0700 (PDT) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Kurt Kanzenbach Date: Tue, 30 Oct 2018 10:31:39 +0100 > The function could report a false positive if it gets preempted between reading > the XEL_MDIOCTRL_OFFSET register and checking for the timeout. In such a case, > the condition has to be rechecked to avoid false positives. > > Therefore, check for expected condition even after the timeout occurred. > > Signed-off-by: Kurt Kanzenbach Same objections as your previous patch. This isn't fixing anything.