linux-loongson/arch/powerpc/include/asm/vdso_datapage.h
Thomas Weißschuh 223970df2b powerpc/vdso: Switch to generic storage implementation
The generic storage implementation provides the same features as the
custom one. However it can be shared between architectures, making
maintenance easier.

Co-developed-by: Nam Cao <namcao@linutronix.de>
Signed-off-by: Nam Cao <namcao@linutronix.de>
Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Christophe Leroy <christophe.leroy@csgroup.eu>
Link: https://lore.kernel.org/all/20250204-vdso-store-rng-v3-14-13a4669dfc8c@linutronix.de
2025-02-21 09:54:02 +01:00

30 lines
583 B
C

/* SPDX-License-Identifier: GPL-2.0-or-later */
#ifndef _VDSO_DATAPAGE_H
#define _VDSO_DATAPAGE_H
#ifdef __KERNEL__
/*
* Copyright (C) 2002 Peter Bergner <bergner@vnet.ibm.com>, IBM
* Copyright (C) 2005 Benjamin Herrenschmidy <benh@kernel.crashing.org>,
* IBM Corp.
*/
#ifndef __ASSEMBLY__
#include <vdso/datapage.h>
#else /* __ASSEMBLY__ */
.macro get_datapage ptr symbol
bcl 20, 31, .+4
999:
mflr \ptr
addis \ptr, \ptr, (\symbol - 999b)@ha
addi \ptr, \ptr, (\symbol - 999b)@l
.endm
#endif /* __ASSEMBLY__ */
#endif /* __KERNEL__ */
#endif /* _SYSTEMCFG_H */