openbsd
8 years agoRemove code for Intel 80219/80321 xscale processors used by armish.
jsg [Sun, 14 Aug 2016 11:30:54 +0000 (11:30 +0000)]
Remove code for Intel 80219/80321 xscale processors used by armish.
Generic xscale support and support for pxa2x0 used by zaurus remains.

8 years agoFix setting the SMP bit in the Auxiliary Control Register. The old code was
kettenis [Sun, 14 Aug 2016 10:36:47 +0000 (10:36 +0000)]
Fix setting the SMP bit in the Auxiliary Control Register.  The old code was
toggling the bit, clearing it when already set.  On Cortex-A7 setting the SMP
bit is essential since without it the CPU doesn't actually use its caches.

The SMP bit supposed to be set before turning on the caches and the MMU, so
move the setting of the Auxiliary Control Register before setting the
System Control Register.

ok jsg@

8 years agoAllow a bus_dmamap_sync() of length zero.
kettenis [Sun, 14 Aug 2016 10:32:17 +0000 (10:32 +0000)]
Allow a bus_dmamap_sync() of length zero.

ok tedu@

8 years agoXr encrypt(1) in the explanation of the -p option.
tb [Sun, 14 Aug 2016 09:52:08 +0000 (09:52 +0000)]
Xr encrypt(1) in the explanation of the -p option.

ok jmc

8 years agoshorten genpkey; ok guenther
jmc [Sun, 14 Aug 2016 09:02:52 +0000 (09:02 +0000)]
shorten genpkey; ok guenther

8 years agoRemove some annoying debug printfs to get rid of u_quad_t in cnmac.
visa [Sun, 14 Aug 2016 08:49:37 +0000 (08:49 +0000)]
Remove some annoying debug printfs to get rid of u_quad_t in cnmac.

8 years agoUtilize the TLB Execute-Inhibit bit with non-executable mappings on CPUs
visa [Sun, 14 Aug 2016 08:23:52 +0000 (08:23 +0000)]
Utilize the TLB Execute-Inhibit bit with non-executable mappings on CPUs
that support the Execute-Inhibit exception. This makes user space W^X
effective on Octeon Plus and later Octeon versions.

Feedback from miod@, thanks!
No objection from deraadt@

8 years agou_quad_t -> uint64_t
dlg [Sun, 14 Aug 2016 04:51:29 +0000 (04:51 +0000)]
u_quad_t -> uint64_t

de is amazing(tm). it really should be cut back and simplified a bit.

8 years agoReplace u_quad_t with unsigned long long and replace "uqd" with "ull" in
guenther [Sun, 14 Aug 2016 04:47:52 +0000 (04:47 +0000)]
Replace u_quad_t with unsigned long long and replace "uqd" with "ull" in
function names to match.  Pull some tangled assignments out of conditions
and use >>= where possible.

ok millert@

8 years agoMark the relro/got section as read-only before setting up the environment
guenther [Sun, 14 Aug 2016 04:30:39 +0000 (04:30 +0000)]
Mark the relro/got section as read-only before setting up the environment
to minimize the amount of code run without it RO.

8 years agoTurning off relro shouldn't insert padding into the middle of the relro
guenther [Sun, 14 Aug 2016 04:25:27 +0000 (04:25 +0000)]
Turning off relro shouldn't insert padding into the middle of the relro
section; remove the PAD_GOT0 use that I should have deleted before.  This
caused ld.so crashes on arm when building binutils.

critical debugging observations by kettenis@

8 years agochange some types in bio from u_quad_t to uint64_t, and fix casts in
dlg [Sun, 14 Aug 2016 04:08:03 +0000 (04:08 +0000)]
change some types in bio from u_quad_t to uint64_t, and fix casts in
drivers that fill that field in too.

quad types are going away.

8 years agoreplace u_quad_t with uint64_t.
dlg [Sun, 14 Aug 2016 01:52:47 +0000 (01:52 +0000)]
replace u_quad_t with uint64_t.

guenther is proposing the removal of u_quad_t. uint64_t is more portable.

tested on a perc5 and perc6, no functional change.

8 years agouse -nosplit for AUTHORS: looks much better, to the point where i wonder why we don...
jmc [Sat, 13 Aug 2016 23:35:00 +0000 (23:35 +0000)]
use -nosplit for AUTHORS: looks much better, to the point where i wonder why we don;t just enforce this...

