From nobody Sat Oct 4 09:37:51 2025 Received: from pidgin.makrotopia.org (pidgin.makrotopia.org [185.142.180.65]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D4F2F15747D; Tue, 19 Aug 2025 01:35:04 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=185.142.180.65 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1755567306; cv=none; b=Dhsww8ba5xZQDfULQ6HtW6pY0n1FjKcbS4y+wv+xk70vxPeHA3yOqBUV7mdBVqkZCp0XefbEERpOakG/mPNVM47H3aLRfAesU6DOZjzmOyVD1ATj1DScVHANPLOUqlL0SYsEbMqhOcQDogkjPhL3jm0Sik18HrjLkVBWRNq3pRE= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1755567306; c=relaxed/simple; bh=MAlPwEUABUm7hiZGRY2uATv4Exkmx934oFD/ePxmpZ8=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=fxlSM47VDN3Y+eDVggKJzUquODuUNcj4lw5FgGyX1sRMgfaprhx1q8s27NRMsH2Zr9GYQyBElr0xFfjmuWNxuVo2Yej7omgYD60//Q6WmM0Uk7IlK6D0YPbGwXFvHhpdd7YVo5IijV9nHDcoXT8UML4p+YLEERZy4kAuUYsu5Ck= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=makrotopia.org; spf=pass smtp.mailfrom=makrotopia.org; arc=none smtp.client-ip=185.142.180.65 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=makrotopia.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=makrotopia.org Received: from local by pidgin.makrotopia.org with esmtpsa (TLS1.3:TLS_AES_256_GCM_SHA384:256) (Exim 4.98.2) (envelope-from ) id 1uoBFc-000000000DC-0bEU; Tue, 19 Aug 2025 01:35:00 +0000 Date: Tue, 19 Aug 2025 02:34:56 +0100 From: Daniel Golle To: Hauke Mehrtens , Andrew Lunn , Vladimir Oltean , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Philipp Zabel , Russell King , linux-kernel@vger.kernel.org, netdev@vger.kernel.org Cc: Andreas Schirm , Lukas Stockmann , Alexander Sverdlin , Peter Christen , Avinash Jayaraman , Bing tao Xu , Liang Xu , Juraj Povazanec , "Fanni (Fang-Yi) Chan" , "Benny (Ying-Tsan) Weng" , "Livia M. Rosu" , John Crispin Subject: [PATCH net-next v2 8/8] net: dsa: lantiq_gswip: add support for SWAPI version 2.3 Message-ID: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Add definition for switch API version 2.3 and a macro to make comparing the switch hardware version with the (byte-swapped) version macros more conveniant. Signed-off-by: Daniel Golle --- drivers/net/dsa/lantiq_gswip.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/net/dsa/lantiq_gswip.h b/drivers/net/dsa/lantiq_gswip.h index 5a0ac7a538d9..54cbfad21ada 100644 --- a/drivers/net/dsa/lantiq_gswip.h +++ b/drivers/net/dsa/lantiq_gswip.h @@ -7,6 +7,7 @@ #include #include #include +#include #include =20 /* GSWIP MDIO Registers */ @@ -93,6 +94,8 @@ #define GSWIP_VERSION_2_1 0x021 #define GSWIP_VERSION_2_2 0x122 #define GSWIP_VERSION_2_2_ETC 0x022 +#define GSWIP_VERSION_2_3 0x023 +#define GSWIP_VERSION_GE(priv, ver) ((priv)->version >=3D swab16(ver)) =20 #define GSWIP_BM_RAM_VAL(x) (0x043 - (x)) #define GSWIP_BM_RAM_ADDR 0x044 --=20 2.50.1