Displaying 19 results from an estimated 19 matches for "at_sysinfo".
2014 Apr 09
0
[klibc:master] Move architecture-specific initialization to arch/
...18 @@
+/*
+ * arch/i386/archinit.c
+ *
+ * Architecture-specific libc initialization
+ */
+
+#include <stdint.h>
+#include <klibc/compiler.h>
+#include <elf.h>
+#include <sys/auxv.h>
+
+extern void (*__syscall_entry)(int, ...);
+
+void __libc_archinit(void)
+{
+ if (__auxval[AT_SYSINFO])
+ __syscall_entry = (void (*)(int, ...)) __auxval[AT_SYSINFO];
+}
diff --git a/usr/klibc/libc_init.c b/usr/klibc/libc_init.c
index 1c6180b..c54d022 100644
--- a/usr/klibc/libc_init.c
+++ b/usr/klibc/libc_init.c
@@ -25,6 +25,7 @@
#include <klibc/compiler.h>
#include <elf.h>
#includ...
2014 Jan 25
0
[klibc:master] i386: use the vdso for system calls on i386
...087f95..1c6180b 100644
--- a/usr/klibc/libc_init.c
+++ b/usr/klibc/libc_init.c
@@ -90,6 +90,15 @@ __noreturn __libc_init(uintptr_t * elfdata, void (*onexit) (void))
__page_size = page_size = __auxval[AT_PAGESZ];
+#ifdef __i386__
+ {
+ extern void (*__syscall_entry)(int, ...);
+ if (__auxval[AT_SYSINFO])
+ __syscall_entry = (void (*)(int, ...))
+ __auxval[AT_SYSINFO];
+ }
+#endif
+
#if __GNUC__ >= 4
/* unsigned int is 32 bits on all our architectures */
page_shift = __builtin_clz(page_size) ^ 31;
2015 Nov 05
0
[klibc:master] Inline __arch_libcinit()
...hinit.h
@@ -1,5 +1,5 @@
/*
- * arch/i386/archinit.c
+ * arch/i386/include/klibc/archinit.h
*
* Architecture-specific libc initialization
*/
@@ -11,7 +11,7 @@
extern void (*__syscall_entry)(int, ...);
-void __libc_archinit(void)
+static inline void __libc_archinit(void)
{
if (__auxval[AT_SYSINFO])
__syscall_entry = (void (*)(int, ...)) __auxval[AT_SYSINFO];
diff --git a/usr/include/klibc/sysconfig.h b/usr/include/klibc/sysconfig.h
index ab947c0..c91d5b8 100644
--- a/usr/include/klibc/sysconfig.h
+++ b/usr/include/klibc/sysconfig.h
@@ -219,7 +219,7 @@
/*
* _KLIBC_HAS_ARCHINIT
*
- *...
2014 Jan 25
0
[klibc:master] auxv: convert auxiliary vector into an array; define getauxval()
...ions(-)
diff --git a/usr/include/sys/auxv.h b/usr/include/sys/auxv.h
new file mode 100644
index 0000000..08fcfcf
--- /dev/null
+++ b/usr/include/sys/auxv.h
@@ -0,0 +1,16 @@
+#ifndef _SYS_AUXV_H
+#define _SYS_AUXV_H
+
+#include <klibc/compiler.h>
+#include <elf.h>
+
+#define _AUXVAL_MAX AT_SYSINFO_EHDR
+
+__extern unsigned long __auxval[_AUXVAL_MAX];
+
+__static_inline unsigned long getauxval(unsigned long __t)
+{
+ return (__t >= _AUXVAL_MAX) ? 0 : __auxval[__t];
+}
+
+#endif /* _SYS_AUXV_H */
diff --git a/usr/include/sys/elfcommon.h b/usr/include/sys/elfcommon.h
index 300ff4e..603b0ce 1...
2007 Mar 05
7
[PATCH 2/10] linux 2.6.18: COMPAT_VDSO
This adds support for CONFIG_COMPAT_VDSO. As this will certainly raise
questions, I left in the code needed for an alternative approach (which
requires mode C code, but less build script changes).
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Index: head-2007-02-27/arch/i386/Kconfig
===================================================================
---
2007 Mar 05
7
[PATCH 2/10] linux 2.6.18: COMPAT_VDSO
This adds support for CONFIG_COMPAT_VDSO. As this will certainly raise
questions, I left in the code needed for an alternative approach (which
requires mode C code, but less build script changes).
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Index: head-2007-02-27/arch/i386/Kconfig
===================================================================
---
2007 Mar 05
7
[PATCH 2/10] linux 2.6.18: COMPAT_VDSO
This adds support for CONFIG_COMPAT_VDSO. As this will certainly raise
questions, I left in the code needed for an alternative approach (which
requires mode C code, but less build script changes).
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Index: head-2007-02-27/arch/i386/Kconfig
===================================================================
---
2007 Apr 18
4
[patch 0/2] Updates to compat VDSOs
Hi Andi,
Here's a couple of patches to fix up COMPAT_VDSO:
The first is a straightforward implementation of Jan's original idea
of relocating the VDSO to match its mapped location. Unlike Jan and
Zach's version, I changed it to relocate based on the phdrs rather than
the sections; the result is pleasantly compact.
The second patch takes advantage of the fact that all the
2007 Apr 18
4
[patch 0/2] Updates to compat VDSOs
Hi Andi,
Here's a couple of patches to fix up COMPAT_VDSO:
The first is a straightforward implementation of Jan's original idea
of relocating the VDSO to match its mapped location. Unlike Jan and
Zach's version, I changed it to relocate based on the phdrs rather than
the sections; the result is pleasantly compact.
The second patch takes advantage of the fact that all the
2007 Apr 18
1
[PATCH] Gerd Hoffman's move-vsyscall-into-user-address-range patch
...el_vsyscall)
extern void __kernel_vsyscall;
+#define ARCH_HAS_SETUP_ADDITIONAL_PAGES
+struct linux_binprm;
+extern int arch_setup_additional_pages(struct linux_binprm *bprm,
+ int executable_stack);
+
#define ARCH_DLINFO \
do { \
NEW_AUX_ENT(AT_SYSINFO, VSYSCALL_ENTRY); \
diff -urpN --exclude TAGS -X /home/rusty/devel/kernel/kernel-patches/current-dontdiff --minimal linux-2.6.17-rc4/include/asm-i386/fixmap.h working-2.6.17-rc4-vsyscall-above-stack/include/asm-i386/fixmap.h
--- linux-2.6.17-rc4/include/asm-i386/fixmap.h 2006-03-23 12:43:10.0000000...
2007 Apr 18
1
[PATCH] Gerd Hoffman's move-vsyscall-into-user-address-range patch
...el_vsyscall)
extern void __kernel_vsyscall;
+#define ARCH_HAS_SETUP_ADDITIONAL_PAGES
+struct linux_binprm;
+extern int arch_setup_additional_pages(struct linux_binprm *bprm,
+ int executable_stack);
+
#define ARCH_DLINFO \
do { \
NEW_AUX_ENT(AT_SYSINFO, VSYSCALL_ENTRY); \
diff -urpN --exclude TAGS -X /home/rusty/devel/kernel/kernel-patches/current-dontdiff --minimal linux-2.6.17-rc4/include/asm-i386/fixmap.h working-2.6.17-rc4-vsyscall-above-stack/include/asm-i386/fixmap.h
--- linux-2.6.17-rc4/include/asm-i386/fixmap.h 2006-03-23 12:43:10.0000000...
2007 Apr 18
4
[patch 0/4] Clean up asm/bugs.h, identify_cpu() and update COMPAT_VDSO
Hi Andi,
Four patches:
- clean up asm/bugs.h, by moving all the C code into its own C file
- split identify_cpu() into boot and secondary variants, so that
boot-time setup functions can be marked __init
- repost of the COMPAT_VDSO patches with a bit more robustness from
unknown DT_tags, and functions marked __init, since all this is
boot-time only setup.
Thanks,
J
--
2007 Apr 18
4
[patch 0/4] Clean up asm/bugs.h, identify_cpu() and update COMPAT_VDSO
Hi Andi,
Four patches:
- clean up asm/bugs.h, by moving all the C code into its own C file
- split identify_cpu() into boot and secondary variants, so that
boot-time setup functions can be marked __init
- repost of the COMPAT_VDSO patches with a bit more robustness from
unknown DT_tags, and functions marked __init, since all this is
boot-time only setup.
Thanks,
J
--
2007 Apr 18
2
[RFC, PATCH] Fixup COMPAT_VDSO to work with CONFIG_PARAVIRT
...;
+
+#define ARCH_HAS_SETUP_ADDITIONAL_PAGES
extern int arch_setup_additional_pages(struct linux_binprm *bprm,
int executable_stack);
-#endif
=
extern unsigned int vdso_enabled;
=
#define ARCH_DLINFO \
do if (vdso_enabled) { \
NEW_AUX_ENT(AT_SYSINFO, VDSO_ENTRY); \
- NEW_AUX_ENT(AT_SYSINFO_EHDR, VDSO_COMPAT_BASE); \
+ NEW_AUX_ENT(AT_SYSINFO_EHDR, VDSO_CURRENT_BASE);\
} while (0)
=
#endif
Index: linux-2.6.21/include/asm-i386/fixmap.h
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=...
2007 Apr 18
2
[RFC, PATCH] Fixup COMPAT_VDSO to work with CONFIG_PARAVIRT
...;
+
+#define ARCH_HAS_SETUP_ADDITIONAL_PAGES
extern int arch_setup_additional_pages(struct linux_binprm *bprm,
int executable_stack);
-#endif
=
extern unsigned int vdso_enabled;
=
#define ARCH_DLINFO \
do if (vdso_enabled) { \
NEW_AUX_ENT(AT_SYSINFO, VDSO_ENTRY); \
- NEW_AUX_ENT(AT_SYSINFO_EHDR, VDSO_COMPAT_BASE); \
+ NEW_AUX_ENT(AT_SYSINFO_EHDR, VDSO_CURRENT_BASE);\
} while (0)
=
#endif
Index: linux-2.6.21/include/asm-i386/fixmap.h
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=...
2012 Jan 29
5
[PATCH 0/2 v3] mkstemp() and m68k support
Hi,
after a year, I decided to hack on klibc again. I?ve reworked
both the patch to add mkstemp(), discussing to use AT_RANDOM
as cheap entropy source on IRC (if there will ever be another
entropy consumer, I can quickly write a minimal arc4random()
seeded from it, as it has only 16 octets), capable of making
a working mksh (static and shared) on amd64/xen, and the m68k
support code, leading to
2007 Apr 18
2
[PATCH] exec-shield style vdso move.
...YSCALL_BASE)
extern void __kernel_vsyscall;
+#define ARCH_HAS_SETUP_ADDITIONAL_PAGES
+struct linux_binprm;
+extern int arch_setup_additional_pages(struct linux_binprm *bprm,
+ int executable_stack);
+
#define ARCH_DLINFO \
do { \
NEW_AUX_ENT(AT_SYSINFO, VSYSCALL_ENTRY); \
@@ -148,15 +158,15 @@ do { \
* Dumping its extra ELF program headers includes all the other information
* a debugger needs to easily find how the vsyscall DSO was being used.
*/
-#define ELF_CORE_EXTRA_PHDRS (VSYSCALL_EHDR->e_phnum)
+#define ELF_CORE_EXTRA_PHDRS...
2007 Apr 18
2
[PATCH] exec-shield style vdso move.
...YSCALL_BASE)
extern void __kernel_vsyscall;
+#define ARCH_HAS_SETUP_ADDITIONAL_PAGES
+struct linux_binprm;
+extern int arch_setup_additional_pages(struct linux_binprm *bprm,
+ int executable_stack);
+
#define ARCH_DLINFO \
do { \
NEW_AUX_ENT(AT_SYSINFO, VSYSCALL_ENTRY); \
@@ -148,15 +158,15 @@ do { \
* Dumping its extra ELF program headers includes all the other information
* a debugger needs to easily find how the vsyscall DSO was being used.
*/
-#define ELF_CORE_EXTRA_PHDRS (VSYSCALL_EHDR->e_phnum)
+#define ELF_CORE_EXTRA_PHDRS...
2007 Jan 09
0
Wine release 0.9.29
...e the Mach thread port as thread id on Mac OS.
server: Implement process control using Mach primitives for Mac OS.
configure: Added a generic macro for checking for Mingw programs.
configure: Use the correct ar tool when building Mingw import libraries.
preloader: Reset both AT_SYSINFO and AT_SYSINFO_EHDR when one of them conflicts.
Revert "wined3d: Simplify the get_write_mask and get_swizzle functions."
gdi32: Avoid leaking a handle in MFDRV_ExtSelectClipRgn.
make_makefiles: Properly skip dlls marked with MKDLL_SKIP.
Use GetDC instead of CreateD...