Received: by 10.223.185.111 with SMTP id b44csp909440wrg; Fri, 9 Mar 2018 16:36:25 -0800 (PST) X-Google-Smtp-Source: AG47ELs8NkakWBN3mnEol4tm1e8+0JrjbiWLFyv/PhCWYb2PAjqB4KUcGU8OcxTLpDjV35TZP5nD X-Received: by 2002:a17:902:522:: with SMTP id 31-v6mr372245plf.122.1520642185242; Fri, 09 Mar 2018 16:36:25 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1520642185; cv=none; d=google.com; s=arc-20160816; b=SYbaOkwmVg90m4xYDR8eWaj0DGReE+A5U+jkEIG/ViTfraeMyki5IA22mYT4AMecDi HCs90N2ANKTKNPr47VSAFbkpFDsfhxZ4of3cHw+AmCgWis+b2MDj4AtjIB0I2vQ/nKFH WfxHb6bUCh0STl/BjVdHcFHOixGXZ/t4bFWl4yfmbbhGXnagesHm4pr2QA8EuT4LmU4E wYJxKhyJ83qQ162sB547UvGjReiJ+lDrtyTtEeTCJRXwQG0GhBTi62RBGbxlEnlfUkVx qq+nJ0VFwTjpjsevx82RXFktVsVMpLk31QtYXiVUN9aMcUA3lSM+3KXwXlfWK7L5BDqr vcLQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=Ylq1TC1Pra7mr41Zw0au2ETy4obUcQDK/9IYgx/S8kk=; b=wj7eX6YehdFFI0QdglPIf+acUDDvZFPLy51wh7JWGPTRil2DX6u2fMDFACmp3y6EcL Fo1nJfC3vfyeoh3XSm90oabxIFEFHR4ahrPOsiNPSzp/+/mUuR6pxe47YW1KtO+tdJhF GG7YHZE+ZipgNb8LIVWSEP3TQ/ESZTaXLJR8GxOKLN5phf0Ve08ZjO9AOFxUxLpMCIin tnR2A/lvU+6bwh9QZLKJGZYeXthW1krLAkCO89igfmvPp2RmLznnF/ERcptc0xW6b0zI k6sKlQpUn7wLuebNxybVXsIXJKUrhfDMr9f60TdUmLaHKGnX5lOlVqm3uHlzFfXrWzAc D9ag== 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 i61-v6si1759316plb.140.2018.03.09.16.36.10; Fri, 09 Mar 2018 16:36:25 -0800 (PST) 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 S933861AbeCJAeL (ORCPT + 99 others); Fri, 9 Mar 2018 19:34:11 -0500 Received: from mail.linuxfoundation.org ([140.211.169.12]:39912 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751434AbeCJAWN (ORCPT ); Fri, 9 Mar 2018 19:22:13 -0500 Received: from localhost (unknown [185.236.200.248]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id 0CE19FE0; Sat, 10 Mar 2018 00:22:12 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Heiner Kallweit , Florian Fainelli , "David S. Miller" Subject: [PATCH 4.9 44/65] net: phy: fix phy_start to consider PHY_IGNORE_INTERRUPT Date: Fri, 9 Mar 2018 16:18:44 -0800 Message-Id: <20180310001828.494433324@linuxfoundation.org> X-Mailer: git-send-email 2.16.2 In-Reply-To: <20180310001824.927996722@linuxfoundation.org> References: <20180310001824.927996722@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.9-stable review patch. If anyone has any objections, please let me know. ------------------ From: Heiner Kallweit [ Upstream commit 08f5138512180a479ce6b9d23b825c9f4cd3be77 ] This condition wasn't adjusted when PHY_IGNORE_INTERRUPT (-2) was added long ago. In case of PHY_IGNORE_INTERRUPT the MAC interrupt indicates also PHY state changes and we should do what the symbol says. Fixes: 84a527a41f38 ("net: phylib: fix interrupts re-enablement in phy_start") Signed-off-by: Heiner Kallweit Reviewed-by: Florian Fainelli Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman --- drivers/net/phy/phy.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/net/phy/phy.c +++ b/drivers/net/phy/phy.c @@ -925,7 +925,7 @@ void phy_start(struct phy_device *phydev break; case PHY_HALTED: /* make sure interrupts are re-enabled for the PHY */ - if (phydev->irq != PHY_POLL) { + if (phy_interrupt_is_valid(phydev)) { err = phy_enable_interrupts(phydev); if (err < 0) break;