8 years agoAdd the shim to make dwge(4) attach to simplebus(4). This brings us
kettenis [Sat, 13 Aug 2016 22:07:01 +0000 (22:07 +0000)]
Add the shim to make dwge(4) attach to simplebus(4).  This brings us
working gigabit on the Allwinner A20.  Probably won't work yet on other
Allwinner SoCs due to differences in how the clocks get set up.

Based on an earlier diff from patrick@.

8 years agoAdd GMAC clock support. Based on an earlier diff from patrick@.
kettenis [Sat, 13 Aug 2016 21:48:44 +0000 (21:48 +0000)]
Add GMAC clock support.  Based on an earlier diff from patrick@.

8 years agoMissed a couple qaddr_t casts
guenther [Sat, 13 Aug 2016 21:28:09 +0000 (21:28 +0000)]
Missed a couple qaddr_t casts

8 years agoPassing in &_DYNAMIC appears to have stuck, so eliminate the extra
guenther [Sat, 13 Aug 2016 20:57:04 +0000 (20:57 +0000)]
Passing in &_DYNAMIC appears to have stuck, so eliminate the extra
variable

8 years agoEliminate pointless casts to qaddr_t of a value being assigned to a void*
guenther [Sat, 13 Aug 2016 20:53:17 +0000 (20:53 +0000)]
Eliminate pointless casts to qaddr_t of a value being assigned to a void*

ok kettenis@ krw@ natano@ dlg@ espie@

8 years agodwge(4)
kettenis [Sat, 13 Aug 2016 20:51:48 +0000 (20:51 +0000)]
dwge(4)

8 years agoAdd the core of the code for dwge(4), a driver for the Synopsis Designware
kettenis [Sat, 13 Aug 2016 20:35:57 +0000 (20:35 +0000)]
Add the core of the code for dwge(4), a driver for the Synopsis Designware
GMAC core which is used on the Allwinner A20 SoCs and later SoCs in the
Allwinner family.  Since this core is very likely to show up the base of
other devices, it gets to live here in dev/ic.

Ported from NetBSD (where it is named awge(4)) by patrick@.  Some further
fixes by me.

ok deraadt@

8 years agoshorten gendsa;
jmc [Sat, 13 Aug 2016 18:23:39 +0000 (18:23 +0000)]
shorten gendsa;

8 years ago%lld -> %llu for u_int64_t struct fields.
krw [Sat, 13 Aug 2016 17:51:25 +0000 (17:51 +0000)]
%lld -> %llu for u_int64_t struct fields.

8 years agoremove ssh1 server code; ok djm@
markus [Sat, 13 Aug 2016 17:47:40 +0000 (17:47 +0000)]
remove ssh1 server code; ok djm@

8 years agoAs the relevant struct's (e.g. tcpstat) use [u_]int64_t types, the
krw [Sat, 13 Aug 2016 17:36:04 +0000 (17:36 +0000)]
As the relevant struct's (e.g. tcpstat) use [u_]int64_t types, the
proper printf() format is %ll[ud], not the antediluvian %q[ud].
Reminded by guenther@'s proposed retirement of quad types.

ok tedu@

8 years agomodern interfaces should use modern speelings, so spell quad_t as int64_t.
tedu [Sat, 13 Aug 2016 17:05:02 +0000 (17:05 +0000)]
modern interfaces should use modern speelings, so spell quad_t as int64_t.

8 years agosync
deraadt [Sat, 13 Aug 2016 15:37:48 +0000 (15:37 +0000)]
sync

8 years agoRemove entries that are no longer needed.
kettenis [Sat, 13 Aug 2016 13:55:25 +0000 (13:55 +0000)]
Remove entries that are no longer needed.

8 years agoAvoid leaking memory if tls_config_set_alpn() is called multiple times
jsing [Sat, 13 Aug 2016 13:15:53 +0000 (13:15 +0000)]
Avoid leaking memory if tls_config_set_alpn() is called multiple times
(this was in the original commit, but got reverted in the recommit).

8 years agoLet libtls load the CA, certificate and key files for nc(1), now that it
jsing [Sat, 13 Aug 2016 13:09:10 +0000 (13:09 +0000)]
Let libtls load the CA, certificate and key files for nc(1), now that it
does this at the time the tls_config_set_*_file() function is called.

