summaryrefslogtreecommitdiff
path: root/sys
AgeCommit message (Collapse)Author
2017-04-27Unifdef KADB.Martin Pieuchot
ok deraadt@
2017-04-27Use (32-bit) word-sized access in the a4x bus space routine even if onlyMark Kettenis
a byte or a half-word is needed. Certain implementations of the Synopsis Designware copy-and-paste logic blocks don't respond to transactions that are smaller than a word. Fixes the serial console on boards with a Rockchip RK3288.
2017-04-27Add code to identify the CPUs on arm64 systems. The primary CPU is attachedMark Kettenis
and identified early on. For the secondary CPUs this happens late, such that the drivers we need to spin up CPUs, such as psci(4), will be available. This also fixes some code in simplebus(4) where the return value of OF_getprop() was not properly checked. Heavily based on an earlier diff from drahn@. ok drahn@, jsg@
2017-04-27rename a struct that was denoted as "VMX only" to make it more clearMike Larkin
that it can be used in SVM and VMX. no functional change
2017-04-27use a more descriptive value from the VEI_DIR_xxx enum instead of aMike Larkin
hardcoded number. no functional change
2017-04-27vmm(4): proper save/restore of FPU context during entry/exit.Mike Larkin
tested by reyk, dcoppa, and a few others. ok kettenis@ on the fpu bits ok deraadt@ on the vmm bits
2017-04-27Restore if_iwm.c r1.173 (mira retry change) which got incarcerated byStefan Sperling
the backout police even though it wasn't responsible for anything. pointed out by tb@
2017-04-27Revert if_iwm.c to the state of r1.170 because ETOOMANYDRAGONSATONCE.Stefan Sperling
Performance regression reported by deraadt@ and uvm_fault reported by fcambus@. I will be poking further at this out of tree.
2017-04-26Perform H-FSC root queue allocation in the kernelMike Belopuhov
Since only leaf queues can have packets assigned to them, H-FSC requires the user specified root queue to have a parent. To simplify userland tools and the configuration interface, the kernel can be leveraged to set it up. ok henning
2017-04-26Convert some hardcoded function names in printfs into %s / __func__.Mike Larkin
Some of these pointed out by Michael W. Bombardieri, I went through the file and fixed the rest. No functional change.
2017-04-26Get rid of convoluted macros in iwm's receive code path.Stefan Sperling
Since we now sync the entire Rx DMA buffer the SYNC_RESP_STRUCT() macro which was used to sync just parts of the buffer can be replaced by assignments. The SYNC_RESP_PTR() macro was already unused so just remove it. The ADVANCE_RXQ() macro was used just once so expand it in place.
2017-04-26Remove the size argument of iwm_rx_addbuf() and use a constant internally.Stefan Sperling
All callers were passing the same constant IWM_RBUF_SIZE, which is derived from the smallest RX buffer the hardware supports (4k). Smaller sizes don't make sense anyway and larger sizes are not on our horizon for now.
2017-04-26Convert some hardcoded function names in printfs into %s / __func__.Mike Larkin
Some of these pointed out by Michael W. Bombardieri, I went through the file and fixed the rest. No functional change.
2017-04-26Tell MiRA about the actual number of retries instead of pretending thatStefan Sperling
a frame which was retried N times was retried just once. This punishes retry-heavy data rates even more and should reduce latency. It does not seem to have a noticable effect on net throughput in my testing. If this change causes throughput problems for anyone, let me know. ok tb@ mlarkin@
2017-04-26Fix a typo relating to savefpu alignmentMike Larkin
ok kettenis
2017-04-24Add support for Cortex-A12. Even though ARM rebranded these as Cortex-A17Mark Kettenis
they have a different ID from "real" Cortex-A17 cores. ok phessler@, patrick@
2017-04-24Process fdt before iobus devices. Needed later when interrupt andVisa Hankala
MDIO controller drivers are attached using fdt.
2017-04-24Add an fdt blob for octeon systems whose firmware does not provideVisa Hankala
a device-tree. It will be needed later when more device drivers are attached using fdt. OK kettenis@
2017-04-24Since rev 1.1 ix has attempted to require a 64 bit BAR, the test forJonathan Gray
this was wrong and was corrected at the end of last year in rev 1.140. Before then a 64 bit BAR was not enforced as the test was wrong. It turns out there exist 82598 parts which have a 32 bit BAR so change the test to only require a memory BAR and not a 64 bit memory BAR. Problem reported by Robert Blacquiere. ok mikeb@
2017-04-24Implement monitor mode support for iwm(4).Stefan Sperling
The magic commands to capture raw 802.11 frames on e.g. channel 1 are: ifconfig iwm0 mediaopt monitor chan 1 tcpdump -n -i iwm0 -y IEEE802_11_RADIO -s 4096 -w /tmp/iwm.pcap ifconfig iwm0 -mediaopt monitor -chan
2017-04-24Implement support for multiple packets per receive DMA buffer in iwm(4).Stefan Sperling
We can now clear SINGLE_FRAME_MSK in the receive configuration register. Linux has not set this bit in years, and Dragonfly stopped setting it in commit b5eb43f0280bbcfd26af51cf5a4b8e8ff3590b67. This is a prerequisite for monitor mode since the firmware seems to ignore the SINGLE_FRAME_MSK bit while running in monitor mode and sends us garbage. Tested on 7260, 7265, and 8260 devices.
2017-04-24Stop dumping registers on "normal" segmentation faults. Do print the contentsMark Kettenis
of the esr_el1 register for unhandled userland exceptions (and continue to dump the registers in that case). Handle breakpoint traps and make sure we call refreshcreds() on userland traps. ok jsg@
2017-04-23Handle unequal numbers of Tx and Rx streams in MiRA.Stefan Sperling
Problem reported by Colton Lewis on misc@ ok tb@
2017-04-23Some of the LOG_NOTICE messages from PF were seen in normal operationsStuart Henderson
with certain rulesets and excessively noisy; move them to LOG_INFO (which was previously unused). ok benno@
2017-04-22Recognize Loongson 3A2000/3B2000 processors.Visa Hankala
2017-04-22Fix an early boot failure on Loongson 3A2000.Visa Hankala
Reported and patch tested by wen heping
2017-04-22Reindent with tabs and add missing braces.Visa Hankala
2017-04-21Speed up DIOCKILLSTATES by using the RB tree index if all fields usedYASUOKA Masahiko
by the tree of given state key are filled. ok sasha
2017-04-21Cast the result of the __swapXX macros to the proper type.Todd C. Miller
The ternary operator was causing the result to be promoted to int for __swap16. Fixes warning with clang. OK guenther@
2017-04-21Make id parameter of iwm_send_cmd_pdu() a uint32_t so that it matchesStefan Sperling
the size of the corresponding id field in struct iwm_host_cmd. Patch by Imre Vadasz.
2017-04-21Fix nic lock usage around iwm_disable_rx_dma().Stefan Sperling
iwm_disable_rx_dma() was unintentionally releasing the nic lock too early. Patch by Imre Vadasz.
2017-04-21Fix nic lock usages around iwm_{read,write}_prph().Stefan Sperling
The iwm_{read,write}_prph() calls don't grab the nic lock themselves so make sure to acquire it where necessary. The iwm_{set,clear}_bits_prph() on the other hand acquire/release the nic lock themselves. Since the nic lock doesn't do recursive locking we need to be careful to avoid accidentally releasing the nic lock too early that way. Patch by Imre Vadasz.
2017-04-21Use ether_crc32_le() instead of a custom version.Martin Pieuchot
From Hiltjo Posthuma.
2017-04-20Get TCB address using the RDHWR instruction instead of __get_tcb().Visa Hankala
This gives fast access to the address on systems that implement the UserLocal register. TCB caching is still used when running in the single-threaded mode in order not to penalize old systems. The kernel counterpart of this change must be in place before using this diff! With guenther@
2017-04-20Make TCB address available to userspace via the UserLocal register.Visa Hankala
This lets programs get the address without a system call on OCTEON II and later. Add UserLocal load emulation for systems that do not implement the RDHWR instruction or the UserLocal register. OK guenther@
2017-04-20only 32 bits of the pledgecode were passed up via ktraceTheo de Raadt
from Anton Lindqvist ok semarie
2017-04-20Drop unnecessary headers. This fixes kernel build on platformsVisa Hankala
without <machine/mplock.h>.
2017-04-20regenJonathan Gray
2017-04-20Remove an incorrect Bay Trail I2C entry that masked a valid Bay TrailJonathan Gray
PCIE entry as it used the same product id. Add another PLX/Avago/"Broadcom" PCIE bridge seen in the wild while here.
2017-04-20Add option to compile witness(4).Visa Hankala
2017-04-20Tweak lock inits to make the system runnable with witness(4)Visa Hankala
on amd64 and i386.
2017-04-20Hook up mutex(9) to witness(4).Visa Hankala
2017-04-20Hook up rwlock(9) to witness(4).Visa Hankala
Loosely based on a diff from Christian Ludwig
2017-04-20Hook up mplock to witness(4) on amd64 and i386.Visa Hankala
2017-04-20Add a port of witness(4) lock validation tool from FreeBSD.Visa Hankala
Go-ahead from kettenis@, guenther@, deraadt@
2017-04-20Add routines for saving stack traces and printing saved tracesVisa Hankala
on amd64 and i386. With guenther@
2017-04-20Use register names without the % prefix in the global register variableMark Kettenis
declarations since clang doesn't register the %-prefixed ones.
2017-04-19Add sizes to free()David Hill
ok deraadt@ visa@
2017-04-19Add size to free()David Hill
ok deraadt@ visa@
2017-04-19icmp6_rip6_input() was mostly duplicated code from rip6_input().Alexander Bluhm
Merge these functions together and remove icmp6_rip6_input(). OK mpi@