Received: by 2002:ab2:69cc:0:b0:1fd:c486:4f03 with SMTP id n12csp323904lqp; Tue, 11 Jun 2024 05:57:57 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUb/2ClVyqx5p/nGjuwyTg01gUua4GjghR1xfBEOKVpZlSWHnj/QD2Iy35r+FoCEPhmbg3LXVkO5tLTM+QNUtzNmtjCG2MFI74LfAFKag== X-Google-Smtp-Source: AGHT+IE3XTxWftmRy5UjLoOb4HKjEN0ftg+jibvHf+aFDF/aAtip0VN37Vx6DQP+bb1fnldvgv0P X-Received: by 2002:a05:6512:3984:b0:52c:8b03:99d1 with SMTP id 2adb3069b0e04-52c8b039aeemr4559632e87.48.1718110677178; Tue, 11 Jun 2024 05:57:57 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1718110677; cv=pass; d=google.com; s=arc-20160816; b=rOo+l+F9YQDblPm7gMvSfwlsAb2ZjBj1bmYS7tD926n7YhnG8TcpqWTBgaR1ywO5tM 8FXPR403cjwkyaJv3KC+PWNVgoptvSnCvE+FGqJcc+Ax+DKbrDijN/JXoIqIx56BD+wq JL8h4zNOCNFYwRJ/TRjV4C9+L4K9ujPUG5mrG46Ncv2cq+6urwz2hzKAPff/NG2Mr6KZ MLr1ByYBiPM4oTlnw7trc3qCFZN/DwAGwKkeorI3Fg/7HWJ6nHEqHRdDgl/U5Klnu3jO txeoVl11n8DlXAoeH3ZiJLSU2WhqknhVU+DssAurNFfe6QAQynhr7atYySvGbNv/z3Wo PTiQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=43M/sVt50RU4a9KtHKnWJdS5bCQ8XkR5rl3Sgok+z+Y=; fh=pRc5M8dRuC5Zmn26duS1zVO8fJ6wmApoN6KE5aDxmg0=; b=bznhPgS8YzcTc/B4SmeABKgaslQmGNZpWBjlnfL6zfR8YsM6Ew0fH09bXpb3nPaiE/ qccl59IX0KK1qGD+HzzRI/LmtzcRb8e3XsWE8t6GmzBeXff9ZaR9siKLZQvpsZQ12htu NyF+BwGmiUp+M0558S7qKa+0WQGchCQTGW9rGYlcPfiKkab7Tl1CuhXpruloVfIr5LOA Cuu1rUL5w5ZGc5mSp3jM0Cc62RfSx6nfdLpwtRMbjna25c8O26aiHgugwe2RsfWtBPfb cSBfoyE33ZpZSJY3CbDPID9IdbjSxhD49puDxrPyxzyDJhrDDH9iI3bIEboNAgb9tjqd BAWg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@lunn.ch header.s=20171124 header.b=RNrk4ENy; 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-209888-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-209888-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=lunn.ch Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id a640c23a62f3a-a6f194827bdsi238902266b.28.2024.06.11.05.57.56 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 11 Jun 2024 05:57:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-209888-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@lunn.ch header.s=20171124 header.b=RNrk4ENy; 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-209888-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-209888-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 am.mirrors.kernel.org (Postfix) with ESMTPS id 9108C1F22AF2 for ; Tue, 11 Jun 2024 12:57:56 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 375F717C7C0; Tue, 11 Jun 2024 12:57:45 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=lunn.ch header.i=@lunn.ch header.b="RNrk4ENy" 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 5034B17C7A6; Tue, 11 Jun 2024 12:57:42 +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=1718110664; cv=none; b=gxnD28mAWB6XZSURuRkHAWN2ZCWwTtHxYw0OtsYGYxutNhJwwylqeLQUIMmZxHrz2c/jVxM5gDc0h3ivqMn/OFDuqzcmCYv9BRaFkO8Iw07DRYOmV4CyeGfO36vLwiqWqP9x4/PplfiZ0sWzqhm0M72CVylUzJMCWL182fk4lGc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718110664; c=relaxed/simple; bh=2CHV3JqDCTzemfzBFGBrj/c0ALmTXYa8bakw+BsFzDM=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=AJd5YOVrqQP0YteYYLvU4lXASXs6QKUu9X8LT6qYSIFlAnmkymNsts9A2HQc57XgBwJ08RIC0M1iF/TIFrGXNQn6Caa8Nkzq3Kk9nXqEUB2/7B3CG1SuSy46Txjt38L26f/kHlRkBQgcwSQM8TYGzKQighWCq+nSU2Ke7mS+QIQ= 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=RNrk4ENy; 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-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=43M/sVt50RU4a9KtHKnWJdS5bCQ8XkR5rl3Sgok+z+Y=; b=RNrk4ENyXK9TwbH6pjcRUATroF oIKSsEXmnKu0n1NjLvnG0dgEgtThhhGXxKut1BQNZNWfsMuLhUYm51woR2aF/iAeOaliuZtvlI0X+ ZDFx+88r3tzTtrMC70b6yTmkrHusdpj25JnW8sBShX1JwvrAghXoODdm2g2iVNjAsEJA=; Received: from andrew by vps0.lunn.ch with local (Exim 4.94.2) (envelope-from ) id 1sH13t-00HO4O-T0; Tue, 11 Jun 2024 14:57:17 +0200 Date: Tue, 11 Jun 2024 14:57:17 +0200 From: Andrew Lunn To: Vineeth Karumanchi Cc: nicolas.ferre@microchip.com, claudiu.beznea@tuxon.dev, davem@davemloft.net, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org, linux@armlinux.org.uk, vadim.fedorenko@linux.dev, netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, git@amd.com Subject: Re: [PATCH net-next v4 3/4] net: macb: Add ARP support to WOL Message-ID: References: <20240610053936.622237-1-vineeth.karumanchi@amd.com> <20240610053936.622237-4-vineeth.karumanchi@amd.com> <6c01bed7-580e-4f1a-9986-39c20f063e67@amd.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=us-ascii Content-Disposition: inline In-Reply-To: <6c01bed7-580e-4f1a-9986-39c20f063e67@amd.com> > > > + /* Don't manage WoL on MAC if there's a failure in talking to the PHY */ > > > + if (!!ret && ret != -EOPNOTSUPP) > > > return ret; > > > > The comment is wrong. You could be happily talking to the PHY, it just > > does not support what you asked it to do. > > > > > These are the 3 possible return scenarios > > 1. -EOPNOTSUPP. : When there is no PHY or no set_wol() in PHY driver. > 2. 0 : Success > 3. any error (-EINVAL, ... ) from set_wol() > > we are returning in case 3. > > The comment can be "Don't manage WoL on MAC, if PHY set_wol() fails" O.K. You don't need the !! on ret. Andrew