From patchwork Mon Dec 19 15:05:38 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Brunet X-Patchwork-Id: 9480455 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 CE5B4601C2 for ; Mon, 19 Dec 2016 15:08:06 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id BDC0828404 for ; Mon, 19 Dec 2016 15:08:06 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id B28DD284DE; Mon, 19 Dec 2016 15:08:06 +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.1 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_MED, T_DKIM_INVALID autolearn=unavailable version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id CE20A28404 for ; Mon, 19 Dec 2016 15:08:05 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.85_2 #1 (Red Hat Linux)) id 1cIzXf-0006Qz-2F; Mon, 19 Dec 2016 15:07:55 +0000 Received: from mail-wm0-x230.google.com ([2a00:1450:400c:c09::230]) by bombadil.infradead.org with esmtps (Exim 4.85_2 #1 (Red Hat Linux)) id 1cIzW2-0004py-RT for linux-amlogic@lists.infradead.org; Mon, 19 Dec 2016 15:06:20 +0000 Received: by mail-wm0-x230.google.com with SMTP id g23so95846279wme.1 for ; Mon, 19 Dec 2016 07:05:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=WjtwTMJ6m350VJaxMgGvVLVhu7Kf6+QI3B6VL+dqN0k=; b=awF/Hd/VqzHxupSQqJGXhlDeAITNsFwDfh4IIzOZfKCeg/bf41LibLVbNwX0pRPMtr y2yNUe0WztGint+GNrtNbB8pZUkNLZ0C4XOrhlq67tR0oNJqlLjaZ//kFbw/J+yDUTdC fsbc5douywIerdC9F9Z5r0+JpAkJIKUSn5oHeEij3kctDt0ifoxljM/phEQjp4hgctgc /iTL0SCNYZq3R+1Ffq44fQYGmN0An6v1nZr5R0Y5YdnvCDwqP3Atdf5WyH3dHKoT5bfV ZUJEL8+AwdFXooOjPS3SpycFGfBnK16QBn9EipGKbbvMogT2yyJaNaEvGqZRkvUeUoTB TTeA== 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:in-reply-to :references; bh=WjtwTMJ6m350VJaxMgGvVLVhu7Kf6+QI3B6VL+dqN0k=; b=X08qXYCaSv515rBFC8oeT4V5RlE8bNXF+eoJ+aEpWd44sEGqh9F57dXegygel3Yais wX5jmXYunah/EBQZBkWp46z4J9trj+6z61tIKXX0DEU5lT4y9CcHiYIgFkmAc7ObYuJH Wat0ZHxgSUkJIkH9V7SZ1OkO0l+Zbr/5gD7DliMoJFYncFitZh0e+c4OcakaBQK8XzIR fxRkcjv6NThoOihgxeFHIgjRBHSYLHj5GKSIesJawKhjryyo3XjXBYDA05gh/ZnrtAPh 1al1btTZnPjr/kX1wXjIKZafzcnVCun4jyE/LIJSPXtuBp6LE+6/tEuo+r+7k8a+RS43 LdvA== X-Gm-Message-State: AIkVDXIcGSeRHaRpgnbnHCtG8e4yssUIpxS2v0Jh88ahIm1ZnXBNMeDkMOyMceu+kAMP7tM2 X-Received: by 10.28.0.210 with SMTP id 201mr13495665wma.49.1482159952787; Mon, 19 Dec 2016 07:05:52 -0800 (PST) Received: from boomer.localdomain ([90.63.244.31]) by smtp.googlemail.com with ESMTPSA id v2sm21046655wja.41.2016.12.19.07.05.51 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 19 Dec 2016 07:05:52 -0800 (PST) From: Jerome Brunet To: netdev@vger.kernel.org, devicetree@vger.kernel.org, Florian Fainelli Subject: [PATCH net 3/3] dt: bindings: net: use boolean dt properties for eee broken modes Date: Mon, 19 Dec 2016 16:05:38 +0100 Message-Id: <1482159938-13239-4-git-send-email-jbrunet@baylibre.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1482159938-13239-1-git-send-email-jbrunet@baylibre.com> References: <1482159938-13239-1-git-send-email-jbrunet@baylibre.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20161219_070615_371410_CBBDCAF4 X-CRM114-Status: GOOD ( 10.52 ) X-BeenThere: linux-amlogic@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Andrew Lunn , Neil Armstrong , Martin Blumenstingl , Kevin Hilman , linux-kernel@vger.kernel.org, Yegor Yefremov , Andre Roth , Carlo Caione , linux-amlogic@lists.infradead.org, =?UTF-8?q?Andreas=20F=C3=A4rber?= , linux-arm-kernel@lists.infradead.org, Jerome Brunet MIME-Version: 1.0 Sender: "linux-amlogic" Errors-To: linux-amlogic-bounces+patchwork-linux-amlogic=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP The patches regarding eee-broken-modes was merged before all people involved could find an agreement on the best way to move forward. While we agreed on having a DT property to mark particular modes as broken, the value used for eee-broken-modes mapped the phy register in very direct way. Because of this, the concern is that it could be used to implement configuration policies instead of describing a broken HW. In the end, having a boolean property for each mode seems to be preferred over one bit field value mapping the register (too) directly. Cc: Florian Fainelli Signed-off-by: Jerome Brunet --- Documentation/devicetree/bindings/net/phy.txt | 10 ++++++++-- include/dt-bindings/net/mdio.h | 19 ------------------- 2 files changed, 8 insertions(+), 21 deletions(-) delete mode 100644 include/dt-bindings/net/mdio.h diff --git a/Documentation/devicetree/bindings/net/phy.txt b/Documentation/devicetree/bindings/net/phy.txt index 54749b60a466..ff1bc4b1bb3b 100644 --- a/Documentation/devicetree/bindings/net/phy.txt +++ b/Documentation/devicetree/bindings/net/phy.txt @@ -38,8 +38,14 @@ Optional Properties: - enet-phy-lane-swap: If set, indicates the PHY will swap the TX/RX lanes to compensate for the board being designed with the lanes swapped. -- eee-broken-modes: Bits to clear in the MDIO_AN_EEE_ADV register to - disable EEE broken modes. +- eee-broken-100tx: +- eee-broken-1000t: +- eee-broken-10gt: +- eee-broken-1000kx: +- eee-broken-10gkx4: +- eee-broken-10gkr: + Mark the corresponding energy efficient ethernet mode as broken and + request the ethernet to stop advertising it. Example: diff --git a/include/dt-bindings/net/mdio.h b/include/dt-bindings/net/mdio.h deleted file mode 100644 index 99c6d903d439..000000000000 --- a/include/dt-bindings/net/mdio.h +++ /dev/null @@ -1,19 +0,0 @@ -/* - * This header provides generic constants for ethernet MDIO bindings - */ - -#ifndef _DT_BINDINGS_NET_MDIO_H -#define _DT_BINDINGS_NET_MDIO_H - -/* - * EEE capability Advertisement - */ - -#define MDIO_EEE_100TX 0x0002 /* 100TX EEE cap */ -#define MDIO_EEE_1000T 0x0004 /* 1000T EEE cap */ -#define MDIO_EEE_10GT 0x0008 /* 10GT EEE cap */ -#define MDIO_EEE_1000KX 0x0010 /* 1000KX EEE cap */ -#define MDIO_EEE_10GKX4 0x0020 /* 10G KX4 EEE cap */ -#define MDIO_EEE_10GKR 0x0040 /* 10G KR EEE cap */ - -#endif