[PATCH net-next] net: macb: make magic-packet property generic

Subsystems: atmel macb ethernet driver, networking drivers, open firmware and flattened device tree bindings, the rest

STALE3856d

3 messages, 3 authors, 2016-02-16 · open the first message on its own page

[PATCH net-next] net: macb: make magic-packet property generic

From: Sergio Prado <hidden>
Date: 2016-02-16 00:14:16

Signed-off-by: Sergio Prado <sergio.prado-1e4yhPs3/ABSwrhanM7KvQ@public.gmane.org>
---
As requested by Rob Herring on patch
https://patchwork.ozlabs.org/patch/580862/
---
 Documentation/devicetree/bindings/net/macb.txt | 2 +-
 drivers/net/ethernet/cadence/macb.c            | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/Documentation/devicetree/bindings/net/macb.txt b/Documentation/devicetree/bindings/net/macb.txt
index c6b1cb5ffa87..b5a42df4c928 100644
--- a/Documentation/devicetree/bindings/net/macb.txt
+++ b/Documentation/devicetree/bindings/net/macb.txt
@@ -25,7 +25,7 @@ Required properties:
 
 Optional properties for PHY child node:
 - reset-gpios : Should specify the gpio for phy reset
-- cdns,magic-packet : If present, indicates that the hardware supports waking
+- magic-packet : If present, indicates that the hardware supports waking
   up via magic packet.
 
 Examples:
diff --git a/drivers/net/ethernet/cadence/macb.c b/drivers/net/ethernet/cadence/macb.c
index 69af049e55a8..7ccf2298a5fa 100644
--- a/drivers/net/ethernet/cadence/macb.c
+++ b/drivers/net/ethernet/cadence/macb.c
@@ -2929,7 +2929,7 @@ static int macb_probe(struct platform_device *pdev)
 		bp->jumbo_max_len = macb_config->jumbo_max_len;
 
 	bp->wol = 0;
-	if (of_get_property(np, "cdns,magic-packet", NULL))
+	if (of_get_property(np, "magic-packet", NULL))
 		bp->wol |= MACB_WOL_HAS_MAGIC_PACKET;
 	device_init_wakeup(&pdev->dev, bp->wol & MACB_WOL_HAS_MAGIC_PACKET);
 
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Re: [PATCH net-next] net: macb: make magic-packet property generic

From: Arnd Bergmann <arnd@arndb.de>
Date: 2016-02-16 09:14:38

On Monday 15 February 2016 22:13:58 Sergio Prado wrote:
Signed-off-by: Sergio Prado <redacted>
---
As requested by Rob Herring on patch
https://patchwork.ozlabs.org/patch/580862/
This needs a changelog comment, at least clarify that the existing
value has never been used in production, so we are not breaking
anything with the incompatible binding  change.

	Arnd

Re: [PATCH net-next] net: macb: make magic-packet property generic

From: Sergei Shtylyov <hidden>
Date: 2016-02-16 14:23:54

Hello.

On 2/16/2016 3:13 AM, Sergio Prado wrote:
quoted hunk
Signed-off-by: Sergio Prado <sergio.prado-1e4yhPs3/ABSwrhanM7KvQ@public.gmane.org>
---
As requested by Rob Herring on patch
https://patchwork.ozlabs.org/patch/580862/
---
  Documentation/devicetree/bindings/net/macb.txt | 2 +-
  drivers/net/ethernet/cadence/macb.c            | 2 +-
  2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/Documentation/devicetree/bindings/net/macb.txt b/Documentation/devicetree/bindings/net/macb.txt
index c6b1cb5ffa87..b5a42df4c928 100644
--- a/Documentation/devicetree/bindings/net/macb.txt
+++ b/Documentation/devicetree/bindings/net/macb.txt
@@ -25,7 +25,7 @@ Required properties:

  Optional properties for PHY child node:
  - reset-gpios : Should specify the gpio for phy reset
-- cdns,magic-packet : If present, indicates that the hardware supports waking
+- magic-packet : If present, indicates that the hardware supports waking
    up via magic packet.

  Examples:
diff --git a/drivers/net/ethernet/cadence/macb.c b/drivers/net/ethernet/cadence/macb.c
index 69af049e55a8..7ccf2298a5fa 100644
--- a/drivers/net/ethernet/cadence/macb.c
+++ b/drivers/net/ethernet/cadence/macb.c
@@ -2929,7 +2929,7 @@ static int macb_probe(struct platform_device *pdev)
  		bp->jumbo_max_len = macb_config->jumbo_max_len;

  	bp->wol = 0;
-	if (of_get_property(np, "cdns,magic-packet", NULL))
+	if (of_get_property(np, "magic-packet", NULL))
    Could as well use of_property_read_bool().

[...]

MBR, Sergei

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help