aboutsummaryrefslogtreecommitdiff
path: root/sys/gnu/dev
Commit message (Collapse)AuthorAgeFilesLines
* bwn(4): BWN_GPL_PHY: make compile againBjoern A. Zeeb2025-06-221-1/+1
| | | | | | | | | | compiler complains about error: comparison of different enumeration types ('bwn_phy_band_t' and 'bwn_band_t'); so use the correct enum value. Sponsored by: The FreeBSD Foundation PR: 287695 Reported by: (tom.mcclean gmail.com) MFC after: 3 days
* sys: Automated cleanup of cdefs and other formattingWarner Losh2023-11-271-1/+0
| | | | | | | | | | | | | | | | Apply the following automated changes to try to eliminate no-longer-needed sys/cdefs.h includes as well as now-empty blank lines in a row. Remove /^#if.*\n#endif.*\n#include\s+<sys/cdefs.h>.*\n/ Remove /\n+#include\s+<sys/cdefs.h>.*\n+#if.*\n#endif.*\n+/ Remove /\n+#if.*\n#endif.*\n+/ Remove /^#if.*\n#endif.*\n/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/types.h>/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/param.h>/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/capsicum.h>/ Sponsored by: Netflix
* sys: Remove $FreeBSD$: one-line .c patternWarner Losh2023-08-167-14/+0
| | | | Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
* sys: Remove $FreeBSD$: one-line .h patternWarner Losh2023-08-167-7/+0
| | | | Remove /^\s*\*+\s*\$FreeBSD\$.*$\n/
* sys: Remove $FreeBSD$: two-line .h patternWarner Losh2023-08-162-4/+0
| | | | Remove /^\s*\*\n \*\s+\$FreeBSD\$$\n/
* bwn: eliminate dead writes in BWN_GPL_PHYGreg V2022-05-042-5/+10
| | | | | | | | | This fixes the newly Werror'ed useless write warnings with options BWN_GPL_PHY. Reviewed by: markj MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D35105
* bwn(4): txpid2g/txpid5g[lh] are not defined after sromrev 7; the defaultLandon J. Fuller2018-02-131-0/+3
| | | | | | | | | | | indices into the TX power gain table should be used instead. This enables use of bwn(4) with later BCM4321 revisions. Reported by: Trev Roydhouse Notes: svn path=/head/; revision=329228
* bwn(4): migrate bwn(4) to the native bhnd(9) interface, and drop siba_bwn.Landon J. Fuller2018-02-056-148/+602
| | | | | | | | | | | | | - Remove the shim interface that allowed bwn(4) to use either siba_bwn or bhnd(4), replacing all siba_bwn calls with their bhnd(4) bus equivalents. - Drop the legay, now-unused siba_bwn bus driver. - Clean up bhnd(4) board flag defines referenced by bwn(4). Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D13518 Notes: svn path=/head/; revision=328912
* Revert r327828, r327949, r327953, r328016-r328026, r328041:Pedro F. Giffuni2018-01-211-3/+2
| | | | | | | | | | | | | | | | | | Uses of mallocarray(9). The use of mallocarray(9) has rocketed the required swap to build FreeBSD. This is likely caused by the allocation size attributes which put extra pressure on the compiler. Given that most of these checks are superfluous we have to choose better where to use mallocarray(9). We still have more uses of mallocarray(9) but hopefully this is enough to bring swap usage to a reasonable level. Reported by: wosch PR: 225197 Notes: svn path=/head/; revision=328218
* misc geom and gnu: make some use of mallocarray(9).Pedro F. Giffuni2018-01-151-2/+3
| | | | | | | | | | | | | | | | Focus on code where we are doing multiplications within malloc(9). None of these ire likely to overflow, however the change is still useful as some static checkers can benefit from the allocation attributes we use for mallocarray. This initial sweep only covers malloc(9) calls with M_NOWAIT. No good reason but I started doing the changes before r327796 and at that time it was convenient to make sure the sorrounding code could handle NULL values. Differential revision: https://reviews.freebsd.org/D13837 Notes: svn path=/head/; revision=328026
* Introduce bwn(4) support for the bhnd(4) bus.Landon J. Fuller2017-12-026-33/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, bwn(4) relies on the siba_bwn(4) bus driver to provide support for the on-chip SSB interconnect found in Broadcom's older PCI(e) Wi-Fi adapters. Non-PCI Wi-Fi adapters, as well as the newer BCMA interconnect found in post-2009 Broadcom Wi-Fi hardware, are not supported by siba_bwn(4). The bhnd(4) bus driver (also used by the FreeBSD/MIPS Broadcom port) provides a unified kernel interface to a superset of the hardware supported by siba_bwn; by attaching bwn(4) via bhnd(4), we can support both modern PCI(e) Wi-Fi devices based on the BCMA backplane interconnect, as well as Broadcom MIPS WiSoCs that include a D11 MAC core directly attached to their SSB or BCMA backplane. This diff introduces opt-in bwn(4) support for bhnd(4) by providing: - A small bwn(4) driver subclass, if_bwn_bhnd, that attaches via bhnd(4) instead of siba_bwn(4). - A bhndb(4)-based PCI host bridge driver, if_bwn_pci, that optionally probes at a higher priority than the siba_bwn(4) PCI driver. - A set of compatibility shims that perform translation of bwn(4)'s siba_bwn function calls into their bhnd(9) API equivalents when bwn(4) is attached via a bhnd(4) bus parent. When bwn(4) is attached via siba_bwn(4), all siba_bwn function calls are simply passed through to their original implementations. To test bwn(4) with bhnd(4), place the following lines in loader.conf(5): hw.bwn_pci.preferred="1" if_bwn_pci_load="YES bwn_v4_ucode_load="YES" bwn_v4_lp_ucode_load="YES" To verify that bwn(4) is using bhnd(4), you can check dmesg: bwn0: <Broadcom 802.11 MAC/PHY/Radio, rev 15> ... on bhnd0 ... or devinfo(8): pcib2 pci2 bwn_pci0 bhndb0 bhnd0 bwn0 ... bwn(4)/bhnd(4) has been tested for regressions with most chipsets currently supported by bwn(4), including: - BCM4312 - BCM4318 - BCM4321 With minimal changes to the DMA code (not included in this commit), I was also able to test support for newer BCMA devices by bringing up basic working Wi-Fi on two previously unsupported, BCMA-based N-PHY chipsets: - BCM43224 - BCM43225 Approved by: adrian (mentor, implicit) Sponsored by: The FreeBSD Foundation & Plausible Labs Differential Revision: https://reviews.freebsd.org/D13041 Notes: svn path=/head/; revision=326454
* [bwn] convert another PHY-N workaround to the freebsd bwn format.Adrian Chadd2016-05-231-8/+4
| | | | | | | | | These were hidden behind an #ifdef that we weren't setting. I don't have the hardware in question to check. Notes: svn path=/head/; revision=300448
* [bwn] typo.Adrian Chadd2016-05-191-1/+1
| | | | Notes: svn path=/head/; revision=300193
* [bwn] disable rfon checks so the 2056/2057 radios are programmed.Adrian Chadd2016-05-191-2/+8
| | | | | | | | | | | | This was the big missing piece for getting the BCM94322MC NIC to work at all. Tested: * BCM4322, STA mode (2g, 5g) Notes: svn path=/head/; revision=300192
* [bwn] improve N-PHY debuggability a little bit.Adrian Chadd2016-05-191-5/+14
| | | | Notes: svn path=/head/; revision=300191
* [bwn] add opt_wlan.h and opt_bwn.h to each of the phy_n source files.Adrian Chadd2016-05-196-0/+17
| | | | Notes: svn path=/head/; revision=300190
* [bwn] add initial bwn(4) N-PHY code, ported from Linux b43.Adrian Chadd2016-05-1713-0/+26868
| | | | | | | | | | | | | | | | | | | | | This is a GPLv2 PHY-N implementation based on the Linux b43 driver, ported over to work in bwn(4). I've tested this on the BCM4321 11abgn device, in 11bg and 11a modes. The b43 PHY code only supports 11abg, no 11n, and 20MHz only wide channels. Yes, this is a GPLv2 driver, so it won't be included in the default builds. Tested: * BCM4321 11abgn device (Apple!), 11bg and 11a STA mode. Obtained from: Linux b43 Notes: svn path=/head/; revision=300016
* Use new OSS-based BSD-licensed header for cs sound driver.Pedro F. Giffuni2012-02-011-341/+0
| | | | | | | | | | | | | | | | | | | | The cs driver requires a table with firmware values. An alternative firmware is available in a similar Open Sound System driver. This is actually a partial revert of Revision 77504. Special thanks to joel@ for patiently testing several replacement attempts. The csa driver and the complete sound system are now free of the GPL. Tested by: joel Approved by: jhb (mentor) MFC after: 3 weeks Notes: svn path=/head/; revision=230897
* Replace GPLd headers from the Maestro3 driver with BSD licensedPedro F. Giffuni2012-01-202-906/+0
| | | | | | | | | | | | | | | | | | | | versions derived from /usr/ports/audio/oss. The particular headers used were taken from the attic/drv/oss_allegro directory and are mostly identical to the previous files. The Maestro3 driver is now free from the GPL. NOTE: due to lack of testers this driver is being considered for deprecation and removal. PR: kern/153920 Approved by: jhb (mentor) MFC after: 2 weeks Notes: svn path=/head/; revision=230401
* Replace GPL'd headers in the emu10kx snd driver code.Pedro F. Giffuni2012-01-113-2015/+0
| | | | | | | | | | | | | | | | | This uses the emuxkireg.h already used in the emu10k1 snd driver. Special thanks go to Alexander Motin as he was able to find some errors and reverse engineer some wrong values in the emuxkireg header. The emu10kx driver is now free from the GPL. PR: 153901 Tested by: mav, joel Approved by: jhb (mentor) MFC after: 2 weeks Notes: svn path=/head/; revision=229981
* Add snd_emu10kx driver for Creative SoundBlaster Live! and Audigy seriesAlexander Leidinger2006-07-152-0/+414
| | | | | | | | | | | | | | | | | | sound cards with optional pseudo-multichannel playback. It's based on snd_emu10k1 sound driver. Single channel version is available from audio/emu10kx port since some time. The two new ALSA header files (GPLed), which contain Audigy 2 ("p16v") and Audigy 2 Value ("p17v") specific interfaces, are latest versions from ALSA Mercurial repository. This is not connected to the build yet. Submitted by: Yuriy Tsibizov <Yuriy.Tsibizov@gfk.ru> Notes: svn path=/head/; revision=160383
* - Update ALSA emu10k1.h (it was imported as emu10k1-alsa.h) header file toAlexander Leidinger2006-07-153-1249/+445
| | | | | | | | | | | | | | | latest version from Mercurial repository. It brings definition of some additional Audigy 2 / Audigy 2 Value registers. - Use new #defines from ALSA emu10k1.h - Remove unused include files: + emu10k1-ac97.h was imported from ALSA and never used, + emu10k1.h was imported from Creative Linux emu10k1 driver, but only AUDIGY_CODEBASE was used from it. Submitted by: Yuriy Tsibizov <Yuriy.Tsibizov@gfk.ru> Notes: svn path=/head/; revision=160382
* /* -> /*- for copyright notices, minor format tweaks as necessaryWarner Losh2005-01-064-4/+5
| | | | Notes: svn path=/head/; revision=139778
* Add dol FreeBSD dol and /*+ize licenseWarner Losh2005-01-061-1/+3
| | | | Notes: svn path=/head/; revision=139777
* This commit was generated by cvs2svn to compensate for changes in r124361,David E. O'Brien2004-01-111-10/+19
|\ | | | | | | | | | | | | which included commits to RCS files with non-trunk default branches. Notes: svn path=/head/; revision=124362
| * Vendor import emu10k1.h from version 1.0.1 of the ALSA driver.vendor/alsaDavid E. O'Brien2004-01-111-10/+19
| | | | | | | | | | | | | | | | ftp://ftp.alsa-project.org/pub/driver/alsa-driver-1.0.1.tar.bz2 or http://www.alsa-project.org/alsa/cvs/alsa-kernel/include/emu10k1.h Notes: svn path=/vendor-sys/alsa/dist/; revision=124361
* | Sync with Creative's 8010.h rev 1.51.David E. O'Brien2004-01-091-74/+140
| | | | | | | | Notes: svn path=/head/; revision=124277
* | Dike out some very Linux-specific parts that we can't compile with.David E. O'Brien2004-01-091-0/+8
| | | | | | | | | | | | | | Also protect AC97_MUTE which is also defined in our own ac97.h. Notes: svn path=/head/; revision=124276
* | This commit was generated by cvs2svn to compensate for changes in r124273,David E. O'Brien2004-01-091-2/+42
|\| | | | | | | | | | | | | which included commits to RCS files with non-trunk default branches. Notes: svn path=/head/; revision=124274
| * Vendor import revision 1.9 of ac97_codec.h (we renamed the file) fromDavid E. O'Brien2004-01-091-2/+42
| | | | | | | | | | | | | | http://cvs.sourceforge.net/viewcvs.py/emu10k1/emu10k1/ac97_codec.h Notes: svn path=/vendor-sys/alsa/dist/; revision=124273
* | This commit was generated by cvs2svn to compensate for changes in r115990,David E. O'Brien2003-06-071-0/+1361
|\| | | | | | | | | | | | | which included commits to RCS files with non-trunk default branches. Notes: svn path=/head/; revision=115991
| * Vendor import emu10k1.h from version 0.9.4 of the ALSA driver (whichDavid E. O'Brien2003-06-071-0/+1361
| | | | | | | | | | | | | | | | | | includes some needed Audigy support). This can be found at ftp://ftp.alsa-project.org/pub/driver/alsa-driver-0.9.4.tar.bz2 and http://www.alsa-project.org/alsa/cvs/alsa-kernel/include/emu10k1.h Notes: svn path=/vendor-sys/alsa/dist/; revision=115990
* | This commit was generated by cvs2svn to compensate for changes in r113778,David E. O'Brien2003-04-211-0/+245
|\| | | | | | | | | | | | | which included commits to RCS files with non-trunk default branches. Notes: svn path=/head/; revision=113779
| * Vendor import revision 1.8 of ac97_codec.h (we renamed the file) fromDavid E. O'Brien2003-04-211-0/+245
| | | | | | | | | | | | | | http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/emu10k1/emu10k1/ac97_codec.h Notes: svn path=/vendor-sys/alsa/dist/; revision=113778
| * Vendor import revision 1.51 of 8010.h (we renamed the file) fromvendor/alsa/1.51David E. O'Brien2003-04-181-68/+134
| | | | | | | | | | | | | | | | | | http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/emu10k1/emu10k1/8010.h. This includes some Audigy support. Notes: svn path=/vendor-sys/alsa/dist/; revision=113654 svn path=/vendor-sys/alsa/1.51/; revision=113655; tag=vendor/alsa/1.51
| * Vendor import revision 1.39 of 8010.h (we renamed the file) fromvendor/alsa/1.39David E. O'Brien2003-04-181-18/+23
| | | | | | | | | | | | | | | | | | http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/emu10k1/emu10k1/8010.h. Rev 1.39 best matches our rev 1.3. Notes: svn path=/vendor-sys/alsa/dist/; revision=113651 svn path=/vendor-sys/alsa/1.39/; revision=113652; tag=vendor/alsa/1.39
| * This commit was manufactured by cvs2svn to create branch 'ALSA'.cvs2svn2000-04-021-0/+666
| | | | Notes: svn path=/vendor-sys/alsa/dist/; revision=58920
* Sync with Creative's 8010.h rev 1.39.David E. O'Brien2003-04-181-3/+3
| | | | Notes: svn path=/head/; revision=113653
* new (gpl licensed) firmware image for cs4280/cs46xx sound chipsCameron Grant2001-05-301-0/+340
| | | | Notes: svn path=/head/; revision=77503
* Close the opening comment line on these two files that mysteriouly vanished.Scott Long2001-05-272-2/+2
| | | | Notes: svn path=/head/; revision=77275
* Oops. Unremove vestiges of the old, broken sound drivers. They are nowBruce Evans2001-05-243-0/+1580
| | | | | | | used in new drivers. Notes: svn path=/head/; revision=77141
* Remove vestiges of the old, broken sound drivers.Bruce Evans2001-05-243-1580/+0
| | | | Notes: svn path=/head/; revision=77134
* Driver for the ESS Maestro3 and Allegro sound chips. Note that due to theScott Long2001-02-012-0/+906
| | | | | | | | | amount of GPL'd firmware in the driver, it will only be built as a module. Approved by: cg Notes: svn path=/head/; revision=71901
* sync CCR register definitions with creative sourcesCameron Grant2000-08-061-1/+3
| | | | Notes: svn path=/head/; revision=64308
* fix missing defines and prototype for emu_vdump()Cameron Grant2000-04-031-3/+9
| | | | Notes: svn path=/head/; revision=58958
* unfinished sblive driver, playback/mixer only for now - not enabled inCameron Grant2000-04-021-0/+666
conf/files i don't seem to be clearing the cache right resulting in a short initial burst of noise, despite doing the same as creative and alsa. i'm committing now so more eyes can pore over the code. Notes: svn path=/head/; revision=58919