| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
MFC after: 3 days
|
|
|
|
|
|
|
|
|
|
|
| |
the separate .o for libc_pic.a. This prevents rtld from making the
symbol global.
Putting the stack_protector_compat.c into the public domain acknowledged
by kan.
Reviewed by: kan
MFC after: 2 weeks
|
|
|
|
| |
MFC after: 2 weeks
|
|
|
|
| |
MFC after: 2 weeks
|
|
|
|
| |
unblock SIGCANCEL which is needed by thread cancellation.
|
|
|
|
|
| |
Prefer MACHNE_CPUARCH to MACHINE_ARCH in most contexts where you want
to test of all the CPUs of a given family conform.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
atexit and __cxa_atexit handlers that are either installed by unloaded
dso, or points to the functions provided by the dso.
Use _rtld_addr_phdr to locate segment information from the address of
private variable belonging to the dso, supplied by crtstuff.c. Provide
utility function __elf_phdr_match_addr to do the match of address against
dso executable segment.
Call back into libthr from __cxa_finalize using weak
__pthread_cxa_finalize symbol to remove any atfork handler which
function points into unloaded object.
The rtld needs private __pthread_cxa_finalize symbol to not require
resolution of the weak undefined symbol at initialization time. This
cannot work, since rtld is relocated before sym_zero is set up.
Idea by: kan
Reviewed by: kan (previous version)
MFC after: 3 weeks
|
|
|
|
|
|
|
|
| |
fills struct dl_phdr_info for the shared object that contains the
specified address, if any.
Idea and reviewed by: kan
MFC after: 3 weeks
|
|
|
|
| |
MFC after: 3 days
|
| |
|
|
|
|
|
|
|
| |
userland SDT probes must be linked with libelf explicitly.
Requested by: kib
Sponsored by: The FreeBSD Foundation
|
|
|
|
|
|
|
|
| |
CLANG_PREFIX macro. This changes the default header search path when we
are building clang as part of cross-tools.
Submitted by: Dimitry Andric <dimitry at andric.com>
Reviewed by: freebsd-current
|
|
|
|
|
|
| |
instrumentation object (dtri.o).
Sponsored by: The FreeBSD Foundation
|
|
|
|
| |
Submitted by: kib
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
which does not know what is the state of interrupted system call, for
example, open() system call opened a file and the thread is still cancelled,
result is descriptor leak, there are other problems which can cause resource
leak or undeterminable side effect when a thread is cancelled. However, this
is no longer true in new implementation.
In defering mode, a thread is canceled if cancellation request is pending and
later the thread enters a cancellation point, otherwise, a later
pthread_cancel() just causes SIGCANCEL to be sent to the target thread, and
causes target thread to abort system call, userland code in libthr then checks
cancellation state, and cancels the thread if needed. For example, the
cancellation point open(), the thread may be canceled at start,
but later, if it opened a file descriptor, it is not canceled, this avoids
file handle leak. Another example is read(), a thread may be canceled at start
of the function, but later, if it read some bytes from a socket, the thread
is not canceled, the caller then can decide if it should still enable cancelling
or disable it and continue reading data until it thinks it has read all
bytes of a packet, and keeps a protocol stream in health state, if user ignores
partly reading of a packet without disabling cancellation, then second iteration
of read loop cause the thread to be cancelled.
An exception is that the close() cancellation point always closes a file handle
despite whether the thread is cancelled or not.
The old mechanism is still kept, for a functions which is not so easily to
fix a cancellation problem, the rough mechanism is used.
Reviewed by: kib@
|
|
|
|
| |
when cmd argument is F_SETLKW.
|
|
|
|
|
|
|
|
|
|
|
| |
number of host CPUs and osreldate.
This eliminates the last sysctl(2) calls from the dynamically linked image
startup.
No objections from: kan
Tested by: marius (sparc64)
MFC after: 1 month
|
|
|
|
|
|
|
|
|
|
|
|
| |
is acted upon, or when a thread calls pthread_exit(), the thread first
disables cancellation by setting its cancelability state to
PTHREAD_CANCEL_DISABLE and its cancelability type to
PTHREAD_CANCEL_DEFERRED. The cancelability state remains set to
PTHREAD_CANCEL_DISABLE until the thread has terminated.
It has no effect if a cancellation cleanup handler or thread-specific
data destructor routine changes the cancelability state to
PTHREAD_CANCEL_ENABLE.
|
|
|
|
|
|
| |
translating these manual pages. Minor corrections by me.
Submitted by: Nobuyuki Koganemaru <n-kogane@syd.odn.ne.jp>
|
|
|
|
|
|
|
|
| |
user in question (usually but not necessarily because we were called
with LOGIN_SETUSER). This plugs a hole where users could raise their
resource limits and expand their CPU mask.
MFC after: 3 weeks
|
|
|
|
| |
sprintf(3).
|
|
|
|
| |
Submitted by: Christoph Mallon <christoph.mallon@gmx.de>
|
|
|
|
|
|
|
| |
with h_errno.
Obtained from: NetBSD
MFC after: 2 weeks
|
|
|
|
|
|
|
|
|
| |
a very bad one, since the shift does not actually overflow. This is
a better example (assuming uint64_t = unsigned long long):
~0LLU >> 9 = 0x7fffffffffffffLLU
~0LLU >> 9 << 10 = 0xfffffffffffffc00LLU
~0LLU >> 9 << 10 >> 10 = 0x3fffffffffffffLLU
|
|
|
|
|
|
|
| |
overflowing shift to be larger than the original value, e.g.
(uint64_t)1 << 53 = 0x20000000000000
((uint64_t)1 << 53) << 10 = 0x8000000000000000
|
|
|
|
|
|
|
| |
switch. Since expand_number() does not accept negative numbers, switch
from int64_t to uint64_t; this makes it easier to check for overflow.
MFC after: 3 weeks
|
|
|
|
|
|
|
|
|
|
| |
have to return ERANGE and terminate with NS_RETURN.
- When gethostbyname_r(3) and the friends end with an error,
set errno to the value nss backend returns, and return errno
value.
PR: kern/131623
MFC after: 2 weeks
|
|
|
|
|
|
|
| |
read-only by default, meaning files copied can't be overwritten next time.
Reviewed by: imp
Approved by: ken (mentor)
|
|
|
|
|
| |
Submitted by: rpaulo
MFC after: 2 weeks
|
|
|
|
|
|
|
|
| |
o return the correct status in proc_wstatus()
o proc_read takes a void *
o correctly allocate the objs structure array
Sponsored by: The FreeBSD Foundation
|
| |
|
|
|
|
|
|
| |
Erwin fired up a ports build a couple of weeks ago and it seems the
following functions are not used by any of the 20k ports we have, which
makes me believe they don't have any purpose. Just remove them.
|
| |
|
|
|
|
|
| |
see problems described in the comment to:
http://www.freebsd.org/cgi/query-pr.cgi?pr=kern/128933
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
whitespace
Approved by: rpaulo
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
clang.
The general idea is that the vendor will not accept our compilation
patches and so disabling the warnings is the best way to go as it makes
future imports bearable.
Submitted by: Dimitry Andric <dimitry at andric.com>
Discussed with: das
|
|
|
|
|
|
|
| |
correct flags are being used (esp. NO_WERROR wrt clang).
Submitted by: Dimitry Andric <dimitry at andric.com>
Reviewed by: ru
|
|
|
|
|
| |
As discussed with kan@, since DTrace is the only consumer of libproc
right now, there's no need for a major shlib bump.
|
|
|
|
| |
Sponsored by: The FreeBSD Foundation
|
|
|
|
| |
Sponsored by: The FreeBSD Foundation
|
|
|
|
|
|
|
|
|
|
|
| |
* breakpoint setup support
* register query
* symbol to address mapping and vice-versa
* more misc utility functions based on their Solaris counterpart
Also, I've written some test cases.
Sponsored by: The FreeBSD Foundation
|
|
|
|
| |
Sponsored by: The FreeBSD Foundation
|
|
|
|
| |
Sponsored by: The FreeBSD Foundation
|
|
|
|
|
|
|
| |
This is not yet enabled in the build because I also need to import a new
version of libproc.
Sponsored by: The FreeBSD Foundation
|
|
|
|
|
|
| |
PR: docs/148891
Submitted by: olgeni
MFC after: 1 week
|