ok bluhm@

8 years agoLoad CA, certificate and key files into memory when the appropriate
jsing [Sat, 13 Aug 2016 13:05:51 +0000 (13:05 +0000)]
Load CA, certificate and key files into memory when the appropriate
tls_config_set_*_file() function is called. This allows us to immediately
propagate useful error messages, play more nicely with privsep/pledge and
have a single code path. Instead of always loading the default CA when
tls_config_new() is called, defer and only load the default CA when
tls_configure() is invoked, if a CA has not already been specified.

ok beck@ bluhm@

8 years agoSplit out the SSL options handling into a separate function, which makes
jsing [Sat, 13 Aug 2016 12:55:21 +0000 (12:55 +0000)]
Split out the SSL options handling into a separate function, which makes
for more readable code and reduces line wrapping. Also improve error
messages by adding tls_config_error() to errx() where appropriate.

ok jca@

8 years agoKill FUSE_ROOT_ID and use FUSE_ROOTINO instead. Also, remove one (ino_t)
natano [Sat, 13 Aug 2016 11:42:46 +0000 (11:42 +0000)]
Kill FUSE_ROOT_ID and use FUSE_ROOTINO instead. Also, remove one (ino_t)
cast from FUSE_ROOTINO, as it is already included in the #define.

ok kettenis

8 years agoUse regulalator API instead of private functions.
kettenis [Sat, 13 Aug 2016 11:08:58 +0000 (11:08 +0000)]
Use regulalator API instead of private functions.

8 years agoBuild ofw_regulator.o.
kettenis [Sat, 13 Aug 2016 10:58:45 +0000 (10:58 +0000)]
Build ofw_regulator.o.

8 years agoAdd a minimal regulator "framework".
kettenis [Sat, 13 Aug 2016 10:52:21 +0000 (10:52 +0000)]
Add a minimal regulator "framework".

ok jsg@, patrick@

8 years agoEven after switching from a pending head to the body, we have to
schwarze [Sat, 13 Aug 2016 09:14:56 +0000 (09:14 +0000)]
Even after switching from a pending head to the body, we have to
continue scanning upwards, because the enclosing block might already
be pending as well, e.g. .Bl .Bl .It Bo .El .It.
Tree corruption leading to a later NULL deref found by tb@ with afl(1).

8 years agoSimplify getprec() by using strchr(3) and strspn(3).
tb [Fri, 12 Aug 2016 23:29:59 +0000 (23:29 +0000)]
Simplify getprec() by using strchr(3) and strspn(3).
Part of NetBSD's jot r1.20 by dsl.

ok jca

8 years agoInclude map entries that have an amap associated with them in the coredump.
kettenis [Fri, 12 Aug 2016 22:46:02 +0000 (22:46 +0000)]
Include map entries that have an amap associated with them in the coredump.
This fixes coredumps of processes that use relro to make part of their
writable address space read-only.

ok guenther@

8 years agoRewrite the paragraphs that describe how the last four arguments are
tb [Fri, 12 Aug 2016 21:49:31 +0000 (21:49 +0000)]
Rewrite the paragraphs that describe how the last four arguments are
handled to make them easier to read and understand.

with help from jmc

8 years agousage() is __dead
tb [Fri, 12 Aug 2016 21:31:11 +0000 (21:31 +0000)]
usage() is __dead

8 years agoThe last four argumens of jot (reps, begin, end, step) can all be
tb [Fri, 12 Aug 2016 21:17:41 +0000 (21:17 +0000)]
The last four argumens of jot (reps, begin, end, step) can all be
specified or omitted, yielding 16 possible combinations, plus
a few special cases.

Instead of hardcoded values, use names to make the bit patterns
that indicate which values were specified human readable. Decide
once and for all what to do in a single switch statement. Don't
enter said switch when random output is requested since that
simply makes no sense at all.

While there, make the error messages a bit more meaningful and
fix a bogus value assigned to begin for jot -r x - y z that has
been there since -r1.1. All regression tests now pass.

Inspired by David Laight (dsl)'s r1.21 of NetBSD's jot.

"move fast and break stuff" tedu
agreement from deraadt

8 years agothe slimmed down random functions inside ld.so are strict clones of the
deraadt [Fri, 12 Aug 2016 20:39:01 +0000 (20:39 +0000)]
the slimmed down random functions inside ld.so are strict clones of the
libc arc4random API, so call them _dl_{arc4random,arcrandombuf}
ok tedu guenther

