xref: /linux/arch/riscv/include/asm/vdso/vsyscall.h (revision 60675d4ca1ef0857e44eba5849b74a3a998d0c0f)
1*ad5d1122SVincent Chen /* SPDX-License-Identifier: GPL-2.0 */
2*ad5d1122SVincent Chen #ifndef __ASM_VDSO_VSYSCALL_H
3*ad5d1122SVincent Chen #define __ASM_VDSO_VSYSCALL_H
4*ad5d1122SVincent Chen 
5*ad5d1122SVincent Chen #ifndef __ASSEMBLY__
6*ad5d1122SVincent Chen 
7*ad5d1122SVincent Chen #include <vdso/datapage.h>
8*ad5d1122SVincent Chen 
9*ad5d1122SVincent Chen extern struct vdso_data *vdso_data;
10*ad5d1122SVincent Chen 
11*ad5d1122SVincent Chen static __always_inline struct vdso_data *__riscv_get_k_vdso_data(void)
12*ad5d1122SVincent Chen {
13*ad5d1122SVincent Chen 	return vdso_data;
14*ad5d1122SVincent Chen }
15*ad5d1122SVincent Chen 
16*ad5d1122SVincent Chen #define __arch_get_k_vdso_data __riscv_get_k_vdso_data
17*ad5d1122SVincent Chen 
18*ad5d1122SVincent Chen /* The asm-generic header needs to be included after the definitions above */
19*ad5d1122SVincent Chen #include <asm-generic/vdso/vsyscall.h>
20*ad5d1122SVincent Chen 
21*ad5d1122SVincent Chen #endif /* !__ASSEMBLY__ */
22*ad5d1122SVincent Chen 
23*ad5d1122SVincent Chen #endif /* __ASM_VDSO_VSYSCALL_H */
24