Received: by 2002:ac0:8845:0:0:0:0:0 with SMTP id g63csp635810img; Thu, 28 Feb 2019 05:32:08 -0800 (PST) X-Google-Smtp-Source: AHgI3IZqOU/JIR5zdXfggZqShGdvYqAY+d65L69j8qJOHb7rGNCyNLlcnKXbgJsHrMlXSv/1EwF1 X-Received: by 2002:a17:902:9a43:: with SMTP id x3mr7896098plv.173.1551360728552; Thu, 28 Feb 2019 05:32:08 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1551360728; cv=none; d=google.com; s=arc-20160816; b=RGgJMhTtR+mssR7zreYAysMN3E1Uvos3/TT3BHXCFfTPA6MYcBalMLHaoU9ruLkX/0 Z835OZwEw6R7WV+eilIRsDgXLZoueuSfGD5406XQYJ9ZDYGcLuNhhDAYckFnB+OmMImi iDu4VWWv6rEJltN26yYmnitj+VQ2555nHGWWz6VfGhBh9PmwMB6oIbIqmU8y1XEcnSY/ GG4CIlLVpSgc+U44vgKDdfbF3g/mfDduTEp8mUklNCuPhcNn/tVfqb6FuqVC2oE8PwPJ yKAwPRKd828sLV1m7ogr7yYCImii4+vebRLOZfLG8+wIgWDmTrGW2h3wz7GdDgM8dfvf NpCA== 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=9sessxM0WyZvzx63pipYy9+TjonHR1dAQi1ieL/55nM=; b=xI5fcIhtxoZNHY+VqzfM6g7LY7bjHmyhYGvRTVWALI2mPMuycLgjlRT547bmHvXOLy NJ9VgHe2IeC+HvZmIH/NDvmen1J1ZwwZ9puWMlfyKqXVcKOohNxi+KdA/3TD1yUD6N2i UARKsmDexE2B8TfOu1+al4EVYmWHfGiXEnHhTa0ZcxltOK2hefkYmFUBCxJOAwJNSNUx S7ihRyxmNn3Zu9VBd2bNZZIG4vgSI3vCXtFwm9IL18Kex65uafts/oGy7OCsEl28a+e/ JSYr7PDfiq5IHhwc4itM8Ijq6sy54v4cXL4SP/2qZrtA28URRZlxkD8jCxetxrzJI8RX oC/g== 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 e6si16839511pgc.252.2019.02.28.05.31.53; Thu, 28 Feb 2019 05:32:08 -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 S1731302AbfB1NZj (ORCPT + 99 others); Thu, 28 Feb 2019 08:25:39 -0500 Received: from relay11.mail.gandi.net ([217.70.178.231]:60623 "EHLO relay11.mail.gandi.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732895AbfB1NZh (ORCPT ); Thu, 28 Feb 2019 08:25:37 -0500 Received: from localhost (aaubervilliers-681-1-27-150.w90-88.abo.wanadoo.fr [90.88.147.150]) (Authenticated sender: antoine.tenart@bootlin.com) by relay11.mail.gandi.net (Postfix) with ESMTPSA id F1FB4100017; Thu, 28 Feb 2019 13:25:33 +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 13/15] net: mvpp2: reset the MACs when reconfiguring a port Date: Thu, 28 Feb 2019 14:21:26 +0100 Message-Id: <20190228132128.30154-14-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 This patch makes sure both PPv2 MACs (GMAC + XLG MAC) are set in reset while a port is reconfigured. This is done so that we make sure a MAC is in a reset state when not used, as only one of the two will be set out of reset after the port is configured properly. Signed-off-by: Antoine Tenart --- drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c b/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c index 13c4fcbc4269..36e709a4e7d9 100644 --- a/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c +++ b/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c @@ -3137,6 +3137,9 @@ static void mvpp22_mode_reconfigure(struct mvpp2_port *port) { u32 ctrl3; + /* Set the GMAC & XLG MAC in reset */ + mvpp2_mac_reset(port); + /* comphy reconfiguration */ mvpp22_comphy_init(port); -- 2.20.1