From patchwork Tue Oct 10 17:42:56 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dan Murphy X-Patchwork-Id: 115422 Delivered-To: patch@linaro.org Received: by 10.140.22.163 with SMTP id 32csp4020556qgn; Tue, 10 Oct 2017 10:44:11 -0700 (PDT) X-Google-Smtp-Source: AOwi7QB7tATCymJgLI+XHLxWYnE7eDPbnR6TJVfDllFZ0RPf8fqYaBkwMRKwvEPXow334+5BJown X-Received: by 10.98.89.208 with SMTP id k77mr14511285pfj.164.1507657451846; Tue, 10 Oct 2017 10:44:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1507657451; cv=none; d=google.com; s=arc-20160816; b=0smM/UvuOcJhDEnlTH+1CqsqgZLuWDm3BmipluB3xlwRhxnHT/2GvteY1ZUPCjuU66 cwjuyzqvqgAX/pfYu06LiffqS2tudHCPyIFLqB2udAMT1esyXjU1rEIz+9SGL11Jd/qf edAB4Rjs3wiWRAHDDIhUWUSj3myJUMFuILuhQiXqD4POlo19vKB4jL/HVSu7BhBhsQTi Cck/NkCFSQUgpLUwa5+jtEF71FXqXzmXKuthfMZd58NqjZ3MQ0LJwOZz0LqeopWwcA1T 9RdWuO5Z4RN0n+xIlL6AFBQypOlx4zBekeTcUh+oLavGrZVlo0+A85sIRmURCxVEGByc XiNw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature :arc-authentication-results; bh=jZiCCSaSPDgUazQXcNQctWbF6J16V5XK8++k/kC/mmI=; b=NMdkNw66q32i4+wnO4+1GmWI0jHyc+SCkugWAt49twiEliNne8xm7QQJGHcdYA9YPs eOLyzdhgXYndulb1D+aVq+95nJLFYK6kUfT0KYNBa04bRjAloKhF+fiA2xVqh92T0Or2 BpibLLyv9GIMdHFiAvwiDBuQW6GwEy+6ucxUPvXdfqGY07HwgkkSVSjmnJsW4DFVupAP sXmzO12dFnGNjsOLBIAcg+mB8ni8sHUfpPGZ1EhXvimnUARkiox/hoQo3c04a6ml4ddZ ZchbIM1wY4Ls+hHYaye9WcJrezQqdlORbLsZom+iESPklR8uS/AaHQSXb9ypxs3xh4ff FHyA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=opPvYhdx; spf=pass (google.com: best guess record for domain of netdev-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=netdev-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 15si9649287pla.622.2017.10.10.10.44.11; Tue, 10 Oct 2017 10:44:11 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of netdev-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=opPvYhdx; spf=pass (google.com: best guess record for domain of netdev-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=netdev-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932317AbdJJRoF (ORCPT + 8 others); Tue, 10 Oct 2017 13:44:05 -0400 Received: from fllnx209.ext.ti.com ([198.47.19.16]:46116 "EHLO fllnx209.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932262AbdJJRoC (ORCPT ); Tue, 10 Oct 2017 13:44:02 -0400 Received: from dflxv15.itg.ti.com ([128.247.5.124]) by fllnx209.ext.ti.com (8.15.1/8.15.1) with ESMTP id v9AHh5dj004737; Tue, 10 Oct 2017 12:43:05 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ti.com; s=ti-com-17Q1; t=1507657385; bh=Qt+tY7Ga9/4Ew7Y1t98vNAjQLaL4FNda77hPDGn1cOc=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=opPvYhdx7pa2zDW0trihLcU3rutj9slhsIYZ2+heohEfnkrWt69Cit3V02bJmYdKD JOinT/KnCa7sxKxwAaxS7nd6dLeh/hD54Kg+w7V74lHEiT8MLurk4ET3aeXl+IaDbQ jAPPm1b2ZcJKOr8W6xEHk15Te0+isUUZEyNm24ac= Received: from DFLE111.ent.ti.com (dfle111.ent.ti.com [10.64.6.32]) by dflxv15.itg.ti.com (8.14.3/8.13.8) with ESMTP id v9AHh0Gj023150; Tue, 10 Oct 2017 12:43:00 -0500 Received: from DFLE114.ent.ti.com (10.64.6.35) by DFLE111.ent.ti.com (10.64.6.32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.1.845.34; Tue, 10 Oct 2017 12:43:00 -0500 Received: from dlep33.itg.ti.com (157.170.170.75) by DFLE114.ent.ti.com (10.64.6.35) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.1.845.34 via Frontend Transport; Tue, 10 Oct 2017 12:43:00 -0500 Received: from legion.dal.design.ti.com (legion.dal.design.ti.com [128.247.22.53]) by dlep33.itg.ti.com (8.14.3/8.13.8) with ESMTP id v9AHh0rf015265; Tue, 10 Oct 2017 12:43:00 -0500 Received: from localhost ([172.22.136.90]) by legion.dal.design.ti.com (8.11.7p1+Sun/8.11.7) with ESMTP id v9AHgx318802; Tue, 10 Oct 2017 12:42:59 -0500 (CDT) From: Dan Murphy To: , CC: , , , Dan Murphy Subject: [PATCH v5 2/2] net: phy: at803x: Change error to EINVAL for invalid MAC Date: Tue, 10 Oct 2017 12:42:56 -0500 Message-ID: <20171010174256.21930-2-dmurphy@ti.com> X-Mailer: git-send-email 2.12.2 In-Reply-To: <20171010174256.21930-1-dmurphy@ti.com> References: <20171010174256.21930-1-dmurphy@ti.com> MIME-Version: 1.0 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org Change the return error code to EINVAL if the MAC address is not valid in the set_wol function. Signed-off-by: Dan Murphy --- v5 - No changes made v4 - Updated $subject to include the part number - https://www.mail-archive.com/netdev@vger.kernel.org/msg192424.html v3 - No changes made v2 - There was no v1 on this patch this is new. drivers/net/phy/at803x.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.14.0 diff --git a/drivers/net/phy/at803x.c b/drivers/net/phy/at803x.c index c1e52b9dc58d..5f93e6add563 100644 --- a/drivers/net/phy/at803x.c +++ b/drivers/net/phy/at803x.c @@ -167,7 +167,7 @@ static int at803x_set_wol(struct phy_device *phydev, mac = (const u8 *) ndev->dev_addr; if (!is_valid_ether_addr(mac)) - return -EFAULT; + return -EINVAL; for (i = 0; i < 3; i++) { phy_write(phydev, AT803X_MMD_ACCESS_CONTROL,