Reorder inline assembly arguments temp2, temp, value and texp to follow
the st(0), st(1), etc. style.
Also mark the temp2 variable as volatile to workaround another clang
bug.
This allows clang to buildworld FreeBSD/i386.
Submitted by: dim
the first line of a script exceeded MAXSHELLCMDLEN characters, then
exec_imgact_shell() silently truncated the line and passed on the truncated
interpreter name or argument. Now, exec_imgact_shell() will fail and return
ENOEXEC, which is the commonly used errno among Unix variants for this type
of error. (2) Previously, exec_imgact_shell()'s check on the length of the
interpreter's name was ineffective. In other words, exec_imgact_shell()
could not possibly fail and return ENAMETOOLONG. The reason being that the
length of the interpreter name had to exceed MAXSHELLCMDLEN characters in
order that ENAMETOOLONG be returned. But, the search for the end of the
interpreter name stops after at most MAXSHELLCMDLEN - 2 characters are
scanned. (In the end, this particular error is eventually discovered
outside of exec_imgact_shell() and ENAMETOOLONG is returned. So, the real
effect of this second change is that the error is detected earlier, in
exec_imgact_shell().)
Update the definition of MAXINTERP to the actual limit on the size of
the interpreter name that has been in effect since r142453 (from
2005).
In collaboration with: kib
whether asynchronous mode is turned on or not, this always gives us a
chance to decide whether thread should be canceled or not in
cancellation points.
acl_is_trivial_np(3) properly recognize the new trivial ACLs. From
the user point of view, that means "ls -l" no longer shows plus signs
for all the files when running ZFS v28.
files and directories were already added/removed in the upstream
repository, but were not added/removed here, when the previous snapshot
was imported.
Note: I did not import the file test/Lexer/conflict-marker.c, because it
contains merge conflict markers on purpose, which upsets our pre-commit
hooks.
Approved by: rpaulo (mentor)
defer-mode cancellation works, asynchrnous mode does not work because
it lacks of libuwind's support. stack unwinding is not enabled unless
LIBTHR_UNWIND_STACK is defined in Makefile.
For all libthr contexts, use ${MACHINE_CPUARCH}
for all libc contexts, use ${MACHINE_ARCH} if it exists, otherwise use
${MACHINE_CPUARCH}
Move some common code up a layer (the .PATH statement was the same in
all the arch submakefiles).
# Hope she hasn't busted powerpc64 with this...
add a wrapper for it in libc and rework the code in libthr, the
system call still can return EINTR, we keep this feature.
Discussed on: thread
Reviewed by: jilles
objects inside one ELF section, which prevents the creation of a ELF
section with mixed data types. For example, gcc LTO use libelf to
create a .gnu_lto_XXX section that contains integers and a string
table, which doesn't work with our libelf implementation.
The changes made in this commit include:
* Allow Elf_Data type to be different than section type.
* Relax Elf_Data alignment check.
* Align each Elf_Data by their own alignment instead of section alignment.
MFC after: 1 month
This adds a new "arrow" key "delete" corresponding to the kD termcap value.
It only works if that is a sequence such as "\033[3~"; if it is "\177", the
em-delete-prev-char or ed-delete-prev-char from the single-character
mappings remains. It turns out that most terminals (xterm and alikes,
syscons in xterm mode) produce "\033[3~" by default so <Delete> has the
expected effect.
This also means that things need to be considerably misconfigured for
<Backspace> to perform a <Delete> action.
This allows the nfs_getrootfh() function to return the
correct file handle size to pxe.c for pxeboot. It also
results in NFSv2 no longer being used by default anywhere
in FreeBSD. If built with OLD_NFSV2 defined, the old
code that predated this patch will be built and NFSv2
will be used.
Tested by: danny at cs.huji.ac.il
MFC after: 2 weeks
module private type, when private type mutex is locked/unlocked, thread
critical region is entered or leaved. These changes makes fork()
async-signal safe which required by POSIX. Note that user's atfork handler
still needs to be async-signal safe, but it is not problem of libthr, it
is user's responsiblity.
some cases we want to improve:
1) if a thread signal got a signal while in cancellation point,
it is possible the TDP_WAKEUP may be eaten by signal handler
if the handler called some interruptibly system calls.
2) In signal handler, we want to disable cancellation.
3) When thread holding some low level locks, it is better to
disable signal, those code need not to worry reentrancy,
sigprocmask system call is avoided because it is a bit expensive.
The signal handler wrapper works in this way:
1) libthr installs its signal handler if user code invokes sigaction
to install its handler, the user handler is recorded in internal
array.
2) when a signal is delivered, libthr's signal handler is invoke,
libthr checks if thread holds some low level lock or is in critical
region, if it is true, the signal is buffered, and all signals are
masked, once the thread leaves critical region, correct signal
mask is restored and buffered signal is processed.
3) before user signal handler is invoked, cancellation is temporarily
disabled, after user signal handler is returned, cancellation state
is restored, and pending cancellation is rescheduled.