Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp12923554pxu; Sat, 2 Jan 2021 17:32:16 -0800 (PST) X-Google-Smtp-Source: ABdhPJxvlvs6U38g7vBs2RwISjlX5GczxS3CW2tsM8Nv1oxAbJaRwLw9Kxz9avkinmGSPaGkw2O5 X-Received: by 2002:a17:906:fb9b:: with SMTP id lr27mr63444830ejb.175.1609637536297; Sat, 02 Jan 2021 17:32:16 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1609637536; cv=none; d=google.com; s=arc-20160816; b=YmAh3nokyVFwaC8BWcxzDpqWidqQlgmSYumJBzAwxA+rJVW9o2a5825j6vemYRx0nJ 56QEd2ZHtzI+K2u/QNlEFpTOncs1b4SQaeOf6Uvja8DYh0JknUpl/XpCe5E8pCsCy/Nk 3Ivs476fTsuVxB6wQsJJs0KE75OzZsEp2B2TOF6+C/UE+VFgUf8ileqE3YSQDIw+jbPh 52AnnnDHKQ1KNlahRPfhGhBkHp1Jki9Fp3WhFZj1q639a3t8gXeV4MAcSQnFfrSNe+7N X2jcrE0+JP105jSUN7MJKFGygkOQ75e5raq62H4Q+VCNeKasSCe6FcaSO2Up3A8JXUjM Gf6w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=6S17wZsGDVyR7PYBl6TcY4s1Y0lYR9kSxULYqsFA63c=; b=U8dCyPXLMFE42MNLSDDzc/Qw5TCM0G91kc4cslQJjECLRlZa6iyZ3KZ1K2cEmQ48PG ux0lMtBCOFKqnRxEgZerpU7Fv+4iuiUvVkis6OpetqpRSiRDe8YdeHRfh/im/zYSPmW/ x/skiqICDtikzaEERXs8RL0dZMqlWMEH4oNK4QzdRcKwmowcWkLHiob65Q6ccSey4C8a 95b/fgimpNIPmpH7aE7Q6IkHDQkSuTyUsPQk43ekM78DadAB3giioyBo1EE9lcQxriWb 1XLR1LeVT6T69jm4fpFSYDCocPdgPPn3zWPXqPF9oURkyDGafWUmE57GzSwnWXmSmRdc H8gw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@googlemail.com header.s=20161025 header.b=teWo+rdS; 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=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=googlemail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id n14si28791819edq.574.2021.01.02.17.31.54; Sat, 02 Jan 2021 17:32:16 -0800 (PST) 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; dkim=pass header.i=@googlemail.com header.s=20161025 header.b=teWo+rdS; 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=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=googlemail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727018AbhACB0l (ORCPT + 99 others); Sat, 2 Jan 2021 20:26:41 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57552 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726689AbhACB0k (ORCPT ); Sat, 2 Jan 2021 20:26:40 -0500 Received: from mail-ej1-x634.google.com (mail-ej1-x634.google.com [IPv6:2a00:1450:4864:20::634]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3B658C061573; Sat, 2 Jan 2021 17:26:00 -0800 (PST) Received: by mail-ej1-x634.google.com with SMTP id jx16so32165987ejb.10; Sat, 02 Jan 2021 17:26:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=6S17wZsGDVyR7PYBl6TcY4s1Y0lYR9kSxULYqsFA63c=; b=teWo+rdSZiDaZ/e8gyEiEMInO56DHz1W2A5q3lEv60OHkbktKyj/bk/mtFQhpafAUs rH1X/J08zE7SRkoC0V6mNOQCrZMmIVZJISRg4zoonLhjazPlVbWfvE8w54VxnohXlVGu /4ehxpwMkMZBCupZlX5TtZcKi/gB8x5Kp2We0sh7iIicpip7TgEo6MLy6z+IGb53nX3l zYaARjGdu8gW6ByVyEvhMhkDANkKwgYRkHClXjz9gBg8Mf3ccY3fPLlkOgAD+TAyS+NX MA7sCXR0Z9H8ybKSgtV7ASwFUI2Ezd9UkXpRIvwsI2qdrNkNTs2wOXR79t+6TsmLybhg ZkbQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=6S17wZsGDVyR7PYBl6TcY4s1Y0lYR9kSxULYqsFA63c=; b=Ws6g4ZXiCHo26gqsYCnGJChDlgp2TwAVJLEFtcxIaSqdBpkIDsmhEsumB/b5CZP2xY vjpAM0hLQIgXYzFNSO0Ss8J2CfxyRopVzsUZ6EgnrIvClM7+6jjJvY1dX7BDvqBcaEzU 1hCEk78NhgjjvmWHOIzF6W6+bsIYk08LdxlMN1ojpIReqML/+qB/Sqt+/qXrYawiAfVA j+N8euaNnRsVRCyojiDsGbDN2Wa4vlPqWA3zOXwxNNkM27DF1KSKQCFMgs2WKLzcDbZs NWiWhYyv16LBipLsei2AvolHlp2cjdzBxoSlMkP11mXmEv6NxYhNkbmxWcy7FIAZucRc Akcw== X-Gm-Message-State: AOAM531apls/E52t4lyM3AmnMgPG+G2dYAqHaS5b2eFr8NkiXeaLZPeD RIFojH/8H/CU9fodPicqWfM= X-Received: by 2002:a17:906:fa12:: with SMTP id lo18mr63742103ejb.354.1609637158900; Sat, 02 Jan 2021 17:25:58 -0800 (PST) Received: from localhost.localdomain (p200300f13724fd00428d5cfffeb99db8.dip0.t-ipconnect.de. [2003:f1:3724:fd00:428d:5cff:feb9:9db8]) by smtp.googlemail.com with ESMTPSA id op5sm22118006ejb.43.2021.01.02.17.25.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 02 Jan 2021 17:25:58 -0800 (PST) From: Martin Blumenstingl To: hauke@hauke-m.de, netdev@vger.kernel.org Cc: andrew@lunn.ch, vivien.didelot@gmail.com, f.fainelli@gmail.com, olteanv@gmail.com, davem@davemloft.net, kuba@kernel.org, linux-kernel@vger.kernel.org, Martin Blumenstingl Subject: [PATCH 0/2] net: dsa: lantiq_gswip: two fixes for -net/-stable Date: Sun, 3 Jan 2021 02:25:42 +0100 Message-Id: <20210103012544.3259029-1-martin.blumenstingl@googlemail.com> X-Mailer: git-send-email 2.30.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org While testing the lantiq_gswip driver in OpenWrt at least one board had a non-working Ethernet port connected to an internal 100Mbit/s PHY22F GPHY. The problem which could be observed: - the PHY would detect the link just fine - ethtool stats would see the TX counter rise - the RX counter in ethtool was stuck at zero It turns out that two independent patches are needed to fix this: - first we need to enable the MII data lines also for internal PHYs - second we need to program the GSWIP_MII_CFG registers for all ports except the CPU port These two patches have also been tested by back-porting them on top of Linux 5.4.86 in OpenWrt. Special thanks to Hauke for debugging and brainstorming this on IRC with me! Martin Blumenstingl (2): net: dsa: lantiq_gswip: Enable GSWIP_MII_CFG_EN also for internal PHYs net: dsa: lantiq_gswip: Fix GSWIP_MII_CFG(p) register access drivers/net/dsa/lantiq_gswip.c | 27 +++++++-------------------- 1 file changed, 7 insertions(+), 20 deletions(-) -- 2.30.0