openbsd
6 years agoAdd support for enabling registered regulators. Make sure that we leave
kettenis [Mon, 18 Dec 2017 09:13:47 +0000 (09:13 +0000)]
Add support for enabling registered regulators.  Make sure that we leave
regulators with a "regulator-always-on" property alone.

ok patrick@

6 years agoReclaim browser screen real estate in bgplg
job [Mon, 18 Dec 2017 09:12:49 +0000 (09:12 +0000)]
Reclaim browser screen real estate in bgplg

Removing versioning information too.

OK deraadt@

6 years agoTighten /usr/local and /usr/X11R6 so that 8G disks still fit in our default
ajacoutot [Mon, 18 Dec 2017 09:09:53 +0000 (09:09 +0000)]
Tighten /usr/local and /usr/X11R6 so that 8G disks still fit in our default
partitioning scheme.

ok florian@ benno@

6 years agolet's not try to document the number of items in a list...
jmc [Mon, 18 Dec 2017 07:15:15 +0000 (07:15 +0000)]
let's not try to document the number of items in a list...

6 years agoAdd the CLOCK_BOOTTIME clockid for use with clock_gettime(2)
cheloha [Mon, 18 Dec 2017 05:51:53 +0000 (05:51 +0000)]
Add the CLOCK_BOOTTIME clockid for use with clock_gettime(2)
and put it to use in userspace in lieu of the kern.boottime
sysctl.

Its absolute value is the time that has elapsed since the
system booted, i.e., the system uptime.

Use in top(1), w(1), and snmpd(8) eliminates a race with
settimeofday(2), adjtime(2), etc. inherent to deriving the
system uptime via the kern.boottime sysctl.

Product of a great deal of discussion/revision with jca@, tb@,
and guenther@.

ok tb@ jca@ guenther@ dlg@ mlarkin@ tom@

6 years agopass negotiated signing algorithm though to sshkey_verify() and
djm [Mon, 18 Dec 2017 02:25:15 +0000 (02:25 +0000)]
pass negotiated signing algorithm though to sshkey_verify() and
check that the negotiated algorithm matches the type in the
signature (only matters for RSA SHA1/SHA2 sigs). ok markus@

6 years agosshkey_sigtype() function to return the type of a signature;
djm [Mon, 18 Dec 2017 02:22:29 +0000 (02:22 +0000)]
sshkey_sigtype() function to return the type of a signature;
ok markus@

6 years agoSupport setting the Cortex-A7 cores to active/passive mode and
patrick [Mon, 18 Dec 2017 00:08:28 +0000 (00:08 +0000)]
Support setting the Cortex-A7 cores to active/passive mode and
fix up the code for the Cortex-R4 which works the same.

6 years agosync
deraadt [Sun, 17 Dec 2017 20:14:40 +0000 (20:14 +0000)]
sync

6 years agovmm(4): pass EFER properly from vmd(8), needed to support vmctl(8)'s "-b"
mlarkin [Sun, 17 Dec 2017 19:16:02 +0000 (19:16 +0000)]
vmm(4): pass EFER properly from vmd(8), needed to support vmctl(8)'s "-b"
option which had been broken due to recent commits on AMD (SVM/RVI)

ok pd@

6 years agoAdd community/large-community commands and retain parameter input in form
job [Sun, 17 Dec 2017 18:41:17 +0000 (18:41 +0000)]
Add community/large-community commands and retain parameter input in form

OK deraadt@

6 years agoAdd a new question "Escape to shell before reboot? [no]" at the end of
rpe [Sun, 17 Dec 2017 18:29:56 +0000 (18:29 +0000)]
Add a new question "Escape to shell before reboot? [no]" at the end of
the install and upgrade process.

"no" or [enter] reboots the system
"yes" leaves the install or upgrade at the shell prompt

On selected architectures, sparc64 being the only so far, the system
is halted instead of rebooted.

autoinstall(8) is NOT affected by this new question as it reboots the
system automatically already.

Suggested by and OK deraadt@, tb@ phessler@
Feedback on sparc64 by stsp@
Positive feedback pea@ landry@

6 years agoMake axppmic(4) attach to a Reduced Serial Bus, and support the AXP806
kettenis [Sun, 17 Dec 2017 18:25:25 +0000 (18:25 +0000)]
Make axppmic(4) attach to a Reduced Serial Bus, and support the AXP806
and AXP809 PMICs.  Disabled for now.

