aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/um/shared/sysdep/stub_64.h
diff options
context:
space:
mode:
authorTiwei Bie <tiwei.btw@antgroup.com>2025-08-27 08:57:03 +0800
committerJohannes Berg <johannes.berg@intel.com>2025-09-10 14:23:52 +0200
commite047f9af9d6948728614f7eea41ba53d5b767e9f (patch)
tree42bda26d92b48016f25c9445dd509406e55fe0ab /arch/x86/um/shared/sysdep/stub_64.h
parentum: Remove outdated comment about STUB_DATA_PAGES (diff)
downloadlinux-e047f9af9d6948728614f7eea41ba53d5b767e9f.tar.gz
linux-e047f9af9d6948728614f7eea41ba53d5b767e9f.zip
um: Centralize stub size calculations
Currently, the stub size is calculated in multiple places. Define a macro that performs the calculation so that the code is easier to read and maintain. Signed-off-by: Tiwei Bie <tiwei.btw@antgroup.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'arch/x86/um/shared/sysdep/stub_64.h')
-rw-r--r--arch/x86/um/shared/sysdep/stub_64.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/um/shared/sysdep/stub_64.h b/arch/x86/um/shared/sysdep/stub_64.h
index 9cfd31afa769..9fd56954e2e0 100644
--- a/arch/x86/um/shared/sysdep/stub_64.h
+++ b/arch/x86/um/shared/sysdep/stub_64.h
@@ -133,7 +133,7 @@ static __always_inline void *get_stub_data(void)
"subq %0,%%rsp ;" \
"movq %1,%%rax ;" \
"call *%%rax ;" \
- :: "i" ((1 + STUB_DATA_PAGES) * UM_KERN_PAGE_SIZE), \
+ :: "i" (STUB_SIZE), \
"i" (&fn))
static __always_inline void