From: "Russell King (Oracle)" <linux@armlinux.org.uk>
To: Jenishkumar Maheshbhai Patel <jpatel2@marvell.com>
Cc: marcin.s.wojtas@gmail.com, davem@davemloft.net,
edumazet@google.com, kuba@kernel.org, pabeni@redhat.com,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/1] net: mvpp2: clear BM pool before initialization
Date: Tue, 16 Jan 2024 09:26:16 +0000 [thread overview]
Message-ID: <ZaZLuPyRa5QhRrmH@shell.armlinux.org.uk> (raw)
In-Reply-To: <20240116055754.279560-1-jpatel2@marvell.com>
On Mon, Jan 15, 2024 at 09:57:54PM -0800, Jenishkumar Maheshbhai Patel wrote:
> static int mvpp2_bm_init(struct device *dev, struct mvpp2 *priv)
> {
> enum dma_data_direction dma_dir = DMA_FROM_DEVICE;
> int i, err, poolnum = MVPP2_BM_POOLS_NUM;
> struct mvpp2_port *port;
>
> + if (priv->percpu_pools)
> + poolnum = mvpp2_get_nrxqs(priv) * 2;
> +
> + for (i = 0; i < poolnum; i++) {
> + /* Make sure about the pool state in case it was
> + * used by firmware.
> + */
> + mvpp2_bm_pool_cleanup(priv, i);
> + }
/* Clean up the pool state in case it contains stale state */
for (i = 0; i < poolnum; i++)
mvpp2_bm_pool_cleanup(priv, i);
Doesn't need quite as many lines!
--
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!
next prev parent reply other threads:[~2024-01-16 9:26 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-01-16 5:57 [PATCH 1/1] net: mvpp2: clear BM pool before initialization Jenishkumar Maheshbhai Patel
2024-01-16 9:26 ` Russell King (Oracle) [this message]
2024-01-16 11:42 ` [EXT] " Jenishkumar Patel [C]
2024-01-16 15:11 ` Jakub Kicinski
2024-01-17 3:55 ` [EXT] " Jenishkumar Patel [C]
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=ZaZLuPyRa5QhRrmH@shell.armlinux.org.uk \
--to=linux@armlinux.org.uk \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=jpatel2@marvell.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=marcin.s.wojtas@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.