Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1415434

Re: [PATCH] net: stmmac: dwmac-rk: keep PHY up for WoL

From Heiko Stübner <heiko@sntech.de>
Newsgroups linux.kernel
Subject Re: [PATCH] net: stmmac: dwmac-rk: keep PHY up for WoL
Date 2016-06-06 22:50 +0200
Message-ID <rH9Db-1jo-25@gated-at.bofh.it> (permalink)
References <rG14Z-6b0-11@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


Hi,

Am Freitag, 3. Juni 2016, 10:29:20 schrieb Vincent Palatin:
> Do not shutdown the PHY if Wake-on-Lan is enabled, else it cannot wake
> us up.
> 
> Signed-off-by: Vincent Palatin <vpalatin@chromium.org>
> ---
>  drivers/net/ethernet/stmicro/stmmac/dwmac-rk.c | 8 ++++++++
>  1 file changed, 8 insertions(+)
> 
> diff --git a/drivers/net/ethernet/stmicro/stmmac/dwmac-rk.c
> b/drivers/net/ethernet/stmicro/stmmac/dwmac-rk.c index 0cd3ecf..2e45e75
> 100644
> --- a/drivers/net/ethernet/stmicro/stmmac/dwmac-rk.c
> +++ b/drivers/net/ethernet/stmicro/stmmac/dwmac-rk.c
> @@ -534,6 +534,10 @@ static int rk_gmac_init(struct platform_device *pdev,
> void *priv) struct rk_priv_data *bsp_priv = priv;
>  	int ret;
> 
> +	/* Keep the PHY up if we use Wake-on-Lan. */
> +	if (device_may_wakeup(&pdev->dev))
> +		return 0;
> +

Hmm, this looks like it would also block the initial setup of clocks and phy?
platform_device + device struct are created before probe gets called, so 
something could set the wakeup flag before the driver initially probes?


Confused,
Heiko

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH] net: stmmac: dwmac-rk: keep PHY up for WoL Vincent Palatin <vpalatin@chromium.org> - 2016-06-03 19:30 +0200
  Re: [PATCH] net: stmmac: dwmac-rk: keep PHY up for WoL Heiko Stübner <heiko@sntech.de> - 2016-06-06 22:50 +0200
    Re: [PATCH] net: stmmac: dwmac-rk: keep PHY up for WoL Vincent Palatin <vpalatin@chromium.org> - 2016-06-06 23:10 +0200
  Re: [PATCH] net: stmmac: dwmac-rk: keep PHY up for WoL Giuseppe CAVALLARO <peppe.cavallaro@st.com> - 2016-06-07 09:30 +0200
    Re: [PATCH] net: stmmac: dwmac-rk: keep PHY up for WoL Vincent Palatin <vpalatin@chromium.org> - 2016-06-09 00:30 +0200
      Re: [PATCH] net: stmmac: dwmac-rk: keep PHY up for WoL Andrew Lunn <andrew@lunn.ch> - 2016-06-09 02:20 +0200
        Re: [PATCH] net: stmmac: dwmac-rk: keep PHY up for WoL Vincent Palatin <vpalatin@chromium.org> - 2016-06-10 01:10 +0200
          Re: [PATCH] net: stmmac: dwmac-rk: keep PHY up for WoL Giuseppe CAVALLARO <peppe.cavallaro@st.com> - 2016-06-10 14:30 +0200
            [PATCH 2/3] net: stmmac: dwmac-rk: keep the PHY up for WoL Vincent Palatin <vpalatin@chromium.org> - 2016-06-11 03:10 +0200
              Re: [PATCH 2/3] net: stmmac: dwmac-rk: keep the PHY up for WoL Heiko Stuebner <heiko@sntech.de> - 2016-06-11 04:00 +0200
            [PATCH 1/3] net: stmmac: allow to split suspend/resume from init/exit callbacks Vincent Palatin <vpalatin@chromium.org> - 2016-06-11 03:10 +0200
              Re: [PATCH 1/3] net: stmmac: allow to split suspend/resume from  init/exit callbacks David Miller <davem@davemloft.net> - 2016-06-11 03:20 +0200
            net: stmmac: dwmac-rk: fixes for Wake-on-Lan on RK3288 Vincent Palatin <vpalatin@chromium.org> - 2016-06-11 03:10 +0200
              [PATCH 3/3] ARM: dts: rockchip: add interrupt for Wake-on-Lan on RK3288 Vincent Palatin <vpalatin@chromium.org> - 2016-06-11 03:10 +0200
              Re: net: stmmac: dwmac-rk: fixes for Wake-on-Lan on RK3288 David Miller <davem@davemloft.net> - 2016-06-11 03:20 +0200

csiph-web