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 D8221C4345F for ; Tue, 30 Apr 2024 20:10:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=uObTqbonSmQfzY5St7NEOBnZC763AY6txPGJSEmDklk=; b=Zzr4EdEXh4jlIL gk2qs/jZwyYs7998lIk/vGlwdIDuhNHi62ie3d7mzPhmkfCmLDq64HPJcyDl2s/7OUF0my49bPIk0 jU8WdsfVPiguGSifuzu4yPryQQ2GSSACovzNZ7zNTyUCIApgo6jm+C3mWGzq0NaCk/eFm83pAgkRe 8JYlmB4kaXWFGE/IQHi0alMCHdtaWKxn0Yc7SKeLhMn08Aw8GnZUxMY8WxWf0uVW9FqSu5sBvfWin 87iDd35kfHFN7/OF83kdrcO2UO0rVKprke4igMJ+Sh2b034cTbCRsHGqy6noWYMMeX37rbFktxMfD cdNXFgQHQibYL8b4lsAg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1s1to9-00000007pSi-2qVa; Tue, 30 Apr 2024 20:10:33 +0000 Received: from sin.source.kernel.org ([2604:1380:40e1:4800::1]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1s1to2-00000007pQQ-3MEa; Tue, 30 Apr 2024 20:10:29 +0000 Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by sin.source.kernel.org (Postfix) with ESMTP id 33BEBCE0EDB; Tue, 30 Apr 2024 20:10:22 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id A0C0CC2BBFC; Tue, 30 Apr 2024 20:10:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1714507821; bh=58CBaYeu4exH4ljqyrgLewfHjjrJsr+lwEV4eBnRRBY=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=WImPU34vi9oog0mmRTYwMKyo1ISHKsDV6YPWI+6u3+xUXQD8qpYdkh3C/41+D6CJw k6UKJmZXrLyk5BK2449OfE1cJpyzZgF9BxLmxWHNjFuDNGZudLuAXQSJKMr8FdYCQV cIEig5Y9rFDOqmC2AJQLvqY3T39W804ABIfyx3tLU0gZeu1lre7MEyjzk+57HmK9OT mYlEXGZh2NVuCp9T1OIwqLDSqmZV580TjPigcNNiN6CtS4oF6eVQHiZ3WNf0YPsEbu W4pzjqjzlUQ7Y9m+2ZqyTh7DDtM1ly32OG7YCKWgtLAsuBKB4WT4rvc+6gb628z1ZP H8aC6Gjk+siug== Date: Tue, 30 Apr 2024 21:08:44 +0100 From: Simon Horman To: Daniel Golle Cc: =?utf-8?B?QXLEsW7DpyDDnE5BTA==?= , Felix Fietkau , Rob Herring , Krzysztof Kozlowski , Conor Dooley , DENG Qingfang , Sean Wang , Andrew Lunn , Florian Fainelli , Vladimir Oltean , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Matthias Brugger , AngeloGioacchino Del Regno , Landen Chao , devicetree@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org Subject: Re: [PATCH net] net: dsa: mt7530: fix impossible MDIO address and issue warning Message-ID: <20240430200844.GE2575892@kernel.org> References: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240430_131027_250172_A9EAED0D X-CRM114-Status: GOOD ( 20.49 ) 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: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Tue, Apr 30, 2024 at 12:45:46AM +0100, Daniel Golle wrote: > The MDIO address of the MT7530 and MT7531 switch ICs can be configured > using bootstrap pins. However, there are only 4 possible options for the > switch itself: 7, 15, 23 and 31 (ie. only 3 and 4 can be configured, bit > 0~2 are always 111). Practically all boards known as of today use the > default setting which is to have the switch respond to address 31, while > the built-in switch PHYs respond to address 0~4 in this case. > > However, even in MediaTek's SDK the address of the switch is wrongly > stated in the device trees as 0 (while in reality it is 31), so warn the > user about such broken device tree and make a good guess what was > actually intended. > > This is imporant to not break compatibility with older Device Trees as > with commit 868ff5f4944a ("net: dsa: mt7530-mdio: read PHY address of > switch from device tree") the address in device tree will be taken into > account. Doing so instead of assuming the switch is always at > address 31 which was previously hard-coded will obviously break things > for many existing downstream device trees as they contain the wrong > address (0) which previously didn't matter. > > Fixes: b8f126a8d543 ("net-next: dsa: add dsa support for Mediatek MT7530 switch") > Signed-off-by: Daniel Golle The cited commit is present in net-next but not net. So I think this patch should target net-next. ... _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel