Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp647625pxb; Wed, 27 Jan 2021 17:59:00 -0800 (PST) X-Google-Smtp-Source: ABdhPJzFzYbqu1nYZIlAJ4xJiZ5+sKl8rAY5EMPwHoom+HqqS7EfTqusRXHUkW+kaH26HADuF5Be X-Received: by 2002:a17:906:e085:: with SMTP id gh5mr9064923ejb.418.1611799140016; Wed, 27 Jan 2021 17:59:00 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1611799140; cv=none; d=google.com; s=arc-20160816; b=iQefU6JhCY5HPMEN8DlzVIGHQFLKoicD1hTIFDuEGQEDR39MXwuM/jJQvwLXk2q9Ie exZzxNM08ZJS36wvv1je2j51BW7Rqxuz9oDUUitlHAOUo+EOPsMw9mK25xetiOArDcEh bNWAr56J+g1uDgGtheYnh1uuQn31L7ApWpjsKB+rvXkv0ICBhc58mBaf8BDcvoCoZ8aq X2u1A4jelOsffLND8Utxd/WYjnZIGoMSgSBK7I6dmLsiFkdv50OOW48969xHZlrf4Yd1 vhIIJDq8SRhz8l9IaiTZjjVi655zIsgRTNs3mo10Y8Ja5DEh3tYpiQaEyYgo+Swne+o5 xMIg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=EahTzXWPG8kjvwb8XtZ10UU8dZRD2P3HNXfRC/7gbjQ=; b=f22Qsrl7b6tm397bAT1550QarFZL0NPoFQhMIgAx+G8d4gZKDPLUFNlUx9pzAOmqKn AgSQX4JutcsdICU9OkJTc+FQbsghGFYgIGdEImOy5dOu1ZwCShydSaV+/9huQFbbfPrc Q5M1IjMYXNeQP7AjUGsZXqzd4kdufkIAQpzXbGLeSRUDVjSg14+WIKIwzC71fZHJRJJV 3sTyqmsGKNivtlcq0NgNvJZ59BBhTCuiOXIhZl4Eo404te2P7fpQsMRACOJEW6hxsnGB MEmTHcc1pfqFUGa/QI91/2HONANF+oI1YcadwnghiDTxZacJN4mhIbPKuRLletLg8qVQ jlzw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id v3si1874643edw.127.2021.01.27.17.58.36; Wed, 27 Jan 2021 17:59:00 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231230AbhA1B5U (ORCPT + 99 others); Wed, 27 Jan 2021 20:57:20 -0500 Received: from vps0.lunn.ch ([185.16.172.187]:35572 "EHLO vps0.lunn.ch" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231163AbhA1B5M (ORCPT ); Wed, 27 Jan 2021 20:57:12 -0500 Received: from andrew by vps0.lunn.ch with local (Exim 4.94) (envelope-from ) id 1l4wXp-002xfn-Lw; Thu, 28 Jan 2021 02:56:25 +0100 Date: Thu, 28 Jan 2021 02:56:25 +0100 From: Andrew Lunn To: Mike Looijmans Cc: netdev@vger.kernel.org, "David S. Miller" , Heiner Kallweit , Jakub Kicinski , Russell King , linux-kernel@vger.kernel.org Subject: Re: [PATCH] net: mdiobus: Prevent spike on MDIO bus reset signal Message-ID: References: <20210126073337.20393-1-mike.looijmans@topic.nl> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210126073337.20393-1-mike.looijmans@topic.nl> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jan 26, 2021 at 08:33:37AM +0100, Mike Looijmans wrote: > The mdio_bus reset code first de-asserted the reset by allocating with > GPIOD_OUT_LOW, then asserted and de-asserted again. In other words, if > the reset signal defaulted to asserted, there'd be a short "spike" > before the reset. > > Instead, directly assert the reset signal using GPIOD_OUT_HIGH, this > removes the spike and also removes a line of code since the signal > is already high. Hi Mike Did you look at the per PHY reset? mdiobus_register_gpiod() gets the GPIO with GPIOD_OUT_LOW. mdiobus_register_device() then immediately sets it high. So it looks like it suffers from the same problem. Andrew