From: Ratheesh Kannoth <rkannoth@marvell.com>
To: Leon Romanovsky <leon@kernel.org>
Cc: <davem@davemloft.net>, <gakula@marvell.com>,
<linux-kernel@vger.kernel.org>, <netdev@vger.kernel.org>,
<sgoutham@marvell.com>, <andrew+netdev@lunn.ch>,
<edumazet@google.com>, <kuba@kernel.org>, <pabeni@redhat.com>
Subject: Re: [PATCH v7 net] octeontx2-af: switch qmem from coherent DMA alloc to streaming DMA mapping
Date: Mon, 7 Sep 2026 17:44:48 +0530 [thread overview]
Message-ID: <ap6quHlmYxI0cJAl@rkannoth-OptiPlex-7090> (raw)
In-Reply-To: <20260907113244.GJ13683@unreal>
On 2026-09-07 at 17:02:44, Leon Romanovsky (leon@kernel.org) wrote:
> > > > + */
> > > > + if (order > MAX_PAGE_ORDER) {
> > >
> > > Size is coming from the kernel, how can it be with order more than MAX_PAGE_ORDER?
> > There is contigious memory allocation request from driver for PF-to-VF mail box memory.
> > It is crossing max page order in newer platforms as number of VFs per PF increased.
>
> I'm not sure what this means. You can't create a VF without assigning it
> enough memory for DMA. You shouldn't get an "order > MAX_PAGE_ORDER"
> error at this stage. If you do, there is likely another bug involved.
I will move the MAX_PAGE_ORDER / size validation out of the DMA helper and handle any
allocation failure with a clear error at the call site, where we know the required size and VF count.
One question on dev_is_dma_coherent(): this qmem path relies on the platform being DMA-coherent
(as noted in the commit message). Would you prefer that we keep this check in this function as explicit
guard so that a future port to a non-I/O-coherent SoC fails early rather than silently misbehaving?
next prev parent reply other threads:[~2026-09-07 12:15 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-07 4:26 Ratheesh Kannoth
2026-09-07 7:20 ` Leon Romanovsky
2026-09-07 10:42 ` Ratheesh Kannoth
2026-09-07 11:32 ` Leon Romanovsky
2026-09-07 12:14 ` Ratheesh Kannoth [this message]
2026-09-08 6:19 ` Leon Romanovsky
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=ap6quHlmYxI0cJAl@rkannoth-OptiPlex-7090 \
--to=rkannoth@marvell.com \
--cc=andrew+netdev@lunn.ch \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=gakula@marvell.com \
--cc=kuba@kernel.org \
--cc=leon@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=sgoutham@marvell.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®