6 years agoallow '-' in usernames
rpe [Sun, 17 Dec 2017 17:03:52 +0000 (17:03 +0000)]
allow '-' in usernames

requested and OK aja
OK halex@

6 years agoAdd 32K output klock support.
kettenis [Sun, 17 Dec 2017 15:29:29 +0000 (15:29 +0000)]
Add 32K output klock support.

6 years agoLet the Insert key toggle overwrite mode. This matches GNU Emacs behavior.
bcallah [Sun, 17 Dec 2017 14:37:57 +0000 (14:37 +0000)]
Let the Insert key toggle overwrite mode. This matches GNU Emacs behavior.
Diff from Lari Rasku <lari.rasku AT elisanet DOT fi>
ok florian@

6 years agoFurther simplifY lease parsing. Fold add_lease() into read_lease_db(),
krw [Sun, 17 Dec 2017 14:24:04 +0000 (14:24 +0000)]
Further simplifY lease parsing. Fold add_lease() into read_lease_db(),
and move all lease parsing into parse_lease().

6 years agodwxe(4)
kettenis [Sun, 17 Dec 2017 13:54:08 +0000 (13:54 +0000)]
dwxe(4)

6 years agoAdd magic to make USB PYs work on Allwinner H3/H5/A64.
kettenis [Sun, 17 Dec 2017 13:23:03 +0000 (13:23 +0000)]
Add magic to make USB PYs work on Allwinner H3/H5/A64.

6 years agoAdd wsdisplay options needed for X and VT switching.
kettenis [Sun, 17 Dec 2017 12:57:32 +0000 (12:57 +0000)]
Add wsdisplay options needed for X and VT switching.

ok patrick@

6 years agoPass Cortex-R4 reset vector to activation function.
patrick [Sun, 17 Dec 2017 10:26:21 +0000 (10:26 +0000)]
Pass Cortex-R4 reset vector to activation function.

6 years agoUse proper BN functions for error reporting; from kshe
otto [Sun, 17 Dec 2017 08:21:10 +0000 (08:21 +0000)]
Use proper BN functions for error reporting; from kshe

6 years agoRead RAM base address and size so we know where to put the firmware.
patrick [Sat, 16 Dec 2017 23:45:16 +0000 (23:45 +0000)]
Read RAM base address and size so we know where to put the firmware.

6 years agoImplement setting the chip into active mode, as needed for setting up
patrick [Sat, 16 Dec 2017 23:39:58 +0000 (23:39 +0000)]
Implement setting the chip into active mode, as needed for setting up
the PCIe-based BCM43602's firmware in the PCI attachment driver.

6 years agoSupport setting the Cortex-R4, as found on a BCM43602, to passive mode.
patrick [Sat, 16 Dec 2017 23:32:56 +0000 (23:32 +0000)]
Support setting the Cortex-R4, as found on a BCM43602, to passive mode.

6 years agoAdd some more Chip IDs to bwfm(4).
patrick [Sat, 16 Dec 2017 23:29:48 +0000 (23:29 +0000)]
Add some more Chip IDs to bwfm(4).

6 years agoEnforce voltage limits from the device tree. Enforcing the limits also
kettenis [Sat, 16 Dec 2017 21:12:03 +0000 (21:12 +0000)]
Enforce voltage limits from the device tree.  Enforcing the limits also
happens when regulators are registered.  As a consequence they will be
properly initialized even when the firmware doesn't do that.

ok patrick@

6 years agoAdd support for 1-byte reads and writes.
kettenis [Sat, 16 Dec 2017 21:09:38 +0000 (21:09 +0000)]
Add support for 1-byte reads and writes.

6 years agoWith leases no longer in dhclient.conf, rename a bunch of
krw [Sat, 16 Dec 2017 20:47:53 +0000 (20:47 +0000)]
With leases no longer in dhclient.conf, rename a bunch of
functions and fields to more obvious names reflecting this
separation.

6 years agoMove __cxa_thread_atexit* to its own .c file to avoid pulling the code
guenther [Sat, 16 Dec 2017 20:06:55 +0000 (20:06 +0000)]
Move __cxa_thread_atexit* to its own .c file to avoid pulling the code
(w/ _dlctl reference) into static executables.  It's all Mark's code so
put his preferred copyright on it.

