Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp1496208imm; Mon, 3 Sep 2018 01:53:04 -0700 (PDT) X-Google-Smtp-Source: ANB0VdbBWT4b2Vz4VfHt2+RhDTQWnHkhr+Rir3ohDv8jwCE1SHoZrEtJnCxCllXR3/2WUHcggebQ X-Received: by 2002:a63:b207:: with SMTP id x7-v6mr61631pge.401.1535964784507; Mon, 03 Sep 2018 01:53:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1535964784; cv=none; d=google.com; s=arc-20160816; b=LiueIGsUNmXE6m5tbRsKfY64OsZRRipIJahdq8ieRwQbe9JaTT//VVoAQg3HOs464i HSYh/qdlfED2hi2WS/R3YsPk2JrI0n8L5NE/0AYb3etbSrfpcy+GK1UNew+FmFuwLSSH e21EF9TUyxKqYo7lrMOZolW4r2hN3tERlalQiZOTXLy8skdnfOdc+EQzps+2gMyg28Cj ttCHyrpESeb71GZmlERuFWSet4QfsU8FUtBLsXG31cQOdeHah4j2JE3gP0Ode8J3K/1A nk5YhpieGE5XGj8ZJugy/Bt/O3nm7olcLitxl6fN6dTYAUnojOzdNSWSiIhhlRBc+/0y ZuJw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:arc-authentication-results; bh=XfyP999xUqVW93CMO/4MtA0plPkHpa8fB29wpVlX1Do=; b=BKkHGow2Jt7ce6cLqSu0ypZWFryuV5lN4kTD7FNdV+yNW1ngINp9gLIUrDzWTgPVj+ 0gK5le97bSbRLTgX7ANVvQ8MhVy9ob6Z0DlrkVCVvZ2UvP9MF1DRmT8f8fDceasu659b YhMWLJQMgy8ydNsCnEi7ebGNVAnywnzktFpZqVvfEjEREArRexNBi45wumGe4xpUZ2Xa ALuD6rFivJY748pDB1S16fxhJPlO2y9awDeXq7EKUPphxrD8mNzLImNl5AQniHPcVn1S Lo/o0mxvbnLhFeiCIDy2pNiGt4WG8GNAEf92rPpHRlm9vVdjPPsVGpZTI5zpjyCVR1qJ bWHg== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a31-v6si17178737pgm.114.2018.09.03.01.52.49; Mon, 03 Sep 2018 01:53:04 -0700 (PDT) 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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727495AbeICNJI (ORCPT + 99 others); Mon, 3 Sep 2018 09:09:08 -0400 Received: from mail.bootlin.com ([62.4.15.54]:53345 "EHLO mail.bootlin.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726212AbeICNIa (ORCPT ); Mon, 3 Sep 2018 09:08:30 -0400 Received: by mail.bootlin.com (Postfix, from userid 110) id 9E07D20DEA; Mon, 3 Sep 2018 10:49:21 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mail.bootlin.com X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED,SHORTCIRCUIT, URIBL_BLOCKED shortcircuit=ham autolearn=disabled version=3.4.0 Received: from localhost.localdomain (AAubervilliers-681-1-92-107.w90-88.abo.wanadoo.fr [90.88.33.107]) by mail.bootlin.com (Postfix) with ESMTPSA id 575ED215E6; Mon, 3 Sep 2018 10:49:11 +0200 (CEST) From: Quentin Schulz To: davem@davemloft.net, robh+dt@kernel.org, mark.rutland@arm.com, andrew@lunn.ch, f.fainelli@gmail.com Cc: allan.nielsen@microchip.com, netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, thomas.petazzoni@bootlin.com, Quentin Schulz Subject: [PATCH net-next v2 3/7] net: phy: mscc: read 'vsc8531,vddmac' as an u32 Date: Mon, 3 Sep 2018 10:48:49 +0200 Message-Id: <20180903084853.18092-3-quentin.schulz@bootlin.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20180903084853.18092-1-quentin.schulz@bootlin.com> References: <20180903084853.18092-1-quentin.schulz@bootlin.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org In the DT binding, it is specified nowhere that 'vsc8531,vddmac' is an u16, even though it's read as an u16 in the driver. Let's update the driver to take into consideration that the 'vsc8531,vddmac' property is of the default type u32. Signed-off-by: Quentin Schulz --- added in v2 drivers/net/phy/mscc.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/net/phy/mscc.c b/drivers/net/phy/mscc.c index aa37e8547cd0..49dc23117732 100644 --- a/drivers/net/phy/mscc.c +++ b/drivers/net/phy/mscc.c @@ -128,7 +128,7 @@ struct vsc8531_private { #ifdef CONFIG_OF_MDIO struct vsc8531_edge_rate_table { - u16 vddmac; + u32 vddmac; u8 slowdown[8]; }; @@ -387,7 +387,7 @@ static void vsc85xx_wol_get(struct phy_device *phydev, static int vsc85xx_edge_rate_magic_get(struct phy_device *phydev) { u8 sd; - u16 vdd; + u32 vdd; int rc, i, j; struct device *dev = &phydev->mdio.dev; struct device_node *of_node = dev->of_node; @@ -396,7 +396,7 @@ static int vsc85xx_edge_rate_magic_get(struct phy_device *phydev) if (!of_node) return -ENODEV; - rc = of_property_read_u16(of_node, "vsc8531,vddmac", &vdd); + rc = of_property_read_u32(of_node, "vsc8531,vddmac", &vdd); if (rc != 0) vdd = MSCC_VDDMAC_3300; -- 2.17.1