From: Andrew Lunn <andrew@lunn.ch>
To: Vineeth Karumanchi <vineeth.karumanchi@amd.com>
Cc: nicolas.ferre@microchip.com, claudiu.beznea@tuxon.dev,
davem@davemloft.net, edumazet@google.com, kuba@kernel.org,
pabeni@redhat.com, robh+dt@kernel.org,
krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org,
linux@armlinux.org.uk, vadim.fedorenko@linux.dev,
netdev@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org, git@amd.com
Subject: Re: [PATCH net-next v3 1/4] net: macb: queue tie-off or disable during WOL suspend
Date: Thu, 6 Jun 2024 03:44:10 +0200 [thread overview]
Message-ID: <90da3dd6-e361-46d0-b547-c662b649b03d@lunn.ch> (raw)
In-Reply-To: <20240605102457.4050539-2-vineeth.karumanchi@amd.com>
> @@ -5224,17 +5257,38 @@ static int __maybe_unused macb_suspend(struct device *dev)
>
> if (bp->wol & MACB_WOL_ENABLED) {
> spin_lock_irqsave(&bp->lock, flags);
> - /* Flush all status bits */
> - macb_writel(bp, TSR, -1);
> - macb_writel(bp, RSR, -1);
> +
> + /* Disable Tx and Rx engines before disabling the queues,
> + * this is mandatory as per the IP spec sheet
> + */
> + tmp = macb_readl(bp, NCR);
> + macb_writel(bp, NCR, tmp & ~(MACB_BIT(TE) | MACB_BIT(RE)));
Is there any need to wait for this to complete? What if there is a DMA
transaction in flight?
Andrew
next prev parent reply other threads:[~2024-06-06 1:44 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-06-05 10:24 [PATCH net-next v3 0/4] net: macb: WOL enhancements Vineeth Karumanchi
2024-06-05 10:24 ` [PATCH net-next v3 1/4] net: macb: queue tie-off or disable during WOL suspend Vineeth Karumanchi
2024-06-06 1:44 ` Andrew Lunn [this message]
2024-06-07 5:54 ` Vineeth Karumanchi
2024-06-05 10:24 ` [PATCH net-next v3 2/4] net: macb: Enable queue disable Vineeth Karumanchi
2024-06-06 2:00 ` Andrew Lunn
2024-06-05 10:24 ` [PATCH net-next v3 3/4] net: macb: Add ARP support to WOL Vineeth Karumanchi
2024-06-06 1:59 ` Andrew Lunn
2024-06-07 5:19 ` Vineeth Karumanchi
2024-06-05 10:24 ` [PATCH net-next v3 4/4] dt-bindings: net: cdns,macb: Deprecate magic-packet property Vineeth Karumanchi
2024-06-05 15:41 ` Rob Herring
2024-06-06 5:13 ` Vineeth Karumanchi
2024-06-06 6:17 ` Krzysztof Kozlowski
2024-06-06 7:04 ` Vineeth Karumanchi
2024-06-06 2:00 ` Andrew Lunn
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=90da3dd6-e361-46d0-b547-c662b649b03d@lunn.ch \
--to=andrew@lunn.ch \
--cc=claudiu.beznea@tuxon.dev \
--cc=conor+dt@kernel.org \
--cc=davem@davemloft.net \
--cc=devicetree@vger.kernel.org \
--cc=edumazet@google.com \
--cc=git@amd.com \
--cc=krzysztof.kozlowski+dt@linaro.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=netdev@vger.kernel.org \
--cc=nicolas.ferre@microchip.com \
--cc=pabeni@redhat.com \
--cc=robh+dt@kernel.org \
--cc=vadim.fedorenko@linux.dev \
--cc=vineeth.karumanchi@amd.com \
/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
all inboxes | Powered by JetHome®