ok kettenis@

6 years agosync
deraadt [Sat, 16 Dec 2017 19:45:52 +0000 (19:45 +0000)]
sync

6 years agotweak previous;
jmc [Sat, 16 Dec 2017 18:28:16 +0000 (18:28 +0000)]
tweak previous;

6 years agoEnable sxirsb(4).
kettenis [Sat, 16 Dec 2017 14:15:56 +0000 (14:15 +0000)]
Enable sxirsb(4).

6 years agoUpdate with changes from FreeBSD via NetBSD. From Sevan Janiyan.
millert [Sat, 16 Dec 2017 13:01:22 +0000 (13:01 +0000)]
Update with changes from FreeBSD via NetBSD.  From Sevan Janiyan.

6 years agohookup execpromise
florian [Sat, 16 Dec 2017 11:01:34 +0000 (11:01 +0000)]
hookup execpromise

6 years agoexecpromise regress
florian [Sat, 16 Dec 2017 11:00:49 +0000 (11:00 +0000)]
execpromise regress

6 years agoPassing NULL to free() is fine; from Michael W. Bombardieri.
anton [Sat, 16 Dec 2017 10:27:21 +0000 (10:27 +0000)]
Passing NULL to free() is fine; from Michael W. Bombardieri.

6 years agoacrtc(4), sxirsb(4)
kettenis [Sat, 16 Dec 2017 10:23:07 +0000 (10:23 +0000)]
acrtc(4), sxirsb(4)

6 years agoAdd a driver for the RSB controller found on various Allwinner SoCs.
kettenis [Sat, 16 Dec 2017 10:22:13 +0000 (10:22 +0000)]
Add a driver for the RSB controller found on various Allwinner SoCs.
Add a driver for the RTC part of the AC100 chip.
Together this turns my Cubieboard4 into a real computer by giving it
a proper clock.

ok patrick@

6 years agoDon't use _libc_ prefix when referencing "builtin" symbols with clang.
kettenis [Sat, 16 Dec 2017 09:25:43 +0000 (09:25 +0000)]
Don't use _libc_ prefix when referencing "builtin" symbols with clang.

Slightly tweaked diff from guenther@

6 years agooops - previous should have been a list item;
jmc [Fri, 15 Dec 2017 20:51:28 +0000 (20:51 +0000)]
oops - previous should have been a list item;

6 years agotypo; from alexander kuleshov
jmc [Fri, 15 Dec 2017 18:08:47 +0000 (18:08 +0000)]
typo; from alexander kuleshov

6 years agosync
jca [Fri, 15 Dec 2017 16:42:21 +0000 (16:42 +0000)]
sync

6 years agoExport only symbols to what's declared in fuse.h/fuse_opt.h
jca [Fri, 15 Dec 2017 16:40:33 +0000 (16:40 +0000)]
Export only symbols to what's declared in fuse.h/fuse_opt.h

While here, use guenther's magic recipe to avoid the PLT when calling
exported symbols from within the library.

ok kettenis@ for v1, ok guenther@ helg@

6 years agoreplace a hardcoded jot with ${JOT}
tb [Fri, 15 Dec 2017 15:24:15 +0000 (15:24 +0000)]
replace a hardcoded jot with ${JOT}

6 years agoThe pledge(2) regress tests fail since the second parameter has
bluhm [Fri, 15 Dec 2017 14:45:51 +0000 (14:45 +0000)]
The pledge(2) regress tests fail since the second parameter has
been converted from paths to execpromises.  Remove the test fragments
for the non-existing paths feature.
OK semarie@ florian@

6 years agoUse the canonical idiom to check strlcat(3). An unchecked strlcat call
tb [Fri, 15 Dec 2017 14:20:52 +0000 (14:20 +0000)]
Use the canonical idiom to check strlcat(3). An unchecked strlcat call
led to unexpected output: compare 'jot -w $(printf %1020s)%d%' 1 1'
with 'jot -w $(printf %1019s)%d%' 1 1'.

found by & ok martijn

6 years agoInstead of pointlessly falling through other cases and ending up doing
tb [Fri, 15 Dec 2017 13:04:11 +0000 (13:04 +0000)]
Instead of pointlessly falling through other cases and ending up doing
goto fmt_broken, do it explicitly. Makes following the code path through
the switch a bit easier.

