From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753103AbdARUf6 (ORCPT ); Wed, 18 Jan 2017 15:35:58 -0500 Received: from mail-pg0-f68.google.com ([74.125.83.68]:35254 "EHLO mail-pg0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751869AbdARUfy (ORCPT ); Wed, 18 Jan 2017 15:35:54 -0500 Subject: Re: [PATCH net-next 2/2] net: dsa: use cpu_switch instead of ds[0] To: Vivien Didelot , netdev@vger.kernel.org References: <20170118014139.31417-1-vivien.didelot@savoirfairelinux.com> <20170118014139.31417-2-vivien.didelot@savoirfairelinux.com> Cc: linux-kernel@vger.kernel.org, kernel@savoirfairelinux.com, "David S. Miller" , Andrew Lunn From: Florian Fainelli Message-ID: <805115a6-3d4e-b968-62cb-eed9af49380f@gmail.com> Date: Wed, 18 Jan 2017 12:35:46 -0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.5.1 MIME-Version: 1.0 In-Reply-To: <20170118014139.31417-2-vivien.didelot@savoirfairelinux.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 01/17/2017 05:41 PM, Vivien Didelot wrote: > Now that the DSA Ethernet switches are true Linux devices, the CPU > switch is not necessarily the first one. If its address is higher than > the second switch on the same MDIO bus, its index will be 1, not 0. > > Avoid any confusion by using dst->cpu_switch instead of dst->ds[0]. > > Signed-off-by: Vivien Didelot Reviewed-by: Florian Fainelli -- Florian