From: Jan Beulich <jbeulich@suse.com>
To: "xen-devel@lists.xenproject.org" <xen-devel@lists.xenproject.org>
Cc: "Andrew Cooper" <andrew.cooper3@citrix.com>,
"Julien Grall" <julien@xen.org>,
"Stefano Stabellini" <sstabellini@kernel.org>,
"Michal Orzel" <michal.orzel@amd.com>,
"Roger Pau Monné" <roger.pau@citrix.com>,
"Alistair Francis" <alistair.francis@wdc.com>,
"Connor Davis" <connojdavis@gmail.com>,
"Oleksii Kurochko" <oleksii.kurochko@gmail.com>,
"Bertrand Marquis" <bertrand.marquis@arm.com>,
"Volodymyr Babchuk" <volodymyr_babchuk@epam.com>
Subject: [PATCH v2 2/2] make ioremap_wc() x86 only (for the time being)
Date: Wed, 8 Apr 2026 14:09:03 +0200 [thread overview]
Message-ID: <da4bf81d-7591-4f5d-8e0d-e6ed9ecb834e@suse.com> (raw)
In-Reply-To: <145299a0-b25c-4612-82c6-9401a2f88ad2@suse.com>
Its use in domain building is questionable: Already at the point both uses
were introduced, ioremap_cache() existed. I can't see why kernel and
initrd would need mapping WC, when at the same time other similar mappings
(in common/device-tree/) are done WB.
With those uses replaced, neither Arm nor RISC-V have a need for the
function anymore.
Amends: d8972aa9645f ("xen/arm: kernel: Rework kernel_zimage_load to use the generic copy helper")
Amends: bb7e6d565d92 ("xen/arm: domain_build: Rework initrd_load to use the generic copy helper")
Signed-off-by: Jan Beulich <jbeulich@suse.com>
Reviewed-by: Oleksii Kurochko <oleksii.kurochko@gmail.com>
--- a/xen/arch/arm/include/asm/mm.h
+++ b/xen/arch/arm/include/asm/mm.h
@@ -213,11 +213,6 @@ static inline void __iomem *ioremap_cach
return ioremap_attr(start, len, PAGE_HYPERVISOR);
}
-static inline void __iomem *ioremap_wc(paddr_t start, size_t len)
-{
- return ioremap_attr(start, len, PAGE_HYPERVISOR_WC);
-}
-
/* XXX -- account for base */
#define mfn_valid(mfn) ({ \
unsigned long __m_f_n = mfn_x(mfn); \
--- a/xen/arch/arm/kernel.c
+++ b/xen/arch/arm/kernel.c
@@ -148,7 +148,7 @@ static void __init kernel_zimage_load(st
printk("Loading zImage from %"PRIpaddr" to %"PRIpaddr"-%"PRIpaddr"\n",
paddr, load_addr, load_addr + len);
- kernel = ioremap_wc(paddr, len);
+ kernel = ioremap_cache(paddr, len);
if ( !kernel )
panic("Unable to map the %pd kernel\n", info->bd.d);
--- a/xen/arch/riscv/include/asm/io.h
+++ b/xen/arch/riscv/include/asm/io.h
@@ -43,7 +43,6 @@
void __iomem *ioremap(paddr_t pa, size_t len);
void __iomem *ioremap_cache(paddr_t pa, size_t len);
-void __iomem *ioremap_wc(paddr_t pa, size_t len);
/* Generic IO read/write. These perform native-endian accesses. */
static inline void __raw_writeb(uint8_t val, volatile void __iomem *addr)
--- a/xen/arch/riscv/mm.c
+++ b/xen/arch/riscv/mm.c
@@ -592,11 +592,6 @@ void __iomem *ioremap_cache(paddr_t pa,
return ioremap_attr(pa, len, PAGE_HYPERVISOR);
}
-void __iomem *ioremap_wc(paddr_t pa, size_t len)
-{
- return ioremap_attr(pa, len, PAGE_HYPERVISOR_WC);
-}
-
void __iomem *ioremap(paddr_t pa, size_t len)
{
return ioremap_attr(pa, len, PAGE_HYPERVISOR_NOCACHE);
--- a/xen/common/device-tree/domain-build.c
+++ b/xen/common/device-tree/domain-build.c
@@ -395,7 +395,7 @@ void __init initrd_load(struct kernel_in
if ( res )
panic("Cannot fix up \"linux,initrd-end\" property\n");
- initrd = ioremap_wc(paddr, len);
+ initrd = ioremap_cache(paddr, len);
if ( !initrd )
panic("Unable to map the %pd initrd\n", kinfo->bd.d);
next prev parent reply other threads:[~2026-04-08 12:09 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-08 12:05 [PATCH v2] ioremap() et al Jan Beulich
2026-04-08 12:07 ` [PATCH v2 1/2] make ioremap_attr() common Jan Beulich
2026-04-09 7:26 ` Luca Fancellu
2026-04-09 7:54 ` Jan Beulich
2026-04-09 7:52 ` Roger Pau Monné
2026-04-09 7:58 ` Jan Beulich
2026-04-09 8:36 ` Oleksii Kurochko
2026-04-08 12:09 ` Jan Beulich [this message]
2026-04-09 7:57 ` [PATCH v2 2/2] make ioremap_wc() x86 only (for the time being) Luca Fancellu
[not found] ` <4291DA48-87D9-491B-83C6-51CCACC0FFE7@arm.com>
2026-04-09 8:01 ` Jan Beulich
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=da4bf81d-7591-4f5d-8e0d-e6ed9ecb834e@suse.com \
--to=jbeulich@suse.com \
--cc=alistair.francis@wdc.com \
--cc=andrew.cooper3@citrix.com \
--cc=bertrand.marquis@arm.com \
--cc=connojdavis@gmail.com \
--cc=julien@xen.org \
--cc=michal.orzel@amd.com \
--cc=oleksii.kurochko@gmail.com \
--cc=roger.pau@citrix.com \
--cc=sstabellini@kernel.org \
--cc=volodymyr_babchuk@epam.com \
--cc=xen-devel@lists.xenproject.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 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.