Prompted by a request by martijn

6 years agoenable the 'wDn' test now that jot has been fixed.
tb [Fri, 15 Dec 2017 12:19:01 +0000 (12:19 +0000)]
enable the 'wDn' test now that jot has been fixed.

6 years agoMake sure the double is cast to a long if the format string is %D, %O, %U.
tb [Fri, 15 Dec 2017 12:17:49 +0000 (12:17 +0000)]
Make sure the double is cast to a long if the format string is %D, %O, %U.
Fixes output of e.g. 'jot -w %D 11 -5'.

ok martijn

6 years agoFix formatting of libfuse version info.
helg [Fri, 15 Dec 2017 12:08:22 +0000 (12:08 +0000)]
Fix formatting of libfuse version info.

ok mpi@

6 years agoAdd a few more Allwinner A80 clocks.
kettenis [Fri, 15 Dec 2017 09:15:36 +0000 (09:15 +0000)]
Add a few more Allwinner A80 clocks.

6 years agoput where im up to into the tree so jmatthew@ can look at it.
dlg [Fri, 15 Dec 2017 05:56:08 +0000 (05:56 +0000)]
put where im up to into the tree so jmatthew@ can look at it.

6 years agoifq_barrier should be callable by any nic, not just MPSAFE ones.
dlg [Fri, 15 Dec 2017 01:40:39 +0000 (01:40 +0000)]
ifq_barrier should be callable by any nic, not just MPSAFE ones.

if (when) tx mitigation goes in again, all nics will have deferred
work that will need a barrier to ensure isn't running anymore.

found by bluhm@ when tx mit was in.

6 years agoadd ifiqueues for mp safety and nics with multiple rx rings.
dlg [Fri, 15 Dec 2017 01:37:30 +0000 (01:37 +0000)]
add ifiqueues for mp safety and nics with multiple rx rings.

currently there is a single mbuf_queue per interface, which all
rings on a nic shove packets onto. while the list inside this queue
is protected by a mutex, the counters around it (ie, ipackets,
ibytes, idrops) are not. this means updates can be lost, and reading
the statistics is also inconsistent. having a single queue means
that busy rx rings can dominate and then starve the others.

ifiqueue structs are like ifqueue structs. they provide per ring
queues, and independent counters for each ring. when ifdata is read
for userland, these counters are aggregated. having a queue per
ring now allows for per ring backpressure to be applied. MCLGETI
will have it's day again.

right now we assume every interface wants an input queue and
unconditionally provide one. individual interfaces can opt into
more.

im not completely happy about the shape of this atm, but shuffling
it around more makes the diff bigger.

ok visa@

6 years agomake sched_barrier use cond_wait/cond_signal.
dlg [Thu, 14 Dec 2017 23:21:04 +0000 (23:21 +0000)]
make sched_barrier use cond_wait/cond_signal.

previously the code was using a percpu flag to manage the sleeps/wakeups,
which means multiple threads waiting for a barrier on a cpu could
race. moving to a cond struct on the stack fixes this.

while here, get rid of the sbar taskq and just use systqmp instead.
the barrier tasks are short, so there's no real downside.

ok mpi@

6 years agoset Location header for 307 and 308 status codes
benno [Thu, 14 Dec 2017 21:19:47 +0000 (21:19 +0000)]
set Location header for 307 and 308 status codes
ok sthen@ phessler@

6 years agoReplace ED25519's private SHA-512 implementation with a call to the
naddy [Thu, 14 Dec 2017 21:07:39 +0000 (21:07 +0000)]
Replace ED25519's private SHA-512 implementation with a call to the
regular digest code.  This speeds up compilation considerably.
ok markus@

6 years agoDon't bother using DETACH_FORCE for the softraid luns at reboot
deraadt [Thu, 14 Dec 2017 20:23:13 +0000 (20:23 +0000)]
Don't bother using DETACH_FORCE for the softraid luns at reboot
time; the aggressive mountpoint destruction seems to hit insane
use-after-frees when we are already far on the way down.

6 years agoGive vflush_vnode() a hint about vnodes we don't need to account as "busy".
deraadt [Thu, 14 Dec 2017 20:20:38 +0000 (20:20 +0000)]
Give vflush_vnode() a hint about vnodes we don't need to account as "busy".
Change mountpoint to RDONLY a little later.  Seems to improve the
rw->ro transition a bit.

