From: <Claudiu.Beznea@microchip.com>
To: <harinik@xilinx.com>
Cc: <harini.katakam@xilinx.com>, <Nicolas.Ferre@microchip.com>,
<davem@davemloft.net>, <netdev@vger.kernel.org>,
<linux-kernel@vger.kernel.org>, <michal.simek@xilinx.com>,
<appanad@xilinx.com>
Subject: Re: [PATCH v2 4/4] net: macb: Add support for suspend/resume with full power down
Date: Tue, 27 Nov 2018 10:31:57 +0000 [thread overview]
Message-ID: <b2bd8eb0-9cc2-2fcb-4b90-17d3cc5212d9@microchip.com> (raw)
In-Reply-To: <CAFcVEC+yyvQckJaj9HrkUtsJSsAKs0F5akRkgBceMqbOAcdx3g@mail.gmail.com>
Hi Harini,
On 27.11.2018 08:25, Harini Katakam wrote:
> Hi Claudiu,
>
> On Mon, Nov 26, 2018 at 8:16 PM <Claudiu.Beznea@microchip.com> wrote:
>>
>>
>>
>> On 26.11.2018 09:07, Harini Katakam wrote:
> <snip>
>>
>> In the previous version you said you encountered some crashes while
>> stressing this part if macb_open()/macb_close() was used in here. Could you
>> share the tests so that I can debug it on my side?
>
> Sure, my tests include doing a series of suspend/resume -- it is done
> as part of a
> random regression script. On ZynqMP, it includes the following to do an
> FPD off suspend and then use either UART or WOL as a wake source and
> repeat the same, sometimes pinging in between:
>
> echo pm_request_wakeup 8 1 0 1 > /sys/kernel/debug/zynqmp-firmware/pm
> echo pm_force_powerdown 6 > /sys/kernel/debug/zynqmp-firmware/pm
> echo enabled > /sys/devices/platform/amba/ff000000.serial/tty/ttyPS0/power/wakeup
> echo enabled > /sys/devices/platform/amba/ff0e0000.ethernet/net/eth0/power/wakeup
> echo mem > /sys/power/state
>
> ping does not work sometimes and after a few iterations (sometimes
> 20), a crash can be
> observed tracing from "kfree_skb_list" to "macb_free_consistent". From
> the flow, the
> only explanation I could come up with was that there was an attempt to
> free buffers that
> may not have been allocated. Also, this was time consuming in the
> suspend/resume path.
Thank you for all these. I will try it on my side to see if I can reproduce it.
>
> <snip>
>>> + } else {
>>> + macb_writel(bp, NCR, MACB_BIT(MPE));
>>
>> Just asking... shouldn't other registers be restored here after SoC power
>> is cut off?
> Ideally yes. But in this series, I'm just attempting to re-initialize
> to a working
> state. I can try context save/restore later.
I see. I have tried it on my own with SAMA5D2 backup and self-refresh mode
where the core is shut down and it doesn't resume OK. Anyway, no issue, I
can add my context save/restore after this is accepted.
The idea with macb_open()/macb_close() was that it is doing everything for
you and every time new things are implemented you wouldn't have to add them
also in suspend/resume functions.
Thank you,
Claudiu Beznea
> Regards,
> Harini
>
prev parent reply other threads:[~2018-11-27 10:32 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-11-26 7:07 [PATCH v2 0/4] Macb power management support for ZynqMP Harini Katakam
2018-11-26 7:07 ` [PATCH v2 1/4] net: macb: Check MDIO state before read/write and use timeouts Harini Katakam
2018-11-26 14:39 ` Andrew Lunn
2018-11-27 5:38 ` Harini Katakam
2018-11-26 14:46 ` Claudiu.Beznea
2018-11-26 14:52 ` Andrew Lunn
2018-11-27 5:36 ` Harini Katakam
2018-11-27 10:25 ` Claudiu.Beznea
2018-11-27 10:49 ` Harini Katakam
2018-11-28 0:35 ` Andrew Lunn
2018-11-29 10:21 ` Claudiu.Beznea
2018-11-26 7:07 ` [PATCH v2 2/4] net: macb: Support clock management for tsu_clk Harini Katakam
2018-11-26 7:07 ` [PATCH v2 3/4] net: macb: Add pm runtime support Harini Katakam
2018-11-26 14:47 ` Andrew Lunn
2018-11-26 14:47 ` Claudiu.Beznea
2018-11-26 7:07 ` [PATCH v2 4/4] net: macb: Add support for suspend/resume with full power down Harini Katakam
2018-11-26 14:46 ` Claudiu.Beznea
2018-11-27 6:25 ` Harini Katakam
2018-11-27 10:31 ` Claudiu.Beznea [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=b2bd8eb0-9cc2-2fcb-4b90-17d3cc5212d9@microchip.com \
--to=claudiu.beznea@microchip.com \
--cc=Nicolas.Ferre@microchip.com \
--cc=appanad@xilinx.com \
--cc=davem@davemloft.net \
--cc=harini.katakam@xilinx.com \
--cc=harinik@xilinx.com \
--cc=linux-kernel@vger.kernel.org \
--cc=michal.simek@xilinx.com \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).