8 years agoDedup vnode type information. Fuse stores the vnode type in two places:
natano [Fri, 12 Aug 2016 20:18:44 +0000 (20:18 +0000)]
Dedup vnode type information. Fuse stores the vnode type in two places:
vtype in struct fusefs_node and v_type in struct vnode. Given the fact,
that fusefs_node structs are never allocated without an associated vnode
and those two fields are always in sync, one of those locations is
superfluous.

While there remove the unused nlookup field.

ok mpi

8 years agoHook up sxipio(4) to the generic gpio code.
kettenis [Fri, 12 Aug 2016 19:55:54 +0000 (19:55 +0000)]
Hook up sxipio(4) to the generic gpio code.

8 years agoUse 2001:db8::/32, the official IPv6 subnet for configuration examples.
jca [Fri, 12 Aug 2016 19:19:04 +0000 (19:19 +0000)]
Use 2001:db8::/32, the official IPv6 subnet for configuration examples.

This makes the IPv6 example consistent with IPv4, and removes a dubious
mention of a 6bone subnet.

ok sthen@ millert@

8 years agoCall pinctrl_byname() such that ports left unconfiguraed by u-boot will work
kettenis [Fri, 12 Aug 2016 16:09:37 +0000 (16:09 +0000)]
Call pinctrl_byname() such that ports left unconfiguraed by u-boot will work
as well.

ok deraadt@, millert@

8 years agoHook up sxipio(4) to the generic pinctrl code. The device binding is pretty
kettenis [Fri, 12 Aug 2016 16:02:31 +0000 (16:02 +0000)]
Hook up sxipio(4) to the generic pinctrl code.  The device binding is pretty
retarded, requiring tables to map text strings to the apropriate numbers.
These tables were generated automatically from data extracted from the
Linux kernel and are kept in a separate file.  This should make it easy
to add support for more SoCs from the same family.

ok deraadt@, millert@

8 years agosync
deraadt [Fri, 12 Aug 2016 15:51:46 +0000 (15:51 +0000)]
sync

8 years agoBump libtls minor due to symbol additions.
jsing [Fri, 12 Aug 2016 15:11:50 +0000 (15:11 +0000)]
Bump libtls minor due to symbol additions.

8 years agoAdd ALPN support to libtls.
jsing [Fri, 12 Aug 2016 15:10:59 +0000 (15:10 +0000)]
Add ALPN support to libtls.

ok beck@ doug@

8 years ago6bone -> documentation range
jca [Fri, 12 Aug 2016 14:04:34 +0000 (14:04 +0000)]
6bone -> documentation range

8 years agoband-aid for a nasty bug. tieto + space constraints don't interact well.
espie [Fri, 12 Aug 2016 11:17:37 +0000 (11:17 +0000)]
band-aid for a nasty bug. tieto + space constraints don't interact well.
there are better fixes (such as computing tieto first, computing the size
better, and doing two passes deletes), but at least this one doesn't fuck
things up.

8 years agotrim errstr, and zap gendh (deprecated) entirely;
jmc [Fri, 12 Aug 2016 06:21:12 +0000 (06:21 +0000)]
trim errstr, and zap gendh (deprecated) entirely;

8 years agoshorten openssl enc, with help from jsing;
jmc [Fri, 12 Aug 2016 06:17:22 +0000 (06:17 +0000)]
shorten openssl enc, with help from jsing;
ok jsing beck

8 years agorework initial text a little, to read better;
jmc [Fri, 12 Aug 2016 06:16:19 +0000 (06:16 +0000)]
rework initial text a little, to read better;

8 years agono more libarm;
jmc [Fri, 12 Aug 2016 06:15:18 +0000 (06:15 +0000)]
no more libarm;

8 years agoSwitch omap to the generic ofw pinctrl framework.
jsg [Fri, 12 Aug 2016 03:22:41 +0000 (03:22 +0000)]
Switch omap to the generic ofw pinctrl framework.

ok kettenis@

8 years agooops, fix stupid typo in previous
schwarze [Thu, 11 Aug 2016 11:39:19 +0000 (11:39 +0000)]
oops, fix stupid typo in previous