6 years agoMake roaming after a background scan work while tcpbench -u is running
stsp [Thu, 14 Dec 2017 20:12:32 +0000 (20:12 +0000)]
Make roaming after a background scan work while tcpbench -u is running
over iwn(4), in the same way as this was done for iwm(4).

I forgot about making iwn(4) heed the IEEE80211_F_TX_MGMT_ONLY flag which
is used to disable queueing of new data frames during an AP switch.

Found due to a problem report by naddy@
ok phessler@ tb@

6 years agoSimplify and unify timespec variables used in those event loops
jca [Thu, 14 Dec 2017 18:56:22 +0000 (18:56 +0000)]
Simplify and unify timespec variables used in those event loops

ok millert@

6 years agoMy previous commit broke the ramdisk build; fix it
stsp [Thu, 14 Dec 2017 18:52:17 +0000 (18:52 +0000)]
My previous commit broke the ramdisk build; fix it

6 years agowhen -h is passed don't print any header, as is common practise in other systems...
jasper [Thu, 14 Dec 2017 18:03:03 +0000 (18:03 +0000)]
when -h is passed don't print any header, as is common practise in other systems too.
adjust uptime.1 while here as pointed out by martijn@

ok tb@ jca@ martijn@

6 years agosync
deraadt [Thu, 14 Dec 2017 17:48:47 +0000 (17:48 +0000)]
sync

6 years agoIf switching RW->RO, then stop deferring timestamp writes...and possibly
guenther [Thu, 14 Dec 2017 17:25:39 +0000 (17:25 +0000)]
If switching RW->RO, then stop deferring timestamp writes...and possibly
other pending inode attribute changes.  We appear to be missing UFS_UPDATE()
calls in some paths with the result that bsd.rd remounting the newly
created /mnt to RO would lose the GID changes on device inodes there.
This only affected devices, as they're the only inodes where timestamp
writes are delayed.

ok deraadt@

6 years agoAdd Symbols.map to explicitly define the ABIs, hiding linker defined symbols.
guenther [Thu, 14 Dec 2017 17:06:33 +0000 (17:06 +0000)]
Add Symbols.map to explicitly define the ABIs, hiding linker defined symbols.
Use hidden aliases for internal invocations of exported symbols to avoid PLT.

ok deraadt@ kettenis@ jca@

6 years agosync
deraadt [Thu, 14 Dec 2017 16:57:59 +0000 (16:57 +0000)]
sync

6 years agoUse CLOCK_MONOTONIC for the rpc event loops
jca [Thu, 14 Dec 2017 16:55:44 +0000 (16:55 +0000)]
Use CLOCK_MONOTONIC for the rpc event loops

From Scott Cheloha, ok deraadt@ tb@

6 years agoAdd a missing call to fuse_set_signal_handlers(3) in fuse_setup(3) so that
helg [Thu, 14 Dec 2017 14:50:02 +0000 (14:50 +0000)]
Add a missing call to fuse_set_signal_handlers(3) in fuse_setup(3) so that
any file systems that call fuse_setup(3) or fuse_main(3) trap signals
gracefully.

ok mpi@

6 years agoStop printing debug info about stations leaving a wifi network when
stsp [Thu, 14 Dec 2017 14:27:10 +0000 (14:27 +0000)]
Stop printing debug info about stations leaving a wifi network when
we aren't running in hostap or ibss mode.

6 years agoThe pf code marks ICMP packets belonging to an TCP or UDP divert
bluhm [Thu, 14 Dec 2017 14:26:50 +0000 (14:26 +0000)]
The pf code marks ICMP packets belonging to an TCP or UDP divert
state as diverted.  This is necessary for IP input to accept the
packet as ours.  But it must not be used to match the ICMP packet
to a raw socket.  Clear the PF_TAG_DIVERTED mbuf pf flag for the
special ICMP and ICMP6 packets in icmp_input_if() and icmp6_input().

The m_tag_delete_chain() caused an inconsistent PF_TAG_DIVERTED
mbuf pf flag and PACKET_TAG_PF_DIVERT mbuf tag which triggered an
assert in rip_input().  Deleting all mbuf tags can have undesired
side effects and is not necessary anymore since icmp_reflect() calls
m_resethdr().  Do not touch the mbuf tags and adjust the mbuf pf
flags for the correct behavior of rip_input() and rip6_input().

