summaryrefslogtreecommitdiffstats
path: root/sys/dev/ic (follow)
Commit message (Collapse)AuthorAgeFilesLines
* ansijsg2021-03-0717-636/+262
|
* off by onejsg2021-03-031-2/+2
| | | | ok claudio@ deraadt@
* Read and parse OTP on the BCM4378. There are quite a few firmware andpatrick2021-02-261-1/+5
| | | | | | | nvram files used for the different Apple devices. The device tree and the OTP hold the information which of those we will have to use. For now this information will simply be printed, but depending on how we choose to do the firmare distribution we could use it for loadfirmware().
* Refactor bwfm(4) firmware loading. The PCIe backend will need to be ablepatrick2021-02-262-2/+121
| | | | | | | to load the CLM blob like the SDIO backend already does. Additionally it is also helpful for the PCIe backend to try a file named after the device tree compatible. Thus refactor the SDIO code and make it available for both SDIO and PCIe.
* Some newer chips have two D11/802.11 cores, and we need to reset both atpatrick2021-02-251-3/+36
| | | | the same time.
* Prevent zero size devices from attachingjan2021-02-251-6/+11
| | | | | | This also fixes two NULL ptr derefs in later code path. OK patick@, krw@
* we don't have to cast to caddr_t when calling m_copydata anymore.dlg2021-02-253-13/+12
| | | | | | | | | | | | | | | | the first cut of this diff was made with coccinelle using this spatch: @rule@ type caddr_t; expression m, off, len, cp; @@ -m_copydata(m, off, len, (caddr_t)cp) +m_copydata(m, off, len, cp) i had fix it's opinionated idea of formatting by hand though, so i'm not sure it was worth it. ok deraadt@ bluhm@
* Enumerate GCI core, which seems to contain the OTP on the Apple M1.patrick2021-02-242-4/+7
|
* remove some unused includesjsg2021-02-237-832/+0
|
* Add a barrier between reading the cqe flags and the command ID, whichjmatthew2021-02-091-1/+3
| | | | | | | | should ensure that we don't read a stale command ID and complete the wrong scsi io. powerpc64 base builds were crashing like this fairly regularly. ok deraadt@ dlg@
* Add basic support for BCM4378 as found on the Apple M1 SoCs. There's apatrick2021-01-312-2/+8
| | | | little bit more to do though before it can be enabled.
* bwfm: add a delay in bwfm_set_key_cb before talking to hardwarejcs2020-12-171-1/+3
| | | | | | | | This works around an issue on the BCM43602 where ieee80211 calls this too quickly during authentication and triggers "unexpected pairwise key update" errors. ok patrick
* Rename the macro MCLGETI to MCLGETL and removes the dead parameter ifp.jan2020-12-1210-28/+28
| | | | | | OK dlg@, bluhm@ No Opinion mpi@ Not against it claudio@
* an(4): tsleep(9) -> tsleep_nsec(9)cheloha2020-12-081-3/+3
| | | | | | | | | | | | | | In an_wait() we spin for up to (3 * hz) iterations awaiting AN_EV_CMD. If we don't see it in a given iteration we block for up to 1 tick and spin again. jsg@ suggests instead blocking for 100ms at a time for up to 30 iterations. Discussed with mpi@. Idea from jsg@. Murmurs of agreement from claudio@ and kettenis@. probably ok jsg@
* Extract another couple of chunks from main() into helper functions,krw2020-12-022-3/+16
| | | | get_routefd() and set_user().
* Split imxiic(4) into the FDT-attachment code and the i.MX I2C codepatrick2020-11-172-0/+407
| | | | | | in preparation for upcoming ACPI-attachment. ok kettenis@
* Fix compile error on big-endian machines caused by recent multicast commit.patrick2020-11-161-2/+2
|
* Add multicast support to bwfm(4) to make IPv6 work and to fixpatrick2020-11-161-6/+52
| | | | | | promiscuous mode. ok gerhard@
* Fix athn(4) in client mode against APs that use WPA1/TKIP as the group cipher.stsp2020-11-111-2/+3
| | | | Problem confirmed and fix tested by Matej Nanut.
* Add support for the Micro Crystal RV4162. This variant holds thepatrick2020-10-231-1/+2
| | | | | | | | square wave frequency control bits in the Day Of Week register. To make sure we don't fudge with those bits, only reset those that hold the day and keep the rest as is. ok kettenis@
* Switch away from splsoftnet() and change the code to splnet().claudio2020-10-221-7/+7
| | | | | | splsoftnet was used for the upper layers of the network stack and should no longer be used. OK patrick@
* Replace simple one-line bcopy()/memcpy() of faked data into scsi_xfer with callkrw2020-10-151-2/+2
| | | | | to scsi_copy_internal_data(). Thus getting xs->resid properly set and adding the usual uio/size sanity checks.
* Replace local *_copy_internal_data() with scsi_copy_internal_data().krw2020-10-155-108/+20
|
* Stop exporting `wt_hwqueue' now that drivers don't advertise it.mpi2020-10-117-14/+7
| | | | Pointed by and ok jsg@
* Kill unused IEEE80211_RADIOTAP_HWQUEUE.mpi2020-10-093-8/+5
| | | | | | | | | | Its value is conflicting with an effort to standardize TX flags fields of the radiotap header from Mathy Vanhoef. This flag used to indicate the presence of a specific hardware queue used by WME but is unchecked. ok sthen@, kn@
* Since dlg@'s 2009 scsi midlayer refactoring the 'struct scsi_generic *cmd'krw2020-09-2225-131/+131
| | | | | | | | | | | | member of 'struct scsi_xfer' has always been pointed at the 'struct scsi_generic cmdstore' member of the same instance. So nuke 'cmdstore' and remove the '*' from cmd. Take the address of cmd as required by the various casts. No intentional functional change. luna88k test by aoyama@, sparc64 test by jmatthew@ Identification of 2009's last *cmd use and ok jmatthew@
* Replace '32' with SID_SCSI2_ALEN (a.k.a. 31) when building emulated INQUIRYkrw2020-09-056-12/+12
| | | | | responses. This is what the SCSI specifications say is the correct value and already used in several cases.
* Replace '.response_format = 2' with '.response_format = SID_SCSI2_RESPONSE'.krw2020-09-036-12/+12
|
* When building emulated INQUIRY results use the SCSI_REV_* #define's tokrw2020-09-021-2/+2
| | | | initialize the 'version' field. Not numbers.
* When building emulated INQUIRY results use the SCSI_REV_* #define's tokrw2020-09-025-10/+10
| | | | initialize the 'version' field. Not numbers.
* Rename [READ|WRITE]_BIG to [READ|WRITE]_10. Rename struct scsi_rw_big tokrw2020-09-017-55/+55
| | | | | | struct scsi_rw_10. ok gnezdo@ jmatthew@ (who also did sparc64 compile test)
* Remove needless uses of SDEV_ONLYBIG. It was always set when SDEV_UMASS was set,krw2020-08-261-2/+1
| | | | | | | | and was always checked in concert with SDEV_ATAPI. Just rely on SDEV_ATAPI and SDEV_UMASS in all but the one place sd(4) where SDEV_ONLYBIG is set independently of SDEV_ATAPI/_UMASS. ok jmatthew@
* Declare hw_{prod,serial,uuid,vendor,ver} in <sys/systm.h>.visa2020-08-261-3/+1
| | | | OK deraadt@, mpi@
* Implement UHS-I support in the sdmmc(4) midlayer.kettenis2020-08-241-3/+2
| | | | ok mglocker@
* Re-commit Exar XR17V35x serial port support previously backed out:jcs2020-08-143-5/+26
| | | | | | | | | | | | | | | The Exar XR17V354 has 4 ports that have a 256-byte FIFO, use a frequency of 125Mhz, and have a unique sleep register. A custom interrupt handler is setup in puc for these ports so it can check a register which reports which ports triggered the interrupt, rather than having to run comintr for every port every time. To avoid probing for these ports in com_attach_subr which requires access to registers that may be reserved on certain platforms, pass the sc_uarttype from com_puc_attach since the port type is already known based on the puc device vendor/id. Input from kettenis, tested in snaps
* Give SCSIBUS_B probing a chance to work with better logic inkrw2020-08-131-2/+2
| | | | | | | SCSI_IS_SCSIBUS_B(). i.e. return true when 'A' is finished probing (sc_child != NULL) and the sc_link->bus is != sc_child.
* qlw_xs_bus() must return 0 while bus 0 is being probed.krw2020-08-131-2/+12
| | | | Found the hard way by martijn@ on his alpha.
* The only thing worse than trailing whitespace is leading spaces instead of tabs.krw2020-08-085-107/+107
|
* When this Aviion-only driver is eventually sent to join its friends in the attickrw2020-07-301-3/+1
| | | | | let it go there without the burden of a spurious struct scsi_link member of struct aic6250_softc.
* "#ifndef SIOP_DEBUG\n#undef SIOP_DEBUG\n#endif" is a bit silly.krw2020-07-301-2/+1
|
* Don't #undef AHC_DEBUG. Lets kernel "option AHC_DEBUG" work. Not sure what I waskrw2020-07-291-4/+2
| | | | | | thinking in 2003. Discovered via deraadt@ typo detection.
* fix new typoderaadt2020-07-291-2/+2
|
* SC_DEBUG() and friends are for debugging the SCSI code, not for scattered randomkrw2020-07-291-12/+20
| | | | | | uses in drivers. Use UHADEBUG sections like the debug output in other uha_* files.
* SC_DEBUG() and friends are for debugging the SCSI code, not for scattered randomkrw2020-07-281-3/+4
| | | | | | uses in drivers. Use a CAC_DEBUG sections like the other debug output does.
* SC_DEBUG() and friends are for debugging the SCSI code, not for scattered randomkrw2020-07-284-12/+22
| | | | | | | uses in drivers. Use AHD_DEBUG/AHC_DEBUG sections like all the other debug output does. Don't #include scsi_debug.h.
* Nuke unused struct scsi_link member of struct wd33c93_softc.krw2020-07-251-2/+1
| | | | SGI compile tests by visa@
* Turning on various scsi drivers' *DEBUG options reveals that this haskrw2020-07-2412-41/+43
| | | | | | | | rarely (if ever) been done. Fix many printf format errors to calm clang and gcc on amd64, i386, hppa. Missing #include, complaints if 'option <blah>DEBUG' is used in config files, etc. All in debug code.
* Nuke unused struct scsi_link members of adapter softc's where thekrw2020-07-2223-61/+24
| | | | driver successfully compiles on one or more of amd64, i386, hppa.
* Neither is saa.ssa.pool the same as saa.saa_pool.krw2020-07-201-2/+2
|
* Missed a chunk somewhere along the line. Use our_id vs our_id_b inkrw2020-07-201-7/+3
| | | | | appropriate spots. Don't copy one empty/unused scsi_link (channel) to another empty/unused scsi_link (channel_b)