8 years agoIf a .Bd display is on the one hand doomed to be deleted because
schwarze [Thu, 11 Aug 2016 10:46:27 +0000 (10:46 +0000)]
If a .Bd display is on the one hand doomed to be deleted because
it has no type, but is on the other hand breaking another block,
delete its end marker as well, or the end marker may remain behind
as an orphan, triggering an assertion in the terminal formatter.
Problem found by tb@ with afl(1).

8 years agofuse requires ufs_ihash.c
natano [Thu, 11 Aug 2016 09:30:57 +0000 (09:30 +0000)]
fuse requires ufs_ihash.c
ok mpi

8 years agoDynamically attach omgpio(4) using the FDT.
jsg [Thu, 11 Aug 2016 04:33:06 +0000 (04:33 +0000)]
Dynamically attach omgpio(4) using the FDT.

am335x has a compatible string of "ti,omap4-gpio" and has the same
offsets as omap4, so combine the omap4 and am335x cases when setting up
function pointers.

8 years agoBetween relro and previous RWX work, the __{got,plt}_{start,end} symbols
guenther [Thu, 11 Aug 2016 03:05:53 +0000 (03:05 +0000)]
Between relro and previous RWX work, the __{got,plt}_{start,end} symbols
are no longer needed by ld.so.  Move them to the m88k-specific list, as
it hasn't made the jump.

ok deraadt@

8 years agoDynamically attach omehci using the FDT.
jsg [Thu, 11 Aug 2016 01:53:18 +0000 (01:53 +0000)]
Dynamically attach omehci using the FDT.
ok kettenis@ patrick@

8 years agoUpdate moduli file.
dtucker [Thu, 11 Aug 2016 01:42:11 +0000 (01:42 +0000)]
Update moduli file.

8 years agoshuffle some code to make it more symmetrical.
dlg [Thu, 11 Aug 2016 01:32:31 +0000 (01:32 +0000)]
shuffle some code to make it more symmetrical.

no functional change.

8 years agoreplace abuse of the static map entries RB_ENTRY pointers with an SLIST
dlg [Thu, 11 Aug 2016 01:17:33 +0000 (01:17 +0000)]
replace abuse of the static map entries RB_ENTRY pointers with an SLIST

free static entries are kept in a simple linked list, so use SLIST
to make this obvious. the RB_PARENT manipulations are ugly and
confusing.

ok kettenis@

8 years agotake TASKQ_CANTSLEEP way from the softnet taskq.
dlg [Thu, 11 Aug 2016 00:58:22 +0000 (00:58 +0000)]
take TASKQ_CANTSLEEP way from the softnet taskq.

the big reason for this is to let us use rw locks in the network
stack, which is how at least two major efforts outside the tree
have approached making pf mpsafe.

this was discussed at length at n2k16. there was general agreement
that this is necessary for us to move smp work forward in the stack.

8 years agoThe ARMv7 ARM says that the TLB may hold translation table entries at any
kettenis [Thu, 11 Aug 2016 00:28:06 +0000 (00:28 +0000)]
The ARMv7 ARM says that the TLB may hold translation table entries at any
level of the translation table, including entries that point to further
levels of the tables.  This means that we have to do a TLB flush whenever
we invalidate an L1 slot too.  Doing so fixes the pmap_fault_fixup
issue on Cortex-A7 processors.

8 years agoAdd defines for the Access Flag as found on armv7. Fix definition of the
kettenis [Wed, 10 Aug 2016 22:28:51 +0000 (22:28 +0000)]
Add defines for the Access Flag as found on armv7.  Fix definition of the
non Global bit Small page desciptions.  iConsistently name the S-bit
Sharable in comments.

8 years agoShuffle armv7 access permission bits around to something that is compatible
kettenis [Wed, 10 Aug 2016 21:22:43 +0000 (21:22 +0000)]
Shuffle armv7 access permission bits around to something that is compatible
with setting the Access Flag Enable bit in the System Control Register.
The new settings mean that read-only userland pages are no longer writable
by the kernel, which is a good thing.  Set the Access Flag Enable bit.

ok patrick@

8 years agoauto-dope-slap: mips64 has 16K pages, not 4K. With that fixed, enable RELRO
guenther [Wed, 10 Aug 2016 20:54:35 +0000 (20:54 +0000)]
auto-dope-slap: mips64 has 16K pages, not 4K.  With that fixed, enable RELRO

