Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp24740pxj; Wed, 23 Jun 2021 14:40:54 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyOvor0/aCExWpYvN/iv+K7kSo/3mGOkc7oEHVDvB2+grB09RM2m6llviTlh726koa8UlNJ X-Received: by 2002:a92:901:: with SMTP id y1mr1192312ilg.212.1624484454457; Wed, 23 Jun 2021 14:40:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1624484454; cv=none; d=google.com; s=arc-20160816; b=QP0MYaRlZBW4KCFVMz84DSftj3SzpPPrRuBQu/8GIR1RnKz8QcQ0n2+Uv5n7fp1jh1 Fdvq676X8YzGUFlztbzez7RvY+HHk+tSOcya05SL5m6SCbCzz+Mo7XN4rBjp9r1dzW2G wnDdYtU4OEFbzqsq939qEJB5FMmYLmmdv7SXpnNeQipvlQ8UUA2y/I3MX7ZQNqHrmJIR hn1GZrkV0R/8+L1GRILSc6LzY8CUEXrRjQOtbKLGZRQdafjwCZ6B04GvL4L7DOec82lj mcJzB3zfGLNjdjig1Vtpp3sMJQcibLFPlX78VXybtiBuBlBGllJQHJKr9vrZ8k49OTqN yUiw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=K1nUxzpkAIvziAcPoUqwCBcyEK/zm0S98B9naW0HRaM=; b=YyYB22Pe4Jio9pcSorxQiszdGUEe547jtH72Qp+12sgZ0BRMtHqXz7//S2xqDy/eCM qkcgozDnAjZOkSdSAfoCXQwffobwZC/lftN5NHK0mZGaPM1cY7OwdPim3I2dcMLPq7ql 1/dBrPm5vjcVeC95LkG9lPUWSKvbLq53NVHVPyhNFDzD9+qhQivN+j3JuzJAvhFom097 KP3K/CNESVen556NfYnplI9kuHIx69wm7qIYxwxjkaIBFEy6ZgNJrzLtIvkdp3CBA2wC VdFEG3bMkrRSoaDf+8lDb0/UjGT4hxMiLy7qGhpfZp5oJgt6BqC3UbTdEcNI4F4nB+PT xWwA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nic.cz header.s=default header.b=tuOZlPT2; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nic.cz Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id l8si841149ilk.17.2021.06.23.14.40.41; Wed, 23 Jun 2021 14:40:54 -0700 (PDT) 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; dkim=pass header.i=@nic.cz header.s=default header.b=tuOZlPT2; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nic.cz Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229915AbhFWVlQ (ORCPT + 99 others); Wed, 23 Jun 2021 17:41:16 -0400 Received: from mail.nic.cz ([217.31.204.67]:55790 "EHLO mail.nic.cz" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229796AbhFWVlP (ORCPT ); Wed, 23 Jun 2021 17:41:15 -0400 Received: from thinkpad (unknown [172.20.6.87]) by mail.nic.cz (Postfix) with ESMTPSA id 6E2B4140B53; Wed, 23 Jun 2021 23:38:56 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=nic.cz; s=default; t=1624484336; bh=IbpJn7feV38gl8Ic2De823HwB1rhd+wrPh4JbEInURQ=; h=Date:From:To; b=tuOZlPT2WiNA0NCMPqCozcxRpR8LcgdUbhFSQWJASs+wAHBXQENZ0DEbPDLp4Vh+j 6ZTvqsg0MrconVh8US0kifvAj/jzObwIkmSLcDVW9r/BktHSo6GD2ByEFBjZPyZpx9 zJcwG5UyWHy/KOKrWmGMe6Vv30v8hwLQdEzsYf5o= Date: Wed, 23 Jun 2021 23:38:54 +0200 From: Marek Behun To: Ling Pei Lee Cc: Russell King , Andrew Lunn , Heiner Kallweit , davem@davemloft.net, Jakub Kicinski , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, weifeng.voon@intel.com, vee.khee.wong@linux.intel.com, vee.khee.wong@intel.com Subject: Re: [PATCH net-next] net: phy: marvell10g: enable WoL for mv2110 Message-ID: <20210623233854.03ed9240@thinkpad> In-Reply-To: <20210623130929.805559-1-pei.lee.ling@intel.com> References: <20210623130929.805559-1-pei.lee.ling@intel.com> X-Mailer: Claws Mail 3.17.8 (GTK+ 2.24.33; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-100.0 required=5.9 tests=SHORTCIRCUIT, USER_IN_WELCOMELIST,USER_IN_WHITELIST shortcircuit=ham autolearn=disabled version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mail.nic.cz X-Virus-Scanned: clamav-milter 0.102.2 at mail X-Virus-Status: Clean Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 23 Jun 2021 21:09:29 +0800 Ling Pei Lee wrote: > + /* Enable the WOL interrupt */ > + ret = phy_set_bits_mmd(phydev, MDIO_MMD_VEND2, > + MV_V2_PORT_INTR_MASK, > + MV_V2_WOL_INTR_EN); > + > + if (ret < 0) > + return ret; Hi, in addition to what Russell said, please remove the extra newline between function call and return value check, i.e. instead of ret = phy_xyz(...); if (ret) return ret; ret = phy_xyz(...); if (ret) return ret; do ret = phy_xyz(...); if (ret) return ret; ret = phy_xyz(...); if (ret) return ret; This is how this driver does this everywhere else. Do you have a device that uses this WoL feature? Marek