From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 06BFACEDD88 for ; Wed, 9 Oct 2024 12:03:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:MIME-Version:In-Reply-To: Content-Type:Message-ID:Subject:Cc:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:References: List-Owner; bh=koygImqvx/+weJAj/khOz7IiA7QhBlFJd2bxTtx9veY=; b=ZJwYYcvEjMTBUK 3MEjA/In9umkkmGQmV7kRUj/yxH9TnPi7gnjtJuoYtgFoW7VgEaI8ISbDdKlmd6J5atJJEnZoRQ6y rhpBXL4287zodAaVxhh7TJbADTWHTS8yRe8dJzbOwU+GA3FNgcSyDQaWQh+QjdQqNz3HjRAj+5u7Z c5de17XS+EvEcL2oHosBr5dXIFfh5e3g+MCwIih2EeZJI75yDpaJOPD8sAQBmd7Jys4TvaErKUMCf oj8Le0kKLLlgICaRJFKTZlteDVIfKIlddpwqrv6XdeJEGjN9VixYfHCs1ypGtQGwAztNu1utFh8K7 ruSUG7C5WMnK59uVphgw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1syVPG-000000099gv-2R5R; Wed, 09 Oct 2024 12:03:06 +0000 Received: from mail-westeuropeazlp170110003.outbound.protection.outlook.com ([2a01:111:f403:c201::3] helo=AS8PR04CU009.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1syV9u-000000096V1-0von for linux-arm-kernel@lists.infradead.org; Wed, 09 Oct 2024 11:47:15 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=vfZpKTRw8mPwoqsOMVEBszgcT9wcAd4HCAhMCZN/mH9hQM3Fr0QM0QfXEoGxjFStrdAM5cXxGj0Ga1733D0hJqakBaFKZKyTqae+x0AbaSq+1K7uO/Bm1tRaiYeOh7HyOMQdPEnWUoC5Eu0WT/sTGiINwSpcS8paXu4Z86niKlEgGpjXUFTzQ0iImtZ+REIJ5jrMelkWe8VqknAAtu9ZsnOJVMIjZWhiOvQXauEypKKz0djfsXmHoDaMkMunqrQullsUH1WTCD0Gt/xzOMu/m7rhaLPR6ajdhNDHuSX5iGAxdWJCaE+6efmpcSDopU33dkxDBhTpN/jXj/Qcj90Oqg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=koygImqvx/+weJAj/khOz7IiA7QhBlFJd2bxTtx9veY=; b=Fh+hXOVJ0y7oGR7+7xvTbx3lYfRAsE6Q1yLAcZXFyYILFqud4g2uGTLs1jzbtGTSWIPYSwwUl4FYjP1u6CFOkeNVOnhwqOcez1bLNttS2J/RWoEJnrCxR3pd0lrbnAsRQioeTPg2sMdVopliSYwrKjdHBjIzotMFHp1zUwQ737YzqOxgnnx/JFqz2Yj9jB4LABbjsx0CO3fmV1pqM/OW8yaedBKIhOwZ0gP7W2sR6ciTSCYLrDsmdiqse0L/+nVxz/gAyWGMSSQv4NgDlpKdxxSfx3yLMmcypdhS+KcqYVba1OULWCZtudW1bOIPNcg0f6+S1leNiNBFKYY32aPONA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=koygImqvx/+weJAj/khOz7IiA7QhBlFJd2bxTtx9veY=; b=kRqE/YsHZ8Y6oyHFayyOP+5VKLffdHhog7X6JJ4LxiOylX1mjP4mj0nEse7SLF7TnJ7eW/PNBOGyMjfs0/dKcQPd3daORSBhSionCPWpzRTCNzzABF8WqhxU0K8KQ7mq4r3ape69r/Xzo1nIike1HPYfH2nMYAapRPWBZznY71IGCiaDlJw+U04EuED+7xcOgGT2+CtVwKB6Z2coKUg5Gt4SZrosAQOpqTfcC9TZazwgclZSEVOK/QxaEMJ50Zl2s/1RR3KMA2fbjgGCK/iNDm6nfHNgnMvusM+4IOAXFyRsL35ehe404K7Tv3dITe7NpLwXJPuN35Hg2gRfufrLVg== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from AM8PR04MB7779.eurprd04.prod.outlook.com (2603:10a6:20b:24b::14) by DB9PR04MB8378.eurprd04.prod.outlook.com (2603:10a6:10:25f::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8026.23; Wed, 9 Oct 2024 11:47:06 +0000 Received: from AM8PR04MB7779.eurprd04.prod.outlook.com ([fe80::7417:d17f:8d97:44d2]) by AM8PR04MB7779.eurprd04.prod.outlook.com ([fe80::7417:d17f:8d97:44d2%3]) with mapi id 15.20.8048.013; Wed, 9 Oct 2024 11:47:06 +0000 Date: Wed, 9 Oct 2024 14:47:03 +0300 From: Vladimir Oltean To: "Russell King (Oracle)" Cc: Andrew Lunn , Heiner Kallweit , Alexandre Torgue , "David S. Miller" , Eric Dumazet , Florian Fainelli , Jakub Kicinski , Jiawen Wu , Jose Abreu , Jose Abreu , linux-arm-kernel@lists.infradead.org, linux-stm32@st-md-mailman.stormreply.com, Maxime Coquelin , Mengyuan Lou , netdev@vger.kernel.org, Paolo Abeni Subject: Re: [PATCH net-next 00/13] net: pcs: xpcs: cleanups batch 2 Message-ID: <20241009114703.3pi6txfqnn2rxgbt@skbuf> Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-ClientProxiedBy: VE1PR08CA0005.eurprd08.prod.outlook.com (2603:10a6:803:104::18) To AM8PR04MB7779.eurprd04.prod.outlook.com (2603:10a6:20b:24b::14) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: AM8PR04MB7779:EE_|DB9PR04MB8378:EE_ X-MS-Office365-Filtering-Correlation-Id: bf77e3fa-ed88-4b96-aaaf-08dce8581968 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|366016|376014|1800799024|7416014; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?kbXaBuN7nuuCmGBC3oSk9Uk31R/a+xfwy8Rcb5wIzSGflodD3LddsXdGPnCh?= =?us-ascii?Q?q3Q7jrjqHYaFcKucOwMrQeowiGRWjMnKl1IFPWuVC8HWeYG96FS4azeXvAkI?= =?us-ascii?Q?C6cvcFmvwavv1nLigGuadDhfr1jgn96rZ4a7GvYX1ZUop3G7IwUm5STrLHNP?= =?us-ascii?Q?gfz9UFPKkwniY3AlTQ+Jk41cmPeexzT+F29a6l7N8wgwPcNo5afZZSklIMYM?= =?us-ascii?Q?AlC+GEoK2X1/zl/JNjuJ3EWnfMMx6F2Z3xh76vkdMQ9JGeX6R0gDqkk1Ygdb?= =?us-ascii?Q?JFhDEXx4O6njk2Gy/m1GQmuTGwbEFzPW+B8sEFCpSCOjOKB+om7Mk1pn8I6E?= =?us-ascii?Q?ZAnsCKjyUwt5f3vhyY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?= =?us-ascii?Q?=3D?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:AM8PR04MB7779.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(366016)(376014)(1800799024)(7416014);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?ZgR2ErAnKEJKjWFMEis7/kXBKYUC9u+5piHa83YmWDspOs8tdrsVbg1gkteT?= =?us-ascii?Q?WdOVFIuaFyuM1dldU+c2MrW27RNmPanrTN4bYercOuudKjmZHxC4RE6QATYR?= =?us-ascii?Q?ZBPnpg2INsQnk/wkdDOy0PbQcKn6Z2C5CTkAh3UOYTKzIlUfOa3F0YcGQgLy?= =?us-ascii?Q?hFVTxJIJK/bnZlnrwzCwgER+K35Ur6f5RTSgGk0lH4gqMcOX01MfbkTnSfZq?= =?us-ascii?Q?jEUjnTU9R94l6tBYZm4sOZKIUS9N6WYlavOdoioHVEKetWl1Qa5yuMXla7n0?= =?us-ascii?Q?eGu7VMv/Sr1m5lCcv7U+2BEWQwbYHtu1TlnGHFIT1TVoTHNtTxlr7Hr+FsgJ?= =?us-ascii?Q?UH1T6DVEcskgEdx0UwuBHRhZiJKF0tuLkA4SFBGFCEXz5mbjGJy5Gr2mus+H?= =?us-ascii?Q?4Lr7fJe8sfVDM6Bly2vvEcQNCrexVmFtu417C9mrGOkw8ggxYc4sve5EgY+g?= =?us-ascii?Q?5wu4CRQgzhvpV2k1Va8bNuwEHlWn+xL0Ro1aQTfTNzNCfAG3kCDk5NWC2Rp+?= =?us-ascii?Q?RcZcRqx26HRZUpuMvD0JivrEDbmpmHCz8LoQzyYNWFBksIvyf9/Lv4pQYOoF?= =?us-ascii?Q?FkWLRqQqfHCFDPMs7SeZ10b/bAXF0JTfBSkGILA29AQc/E33G9vMLb3GYCIo?= =?us-ascii?Q?ASK2P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59CZBlV7kMThTQ827S?= =?us-ascii?Q?5Z3R7sKSMa6Si5oxP85IpbY47XBwYHOKmRi/7KFXoAUcCf2BZM/xv4IhKReX?= =?us-ascii?Q?Tw=3D=3D?= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: bf77e3fa-ed88-4b96-aaaf-08dce8581968 X-MS-Exchange-CrossTenant-AuthSource: AM8PR04MB7779.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Oct 2024 11:47:06.4294 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: Pw8DRm6IxYiQ74KpLuBHQIRrORqqirbHus1smQ/johFWgnDKnJ2geZKec22GcTvke8EPgYYthnM0Y7rJNUHfaQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB9PR04MB8378 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20241009_044714_290930_4EA99249 X-CRM114-Status: GOOD ( 24.39 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Fri, Oct 04, 2024 at 11:19:57AM +0100, Russell King (Oracle) wrote: > This is the second cleanup series for XPCS. > > Patch 1 removes the enum indexing the dw_xpcs_compat array. The index is > never used except to place entries in the array and to size the array. > > Patch 2 removes the interface arrays - each of which only contain one > interface. > > Patch 3 makes xpcs_find_compat() take the xpcs structure rather than the > ID - the previous series removed the reason for xpcs_find_compat needing > to take the ID. > > Patch 4 provides a helper to convert xpcs structure to a regular > phylink_pcs structure, which leads to patch 5. > > Patch 5 moves the definition of struct dw_xpcs to the private xpcs > header - with patch 4 in place, nothing outside of the xpcs driver > accesses the contents of the dw_xpcs structure. > > Patch 6 renames xpcs_get_id() to xpcs_read_id() since it's reading the > ID, rather than doing anything further with it. (Prior versions of this > series renamed it to xpcs_read_phys_id() since that more accurately > described that it was reading the physical ID registers.) > > Patch 7 moves the searching of the ID list out of line as this is a > separate functional block. > > Patch 8 converts xpcs to use the bitmap macros, which eliminates the > need for _SHIFT definitions. > > Patch 9 adds and uses _modify() accessors as there are a large amount > of read-modify-write operations in this driver. This conversion found > a bug in xpcs-wx code that has been reported and already fixed. > > Patch 10 converts xpcs to use read_poll_timeout() rather than open > coding that. > > Patch 11 converts all printed messages to use the dev_*() functions so > the driver and devie name are always printed. > > Patch 12 moves DW_VR_MII_DIG_CTRL1_2G5_EN to the correct place in the > header file, rather than amongst another register's definitions. > > Patch 13 moves the Wangxun workaround to a common location rather than > duplicating it in two places. We also reformat this to fit within > 80 columns. > > drivers/net/ethernet/stmicro/stmmac/dwmac-intel.c | 2 +- > drivers/net/pcs/pcs-xpcs-nxp.c | 24 +- > drivers/net/pcs/pcs-xpcs-wx.c | 56 ++- > drivers/net/pcs/pcs-xpcs.c | 445 +++++++++------------- > drivers/net/pcs/pcs-xpcs.h | 26 +- > include/linux/pcs/pcs-xpcs.h | 19 +- > 6 files changed, 237 insertions(+), 335 deletions(-) > > -- > RMK's Patch system: https://www.armlinux.org.uk/developer/patches/ > FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last! Late, I know, but: Reviewed-by: Vladimir Oltean