summaryrefslogtreecommitdiff
path: root/sys/dev
AgeCommit message (Collapse)Author
2017-11-02Switch DEC 3000 (TURBOchannel) alpha serial code to MI z8530 code.Martin Pieuchot
ttyB* minor numbers change; be sure to rerun MAKEDEV if you do not upgrade with bsd.rd Adapted from NetBSD by miod@
2017-10-29IFF_NOARP has no effect if the interface don't use ether_input() norMartin Pieuchot
ether_output().
2017-10-28Add the compat-mode setup for wsmouse.Ulf Brosziewski
2017-10-28Adapt the Elantech handlers (v1-3) to the new wsmouse infrastructure.Ulf Brosziewski
The new versions use wsmouse_configure, and leave compat-mode handling to wsmouse. ok stsp
2017-10-27Replace ancient DELAY inherited from Mach and the associated scaryMartin Pieuchot
comment with a barrier. Tested in both fast and slow modes. from miod@
2017-10-26Move common code to add/remove multicast filters to ieee80211_ioctl(9).Martin Pieuchot
ok jsg@, stsp@
2017-10-24remove defines for ioctls the kernel doesn't recogniseJonathan Gray
ok mpi@
2017-10-23Even if a USB transfer fails, call umb_start() so that processingGerhard Roth
of the if_snd queue doesn't stall. ok stsp@
2017-10-22It's time I claimed proper copyright on this.Stefan Sperling
2017-10-22In iwm(4), allocate command response buffers dynamically in a ringStefan Sperling
instead of stashing responses in one single buffer in the softc. Allows getting rid of a tsleep() which protected the single buffer. Tested by myself and Carlos Cardenas on 7260, 7265, and 8260. hurray ok deraadt@
2017-10-21Even though letting the firmware handle the handshake is nice fromPatrick Wildt
a user perspective, it's rather horrible from a security perspective. Especially since there has not only been the KRACK attack, but also exploited wireless firmware. Thus this commit changes the way that bwfm(4) is integrated into our network stack. Instead of making it an Ethernet controller with some WiFi capability, deeply integrate it into the net80211 stack. This way we can do the WPA handshake in software and we don't have to reimplement or copy too much code from the net80211 stack. Some code taken from NetBSD where Jared McNeill committed bwfm(4) with net80211 integration as well. Discussed with and "looks good" stsp@
2017-10-21Initialize all fields in the BCDC protocol, otherwise the controllerPatrick Wildt
behaves erratically and drops packets on TX. Found the hard way by Jared McNeill. While there, also set the priority field. ok stsp@
2017-10-20Kill dead ioctl handlers.Martin Pieuchot
SIOCGIF{HARD,}MTU are handled by ifioctl() and not passed down to drivers. ok visa@
2017-10-19Don't just return but setup and resubmit the transfer if we're notPatrick Wildt
getting the data we expect to be getting. Otherwise the firmware can starve our USB RX descriptors using invalid packets. Caught by Jared McNeill.
2017-10-19spelling fix; from miodJason McIntyre
2017-10-19Don't forget to free the firmware in the error path, and make sure toPatrick Wildt
pass the proper size. Caught by Jared McNeill.
2017-10-19Disable promisc mode and accepting all multicast packets. These shouldPatrick Wildt
be properly enabled by the correct ioctls.
2017-10-18Pass the SIOCG80211ALLCHANS and SIOCG80211STATS ioctls to our net80211Patrick Wildt
which can handle those ioctls quite well for us.
2017-10-18Add a scan timeout so we can recover if the firmware decides not toPatrick Wildt
send us any answers to our request.
2017-10-18Pad the holes in the struct to make sure compilers do not choose toPatrick Wildt
pad the structs in a different way.
2017-10-18Read and extract the channel number from the chanspec to beautify thePatrick Wildt
scan results. Since the channel number is encoded on both IO types in the same way, we don't need to implement per IO type helpers for now.
2017-10-18It turns out that using the packed attribute on most structs was a badPatrick Wildt
idea since the brcmfmac implementation relies on the compiler generated padding. Removing the packed attribute allows reading correct data from the BSS info. As a next step it might be a good idea to pad the structs manually.
2017-10-18Stop handling SIOCSIFMTU like in the wireless stack.Martin Pieuchot
This driver does not use the net80211 stack, so let ether_ioctl() handle it like any other Ethernet driver. Suggested by and ok patrick@, ok stsp@
2017-10-18Extract supported frequencies and HT/VHT mode from the firmware insteadPatrick Wildt
of assuming the chip supports both 2.4GHz and 5Ghz. Based on a diff from Jared McNeill.
2017-10-18Revert previous commit, since not all interfaces behaved the same.Patrick Wildt
2017-10-18Only overwrite the caller's variable if we successfully read data fromPatrick Wildt
the chip.
2017-10-17remove the remaining references to .depend files since nothing creates themChristian Weisgerber
any longer; ok espie@ deraadt@
2017-10-16Allow a more fine grained control about which ciphers to use.Patrick Wildt
2017-10-16Handle wpa parameters using the ieee80211 ioctl so we can startPatrick Wildt
setting and allowing only the specified parameters.
2017-10-16Clear up some defines regarding WPA cipher settings. This allows mePatrick Wildt
to attach to my WiFi AP. It looks like even though it's thought of as a bitvector, the settings are exclusive. More tests will have to occur to verify that theory. Add a comment to enabling the firmware supplicant, mentioning its use is not really awesome.
2017-10-16drm/i915/bios: ignore HDMI on port AJonathan Gray
From Jani Nikula 33d1fa43aad4ca11f5d01ede363c1dbdd2010540 in linux 4.4.y/4.4.92 2ba7d7e0437127314864238f8bfcb8369d81075c in mainline linux ok kettenis@
2017-10-15Set default join preferences to prefer APs based on the RSSI, withPatrick Wildt
a boost set to prefer 5GHz APs.
2017-10-15Similar to other USB based backend drivers, have a list of TX/RXPatrick Wildt
buffers. By storing the pointer of the TX mbuf in the TX buffer, we can make sure to free the mbuf properly after TX completed. This also seems to speed up the WiFi scan. previous version ok stsp@
2017-10-15Initialize status return code in ar5k_ar5211_reset() and ar5k_ar5212_reset(),Stefan Sperling
in the same way as ar5k_ar5210_reset() does it. Error messages were displaying uninitialized values: "ath_reset: unable to reset hardware; hal status 3497439432" ok mpi@
2017-10-13Implement media auto selection for DEC 3000.Martin Pieuchot
diff from miod@
2017-10-12Apparently one of the main concepts in the SDMMC I/O subsystem is thatPatrick Wildt
the driver attached to an SDIO card always holds the lock and only releases it once it detaches. Now with that in mind, some time ago sdmmc_io_function_disable() and sdmmc_io_function_ready() were changed to only assert the write lock and not take it, but not all of the tree was converted. Change sdmmc_io_function_enable() as well, and remove the enter/exit dance in the interrupt code. Apparently there is no SDIO driver yet/anymore which would trigger those issues. ok kettenis@
2017-10-12Add missing size to free(); ok deraadt@ mpi@anton
2017-10-11regenPatrick Wildt
2017-10-11Add bwfm(4), a driver for Broadcom FullMAC WiFi controllers. ThePatrick Wildt
FullMAC, in comparison to SoftMAC, does most WiFi handling in the firmware that's running on the controller. This means we have to work around the net80211 stack while still implementing all the WiFi interfaces to userland. This driver is still in early development. So far it can connect to open WiFis over the USB bus. SDIO and PCIe support, for devices like the Raspberry Pi 3 or the Macbooks, is not yet implemented. Also mbufs on the transmit path leak and are not yet freed. ok stsp@
2017-10-11Fix debug printf, from Dave Voutila.Martin Pieuchot
2017-10-10hidmt: send input mode set report as 2 bytes, matches linuxJoshua Stein
tested by a few
2017-10-10hidmt: add support for hybrid packet mode used by some touchpadsJoshua Stein
2017-10-10hidmt: rename internal hidmt_input struct to hidmt_data, avoid clashJoshua Stein
with hidmt_input function
2017-10-09Fix build on 32 bit; paddr in rtsx_xfer_dma needs to be 64bit on all platforms.Stefan Sperling
Found the hard way by deraadt@
2017-10-09Add ADMA support to rtsx(4) to make use of DMA buffers provided by sdmmc(4).Stefan Sperling
Data transfers use a little bit less CPU time now. Tested by me on RT5209 and on RTS525A by jcs@ ok mpi@ visa@
2017-10-09Print the name of the device tree node like we do for simplebus(4).Mark Kettenis
This makes it easier to match dmesg output to the device tree. ok patrick@
2017-10-09The previous commit was deemed too invasive, so back it out and replacePatrick Wildt
it with a simple ifdef that uses the inline keyword if being compiled with clang and doesn't use the keyword if being compiled with gcc. ok kettenis@
2017-10-09Correct logic check preventing the device to attach.Martin Pieuchot
Fix regression introdruced in previous. Found the hardway and diff from weerd@
2017-10-09Turns out that the previous commit resolves the problem on Clang but atPatrick Wildt
the same time breaks the sparc64 build due to a very similar issue. To make it work, stop returning a huge struct and instead make the caller pass a pointer to the struct it allocated only once on the stack. Similar diff from sashan@ "yeah just make it work, and add it to the mop list" deraadt@
2017-10-08Adapt hidmt to the MT interface of wsmouse, and add the compat-mode setup.Ulf Brosziewski
ok mpi@, jcs@