From: "Troy Mitchell" <troy.mitchell@linux.dev>
To: "Paul Walmsley" <pjw@kernel.org>,
"Palmer Dabbelt" <palmer@dabbelt.com>,
"Albert Ou" <aou@eecs.berkeley.edu>,
"Alexandre Ghiti" <alex@ghiti.fr>
Cc: <linux-riscv@lists.infradead.org>, <linux-kernel@vger.kernel.org>,
<spacemit@lists.linux.dev>,
"Anirudh Srinivasan" <asrinivasan@oss.tenstorrent.com>
Subject: Re: [PATCH v2] riscv: mm: fix SWIOTLB initialization for systems with DRAM above 4GB
Date: Mon, 27 Jul 2026 00:12:45 -0700 [thread overview]
Message-ID: <DK9610Z1F0G9.3KQ7JB8NG1HO7@linux.dev> (raw)
In-Reply-To: <57a24fb1-1ca6-3bb5-1c1e-bdcb50ce2b7e@kernel.org>
> > > 2. kmalloc() bounce buffer allocation failure on non-coherent systems:
> > > For non-coherent hardware, a bounce buffer is still mandatory for
> > > cache-line-aligned kmalloc(), even if 32-bit DMA bouncing is skipped.
>
> I'm not sure I'm parsing this correctly. Shouldn't this read "for
> *non*-cache-aligned kmalloc()" ? Or am I missing the point?
You are right; this should refer to kmalloc() buffers whose
size is not cache-line-aligned. dma_kmalloc_needs_bounce() requests
bouncing only when dma_kmalloc_size_aligned(size) is false for a
non-coherent device and a direction other than DMA_TO_DEVICE. I will
correct both the commit message and the corresponding code comment in the
next revision.
- Troy
prev parent reply other threads:[~2026-07-27 7:13 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-29 11:41 [PATCH v2] riscv: mm: fix SWIOTLB initialization for systems with DRAM above 4GB Troy Mitchell
2026-06-08 1:22 ` Troy Mitchell
2026-07-14 15:37 ` Anirudh Srinivasan
2026-07-20 0:55 ` Paul Walmsley
2026-07-20 14:54 ` Anirudh Srinivasan
2026-07-27 7:12 ` Troy Mitchell [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=DK9610Z1F0G9.3KQ7JB8NG1HO7@linux.dev \
--to=troy.mitchell@linux.dev \
--cc=alex@ghiti.fr \
--cc=aou@eecs.berkeley.edu \
--cc=asrinivasan@oss.tenstorrent.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-riscv@lists.infradead.org \
--cc=palmer@dabbelt.com \
--cc=pjw@kernel.org \
--cc=spacemit@lists.linux.dev \
/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