From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andrew Lunn Subject: Re: Linux kernel hangs if using RV1108 with MSZ8863 switch with two ports connected Date: Sat, 17 Nov 2018 00:40:44 +0100 Message-ID: <20181116234044.GA752@lunn.ch> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: netdev@vger.kernel.org, Heiko Stuebner , david.choi@micrel.com, Andy Yan To: Otavio Salvador Return-path: Received: from vps0.lunn.ch ([185.16.172.187]:38059 "EHLO vps0.lunn.ch" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726222AbeKQJzM (ORCPT ); Sat, 17 Nov 2018 04:55:12 -0500 Content-Disposition: inline In-Reply-To: Sender: netdev-owner@vger.kernel.org List-ID: On Fri, Nov 16, 2018 at 04:28:29PM -0200, Otavio Salvador wrote: > Hi, > > I have a custom design based on Rockchip RV1108 that uses an MSZ8863 > switch running kernel 4.19. > > The dts part is as follows: > > &gmac { > pinctrl-names = "default"; > pinctrl-0 = <&rmii_pins>; > snps,reset-gpio = <&gpio1 RK_PC1 GPIO_ACTIVE_LOW>; > snps,reset-active-low; > clock_in_out = "output"; > status = "okay"; > }; > > RV1108 GMAC is connected to KSZ8863 port 3 and after kernel boots, I > can put an Ethernet cable from my router to the uplink port of > KSZ8863, which makes the RV1108 board and a Linux PC connected to the > other KSZ8863 port to both get IP addresses. > > So in this usecase the setup is working fine. > > However, if the RV1108 board boots with both Ethernet cables to the > KSZ8863 switch connected, then the kernel silently hangs. Hi Otavio By silently, you mean it prints nothing at all? I would try building the kernel with all the lock debugging turned on. That might find something even with your working case, if there is a potential deadlock. If the kernel dies very early, you might need to enable "kernel low-level debugping print and EARLY_PRINTK, in order to see anything. Andrew