Per feedback from kettenis@, Miod, and deraadt@, the padding between
text and rodata will be retained for consistency with other archs,
to minimize reliance on the R4000 EOP bug workaround, and to enable
possible future work.

ok deraadt@

8 years agoTeach readelf and objdump about the PT_OPENBSD_BOOTDATA section value.
guenther [Wed, 10 Aug 2016 20:46:08 +0000 (20:46 +0000)]
Teach readelf and objdump about the PT_OPENBSD_BOOTDATA section value.
Teach ld to access that and PT_GNU_RELRO in linker scripts.

ok deraadt@

8 years agoRemove the encrypted password length check. The admin should be
millert [Wed, 10 Aug 2016 20:30:34 +0000 (20:30 +0000)]
Remove the encrypted password length check.  The admin should be
able to put whatever they like in the encrypted password field,
regardless of whether it can be matched or not.  Having this check
just makes it harder to add new encrypted password functions.
This also fixes "usermode -Z" which was the impetus for the change.
OK benno@

8 years agoDon't deref NULL if the only child of the first .Sh is an empty
schwarze [Wed, 10 Aug 2016 20:16:43 +0000 (20:16 +0000)]
Don't deref NULL if the only child of the first .Sh is an empty
in-line macro, and don't printf("%s", NULL) if the first child
of the first .Sh is a macro; again found by tb@ with afl(1).
(No, you should never use macros in any .Sh at all, please.)

8 years agofix HISTORY; from Sevan Janiyan <venture37 at geeklan dot co dot uk>;
schwarze [Wed, 10 Aug 2016 19:46:43 +0000 (19:46 +0000)]
fix HISTORY; from Sevan Janiyan <venture37 at geeklan dot co dot uk>;
checked with http://minnie.tuhs.org/cgi-bin/utree.pl?file=V1/man/man1

8 years agomove armish and hppa64 down in the dropdown box; reminded by jmc@
schwarze [Wed, 10 Aug 2016 18:39:04 +0000 (18:39 +0000)]
move armish and hppa64 down in the dropdown box; reminded by jmc@

8 years agoshorten ecparam;
jmc [Wed, 10 Aug 2016 17:41:08 +0000 (17:41 +0000)]
shorten ecparam;

8 years agono more armish;
jmc [Wed, 10 Aug 2016 17:37:01 +0000 (17:37 +0000)]
no more armish;

8 years agoKill stale prototypes.
natano [Wed, 10 Aug 2016 16:12:13 +0000 (16:12 +0000)]
Kill stale prototypes.
ok deraadt millert stefan

8 years agoarmish handled some early-gen arm machines, which required tons of
deraadt [Wed, 10 Aug 2016 14:27:15 +0000 (14:27 +0000)]
armish handled some early-gen arm machines, which required tons of
workarounds.  Some of them will soon stand in the way of armv7.
Off to the attic you go.

8 years agoregression tests for mdoc_validate.c revisions 1.219 and 1.220
schwarze [Wed, 10 Aug 2016 13:10:17 +0000 (13:10 +0000)]
regression tests for mdoc_validate.c revisions 1.219 and 1.220

8 years agoDon't printf("%s", NULL) if .It has a macro as an argument
schwarze [Wed, 10 Aug 2016 12:29:02 +0000 (12:29 +0000)]
Don't printf("%s", NULL) if .It has a macro as an argument
in a list of a type where items don't takes arguments.
Issue found by tb@ with afl(1).

8 years agoWhen validating a .Bl list that defaults to -item for want of a type,
schwarze [Wed, 10 Aug 2016 12:04:57 +0000 (12:04 +0000)]
When validating a .Bl list that defaults to -item for want of a type,
don't let a subsequent -width access mdoc_argnames[] out of bounds.
Found by tb@ with afl(1).

8 years agofix previous; ffs_vinit() requires #ifdef _KERNEL to not break the
natano [Wed, 10 Aug 2016 11:33:01 +0000 (11:33 +0000)]
fix previous; ffs_vinit() requires #ifdef _KERNEL to not break the
sbin/fsck_ffs build. bad natano!
reported by naddy

8 years agoFix assertion failures caused by whitespace inside \o'' (overstrike)
schwarze [Wed, 10 Aug 2016 11:02:30 +0000 (11:02 +0000)]
Fix assertion failures caused by whitespace inside \o'' (overstrike)
sequences that jsg@ found with afl(1):
* Avoid writing \t\b in term.c.
* Handle trailing \b in term_ps.c.

