summaryrefslogtreecommitdiff
path: root/sys
AgeCommit message (Collapse)Author
2018-05-02Record lock type even if witness is disabled. The value will be neededVisa Hankala
if the lock becomes watched later.
2018-05-01Bump the clock frequency to a higher level that every card (per spec)Patrick Wildt
has to support for MMC cards prior to reading the extended registers. We already do this for SD cards. Fixes eMMC support on the i.MX8M. Tested by and ok kettenis@
2018-05-01Simplify/refactor the way vendor/product/serial informations areLandry Breuil
gathered from usb devices. Cache them early in usbd_new_device() instead of querying the device several times (the content wont change anyway) and uselessly generating usb traffic (which could conflict with other access..) The heuristic stays the same, first look in the device descriptor, then try to match against usb_known_vendors/usb_known_products, then fallback to use the idVendor/idProduct codes. Remove the now useless 'usedev' parameter from usbd_fill_deviceinfo(). Tested from bsd & bsd.rd. suggested by and ok mpi@
2018-05-01vmmci(4) depends on pvbus(4) being available, unbreakPeter Hessler
from mlarkin@
2018-04-30Reduce the scope of the NET_LOCK() in in_control(). Two functions wereTheo Buehler
protected: mrt_ioctl() and in_ioctl(). The former has no other callers and only needs a read lock. The latter will need refactoring to reduce the lock's scope further. In a first step, establish a single exit point and protect most of the function body with the NET_LOCK() while removing the NET_LOCK() from a handful of callers. suggested by & ok mpi, ok visa
2018-04-30Use acpi_register_gpio() to register gpio space like we do for chvgpio(4).Mark Kettenis
ok mpi@
2018-04-30Treat all negative values of witness_watch equally for robustness.Visa Hankala
2018-04-30vmd(8): unbreak i386Mike Larkin
2018-04-29In hash{free,init}(), there's no need to calculate the size of the hash table ifanton
the given number of elements already is a power of 2. ok visa@, "seems like a good plan" deraadt@
2018-04-29Don't bother with background scans while the desired BSSID is fixed.Stefan Sperling
Patch by Jesper Wallin
2018-04-29Unsigned values are always >= 0, fix Coverity 1468443.Martin Pieuchot
2018-04-29Fail early when transfers aren't completed in order.Martin Pieuchot
ok pirofti@, visa@
2018-04-29'juming' -> 'jumping' in comment.Kenneth R Westerback
Pointed out by Ryan Lennox via tech@
2018-04-29em: Add magic delay for HP elitebook 820 G3Stefan Fritsch
Add another magic 1ms delay that seems to help with some remaining "Hardware Initialization Failed" issues on an HP elitebook 820 G3 with i219LM. A printf() at the same place helps, too. ok mikeb@
2018-04-29em: Make em_get_software_flag() recursiveStefan Fritsch
The em driver calls em_get_software_flag() recursively, which causes the semaphore to be unlocked too early. Make em_get_software_flag and em_release_software_flag handle this correctly. Freebsd does not do this, but they have a mutex that probably allows them to detect recursive calls to e1000_acquire_swflag_ich8lan(). Reworking the openbsd driver to not recursively get the semaphore would be very invasive. ok mikeb@
2018-04-29em: Improve access logic for software flagStefan Fritsch
Some em chips have a semaphore ("software flag") to synchronize access to certain registers between OS and firmware (ME/AMT). Make the logic to get the flag match the logic in freebsd. This includes higher timeouts and waiting for a previous unlock to complete before trying a lock again. ok mikeb@
2018-04-29INIT->RUN transitions are valid in monitor mode, so don'tStefan Sperling
debug print "invalid transition" to dmesg in this case.
2018-04-28Some drivers handle settting a new wifi link state manually, so make surePeter Hessler
they flush old nodes and set the interface link state to down, like the framework does. OK stsp@ pirofti@
2018-04-28replace add_*_randomness with enqueue_randomness()Jasper Lievisse Adriaanse
this gets rid of the source annotation which doesn't really add anything other than adding complexitiy. randomess is generally good enough that the few extra bits that the source type would add are not worth it. ok mikeb@ deraadt@
2018-04-28When starting a background scan, free the nodes table to ensure weStefan Sperling
get an up-to-date view of APs around us. In particular, we need to kick out the AP we are associated to. Otherwise, our current AP might stay cached if it is turned off while we are scanning, and we could end up picking a now non-existent but "good looking" AP over and over. found with and ok phessler@
2018-04-28Fix WEP key selection in ieee80211_get_txkey().Stefan Sperling
The WEP key index is stored in ic_def_txkey. The iGTK ("integrity group key") index is specific to WPA. The previous code happened to always select WEP key index 0 since the iGTK index is not yet used by any driver. ok phessler@
2018-04-28If ieee80211_encrypt() is passed a key with an unrecognized cipherStefan Sperling
type then panic immediately instead of silently dropping packets. ok phessler@
2018-04-28Remove redundant error checkkn
error is set by copyinstr(9) only and we return early if it is non-zero, so the loop's last condition is always true. OK deraadt, jca
2018-04-28pgt(4): do not tsleep in the scan ioctl.Paul Irofti
The only action taken during the scan ioctl was to sleep. This does not make sense as the scanning process happens in the state machine behind the scenes. Initialization indeed performs newstate(SCAN), but that is done no matter if the user waits for the full results or not. Instead, this change unifies the (new) user experience when performing ifconfig scan and shows the nodes list produced by the latest background scan. This was not tested on real hardware. Please message me directly in case this broke your card. OK stsp@, deraadt@
2018-04-28Print more debug informations in the event xfer handler.Martin Pieuchot
2018-04-28Correct IST macro and add a new macro for setting Frame IDs.Martin Pieuchot
2018-04-28bump my copyrightPeter Hessler
2018-04-28don't check if we still have the BFD flag set when sending a packet, as wePeter Hessler
might be shutting the session down
2018-04-28properly delete the bfd configuration when it is disabledPeter Hessler
2018-04-28use unsigned variables for things that we use as unsignedPeter Hessler
noticed by clang
2018-04-28add the socket lock around our use of socketsPeter Hessler
2018-04-28Clean up the parameters of VOP_LOCK() and VOP_UNLOCK(). It is alwaysVisa Hankala
curproc that does the locking or unlocking, so the proc parameter is pointless and can be dropped. OK mpi@, deraadt@
2018-04-27rasops: implement scrollbackJoshua Stein
activate it for efifb and inteldrm ok kettenis
2018-04-27If a wifi driver does not provide an ic_bgscan_start() function there is noStefan Sperling
point in scheduling ic_bgscan_timeout() since this timeout will find that it has nothing to do. ok phessler pirofti
2018-04-27use nitems()Jasper Lievisse Adriaanse
verified md5 sum on amd64 ok mlarkin@
2018-04-27Fix WEP.Stefan Sperling
Clear group keys in iee80211_newstate only if we're doing WPA. Otherwise, ieee80211_crypto_clear_groupkeys() will clear WEP keys configured by userland before associating. (All WEP keys are group keys.) ok phessler@ tb@ pirofti@
2018-04-27Fix the scan loop: We were only looking for an AP once and stoppedStefan Sperling
scanning if none was found. Accidentally broken in recent ifconfig scan changes by pirofti and me. ok pirofti
2018-04-27-fretpoline for non-RAMDISK kernels. Skylake product needs it, andTheo de Raadt
therefore all other x86 cpus must pay the performance price of the hazard workaround until Skylake disappears from the ecosystem eventually like 486. This returns your cpu's performance to pre-inflated performance. ok mlarkin guenther
2018-04-27Introduce an helper function to extract endpoint's max burst value.Martin Pieuchot
Use this helper to calculate the Transfer Burst Count (TBC) and Transfer Last Burst Packet Count (TLBPC) required for isochronous support. Note that SS companion descriptors are still not read. While here print the ETE and IST values in debug mode.
2018-04-27Introduce an helper function to extract endpoint's max burst value.Martin Pieuchot
Use this helper to calculate the Transfer Burst Count (TBC) and Transfer Last Burst Packet Count (TLBPC) required for isochronous support. Note that SS companion descriptors are still not read. While here print the ETE and IST values in debug mode.
2018-04-27regenMike Larkin
2018-04-27add Marvell 88W8897 wireless to pcidevs (no driver yet)Mike Larkin
2018-04-27vmm(4): pass through ELCRx ports to vmd(8)Mike Larkin
These ports are used for Edge/Level control on the legacy PIC and will be needed for a subsequent commit.
2018-04-27Print index as unsigned.Martin Pieuchot
2018-04-27Move FREF() inside fd_getfile().Martin Pieuchot
ok visa@
2018-04-27Fix an off-by-one in xhci_xfer_tdsize().Martin Pieuchot
While here use UE_GET_SIZE() coherently. ok pirofti@, stsp@, visa@
2018-04-27Remove duplicate device identification so my usb drive attaches as a umassTheo Buehler
and not as a uplcom. From mpi, ok deraadt, no objection kettenis
2018-04-27Fix the prologue detection to match amd64 opcodes, not i386 opcodesPhilip Guenther
ok mlarkin@
2018-04-27Delete superfluous includes of <sys/file.>Philip Guenther
ok krw@
2018-04-27The i.MX8M has the same quirk as the i.MX6SX, where the CAP1 registerPatrick Wildt
spills into the CAP register.