From: "Christophe Leroy (CS GROUP)" <chleroy@kernel•org>
To: Arnd Bergmann <arnd@kernel•org>,
Madhavan Srinivasan <maddy@linux•ibm.com>,
Michael Ellerman <mpe@ellerman•id.au>,
"T.J. Mercier" <tjmercier@google•com>,
Maxime Ripard <mripard@kernel•org>,
Sumit Semwal <sumit.semwal@linaro•org>, Andrew Davis <afd@ti•com>,
Christoph Hellwig <hch@infradead•org>
Cc: Arnd Bergmann <arnd@arndb•de>,
Nicholas Piggin <npiggin@gmail•com>,
linuxppc-dev@lists•ozlabs.org, linux-kernel@vger•kernel.org
Subject: Re: [PATCH 2/2] powerpc: export memory encryption helper functions
Date: Tue, 26 May 2026 13:53:50 +0200 [thread overview]
Message-ID: <eebe442e-eb5e-40db-b07a-f446c8f7c8db@kernel.org> (raw)
In-Reply-To: <20260526102113.2594501-2-arnd@kernel.org>
Hi Arnd,
Le 26/05/2026 à 12:20, Arnd Bergmann a écrit :
> From: Arnd Bergmann <arnd@arndb•de>
>
> The set_memory_encrypted/set_memory_decrypted functions are exported
> on x86 and arm64 but not on powerpc, which leads to a new build failure
> because they are now used in a loadable module:
>
> ERROR: modpost: "set_memory_encrypted" [drivers/dma-buf/heaps/system_heap.ko] undefined!
> ERROR: modpost: "set_memory_decrypted" [drivers/dma-buf/heaps/system_heap.ko] undefined!
>
> Export these the same way we do on the other architectures.
The same fix was rejected already, see
https://lore.kernel.org/all/ahPqbfH54R3JJyaV@infradead.org/
Christophe
>
> Fixes: fd55edff8a0a ("dma-buf: heaps: system: Turn the heap into a module")
> Signed-off-by: Arnd Bergmann <arnd@arndb•de>
> ---
> arch/powerpc/platforms/pseries/svm.c | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/arch/powerpc/platforms/pseries/svm.c b/arch/powerpc/platforms/pseries/svm.c
> index 384c9dc1899a..ab8f8c722741 100644
> --- a/arch/powerpc/platforms/pseries/svm.c
> +++ b/arch/powerpc/platforms/pseries/svm.c
> @@ -6,6 +6,7 @@
> * Author: Anshuman Khandual <khandual@linux•vnet.ibm.com>
> */
>
> +#include <linux/export.h>
> #include <linux/mm.h>
> #include <linux/memblock.h>
> #include <linux/mem_encrypt.h>
> @@ -50,6 +51,7 @@ int set_memory_encrypted(unsigned long addr, int numpages)
>
> return 0;
> }
> +EXPORT_SYMBOL_GPL(set_memory_encrypted);
>
> int set_memory_decrypted(unsigned long addr, int numpages)
> {
> @@ -63,6 +65,7 @@ int set_memory_decrypted(unsigned long addr, int numpages)
>
> return 0;
> }
> +EXPORT_SYMBOL_GPL(set_memory_decrypted);
>
> /* There's one dispatch log per CPU. */
> #define NR_DTL_PAGE (DISPATCH_LOG_BYTES * CONFIG_NR_CPUS / PAGE_SIZE)
prev parent reply other threads:[~2026-05-26 11:54 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20260526102113.2594501-1-arnd@kernel.org>
2026-05-26 10:20 ` [PATCH 2/2] powerpc: export memory encryption helper functions Arnd Bergmann
2026-05-26 11:53 ` Christophe Leroy (CS GROUP) [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=eebe442e-eb5e-40db-b07a-f446c8f7c8db@kernel.org \
--to=chleroy@kernel$(echo .)org \
--cc=afd@ti$(echo .)com \
--cc=arnd@arndb$(echo .)de \
--cc=arnd@kernel$(echo .)org \
--cc=hch@infradead$(echo .)org \
--cc=linux-kernel@vger$(echo .)kernel.org \
--cc=linuxppc-dev@lists$(echo .)ozlabs.org \
--cc=maddy@linux$(echo .)ibm.com \
--cc=mpe@ellerman$(echo .)id.au \
--cc=mripard@kernel$(echo .)org \
--cc=npiggin@gmail$(echo .)com \
--cc=sumit.semwal@linaro$(echo .)org \
--cc=tjmercier@google$(echo .)com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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