From patchwork Tue Nov 28 16:48:22 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Corentin Labbe X-Patchwork-Id: 10080781 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 665B660353 for ; Tue, 28 Nov 2017 16:51:01 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 64B4A294DA for ; Tue, 28 Nov 2017 16:51:01 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 59635294E4; Tue, 28 Nov 2017 16:51:01 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, DKIM_VALID, FREEMAIL_FROM, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id D8EC9294DB for ; Tue, 28 Nov 2017 16:51:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:Message-Id:Date: Subject:To:From:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To: References:List-Owner; bh=Rjy6Eq/mWX+gpS5HbhG8kVHwVg6+vDxPbs7KFLKSxw0=; b=Pap Xzyeu70Lf625rQNZFEOrbCCvSCxqJbrOFJ0JAcMdULyFurhH2FJyrQStEc3/PQ6rCNr/R3WDygxQ6 yeJTQGvr2g1Q+LVxkYU83g7PiIz7F3hgL9gJdE8R+FiMsiFTyldwbevLkjY6pad5tD7/adAduOEK6 HhA6ULkAs5I/vt2aDgBz4oxfCgZAqplmL4dtXJM7/4ydvNbx44v8+XU64q+j2dl7h98drYg0JDWik nD5qW6R6N5XI3JuZlokxKhULSpuA8eTSOAXsfpFYV+Nj9Ajte9Ae408w7E8WZXEbVAcL2T7yPxtqW DbYzHonB7xdnm2/qa32FGgZLv8Wb7rg==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1eJj63-0001nE-EI; Tue, 28 Nov 2017 16:50:59 +0000 Received: from mail-wr0-x244.google.com ([2a00:1450:400c:c0c::244]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1eJj60-0001hJ-6M for linux-arm-kernel@lists.infradead.org; Tue, 28 Nov 2017 16:50:57 +0000 Received: by mail-wr0-x244.google.com with SMTP id v105so702569wrc.3 for ; Tue, 28 Nov 2017 08:50:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=Ue0M7fOwjDZC/vGU00RbBsThucY3Y+oh9zQSdssHSAw=; b=nqMTWQkywrDgQrCi5HSJjrI4pQeu+naE1BJnZiuJo/FHA3fEKH0HJc4wZdpAlS3U/M gpl10SSKZ7gtdcLI2SKO2pX7JHzLBxtE/izOTxoiXhPf9/TDo6ZmX7MqPYUsc6lCi0lm okkW45scLrYwhajrlqcFfsGFPtMszqu7cmoxm7F2/Y/9JUtiqRj72BTJh/gwLc2CrIXS gaZeY7WJx+hkuwXLwdmmV9BwBD39PTe5ZaNuwmAe8rST/RnfrgubQNQqqomzpiWO3Zm9 7SzV0sB8DpW++NxjDDip2RsfQqMWQx2bPUHS3E6yHpbtMNjployFJA2rCr4sytDh5/Gx 036g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=Ue0M7fOwjDZC/vGU00RbBsThucY3Y+oh9zQSdssHSAw=; b=c3yj1da1G2nFF6X2pzEdfcvQdJ62ja5WVAq3Ret6oTkRxhYZlkCQsML8Ds/14pq4AX 09fej9KIzbKqubcNUfpHFqOyKwC4ZKlt3bJgsF2KXjOdqsgR2rfsuig2xYJRZTckpiD2 7sHifoxuhWxE/Cu0JxBOxSNFd5/H4WM2QAAQANVEkQFTREzfDEaIuG1JNx60YF7IXv2p 6dnn/zBeVgjGvbKLhE57RKtm+4smeeKZcRI3bBPxBKPB1Byr/b6mu/nMSEw9DqJA7Al0 hcquKrL4ObptKtUNr+juOcxp2lSob/Nj2CIprpqvdKb/lSAT4Hp2uT6Wr216ZE31Sbfj fr6g== X-Gm-Message-State: AJaThX5ToYKhOXJgUSgUwM5RMXC7/4bQmYixww+Gxfr8/GkzguyjlqdV XPE/2rAzLHfkAx/N2QfHJFA= X-Google-Smtp-Source: AGs4zMb+P0lNd56cpatr+pUiIwXjcDTcF+4z8b3gCwjx+BxEhQRrlSHOf6oJfOBDNPDZucEwsu08dg== X-Received: by 10.223.186.9 with SMTP id o9mr25931956wrg.221.1511887833745; Tue, 28 Nov 2017 08:50:33 -0800 (PST) Received: from Red.local (LFbn-MAR-1-580-204.w90-118.abo.wanadoo.fr. [90.118.159.204]) by smtp.googlemail.com with ESMTPSA id j15sm3259603wmg.48.2017.11.28.08.50.32 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 28 Nov 2017 08:50:33 -0800 (PST) From: Corentin Labbe To: alexandre.torgue@st.com, maxime.ripard@free-electrons.com, peppe.cavallaro@st.com, wens@csie.org Subject: [PATCH] net: stmmac: dwmac-sun8i: fix allwinner, leds-active-low handling Date: Tue, 28 Nov 2017 17:48:22 +0100 Message-Id: <20171128164822.29218-1-clabbe.montjoie@gmail.com> X-Mailer: git-send-email 2.13.6 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20171128_085056_385835_F1211928 X-CRM114-Status: GOOD ( 10.56 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: netdev@vger.kernel.org, linux-sunxi@googlegroups.com, Corentin Labbe , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP The driver expect "allwinner,leds-active-low" to be in PHY node, but the binding doc expect it to be in MAC node. Since all board DT use it also in MAC node, the driver need to search allwinner,leds-active-low in MAC node. Signed-off-by: Corentin Labbe --- drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c b/drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c index e5ff734d4f9b..9eb7f65d8000 100644 --- a/drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c +++ b/drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c @@ -808,8 +808,7 @@ static int sun8i_dwmac_set_syscon(struct stmmac_priv *priv) val, reg); if (gmac->variant->soc_has_internal_phy) { - if (of_property_read_bool(priv->plat->phy_node, - "allwinner,leds-active-low")) + if (of_property_read_bool(node, "allwinner,leds-active-low")) reg |= H3_EPHY_LED_POL; else reg &= ~H3_EPHY_LED_POL;