8 years agoufs_vinit() should really be called ffs_vinit(); it's only called from
natano [Wed, 10 Aug 2016 08:04:57 +0000 (08:04 +0000)]
ufs_vinit() should really be called ffs_vinit(); it's only called from
ffs code.
ok mpi tedu

8 years agoext2fs only has one set of specops/fifoops
natano [Wed, 10 Aug 2016 07:53:02 +0000 (07:53 +0000)]
ext2fs only has one set of specops/fifoops
ok mpi tedu

8 years agoattach agtimer with fdt on RAMDISK as well
jsg [Wed, 10 Aug 2016 07:09:37 +0000 (07:09 +0000)]
attach agtimer with fdt on RAMDISK as well

8 years agoDynamically attach agtimer(4). Since agtimer(4) also provides the delay()
kettenis [Wed, 10 Aug 2016 06:51:57 +0000 (06:51 +0000)]
Dynamically attach agtimer(4).  Since agtimer(4) also provides the delay()
function for platforms that have it, rework the code a bit such that it can
be used before agtimer(4) attaches.  Introduce a new agtimer_init()
function that checks whether the CPU implements the Generic Timer feature
and switches to agtimer_delay() if that feature is present.  Call this
function from the generic platform initialization code.

ok jsg@

8 years agoOn armv7 we put the vector page up high and never have to bother switching it.
kettenis [Wed, 10 Aug 2016 06:46:36 +0000 (06:46 +0000)]
On armv7 we put the vector page up high and never have to bother switching it.
Remove the code to do so from cpuswitch().

ok guenther@

8 years agoCover your kid's remaining eye and lock up the pets for the great old ones
guenther [Wed, 10 Aug 2016 02:58:44 +0000 (02:58 +0000)]
Cover your kid's remaining eye and lock up the pets for the great old ones
have been disturbed: rework the linker script and then enable RELRO support
on all but mips64 (something something padding) and m88k (untested).
This extends the RO coverage from just .got and .cdtors to also include
.openbsd.randomdata, .jcr, .dynamic, and .data.rel.ro., and moves more
segments from the text section to the rodata section.  Depends on the
previous csu and ld.so work; reinstall those *before* rebuilding ld, or
just get a snapshot.

clues from kettenis
assistance testing and ok deraadt@

8 years agoXr vmx(4)
czarkoff [Tue, 9 Aug 2016 23:27:33 +0000 (23:27 +0000)]
Xr vmx(4)

"go for it" jmc@

8 years agosync
deraadt [Tue, 9 Aug 2016 23:16:26 +0000 (23:16 +0000)]
sync

8 years agoremove pointless csh placeholder files from /etc
halex [Tue, 9 Aug 2016 21:24:31 +0000 (21:24 +0000)]
remove pointless csh placeholder files from /etc

ok jung@ (some time ago) phessler@

8 years agoExpand the asynchronous connect information and move it out of
millert [Tue, 9 Aug 2016 17:34:06 +0000 (17:34 +0000)]
Expand the asynchronous connect information and move it out of
ERRORS and into a new second paragraph.  Adapted from NetBSD.
OK deraadt@ jmc@

8 years agotrim the ec text;
jmc [Tue, 9 Aug 2016 17:07:33 +0000 (17:07 +0000)]
trim the ec text;

8 years agoJust re-set the line speed when required. This fixes a serial console
mglocker [Tue, 9 Aug 2016 16:52:42 +0000 (16:52 +0000)]
Just re-set the line speed when required.  This fixes a serial console
hang seen on the allwinner,sun5i-r8.

ok kettenis

8 years agofix printf("%s", NULL);
schwarze [Tue, 9 Aug 2016 15:08:15 +0000 (15:08 +0000)]
fix printf("%s", NULL);
found while investigating an unrelated bug report from jsg@

8 years agoCheck xs->status for SCSI_CHECK even in underrun situations.
krw [Tue, 9 Aug 2016 15:04:34 +0000 (15:04 +0000)]
Check xs->status for SCSI_CHECK even in underrun situations.

Lets Bacula find the end of medium on LTO5 drive.

Reported & fix tested by Kor son of Rynar.

ok mikeb@ deraadt@