History log of /openbsd-src/lib/csu/alpha/md_init.h (Results 1 – 13 of 13)
Revision Date Author Comments
# 1e43641e 18-Nov-2023 deraadt <deraadt@openbsd.org>

crt0 uses a helper function in a MD src/libexec/ld.so .h file (rather than
reproducing the relevant defines and code in a different place) to perform
minor relocations. If things go very wrong, it w

crt0 uses a helper function in a MD src/libexec/ld.so .h file (rather than
reproducing the relevant defines and code in a different place) to perform
minor relocations. If things go very wrong, it would call _dl_exit() --
a locally defined crt0 function which is syscall exit(2). We don't need
to call exit(2) for this obscure case which doesn't happen and provides no
debugging information. An 'abort' is going to provide better information.
So let's change the function name to _dso_abort() and make it a single
illegal instruction.
ok guenther

show more ...


# 2bc3a8c0 15-Oct-2020 deraadt <deraadt@openbsd.org>

crt0 MD _dl_exit() performs syscall to SYS_exit directly, but then
some of these functions were returning. That makes the +1word address
a fairly strong and easily located gadget. Put a hard-trap
i

crt0 MD _dl_exit() performs syscall to SYS_exit directly, but then
some of these functions were returning. That makes the +1word address
a fairly strong and easily located gadget. Put a hard-trap
instruction after the syscall. This remains a gadget for 'terminal
system' calls (such as execve), but hey that's why we have pledge w/o
"exec" throughout the tree.
Quite surprisingly, hppa's delay-slot load of SYS_exit makes it the
safest of the bunch, not that this helps anyone.
ok kettenis

show more ...


# 9c558c11 14-Oct-2020 deraadt <deraadt@openbsd.org>

use symbolic SYS_exit instead of the value 1
ok kettenis


# c9db2c6c 22-Nov-2018 guenther <guenther@openbsd.org>

Make alpha less special: _dl_boot_bind() is written to complete
relocation of ld.so's GOT without using it, so _reloc_alpha_got()
merely made the call to _dl_boot_bind() from asm simpler...while
itse

Make alpha less special: _dl_boot_bind() is written to complete
relocation of ld.so's GOT without using it, so _reloc_alpha_got()
merely made the call to _dl_boot_bind() from asm simpler...while
itself being a call that required special handling.

diff and muild baking by miod@
ok guenther@

show more ...


# 344baaa7 11-Aug-2017 guenther <guenther@openbsd.org>

_dl_printf is no longer referenced by RELOC_{JMPREL,DYN,GOT}; delete the stub

ok kettenis@


# 48c2532c 19-Jan-2017 guenther <guenther@openbsd.org>

MD_START is now always ___start, so expand and eliminate it

ok phessler@ deraadt@


# 6cd8d357 07-Aug-2016 guenther <guenther@openbsd.org>

alpha already calculates &_DYNAMIC for the _reloc_alpha_got() call, so
save that and pass it to _dl_boot_bind() too


# 5af055cd 20-Mar-2016 guenther <guenther@openbsd.org>

Rearrange C runtime bits: now that ld.so exports environ and __progname,
move their definitions and initialization in static links to libc.a
Make crt0 always invoke a new func _csu_finish() in libc t

Rearrange C runtime bits: now that ld.so exports environ and __progname,
move their definitions and initialization in static links to libc.a
Make crt0 always invoke a new func _csu_finish() in libc to process the auxv
and to either register the ld.so cleanup function (in dynamic links) or
initialize environ and __progname and do MC_DISABLE_KBIND (in static links).
In libc, get pagesize from auxv; cache that between getpagesize() and
sysconf(_SC_PAGESIZE)

ok mpi@ "good time" deraadt@

show more ...


# d5d4315e 13-Mar-2016 guenther <guenther@openbsd.org>

crt0.c is already setting environ, so don't set it in MD_START_SETUP

ok kettenis@ mpi@


# 0a8a9c34 01-Sep-2015 guenther <guenther@openbsd.org>

In static binaries, invoke kbind() once to disable it.

With much assistance from miod@
ok deraadt@@


# 2f7dfe5d 27-Dec-2014 kettenis <kettenis@openbsd.org>

Static PIE support for alpha.

This adds alpha-specific first-pass GOT relocation code to boot.h.
The assembly code is pure magic. The numeric register
names don't make it easier to understand (or c

Static PIE support for alpha.

This adds alpha-specific first-pass GOT relocation code to boot.h.
The assembly code is pure magic. The numeric register
names don't make it easier to understand (or compare with the
equivalent ld.so code). Unfortunately the assembler only understands
a few symbolic register names.

Renames the crt0.o entry point to __start. Our compiler was already using
__start and the linker will soon follow.

ok kurt@

show more ...


# 453b49cd 03-Dec-2013 guenther <guenther@openbsd.org>

Merge the per-arch crt0.c files into common_elf/crt0.c, with MD macros in
the md_init.h files.

Worked out with and ok miod@; ok matthew@


# 8d0ba7c9 08-Jan-2004 drahn <drahn@openbsd.org>

__init/__fini handling on ELF has not been correct. It is supposed to
be a section which code stubs (branches) can be added to initialize/destructor
This adds MD stubs to allow this to operate as exp

__init/__fini handling on ELF has not been correct. It is supposed to
be a section which code stubs (branches) can be added to initialize/destructor
This adds MD stubs to allow this to operate as expected. should fix wine
and behave according to ELF specs. ok miod@

show more ...