reported by Chris Eidem, James Turner, vicviq, Scott Vanderbilt
OK mpi@

6 years agoAdd background scanning support to iwn(4), as was done for iwm(4) recently.
stsp [Thu, 14 Dec 2017 14:21:11 +0000 (14:21 +0000)]
Add background scanning support to iwn(4), as was done for iwm(4) recently.

Tested on following devices by various people: 6300, 6200, 6205, 2200, 5100

ok phessler@ tb@

6 years agoDrop -g from CFLAGS, bsd.lib.mk adds it by default
jca [Thu, 14 Dec 2017 13:50:13 +0000 (13:50 +0000)]
Drop -g from CFLAGS, bsd.lib.mk adds it by default

ok mpi@ helg@

6 years agofuse_opt_add_opt_escaped needs to allocate space for the terminating NUL
jca [Thu, 14 Dec 2017 13:23:30 +0000 (13:23 +0000)]
fuse_opt_add_opt_escaped needs to allocate space for the terminating NUL

Spotted by malloc.conf -> S, ok helg@

6 years agoFree FUSE channel if fuse_new(3) fails in fuse_setup(3).
helg [Thu, 14 Dec 2017 13:11:37 +0000 (13:11 +0000)]
Free FUSE channel if fuse_new(3) fails in fuse_setup(3).

ok mpi@

6 years agoEnable the awk scripts to generate ex_def.h and options_def.h.
martijn [Thu, 14 Dec 2017 10:02:53 +0000 (10:02 +0000)]
Enable the awk scripts to generate ex_def.h and options_def.h.
These scripts generate the enums required for the ex commands and vi
options.
Before these lists had to be maintained either by hand or someone had to
stumble upon these scripts and figure out how to use them. By enabling them
these headers are now always in sync based on the comments in the
corresponding source files, which are a lot harder to miss during an
update than an extra file.

Update the awk scripts to the new enum style introduced by bentley@ with
his update on options_def.h r1.7

Feedback Makefile semantics by espie@
Original diff and OK tb@
OK millert@

6 years agoMake a few internal symbols static and add a Symbols.map version script
kettenis [Thu, 14 Dec 2017 09:27:44 +0000 (09:27 +0000)]
Make a few internal symbols static and add a Symbols.map version script
to control which symbols are exported from the shared library.

ok guenther@, deraadt@, jca@

6 years agolet urtwn(4) find my TP-LINK TL-WN722N v2
benno [Thu, 14 Dec 2017 09:26:11 +0000 (09:26 +0000)]
let urtwn(4) find my TP-LINK TL-WN722N v2
ok deraadt@ phessler@ kettenis@

6 years agosync
benno [Thu, 14 Dec 2017 09:25:31 +0000 (09:25 +0000)]
sync

6 years agoadd usb id for TP-LINK TL-WN722N v2
benno [Thu, 14 Dec 2017 09:22:16 +0000 (09:22 +0000)]
add usb id for TP-LINK TL-WN722N v2
ok deraadt@ phessler@ kettenis@

6 years agoChange bcopy to memcpy in the i386 version of the VIA PadLock driver.
fcambus [Thu, 14 Dec 2017 09:14:30 +0000 (09:14 +0000)]
Change bcopy to memcpy in the i386 version of the VIA PadLock driver.
It was done a while ago in the amd64 version.

OK mlarkin@, deraadt@, dlg@

6 years agozap trailing whitespace;
jmc [Thu, 14 Dec 2017 06:43:44 +0000 (06:43 +0000)]
zap trailing whitespace;

6 years agoRepair flushcache/standby operations to not convert AT_WAIT operations
deraadt [Thu, 14 Dec 2017 06:21:04 +0000 (06:21 +0000)]
Repair flushcache/standby operations to not convert AT_WAIT operations
to AT_POLL, which some chip driver underneath cannot handle.
tested by bluhm also

6 years agofcntl(F_SETFL) invokes the FIONBIO and FIOASYNC ioctls internally, so
guenther [Thu, 14 Dec 2017 03:30:43 +0000 (03:30 +0000)]
fcntl(F_SETFL) invokes the FIONBIO and FIOASYNC ioctls internally, so
the memory devices (/dev/null, /dev/zero, etc) need to permit them.

