summaryrefslogtreecommitdiffstats
path: root/sys (follow)
Commit message (Collapse)AuthorAgeFilesLines
* curproc access isn't necessarily as cheap as a local variable access,deraadt2017-12-191-3/+4
| | | | | so only get it once ok guenther
* Remove unused ps_stackgap from process structstefan2017-12-192-6/+2
| | | | | Nothing uses this field since Linux compat was removed. ok mpi@ deraadt@ guenther@
* Remove a 27 year old #ifdef notdef chunk involving SB_LOCK.mpi2017-12-191-17/+1
| | | | ok bluhm@
* Inline socket buffer related defines, no functional change.mpi2017-12-191-11/+8
| | | | ok bluhm@
* Remove unnecessary unlock/lock dance when following a goto.mpi2017-12-191-5/+5
| | | | ok bluhm@
* Properly implement the rsb attribute and actually use it.kettenis2017-12-183-10/+11
|
* Add sensors for the AXP809.kettenis2017-12-181-3/+10
|
* Generate SIGBUS/BUS_ADRALN when we see a PC Alignment Exception from userland.kettenis2017-12-181-1/+6
| | | | ok patrick@
* Use axppmic as a dependency instead of axppmic_rsb.kettenis2017-12-181-2/+2
|
* Read RAM size for chips with SOCRAM like the BCM4334 on one of mypatrick2017-12-181-2/+18
| | | | Intel machines.
* Read RAM size for chips with SOCRAM like the BCM4334 on one of mypatrick2017-12-181-5/+55
| | | | Intel machines.
* Pass the BSSID to the join command so that we connect to the AP thatpatrick2017-12-181-4/+7
| | | | we chose instead of any AP the firmware chooses based on the SSID.
* Pass scan type directly to the scan command instead of using the globalpatrick2017-12-182-8/+6
| | | | variable.
* Add sizes for free() in libsa for amd64 and i386.fcambus2017-12-184-12/+12
| | | | OK tom@, deraadt@
* Enable RSB attachment for axppmic(4).kettenis2017-12-181-1/+2
|
* Add i2c interface code to the new axppmic(4) code and add support for thekettenis2017-12-183-164/+305
| | | | | | AXP152 and AXP209 here as well. The AXP209 is extended to support regulators and sensors. The ACIN and VBUS indicators are now exported as sensors. Retire the old AXP152/AXP209 support code.
* Map framebuffer into userland as non-cachable (but normal) memory. We stillkettenis2017-12-181-2/+4
| | | | | | | | | map the framebuffer as device memory in the kernel. Using mismatched memory attributes like this is discouraged (and we should probably fix this at some point) but this particular case is well-defined and the potential side-effects should not matter for thus use-case. ok patrick@
* Revert support for multiple threads to enter kqueue_scan() in parallel.mpi2017-12-182-64/+3
| | | | | | It is not clear if this change is responsible for the lockups experienced by dhill@ and jcs@ but since we're no longer grabbing the socket lock in kqueue(2) filters there's no need for this change.
* Revert grabbing the socket lock in kqueue(2) filters.mpi2017-12-183-28/+10
| | | | | | | | | | This change exposed or created a situation where a CPU started to be irresponsive while holding the KERNEL_LOCK(). These led to lockups and even with MP_LOCKDEBUG it was not clear what happened to this CPU. These situations have been experience by dhill@ with dcrwallet and jcs@ with syncthing. Both applications are written in Go and do kevent(2) & networking across multiple threads.
* Make rw_exit() always succeed after a panic.mpi2017-12-181-1/+5
| | | | | | | Prevents a deadlock in if_downall() when rw_enter() succeed without really grabbing the lock. Reported by and ok phessler@
* Size for free(9).mpi2017-12-181-15/+14
| | | | From <kshe59 at zoho.eu>
* Add support for enabling registered regulators. Make sure that we leavekettenis2017-12-182-11/+32
| | | | | | regulators with a "regulator-always-on" property alone. ok patrick@
* Add the CLOCK_BOOTTIME clockid for use with clock_gettime(2)cheloha2017-12-182-2/+5
| | | | | | | | | | | | | | | | | 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@
* Support setting the Cortex-A7 cores to active/passive mode andpatrick2017-12-181-4/+32
| | | | fix up the code for the Cortex-R4 which works the same.
* vmm(4): pass EFER properly from vmd(8), needed to support vmctl(8)'s "-b"mlarkin2017-12-171-1/+6
| | | | | | option which had been broken due to recent commits on AMD (SVM/RVI) ok pd@
* Make axppmic(4) attach to a Reduced Serial Bus, and support the AXP806kettenis2017-12-172-1/+323
| | | | and AXP809 PMICs. Disabled for now.
* Add 32K output klock support.kettenis2017-12-171-17/+60
|
* Add magic to make USB PYs work on Allwinner H3/H5/A64.kettenis2017-12-171-4/+15
|
* Add wsdisplay options needed for X and VT switching.kettenis2017-12-171-1/+5
| | | | ok patrick@
* Pass Cortex-R4 reset vector to activation function.patrick2017-12-171-2/+2
|
* Read RAM base address and size so we know where to put the firmware.patrick2017-12-162-3/+104
|
* Implement setting the chip into active mode, as needed for setting uppatrick2017-12-162-14/+63
| | | | the PCIe-based BCM43602's firmware in the PCI attachment driver.
* Support setting the Cortex-R4, as found on a BCM43602, to passive mode.patrick2017-12-161-2/+9
|
* Add some more Chip IDs to bwfm(4).patrick2017-12-161-1/+4
|
* Enforce voltage limits from the device tree. Enforcing the limits alsokettenis2017-12-162-3/+21
| | | | | | | happens when regulators are registered. As a consequence they will be properly initialized even when the firmware doesn't do that. ok patrick@
* Add support for 1-byte reads and writes.kettenis2017-12-162-23/+63
|
* Enable sxirsb(4).kettenis2017-12-162-2/+4
|
* Add a driver for the RSB controller found on various Allwinner SoCs.kettenis2017-12-166-3/+533
| | | | | | | | 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@
* Add a few more Allwinner A80 clocks.kettenis2017-12-151-1/+44
|
* put where im up to into the tree so jmatthew@ can look at it.dlg2017-12-151-143/+367
|
* ifq_barrier should be callable by any nic, not just MPSAFE ones.dlg2017-12-151-4/+1
| | | | | | | 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.
* add ifiqueues for mp safety and nics with multiple rx rings.dlg2017-12-155-78/+284
| | | | | | | | | | | | | | | | | | | | | | | | 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@
* make sched_barrier use cond_wait/cond_signal.dlg2017-12-142-23/+17
| | | | | | | | | | | 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@
* Don't bother using DETACH_FORCE for the softraid luns at rebootderaadt2017-12-142-13/+14
| | | | | time; the aggressive mountpoint destruction seems to hit insane use-after-frees when we are already far on the way down.
* Give vflush_vnode() a hint about vnodes we don't need to account as "busy".deraadt2017-12-143-11/+14
| | | | | Change mountpoint to RDONLY a little later. Seems to improve the rw->ro transition a bit.
* Make roaming after a background scan work while tcpbench -u is runningstsp2017-12-141-2/+3
| | | | | | | | | | 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@
* My previous commit broke the ramdisk build; fix itstsp2017-12-141-3/+5
|
* If switching RW->RO, then stop deferring timestamp writes...and possiblyguenther2017-12-141-4/+16
| | | | | | | | | | 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@
* Stop printing debug info about stations leaving a wifi network whenstsp2017-12-141-5/+7
| | | | we aren't running in hostap or ibss mode.
* The pf code marks ICMP packets belonging to an TCP or UDP divertbluhm2017-12-142-19/+18
| | | | | | | | | | | | | | | | | 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@