hselasky [Tue, 28 Jan 2014 09:55:07 +0000 (09:55 +0000)]
When detaching a [USB] keyboard, keys might still be pressed. Ensure
that all pressed keys are released before completing the USB keyboard
detach. This will prevent so-called "ghost-keys" from appearing after
that the USB device generating the key event(s) has been detached.
csjp [Tue, 28 Jan 2014 01:49:49 +0000 (01:49 +0000)]
Allow sigwait(2) in capabilities mode.
It's common for multi-threaded processes to create a thread for
the purpose of synchronously processing signals. Allow such processes to
utilize a capabilities sandbox.
jhb [Mon, 27 Jan 2014 22:26:15 +0000 (22:26 +0000)]
Remove support for legacy PCI devices. These haven't been needed since
support for LPC uart devices was added and it conflicts with upcoming
patches to add PCI INTx support.
jilles [Sun, 26 Jan 2014 22:49:24 +0000 (22:49 +0000)]
login: Clean up PAM and audit, then exit, on SIGHUP and SIGTERM.
This avoids leaving stale entries in utmpx after the connection is closed on
an open login session. It also allows a clean way (SIGTERM) to forcibly
terminate a user's terminal session.
This does not affect the situation for "hung" processes after the connection
is closed. The foreground process group receives SIGHUP and the tty becomes
inaccessible.
Also replace all use of the obsolete signal() function with sigaction() (not
only the part where it is actually required: SIGHUP and SIGTERM must mask
the other as well when caught).
imp [Sun, 26 Jan 2014 04:57:58 +0000 (04:57 +0000)]
Before resetting the USART, delay a bit to allow the transmitter to
finish the current character to drain to avoid glitching. Also,
simplify the code a smidge.
pfg [Sun, 26 Jan 2014 02:36:06 +0000 (02:36 +0000)]
gcc: Add support for -Wmissing-prototypes in C++
Support for warnings about missing prototypes in C++ was added by Apple
GCC (Radar 6261539). Most of the code crept into r260311 so it felt
natural to make use of it.
imp [Sat, 25 Jan 2014 21:52:19 +0000 (21:52 +0000)]
Bus space handles need to be the VA of the requested resource, not the
rounded page VA. Correct so the DBGU device can be mapped for FDT
console since it isn't on a page boundary.
neel [Sat, 25 Jan 2014 20:58:05 +0000 (20:58 +0000)]
Support level triggered interrupts with VT-x virtual interrupt delivery.
The VMCS field EOI_bitmap[] is an array of 256 bits - one for each vector.
If a bit is set to '1' in the EOI_bitmap[] then the processor will trigger
an EOI-induced VM-exit when it is doing EOI virtualization.
The EOI-induced VM-exit results in the EOI being forwarded to the vioapic
so that level triggered interrupts can be properly handled.
dim [Sat, 25 Jan 2014 16:35:56 +0000 (16:35 +0000)]
Pull in r195679 from upstream llvm trunk:
Don't use nopl in cpus that don't support it.
Patch by Mikulas Patocka. I added the test. I checked that for cpu names that
gas knows about, it also doesn't generate nopl.
The modified cpus:
i686 - there are i686-class CPUs that don't have nopl: Via c3, Transmeta
Crusoe, Microsoft VirtualBox - see
https://bbs.archlinux.org/viewtopic.php?pid=775414
k6, k6-2, k6-3, winchip-c6, winchip2 - these are 586-class CPUs
via c3 c3-2 - see https://bugs.archlinux.org/task/19733 as a proof that
Via c3 and c3-Nehemiah don't have nopl
ache [Sat, 25 Jan 2014 02:16:09 +0000 (02:16 +0000)]
Bad timespec_subtract() calculations produce negative tv_nsec on i386
which cause EINVAL returned from nanosleep() which cause loop in
cron_sleep() and making all cron jobs to start about 30 seconds earlier
(which cause f.e. logfiles rotation by newsyslog delayed by 1 hour).
Use simple and proved calculations from kernel's timespecsub() instead.
andrew [Fri, 24 Jan 2014 20:51:56 +0000 (20:51 +0000)]
Correct the alignment of sp through functions that use UNWINDSVCFRAME. We
were incorrectly adding the trap frame padding to the stack pointer after
reading it's value and unaligning it.
alc [Fri, 24 Jan 2014 19:08:42 +0000 (19:08 +0000)]
In an effort to diagnose possible corruption of struct vm_page on some
sparc64 machines make the page queue assert in vm_page_dequeue() more
precise. While I'm here switch the page lock assert to the newer style.
asomers [Fri, 24 Jan 2014 18:01:46 +0000 (18:01 +0000)]
Fix the build so -DNO_TESTS is passed in various phases that don't
require tests in order to build or install. Crucially, don't try to
install tests during the lib32 install phase. This commit supersedes
r261081, which fixed the lib32 install phase problem, but didn't fix
other phases.
Submitted by: Garrett Cooper
Reviewed by: sjg
MFC after: 13 days
jilles [Fri, 24 Jan 2014 16:40:51 +0000 (16:40 +0000)]
sh: Solve the alias recursion problem in a less hackish way.
Add the space to avoid alias recursion when the alias is expanded, not when
it is added.
As a result, displaying an alias via command -v, command -V or type no
longer erroneously appends a space. Adjust the tests so they now require
this bug to be absent.
avg [Fri, 24 Jan 2014 15:04:02 +0000 (15:04 +0000)]
dtrace: remove unexplained 16MB limitation from dt_alloc/dt_zalloc
The limitation was introduced in r178556 without any note or comment.
It seems pretty artificial and now it leads to problems like the following:
$ dtrace -x bufsize=17m -n ...
dtrace: processing aborted: Memory allocation failure
OpenSolaris and illumos never had this limitation.
jhibbits [Fri, 24 Jan 2014 02:57:00 +0000 (02:57 +0000)]
Fix 32-bit signal handling on ppc64. This was broken when the PSL_USERSTATIC
macro was changed. Since copying 64-bit srr1 into 32-bit srr1 drops the upper
32 bits, any bits set in the context were dropped, meaning the context check
fails. Since 32-bit set_context can't change those bits anyway, copy the ones
from the current context (td->td_frame) before calling set_context().
ian [Fri, 24 Jan 2014 00:42:18 +0000 (00:42 +0000)]
Be more robust with malformed interrupt config data. Instead of crashing
or going into a near-infinite loop, warn and make potentially-reasonable
assumptions.
ae [Thu, 23 Jan 2014 19:55:02 +0000 (19:55 +0000)]
In gctl_copyin() remove unused error variable.
geom_alloc_copyin() can't return ENOMEM, so describe its fail as bad
control request. Add check for NULL pointer in gctl_dump(), since it
can be NULL when geom_alloc_copyin() failed.
ae [Thu, 23 Jan 2014 19:31:17 +0000 (19:31 +0000)]
Fix typo in r261084.
Add to the gctl_error() an ability to specify error description even
if numeric error code is already specified. Also by default set
error code to EINVAL.
asomers [Thu, 23 Jan 2014 17:26:28 +0000 (17:26 +0000)]
Replace the old unix_seqpacket and unix_seqpacket_exercise tests, which
were a little broken and not automatable, with unix_seqpacket_test.
It's coverage is a superset of the old tests and it uses ATF. It
includes test cases for bugs kern/185813 and kern/185812.
neel [Thu, 23 Jan 2014 06:06:50 +0000 (06:06 +0000)]
Set "Interrupt Window Exiting" in the case where there is a vector to be
injected into the vcpu but the VM-entry interruption information field
already has the valid bit set.
Pointed out by: David Reed (david.reed@tidalscale.com)
mav [Wed, 22 Jan 2014 22:19:53 +0000 (22:19 +0000)]
Mostly revert r260267 and hopefully really fix the original problem.
The latest draft of SBC-3 tells: "A MAXIMUM UNMAP LBA COUNT field set to
a non-zero value indicates the maximum number of LBAs that may be unmapped
by an UNMAP command." To me it does not sound like that limit is set per
single descriptor, but rather per all command. And I have at least one
device that behaves exactly that way. This patch fixes the problem there.
imp [Wed, 22 Jan 2014 22:01:29 +0000 (22:01 +0000)]
Clean up HL201 config (for the hot-e 201 and 101 models from thinlinx).
Make comments match parameters
Add options for early printf so we get regression build testing on it.
Add preview of options for FDT support coming soon (I hope)
imp [Wed, 22 Jan 2014 21:20:08 +0000 (21:20 +0000)]
Implement generic support for early printf. Thought I can't find the
paper trail now, this patch is similar to one posted for one of the
preliminary versions of a new armv6 port. I took them and made them
more generic. Option not enabled by default since each board/port has
to provide its own eputc, and possibly do other things as well...