problem noted, tweak, and testing by jeremy@
ok deraadt@

6 years agoi forgot to convert timeout_proc_barrier to cond_signal
dlg [Thu, 14 Dec 2017 02:42:18 +0000 (02:42 +0000)]
i forgot to convert timeout_proc_barrier to cond_signal

6 years agoi forgot to convert ifq_barrier_task to cond_signal.
dlg [Thu, 14 Dec 2017 02:40:51 +0000 (02:40 +0000)]
i forgot to convert ifq_barrier_task to cond_signal.

6 years agoreplace the bare sleep state handling in barriers with wait cond code
dlg [Thu, 14 Dec 2017 00:45:16 +0000 (00:45 +0000)]
replace the bare sleep state handling in barriers with wait cond code

6 years agoadd code to provide simple wait condition handling.
dlg [Thu, 14 Dec 2017 00:41:58 +0000 (00:41 +0000)]
add code to provide simple wait condition handling.

this will be used to replace the bare sleep_state handling in a
bunch of places, starting with the barriers.

6 years agoFix whitespace botch that snuck in.
krw [Wed, 13 Dec 2017 18:53:04 +0000 (18:53 +0000)]
Fix whitespace botch that snuck in.

6 years agoSimplifiy parser by not worrying about nesting 'interface <if> {}'
krw [Wed, 13 Dec 2017 18:45:08 +0000 (18:45 +0000)]
Simplifiy parser by not worrying about nesting 'interface <if> {}'
statements. They are silly but harmless and work fine.

6 years agoFix a softdep bug exposed by our recent changes to make reboot drop to read-only
beck [Wed, 13 Dec 2017 16:38:34 +0000 (16:38 +0000)]
Fix a softdep bug exposed by our recent changes to make reboot drop to read-only

The deadlock happens when softdep gets the same buffer in the BMSAFEMAP case
that it already called getdirtybuf() on and made busy at the top of the loop.
when this is the case, skip the BMSAFEMAP case and simply write the buffer
out at the bottom of the loop as always. This avoids calling getdirtybuf()
a second time on the same buffer we already took for exclusive use ourself
and have not yet written out.

While I'm in here add a KASSERT for the similar case above, which I don't
think can happen but we would deadlock in the same way if it does.

testing by and ok bluhm@

6 years agoFix array index by signed char; from martijn@
millert [Wed, 13 Dec 2017 16:07:54 +0000 (16:07 +0000)]
Fix array index by signed char; from martijn@

6 years agoFix sign compare warnings; OK martijn@
millert [Wed, 13 Dec 2017 16:06:34 +0000 (16:06 +0000)]
Fix sign compare warnings; OK martijn@

6 years agoEnable compiler warnings; OK martijn@
millert [Wed, 13 Dec 2017 16:06:05 +0000 (16:06 +0000)]
Enable compiler warnings; OK martijn@

6 years agoAdd support for the -d (-o debug) option to libfuse. Currently works for FUSE
helg [Wed, 13 Dec 2017 12:30:18 +0000 (12:30 +0000)]
Add support for the -d (-o debug) option to libfuse. Currently works for FUSE
file systems that call fuse_parse_cmdline(3), fuse_main(3) or
fuse_setup(3).

ok mpi@, jca@

6 years agoIf the list of templates 'o' passed to fuse_opt_parse(3) is NULL then
helg [Wed, 13 Dec 2017 12:23:48 +0000 (12:23 +0000)]
If the list of templates 'o' passed to fuse_opt_parse(3) is NULL then
the processing function should be called in the same way as if no match
was found.

ok mpi@

6 years agoFix stray return; hopefully this makes the internal PHY actually work now.
kettenis [Wed, 13 Dec 2017 10:38:06 +0000 (10:38 +0000)]
Fix stray return; hopefully this makes the internal PHY actually work now.

6 years agoSpacing from kshe59@zoho.eu.
mpi [Wed, 13 Dec 2017 08:59:02 +0000 (08:59 +0000)]
Spacing from kshe59@zoho.eu.

6 years agoSizes for free in route_output().
mpi [Wed, 13 Dec 2017 08:54:59 +0000 (08:54 +0000)]
Sizes for free in route_output().

From kshe59@zoho.eu.