Received: by 2002:ac0:8845:0:0:0:0:0 with SMTP id g63csp635923img; Thu, 28 Feb 2019 05:32:13 -0800 (PST) X-Google-Smtp-Source: AHgI3IZtEF3eM9QhwmC28af6NLgQFeFepdHi3/Uw0dAFXdPrQD1eTeoNgV4OgaI8S1C/w5rM6mWE X-Received: by 2002:a62:5e46:: with SMTP id s67mr7465963pfb.126.1551360733320; Thu, 28 Feb 2019 05:32:13 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1551360733; cv=none; d=google.com; s=arc-20160816; b=dbSN29D5ekeG1LWqSMT0zssgdKYqgtMLEJKba3AWPUtp1A6KIxC/AXS94yPhiFaFx+ xUV9yZgGatnVE175FQXlGqwbr93k/eTODcU1nmQKuxlT2xHPdVHbkunvr7cVqHvNo2hy WgOyH51uSYQl/y6BsVj7yedj3Il5aiHoC7rTEO4GGtCCAY+ZFRTApr53R95AkR08uYy0 f2TI8tW/ZtSZmngAyatlVQBY5qxwZq1F7Wwv8E3HzGYT+D9LTbJFfeopVuzZkV3Oxpki Lqg0yRY1S8xT2PXn+FVIzhJNU/hcubzGhJIrHDXhqoSqOImYMyBzFtwkDi2uNoGA2pZM Hoqg== 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:message-id:date:subject:cc:to:from; bh=cNZUD1iZB5gFsNPdEXE7VGY3JaDVvjHq+iABkg1odaI=; b=vIAtNEBj2VAcSl+raqZq+NIyylSeG9J8psjiOMbY/HohSxx39UMjmtKF+FLP71i53o dztFXp1TDlvikpjBlj/bsgsp7TAHD4Pie2iej+LC762II31ZhGxtKazJHnzYIoXY9cly wxd/3l74ofsnRCZ5gsz9Ih0+FitQtoXxrBST7+plXKzFm4in57Zy35edy6dpNwywvtZk A6Y8eV+5u+62Pdx87XViAZoKnwcJRJanNuNW4oHNRaoBYA1iqMZRBkt2ZTFwSPVd+J2N zMC3x2lNeweBM78UhvQv/8NJcuElUiHzNtJ7GDNn9qiES0lXFiSFEr7fZcP0r8iFEmgp Qb4g== 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 s6si17880175plq.160.2019.02.28.05.31.58; Thu, 28 Feb 2019 05:32:13 -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 S1732648AbfB1NZP (ORCPT + 99 others); Thu, 28 Feb 2019 08:25:15 -0500 Received: from relay2-d.mail.gandi.net ([217.70.183.194]:58691 "EHLO relay2-d.mail.gandi.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732361AbfB1NZO (ORCPT ); Thu, 28 Feb 2019 08:25:14 -0500 X-Originating-IP: 90.88.147.150 Received: from localhost (aaubervilliers-681-1-27-150.w90-88.abo.wanadoo.fr [90.88.147.150]) (Authenticated sender: antoine.tenart@bootlin.com) by relay2-d.mail.gandi.net (Postfix) with ESMTPSA id 716DD40005; Thu, 28 Feb 2019 13:25:11 +0000 (UTC) From: Antoine Tenart To: davem@davemloft.net, linux@armlinux.org.uk Cc: Antoine Tenart , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, thomas.petazzoni@bootlin.com, maxime.chevallier@bootlin.com, gregory.clement@bootlin.com, miquel.raynal@bootlin.com, nadavh@marvell.com, stefanc@marvell.com, ymarkman@marvell.com, mw@semihalf.com Subject: [PATCH net-next 04/15] net: mvpp2: a port can be disabled even if we use the link IRQ Date: Thu, 28 Feb 2019 14:21:17 +0100 Message-Id: <20190228132128.30154-5-antoine.tenart@bootlin.com> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190228132128.30154-1-antoine.tenart@bootlin.com> References: <20190228132128.30154-1-antoine.tenart@bootlin.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org We had a check in the mvpp2_mac_link_down() function (called by phylink) to avoid disabling the port when link interrupts are used. It turned out the interrupt can still be used with the port disabled. We can thus remove this check. Signed-off-by: Antoine Tenart --- drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c | 7 ------- 1 file changed, 7 deletions(-) diff --git a/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c b/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c index 37d3c97c0b9b..71a3fdb76b12 100644 --- a/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c +++ b/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c @@ -4739,13 +4739,6 @@ static void mvpp2_mac_link_down(struct net_device *dev, unsigned int mode, mvpp2_egress_disable(port); mvpp2_ingress_disable(port); - /* When using link interrupts to notify phylink of a MAC state change, - * we do not want the port to be disabled (we want to receive further - * interrupts, to be notified when the port will have a link later). - */ - if (!port->has_phy) - return; - mvpp2_port_disable(port); } -- 2.20.1