summaryrefslogtreecommitdiff
path: root/sys
AgeCommit message (Collapse)Author
2018-04-27The i.MX8M has the same quirk as the i.MX6SX, where the CAP1 registerPatrick Wildt
spills into the CAP register.
2018-04-27Newer fec(4), like implemented on i.MX8M, have multiple interrupt linesPatrick Wildt
to the ethernet controller for different types of events. On the i.MX8M interrupts only seem to happen on the last interrupt, while the i.MX6 that we support very well only has a single interrupt line. Simply establish all three lines (if available) in a non-MPSAFE fashion to make ethernet work on the i.MX8M SoC. ok kettenis@
2018-04-27implement test for running in a hypervisor on amd64/i386Jonathan Gray
2018-04-26vmm(4): passthrough port 0x61 to vmd(8)Mike Larkin
ok guenther
2018-04-26Oups, we only need vmmci(4) for the ramdisk, not the whole vmm(4).Peter Hessler
noticed by deraadt@ and mlarkin@
2018-04-26enable vmmci(4) on the ramdisks, so bsd.rd plays nicer when it powers offPeter Hessler
OK mlarkin@
2018-04-26vmm(4): Rearrange some interrupt window exiting codeMike Larkin
Simplify some code and reduce the number of places we are handling VINTR exits. ok brynet
2018-04-26Prefer leaq+%rip-relative over movabsqPhilip Guenther
xrstor_resume must not have profile prologue, so use NENTRY Don't use _C_LABEL() with some pure-ASM labels
2018-04-26net80211: stub SIOCS80211SCAN, make ifconfig scan instant.Paul Irofti
The following removes the functionality of the SIOCS80211SCAN ioctl. After long discussions with stps@, mpi@, and deraadt@ we decided that this was the correct way of fixing ifconfig scan from blocking the network stack. The kernel will continue scanning in the background and filling the nodes array, but ifconfig scan commands will now basically do just a SIOCG80211ALLNODES and pretty print the array. So the output stays the same but is instant. In fact, when the interface is freshly brought up, if you type fast enough, you can see the array being filled by running multiple ifconfig scans in sequence. The SIOCS80211SCAN ioctl stays for now as wi(4), pgt(4) and malo(4) still need it around. But not for long... Another change that this introduces is the fact that ifconfig scan no longer plays with UP and DOWN. If the interface is down it complains and exits. This is needed in order to maintain the nodes list. Works on iwm(4), iwn(4), urtwn(4), run(4) and athn(4). Tested by mpi@, landry@, florian@, thanks! OK mpi@.
2018-04-26Reorder trapframe/intrframe to put %rbp next to %rip and make itPhilip Guenther
behave like a real call frame, thus vastly simplifying the ddb back trace logic. based on whinging from deraadt@ ok jasper@ mpi@ phessler@
2018-04-26vmm(4): remove some unnecessary kernel lock code from the SVM guest loopMike Larkin
that is not needed; this code deals with delaying the relocking of the kernel lock until after interrupts are processed during external interrupt exiting, but this is handled differently on SVM. External interrupts are automatically handled by the CPU as soon as stgi() is performed after exit. (The original code came from the VMX/Intel guest loop.) ok guenther@
2018-04-26Remove solock() surrounding PRU_CONTROL in soo_ioctl().Paul Irofti
We do not need the lock there. Missed this in my former commit pushing NET_LOCK() down the stack. Found the hard way by naddy@, sorry! OK mpi@.
2018-04-26vmm(4): ensure SVM_INTERCEPT_INTR is always enabled before enteringMike Larkin
guest VM.
2018-04-26Reduce differences between isoch & bulk/intr routines.Martin Pieuchot
ok stsp@
2018-04-26Follows section 6.2.3.6 to compute endpoint interval.Martin Pieuchot
ok stsp@
2018-04-26prot_exec is the correct name; spotted by landryTheo de Raadt
2018-04-26Drop into ddb(4) if pmap_tlb_shoot*() take too much time in MP_LOCKDEBUGMartin Pieuchot
kernels. While here sync all MP_LOCKDEBUG/while loops. ok mlarkin@, visa@
2018-04-26Rewrite fdcopy() to avoid memcpy()s.Martin Pieuchot
With and ok visa@
2018-04-25Simplify the handling of faults in iretq and xrstor by doing thePhilip Guenther
handling purely in ASM instead of fixing up the state to call into C...all in order to return back into a chunk of custom ASM which was longer than the direct solution! ok mlarkin@
2018-04-25vmm(4): clarify whose FPU state we are saving (change in a comment)Mike Larkin
no code change
2018-04-25Make this header standalone #if __BSD_VISIBLE, by including needed headersJeremie Courreges-Anglas
Puts us in line with Free/NetBSD and Linux and will get us rid of pointless patches in the ports tree. ok guenther@ deraadt@
2018-04-25Fix use of unreferenced vnode by decrementing the vnode's referenceVisa Hankala
count after unlocking. To improve consistency, use vput() instead of VOP_UNLOCK() + vrele(). OK guenther@, mpi@, tedu@
2018-04-25use size_t for the size of buffers and strings, not int.David Gwynne
sprinkle some bounded attributes while here. ok deraadt@
2018-04-25Teach mtx_enter_try(9) to avoid deadlocks after a panic.Martin Pieuchot
ok deraadt@
2018-04-25Introduce fd_iterfile() a new helper function to iterate over `filehead'.Martin Pieuchot
This turns `filehead' into a local variable, that will make it easier to protect it. ok visa@
2018-04-25update ttm and radeondrm(4) to Linux 4.4.129Jonathan Gray
Compared to the previous Linux 3.8 based port this adds support for KAVERI/KABINI/MULLINS APUs and OLAND/BONAIRE/HAINAN/HAWAII GPUs. Thanks to the OpenBSD Foundation for sponsoring this work.
2018-04-25Add a way to reattach efifb(4). This will be used when radeondrm(4)Jonathan Gray
attaches and claims glass console but after root is mounted if firmware is not found efifb gets reattached to have a useable glass console.
2018-04-24Use pf_rm_rule() instead of pool_put() to decrement references byAlexander Bluhm
the rule created in pf_rule_copyin(). Plugs a potential kif memory leak in pf(4) ioctl. OK sashan@
2018-04-24Move code into inline functions to hide #ifdefs and improve readability.Philip Guenther
Constipate a couple variables. Delete IDTVEC() macro and code handling 32bit-only traps (panic instead). ok mlarkin@
2018-04-24vmm(4): fix lockups on SVM hosts when booting Linux guestsMike Larkin
The previous version of the code used "disable_intr" as a protection around the FPU state saving routine, which left host RFLAGS.IF=0 when entering the guest. If the guest ended up in a non-exitable condition, the machine could hang due to missed TLB flush IPIs (and eventual kernel lock contention and starvation). tested by brynet@ ok guenther@
2018-04-24<machine/i82489reg.h> isn't used herePhilip Guenther
ok mlarkin@
2018-04-24Fix copy and paste typo in pfi_kif_unref route error message.Alexander Bluhm
2018-04-24Make the ramdisks compile again, we don't have MROUTING on them.Florian Obser
Found the hard way.
2018-04-24Fill the 'card' member of v4l2_capability struct with the usb productLandry Breuil
name coming from usbd_devinfo_vp() instead of the dummy "Generic USB video class device" string, makes it easier to differentiate multiple webcams in firefox's webrtc permission dialog. ok/help mpi@
2018-04-24Make futex(2) also return ECANCELED in case SA_RESTART was set.Paul Irofti
Prodded by and ok mpi@
2018-04-24account for FPU context switch (uvm statistic only)Mike Larkin
2018-04-24Validate timespec and return ECANCELED when interrupted with SA_RESTART.Paul Irofti
Discussing with mpi@ and guenther@, we decided to first fix the existing semaphore implementation with regards to SA_RESTART and POSIX compliant returns in the case where we deal with restartable signals. Currently we return EINTR everywhere which is mostly incorrect as the user can not know if she needs to recall the syscall or not. Return ECANCELED to signal that SA_RESTART was set and EINTR otherwise. Regression tests pass and so does the posixsuite. Timespec validation bits are needed to pass the later. OK mpi@, guenther@
2018-04-24Push NET_LOCK down in the default ifioctl case.Paul Irofti
For the PRU_CONTROL bit the NET_LOCK surrounds in[6]_control() and on the ENOTSUPP case we guard the driver if_ioctl functions. OK mpi@
2018-04-24make the check for XSAVE the same as it is later in the file, forMike Larkin
consistency. ok guenther note - there is no equivalent diff here for i386 since XSAVE is not used there.
2018-04-24Enable gpioiic(4) and gpioow(4). From Artturi Alm.Mark Kettenis
2018-04-24Run duplicate address detection again if an existing address getsFlorian Obser
updated from userland that was marked duplicated or tentative. Otherwise we would just lose the duplicated / tentative state and assume that the address is now unique and usable. OK kn
2018-04-24Remove unused rtentry parameter.Florian Obser
Input bluhm OK benno, kn, claudio
2018-04-24Enable em(4) on loongson.Visa Hankala
2018-04-24Do not lock the kernel when expanding the working buffer.Visa Hankala
malloc(9) and free(9) are MP-safe nowadays. OK mpi@
2018-04-23Move efi_cleanup() to before the mem_pass() since efi_cleanup() mightYASUOKA Masahiko
change the memory map. diff from Ryan Lennox ok kettenis
2018-04-23regenccardenas
2018-04-23Add ids for AMD 15h 3xh family along with Kaveri graphicsccardenas
Ok mlarkin@ jsg@
2018-04-22Use free(9) size argument in azalia_codec_select_dacs(). FromAlexandre Ratchov
Michael W. Bombardieri. Thanks.
2018-04-22Wrap debug-only variable definition in #ifdef AZALIA_DEBUG. FromAlexandre Ratchov
Michael W. Bombardieri. Thanks.
2018-04-22Add reference counting that prevents freeing of busy aesni sessions.Visa Hankala
The early freeing has become possible because aesni_process() and crypto_freesession() are no longer serialized by the kernel lock. The flaw has caused kernel panics with IPsec traffic. Issue seen by some, fix tested by mabi on bugs@ OK mikeb@, mpi@