Received: by 2002:a89:413:0:b0:1fd:dba5:e537 with SMTP id m19csp298144lqs; Thu, 13 Jun 2024 10:15:04 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWSq24VI6Z9A9Jw5EF8lIVt6WWXjXDg5e1dAnnoMr7Z6by2D8jq0Y+bq8kFsD//UzpnXJPiluWK11SoYK5r6hU2fH16n/88uqL517/Yuw== X-Google-Smtp-Source: AGHT+IHzG+7/MMPMFOBgzHxhaqKVzd/jR1bF4hzztF1kCabcLw3ktdzYTWa1dhQsKpbYPxBZTAbg X-Received: by 2002:a17:903:41c7:b0:1f7:2849:184c with SMTP id d9443c01a7336-1f8625c64d4mr3645035ad.6.1718298904250; Thu, 13 Jun 2024 10:15:04 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1718298904; cv=pass; d=google.com; s=arc-20160816; b=fmS7Guk9BKmvUr5mipW9crxRggs4C2YioHdj9D1FHvjXvCNnwhBZaVY2eJMQDj7kCo ObIoZUOh6qyAPS2kavJecqk62ha8wf3VUnUd25arn5ISz4XEv3GKgJ5wu2TB+DqKPJZD +0sQIUOULiGGrTOcCF51KZTI/uLfR/9Q+xrZUWkuPjH3ZMIcRp+gH1t7G9kkghgetDzf njRYWhnMQbCa2RSkZAMGuGIo8r7yMHxxpmME9FslbmiOaAua0FBZOVs7WYbSxXhq6I3Q sLPaLAfZ63rGFruI3ZTiw+lU+gQDyTloJ4QZbGhE3pcqL4hiTiiztinbcs3QbD+XD4oh EJXQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :references:message-id:subject:cc:to:from:date:dkim-signature; bh=w6/11ltu780lh2jX4tChv2b8UmgJrvfcgICTSnxHFmk=; fh=OUCm0Pc9RFFXfdhqbkuiOg7GDnsVTlV5lY40+RYg+ds=; b=JTdB4B2SXDBIbhv4738IHPGSmnaN+yFlkoVS1z8KD5MlNfG+Cqz1EVsGd14suwEWhM 0yUABbi2puHBOY32m8DAv2RU0W59PR0DbFZ1CnKjs3TKljT7nEqynjDCmpKUDgoGNuTR gse9Z5HGZtd4IrnYO770gi+y5RcTQsany75nhebjtHadQxBbjKcIS4q/R0D/JN8V/mdA fAzual9UbOmRxsFz2XvwugjAN9y+xt6B47s41Ul0AIaroi6wVwcjtMVi3ZOc80QIr75Y 5MHrns1kzA4LAsv16wiWQ4nBNXOh3qmwNX6hIFZxPUMIL2L3gZxvaXtwwZgAZzuAuOIa dcaw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@lunn.ch header.s=20171124 header.b="B/oUlh3v"; arc=pass (i=1 spf=pass spfdomain=lunn.ch dkim=pass dkdomain=lunn.ch dmarc=pass fromdomain=lunn.ch); spf=pass (google.com: domain of linux-kernel+bounces-213720-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-213720-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=lunn.ch Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id d9443c01a7336-1f855ee9e1bsi16130235ad.427.2024.06.13.10.15.03 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 13 Jun 2024 10:15:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-213720-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@lunn.ch header.s=20171124 header.b="B/oUlh3v"; arc=pass (i=1 spf=pass spfdomain=lunn.ch dkim=pass dkdomain=lunn.ch dmarc=pass fromdomain=lunn.ch); spf=pass (google.com: domain of linux-kernel+bounces-213720-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-213720-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=lunn.ch Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 6BCCBB24511 for ; Thu, 13 Jun 2024 17:14:04 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id BFDFF14A088; Thu, 13 Jun 2024 17:13:52 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=lunn.ch header.i=@lunn.ch header.b="B/oUlh3v" Received: from vps0.lunn.ch (vps0.lunn.ch [156.67.10.101]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8DAD24C6B; Thu, 13 Jun 2024 17:13:46 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=156.67.10.101 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718298832; cv=none; b=DNE1ih0iv0yarWzyFphV87LWPBFgRH2uZbEeoLmoXHIrADpjK9IBN9X+C2py/4qqCT6oEVT72KXtfogxAG1ZRXLJgNfD052S7mc2PvsvqPRoofTNxqtQlK3/PZLwaORjUPJphbjYifkF+Mq7ehlBR50X5Qf1K1b68JaGRI4VwhQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718298832; c=relaxed/simple; bh=RurbkwLbpyNA8X3ETrlVRcztrM3lGDK5+fNbyV5IN/k=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=ZauhBFdG0nooCSEk0aGaC/71uouPne9ypBaJtsi8qiD8CHvAc+Q8YRddcI0UWWvAyMFT4xs6x3oxE6Ns5x/fwEwhF4gPOAGvhsMtNiD52RJt8rrWBPyY4lAvIRrQVsRa9sH9bK+OSkZzmVhQdcOhqJBoWXqy+87vlm5vCU8/HMk= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=lunn.ch; spf=pass smtp.mailfrom=lunn.ch; dkim=pass (1024-bit key) header.d=lunn.ch header.i=@lunn.ch header.b=B/oUlh3v; arc=none smtp.client-ip=156.67.10.101 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=lunn.ch Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=lunn.ch DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lunn.ch; s=20171124; h=In-Reply-To:Content-Transfer-Encoding:Content-Disposition: Content-Type:MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:From: Sender:Reply-To:Subject:Date:Message-ID:To:Cc:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Content-Disposition: In-Reply-To:References; bh=w6/11ltu780lh2jX4tChv2b8UmgJrvfcgICTSnxHFmk=; b=B/ oUlh3vBZhTVNh+yyzfT7umg9yzAZ81yKD+68qgrLdv7qY81n8nM9kL5rUjbOKifZwMfuii0Ekn86q Wno3DRhw7uc+Dkrg4cK4iwSsyQcHOuA2wBSY1LqX4Lhz99JIxQGiQxUled69R5vbacNBeP+Y5i8He iWEAKv3kX9BQZUI=; Received: from andrew by vps0.lunn.ch with local (Exim 4.94.2) (envelope-from ) id 1sHo0t-00HaWk-LO; Thu, 13 Jun 2024 19:13:27 +0200 Date: Thu, 13 Jun 2024 19:13:27 +0200 From: Andrew Lunn To: =?iso-8859-1?Q?Jo=E3o?= Rodrigues Cc: Heiner Kallweit , Russell King , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , "open list:ETHERNET PHY LIBRARY" , open list Subject: Re: [PATCH net-next 1/3] net: phy: dp83867: Add SQI support Message-ID: <0f7cef0d-b5ef-4feb-981e-c587e08de0e9@lunn.ch> References: <20240613145153.2345826-1-jrodrigues@ubimet.com> <20240613145153.2345826-2-jrodrigues@ubimet.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20240613145153.2345826-2-jrodrigues@ubimet.com> On Thu, Jun 13, 2024 at 04:51:51PM +0200, Jo?o Rodrigues wrote: > Don't report SQI values for 10 ethernet, since the datasheet > says MSE values are only valid for 100/1000 ethernet The commit message could be better. Something like: Don't report the SQI value when the link speed is 10Mbps, since the datasheet says MSE values are only valid for 100/1000 links. > +static int dp83867_get_sqi(struct phy_device *phydev) > +{ > + u16 mse_val; > + int sqi; > + int ret; > + > + if (phydev->speed == SPEED_10) > + return -EOPNOTSUPP; What does the datasheet say about MSE where there is no link at all? Maybe you need to expand this test to include SPEED_UNKNOWN? Andrew --- pw-bot: cr