blob: dc0419b66f17ac1f676bf247f8706b0a1a08b9f2 [file] [log] [blame]
Linus Torvalds1da177e2005-04-16 15:20:36 -07001#ifndef __PPC64_VDSO_H__
2#define __PPC64_VDSO_H__
3
4#ifdef __KERNEL__
5
6/* Default link addresses for the vDSOs */
Benjamin Herrenschmidt547ee842005-04-16 15:24:35 -07007#define VDSO32_LBASE 0x100000
8#define VDSO64_LBASE 0x100000
Linus Torvalds1da177e2005-04-16 15:20:36 -07009
Anton Blanchard30d0b362009-07-13 20:53:51 +000010/* Default map addresses for 32bit vDSO */
Benjamin Herrenschmidt547ee842005-04-16 15:24:35 -070011#define VDSO32_MBASE VDSO32_LBASE
Linus Torvalds1da177e2005-04-16 15:20:36 -070012
Benjamin Herrenschmidt5d66da32005-11-16 13:54:32 +110013#define VDSO_VERSION_STRING LINUX_2.6.15
Linus Torvalds1da177e2005-04-16 15:20:36 -070014
15/* Define if 64 bits VDSO has procedure descriptors */
16#undef VDS64_HAS_DESCRIPTORS
17
18#ifndef __ASSEMBLY__
19
Linus Torvalds1da177e2005-04-16 15:20:36 -070020/* Offsets relative to thread->vdso_base */
21extern unsigned long vdso64_rt_sigtramp;
22extern unsigned long vdso32_sigtramp;
23extern unsigned long vdso32_rt_sigtramp;
24
Linus Torvalds1da177e2005-04-16 15:20:36 -070025#else /* __ASSEMBLY__ */
26
27#ifdef __VDSO64__
28#ifdef VDS64_HAS_DESCRIPTORS
29#define V_FUNCTION_BEGIN(name) \
30 .globl name; \
31 .section ".opd","a"; \
32 .align 3; \
33 name: \
34 .quad .name,.TOC.@tocbase,0; \
35 .previous; \
36 .globl .name; \
37 .type .name,@function; \
38 .name: \
39
40#define V_FUNCTION_END(name) \
41 .size .name,.-.name;
42
43#define V_LOCAL_FUNC(name) (.name)
44
45#else /* VDS64_HAS_DESCRIPTORS */
46
47#define V_FUNCTION_BEGIN(name) \
48 .globl name; \
49 name: \
50
51#define V_FUNCTION_END(name) \
52 .size name,.-name;
53
54#define V_LOCAL_FUNC(name) (name)
55
56#endif /* VDS64_HAS_DESCRIPTORS */
57#endif /* __VDSO64__ */
58
59#ifdef __VDSO32__
60
61#define V_FUNCTION_BEGIN(name) \
62 .globl name; \
63 .type name,@function; \
64 name: \
65
66#define V_FUNCTION_END(name) \
67 .size name,.-name;
68
69#define V_LOCAL_FUNC(name) (name)
70
71#endif /* __VDSO32__ */
72
73#endif /* __ASSEMBLY__ */
74
75#endif /* __KERNEL__ */
76
77#endif /* __PPC64_VDSO_H__ */