Received: by 10.223.176.46 with SMTP id f43csp276785wra; Tue, 23 Jan 2018 20:52:52 -0800 (PST) X-Google-Smtp-Source: AH8x227sPGuM4Br9MwSU68J+pc5vIZgrIHDroe7Pe0xEYQrlIp+3gSAhMGScTcfgWbB/3IbtNROy X-Received: by 10.101.71.199 with SMTP id f7mr9861283pgs.91.1516769571971; Tue, 23 Jan 2018 20:52:51 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1516769571; cv=none; d=google.com; s=arc-20160816; b=h81eWuIhyQVJVFuAjWS92iXq9SMA9Se4DNDu5L6Zg+g34IfjgMQ4s1vXbWBUt7NrLQ TPUnPnWg+Xc3bvQPyyN2nc3qck/nBzUzKkiCHdILjBpLBGYPSGSG3O3aLBIcwecuYSfN FCTvuXQOdyyGP0i1Pet9OMuGCT4dN/QNlX6hXNZI0r50ulgA/03qEP1mH10qhOJk0mVc JN62POn6eQzL6MLjSUPxyFFGq66BmpCVMATMA2JP/SuP24OguOfYRt9ChT/V6yyLzFiT /SBtEKvZIndlrusnBYl9iZgjQAy3Wlr/Dupt5y4bRcq5sYMeV7K7It16eZiVYwUS4PAx SL+A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :spamdiagnosticmetadata:spamdiagnosticoutput:content-language :accept-language:in-reply-to:references:message-id:date:thread-index :thread-topic:subject:cc:to:from:dkim-signature :arc-authentication-results; bh=NIB88Hug+t/l5Ydxhznyfr2GKyMn4z+jqkk5yDxffBU=; b=o1doPjJ88IcyiCzMBBLPDr9Gi3IllCIdpUethEssFbBZ1pGgnZWZc2vnqaZbgnu0oc 90tkY8n3QTEW0XGHs6NeoqUJv5Irh8ZQJ1XrodO9UOIor4nAwgp65Uubq+UJWMugkAoO MFScbUGPg2n5WoQ8iIRG8nbOfROfME5MTbYiYS/hzQZj4JuBgyTqpVKsATUazfuZnjXw Uc+qMv9LqmgELQ2kVasj2Lr/0/fCZhbW4KG40ynSoO/hV4f1xDeq8xzZAPYNHFvVBg07 snx63BR5olhwFmC/JNhj7/QYdR2RFIrILVQYvC1H88bLCw68IVAbqMj673qrBuWK2anB DR3A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@microsoft.com header.s=selector1 header.b=FdjnBcRZ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=microsoft.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n10si14612619pgs.314.2018.01.23.20.52.38; Tue, 23 Jan 2018 20:52:51 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-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=@microsoft.com header.s=selector1 header.b=FdjnBcRZ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=microsoft.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932547AbeAXEwQ (ORCPT + 99 others); Tue, 23 Jan 2018 23:52:16 -0500 Received: from mail-sn1nam01on0120.outbound.protection.outlook.com ([104.47.32.120]:45079 "EHLO NAM01-SN1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S932462AbeAXEQC (ORCPT ); Tue, 23 Jan 2018 23:16:02 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=NIB88Hug+t/l5Ydxhznyfr2GKyMn4z+jqkk5yDxffBU=; b=FdjnBcRZYXomjXZEeuGhIrljqW/U267WSAy36pgz2m+VsIDK2WhttzfS++hAg0anwdZTrPsAHXCRokEztE2E9RGDwPDGRPMq9f1Eew6M08K74NJK27i71ZTGUaYd0YI0Ba9uWMW+cngjM5Scuuze+oBfvNcPfGDuoS6lwTAw3fs= Received: from DM5PR2101MB1032.namprd21.prod.outlook.com (52.132.128.13) by DM5PR2101MB1015.namprd21.prod.outlook.com (52.132.133.37) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.464.0; Wed, 24 Jan 2018 04:15:55 +0000 Received: from DM5PR2101MB1032.namprd21.prod.outlook.com ([fe80::6485:b98:d15e:9da7]) by DM5PR2101MB1032.namprd21.prod.outlook.com ([fe80::6485:b98:d15e:9da7%2]) with mapi id 15.20.0464.000; Wed, 24 Jan 2018 04:15:55 +0000 From: Sasha Levin To: "linux-kernel@vger.kernel.org" , "stable@vger.kernel.org" CC: Antoine Tenart , "David S . Miller" , Sasha Levin Subject: [PATCH AUTOSEL for 4.14 067/100] net: phy: marvell10g: fix the PHY id mask Thread-Topic: [PATCH AUTOSEL for 4.14 067/100] net: phy: marvell10g: fix the PHY id mask Thread-Index: AQHTlMnlK/w6HwfZ9US2JGKCtBb4ag== Date: Wed, 24 Jan 2018 04:14:59 +0000 Message-ID: <20180124041414.32065-67-alexander.levin@microsoft.com> References: <20180124041414.32065-1-alexander.levin@microsoft.com> In-Reply-To: <20180124041414.32065-1-alexander.levin@microsoft.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [52.168.54.252] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;DM5PR2101MB1015;7:krvr1eI/rPy81Jm1Gdi58cKRktjqt6s3I82C5/YHUxQSdPLlY2CcXsKlDUoiYcILsFNKJt/f+Le/yZEL398/dQ2woXNDMBG9mCxKAGjhEuFNaw5aq4ataBp9p2uQZH6cx9U5M8aa2MQa79aKpnF30HID6vXHdMmOA4M9C6zQ/KGG9PYXSZqy9rDe+aX9KuL+kKiYx06PA8wmTUXnQ7eB7tzr+cryzNLl8iz2ou9N51p+kI21C3ss8k8SVNjCBmU/ x-ms-office365-filtering-correlation-id: 9327d9a2-c40b-4419-e454-08d562e12a0c x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:(7020095)(4652020)(5600026)(4604075)(3008032)(4534165)(4627221)(201703031133081)(201702281549075)(48565401081)(2017052603307)(7193020);SRVR:DM5PR2101MB1015; x-ms-traffictypediagnostic: DM5PR2101MB1015: x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:(28532068793085)(89211679590171)(58145275503218); x-exchange-antispam-report-cfa-test: BCL:0;PCL:0;RULEID:(61425038)(6040501)(2401047)(5005006)(8121501046)(3002001)(10201501046)(3231046)(2400081)(944501161)(93006095)(93001095)(6055026)(61426038)(61427038)(6041288)(20161123558120)(20161123562045)(20161123564045)(20161123560045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(6072148)(201708071742011);SRVR:DM5PR2101MB1015;BCL:0;PCL:0;RULEID:;SRVR:DM5PR2101MB1015; x-forefront-prvs: 056297E276 x-forefront-antispam-report: SFV:NSPM;SFS:(10019020)(396003)(39380400002)(376002)(366004)(39860400002)(346002)(199004)(189003)(478600001)(106356001)(6512007)(53936002)(2900100001)(36756003)(102836004)(2950100002)(2501003)(10290500003)(97736004)(14454004)(81166006)(72206003)(8936002)(6486002)(1076002)(10090500001)(6346003)(26005)(54906003)(4326008)(76176011)(99286004)(86362001)(3660700001)(105586002)(6116002)(8676002)(68736007)(22452003)(66066001)(25786009)(6506007)(5660300001)(305945005)(59450400001)(7736002)(3280700002)(5250100002)(2906002)(107886003)(86612001)(6436002)(316002)(81156014)(3846002)(110136005)(22906009)(217873001);DIR:OUT;SFP:1102;SCL:1;SRVR:DM5PR2101MB1015;H:DM5PR2101MB1032.namprd21.prod.outlook.com;FPR:;SPF:None;PTR:InfoNoRecords;A:1;MX:1;LANG:en; received-spf: None (protection.outlook.com: microsoft.com does not designate permitted sender hosts) authentication-results: spf=none (sender IP is ) smtp.mailfrom=Alexander.Levin@microsoft.com; x-microsoft-antispam-message-info: jVqcf1Mz45ag1rb8qmxV6RmytUdt29zjMS1EKygB8wZc/Eo0Zcl1xlpfO7VR0Gnpwc+CIgB4zV6d1bi6g+6HWw== spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: microsoft.com X-MS-Exchange-CrossTenant-Network-Message-Id: 9327d9a2-c40b-4419-e454-08d562e12a0c X-MS-Exchange-CrossTenant-originalarrivaltime: 24 Jan 2018 04:14:59.1444 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 72f988bf-86f1-41af-91ab-2d7cd011db47 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR2101MB1015 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Antoine Tenart [ Upstream commit 952b6b3b07877419386e719ff20917170e1ce684 ] The Marvell 10G PHY driver supports different hardware revisions, which have their bits 3..0 differing. To get the correct revision number these bits should be ignored. This patch fixes this by using the already defined MARVELL_PHY_ID_MASK (0xfffffff0) instead of the custom 0xffffffff mask. Fixes: 20b2af32ff3f ("net: phy: add Marvell Alaska X 88X3310 10Gigabit PHY = support") Suggested-by: Yan Markman Signed-off-by: Antoine Tenart Reviewed-by: Andrew Lunn Signed-off-by: David S. Miller Signed-off-by: Sasha Levin --- drivers/net/phy/marvell10g.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/net/phy/marvell10g.c b/drivers/net/phy/marvell10g.c index aebc08beceba..21b3f36e023a 100644 --- a/drivers/net/phy/marvell10g.c +++ b/drivers/net/phy/marvell10g.c @@ -16,6 +16,7 @@ * link takes priority and the other port is completely locked out. */ #include +#include =20 enum { MV_PCS_BASE_T =3D 0x0000, @@ -338,7 +339,7 @@ static int mv3310_read_status(struct phy_device *phydev= ) static struct phy_driver mv3310_drivers[] =3D { { .phy_id =3D 0x002b09aa, - .phy_id_mask =3D 0xffffffff, + .phy_id_mask =3D MARVELL_PHY_ID_MASK, .name =3D "mv88x3310", .features =3D SUPPORTED_10baseT_Full | SUPPORTED_100baseT_Full | @@ -360,7 +361,7 @@ static struct phy_driver mv3310_drivers[] =3D { module_phy_driver(mv3310_drivers); =20 static struct mdio_device_id __maybe_unused mv3310_tbl[] =3D { - { 0x002b09aa, 0xffffffff }, + { 0x002b09aa, MARVELL_PHY_ID_MASK }, { }, }; MODULE_DEVICE_TABLE(mdio, mv3310_tbl); --=20 2.11.0