From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751988AbdJZIlz (ORCPT ); Thu, 26 Oct 2017 04:41:55 -0400 Received: from shards.monkeyblade.net ([184.105.139.130]:59496 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750884AbdJZIlx (ORCPT ); Thu, 26 Oct 2017 04:41:53 -0400 Date: Thu, 26 Oct 2017 17:41:47 +0900 (KST) Message-Id: <20171026.174147.1810311288840630490.davem@davemloft.net> To: privat@egil-hjelmeland.no Cc: andrew@lunn.ch, vivien.didelot@savoirfairelinux.com, f.fainelli@gmail.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH net-next] net: dsa: lan9303: Do not disable switch fabric port 0 at .probe From: David Miller In-Reply-To: <20171024151410.28494-1-privat@egil-hjelmeland.no> References: <20171024151410.28494-1-privat@egil-hjelmeland.no> X-Mailer: Mew version 6.7 on Emacs 25.3 / Mule 6.0 (HANACHIRUSATO) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.5.12 (shards.monkeyblade.net [149.20.54.216]); Thu, 26 Oct 2017 01:41:53 -0700 (PDT) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Egil Hjelmeland Date: Tue, 24 Oct 2017 17:14:10 +0200 > Make the LAN9303 work when lan9303_probe() is called twice. > > For some unknown reason the LAN9303 switch fail to forward data when switch > fabric port 0 TX is disabled during probe. (Write of LAN9303_MAC_TX_CFG_0 > in lan9303_disable_processing_port().) > > In that situation the switch fabric seem to receive frames, because the ALR > is learning addresses. But no frames are transmitted on any of the ports. > > In our system lan9303_probe() is called twice, first time > dsa_register_switch() return -EPROBE_DEFER. As an experiment, modified the > code to skip writing LAN9303_MAC_TX_CFG_0, port 0 during the first probe. > Then the switch works as expected. > > Resolve the problem by not calling lan9303_disable_processing_port() on > port 0 during probe. Ports 1 and 2 are still disabled. > > Although unsatisfying that the exact failure mechanism is not known, > the patch should not cause any harm. > > Signed-off-by: Egil Hjelmeland Applied.