Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp632059pxb; Tue, 9 Feb 2021 08:43:47 -0800 (PST) X-Google-Smtp-Source: ABdhPJyh9bsw9NvdooEf7X9i6nVYhfaDNci+hAIoJGcB8R3YK+ZvEKFsv9cw90qfBbgnCmFZrhTp X-Received: by 2002:a05:6402:10c8:: with SMTP id p8mr13030293edu.144.1612889026897; Tue, 09 Feb 2021 08:43:46 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1612889026; cv=none; d=google.com; s=arc-20160816; b=wbSVw84q+0NWu0pa0e7KbctB69BDARdv26C2y6Yaw+O7LJ+buZ4+BHWnAzc9Gj45UF ao6JQ8HpeiWBBBif1bJMQjO6+1dVPFYFIL4mZWIQ2h/cudmoqRq8en/KXtoZpO/I4C8o 64srvFis9RpX9W/1fD4fNVNyEmUoAOJEvZJq90JExfp47n8DfHAu+4sVkD/ThH4NTPe+ CM+mXrYcR2ImzwTNBu1HPgYCpncRwg4zCMJc7qBCo3AkS9h8G4DTCeYnv1rOlZHxxNU9 j4h8H3ZXQ9d1baZy3hFrrr0Hw2RJeEZavWvzLz7mYO0RfOD1/KUeqwJklJUe0RcwWfmH XiJw== 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=bwWb+OJP6s00/2x+yYPwF424Xe+3mxuWhgXwV0dqEeg=; b=gDkq3rRa3NVy3pbehBVGaazY40w2/2+Lk6mxC1HGAFWDi9SQIDSCwmo+Gsy1i2vXu3 M9E1e74hBaV0lNmJblZS6E9o9E+eIjBDvnmaaDi97hp/mC7apElVNp3HskUhepTqD9ui qmlAixjIVT4tWHY5Wej4SNEP2y5i68Yaig3rGWaDBuZImdbM8ZTX3h1oDZ9wWUYtiS3i 0gyau2btlD9F6ZlB3V7KHTHA3Y2HcEadKraF6BscPpPb34JlW0tHqpDemabzUVlIBlZ1 9O+kB5ZEVWMDBvP+uYniem51N54jbrT5dx0S27YNiqQEfP2AUfeVHV2WLKI9s4g2hBcR QINw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@walle.cc header.s=mail2016061301 header.b=XvNWSE1p; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id b8si15030463eds.433.2021.02.09.08.43.22; Tue, 09 Feb 2021 08:43:46 -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=@walle.cc header.s=mail2016061301 header.b=XvNWSE1p; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232989AbhBIQlq (ORCPT + 99 others); Tue, 9 Feb 2021 11:41:46 -0500 Received: from ssl.serverraum.org ([176.9.125.105]:39879 "EHLO ssl.serverraum.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232805AbhBIQlj (ORCPT ); Tue, 9 Feb 2021 11:41:39 -0500 Received: from mwalle01.fritz.box (unknown [IPv6:2a02:810c:c200:2e91:fa59:71ff:fe9b:b851]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-384) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by ssl.serverraum.org (Postfix) with ESMTPSA id 1131D22FB3; Tue, 9 Feb 2021 17:40:57 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=walle.cc; s=mail2016061301; t=1612888857; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=bwWb+OJP6s00/2x+yYPwF424Xe+3mxuWhgXwV0dqEeg=; b=XvNWSE1pmTHlqhMPNTpc3/btm+CjL8A1I829knxyMKcInonPbtxbMYTp9oHqsyZn3yIby2 E7/TqhS7wt09qkycQ2F5mAWfYzj/raXlqr3s6rsEss0Lpmhm8d0C4r2PThc/U/wIgNndbP ll+dchniVzC8Y3O1Rh4ZS2RostVgX/Q= From: Michael Walle To: netdev@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Andrew Lunn , Heiner Kallweit , Russell King , "David S . Miller" , Jakub Kicinski , Michael Walle Subject: [PATCH net-next 0/9] net: phy: icplus: cleanups and new features Date: Tue, 9 Feb 2021 17:40:42 +0100 Message-Id: <20210209164051.18156-1-michael@walle.cc> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Cleanup the PHY drivers for IPplus devices and add PHY counters and MDIX support for the IP101A/G. Patch 5 adds a model detection based on the behavior of the PHY. Unfortunately, the IP101A shares the PHY ID with the IP101G. But the latter provides more features. Try to detect the newer model by accessing the page selection register. If it is writeable, it is assumed, that it is a IP101G. With this detection in place, we can now access registers >= 16 in a correct way on the IP101G; that is by first selecting the correct page. This might previouly worked, because no one ever set another active page before booting linux. The last two patches add the new features. Michael Walle (9): net: phy: icplus: use PHY_ID_MATCH_MODEL() macro net: phy: icplus: use PHY_ID_MATCH_EXACT() for IP101A/G net: phy: icplus: drop address operator for functions net: phy: icplus: use the .soft_reset() of the phy-core net: phy: icplus: add IP101A/IP101G model detection net: phy: icplus: don't set APS_EN bit on IP101G net: phy: icplus: select page before writing control register net: phy: icplus: add PHY counter for IP101G net: phy: icplus: add MDI/MDIX support for IP101A/G drivers/net/phy/icplus.c | 328 ++++++++++++++++++++++++++++++++------- 1 file changed, 272 insertions(+), 56 deletions(-) -- 2.20.1