summaryrefslogtreecommitdiff
path: root/usr/src/uts/common/sys/exec.h
diff options
context:
space:
mode:
authoredp <none@none>2007-06-11 17:48:55 -0700
committeredp <none@none>2007-06-11 17:48:55 -0700
commit396a100be44de1a20eabaee45519160dea8333b4 (patch)
tree19a7304f9217c9b5d8b1c334213d942d9977db46 /usr/src/uts/common/sys/exec.h
parent846a903d89a619feab07525059670a4203e100f8 (diff)
downloadillumos-joyent-396a100be44de1a20eabaee45519160dea8333b4.tar.gz
6562537 brandz elfexec support code assumes 32-bit elf binaries
Diffstat (limited to 'usr/src/uts/common/sys/exec.h')
-rw-r--r--usr/src/uts/common/sys/exec.h26
1 files changed, 24 insertions, 2 deletions
diff --git a/usr/src/uts/common/sys/exec.h b/usr/src/uts/common/sys/exec.h
index de8a940db7..d1243a926f 100644
--- a/usr/src/uts/common/sys/exec.h
+++ b/usr/src/uts/common/sys/exec.h
@@ -19,7 +19,7 @@
* CDDL HEADER END
*/
/*
- * Copyright 2006 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2007 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
@@ -38,6 +38,7 @@
#include <sys/model.h>
#include <sys/uio.h>
#include <sys/corectl.h>
+#include <sys/machelf.h>
#ifdef __cplusplus
extern "C" {
@@ -105,7 +106,7 @@ typedef struct uarg {
uintptr_t thrptr;
char *emulator;
char *brandname;
- auxv32_t *brand_auxp; /* starting user addr of brand auxvs on stack */
+ char *auxp_brand_phdr; /* addr of brand phdr auxv on user stack */
} uarg_t;
/*
@@ -226,6 +227,27 @@ extern void setregs(uarg_t *);
extern void exec_set_sp(size_t);
/*
+ * Utility functions for branded process executing
+ */
+#if !defined(_ELF32_COMPAT)
+/*
+ * When compiling 64-bit kernels we don't want these definitions included
+ * when compiling the 32-bit compatability elf code in the elfexec module.
+ */
+extern int elfexec(vnode_t *, execa_t *, uarg_t *, intpdata_t *, int,
+ long *, int, caddr_t, cred_t *, int);
+extern int mapexec_brand(vnode_t *, uarg_t *, Ehdr *, Addr *,
+ intptr_t *, caddr_t, int *, caddr_t *, caddr_t *, size_t *);
+#endif /* !_ELF32_COMPAT */
+
+#if defined(_LP64)
+extern int elf32exec(vnode_t *, execa_t *, uarg_t *, intpdata_t *, int,
+ long *, int, caddr_t, cred_t *, int);
+extern int mapexec32_brand(vnode_t *, uarg_t *, Elf32_Ehdr *, Elf32_Addr *,
+ intptr_t *, caddr_t, int *, caddr_t *, caddr_t *, size_t *);
+#endif /* _LP64 */
+
+/*
* Utility functions for exec module core routines:
*/
extern int core_seg(proc_t *, vnode_t *, offset_t, caddr_t,