summaryrefslogtreecommitdiffstats
path: root/sys/dev/ic (follow)
Commit message (Collapse)AuthorAgeFilesLines
* 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)
* Move remaining scsi bus initialization info from "prototype scsi link"krw2020-07-2023-147/+141
| | | | | | | fields to struct scsibus_attach_args. Nuke the struct scsi_link * (saa_sc_link) in scaibus_attach_args. Explicitly initialize each field in scsibus_attach_args variables.
* The IEEE80211_F_HIDENWID flag is now part of ic_userflags, not ic_flags.stsp2020-07-203-6/+6
| | | | | | | | | | Fix code which was still looking for this flag at the old location. The 'hidenwid' feature was slightly broken as a result: The SSID was leaked in probe responses to wildcard probe requests. There are other trivial ways of snooping a "hidden" SSID however so this is not a big deal. Problem reported by Mogens Jensen.
* Move the adapter related items (luns, adapter, adapter_target,krw2020-07-1923-134/+153
| | | | | | | adapter_buswidth, adapter_softc) from struct scsi_link to struct scsibus_attach_args. Additional compile tests by jmatthew@ (sparc64) and aoyam@ (luna88k).
* Access adapter softc via link->bus->sb_adapter_softc.krw2020-07-1626-98/+97
| | | | | | | | In sparc64 autoconf access 'luns' via sb_luns and 'adapter_buswidth' via sb_adapter_buswidth. Removes last post-config uses of the copies of bus related information in scsi_link.
* Set SDEV_NOWIDE and SDEV_NOSYNC on the 'real' link (xs->sc_link) whenkrw2020-07-141-3/+3
| | | | negotiations fail.
* Where we have a pointer (sc) to the relevant adapter_softc, usekrw2020-07-133-6/+6
| | | | | &sc->sc_dev to get a device pointer rather than using the void * whence we obtained 'sc'.
* Remove some pointless casting of void * when assigning onekrw2020-07-138-23/+23
| | | | (scsi_link.adapter_softc) to a pointer of a particular softc type.
* When athn(4) is deciding how to decrypt an incoming frame, look into thestsp2020-07-131-2/+2
| | | | | | | | | ieee80211_node data structure to find the WPA group cipher which was negotiated with the peer, rather than checking the wireless interface's configuration data. Found while investigating a problem where WPA2+TKIP wasn't working with athn. Problem reported by Tim Chase.
* Minor code shuffle to close ranks of sc_link initializations.krw2020-07-121-3/+5
|