Commit Graph

1715 Commits

Author SHA1 Message Date
Florian Walpen
ad370f7658 sound(4): Fix memory map of /dev/dsp devices when buffer size is not a multiple of PAGE_SIZE.
By using sndbuf_getallocsize() instead of sndbuf_getsize() in dsp_mmap_single().

PR:		267555
MFC after:	1 week
Sponsored by:	NVIDIA Networking
2022-11-04 19:05:34 +01:00
Alexander Motin
2a31a06bf1 Add random VMware device IDs.
Just to make dmesg look nicer there.

MFC after:	1 week
2022-10-20 10:19:24 -04:00
Nuno Teixeira
b44869cba1 sound: add patch for Lenovo Legion 5 Intel
Laptop Legion Lenovo 5 15MH05 (Intel)

Patch to fix the sound on this machine.
It requires sending the speaker and the headphone jack to the same nid.

PR:		265632
Approved by:	emaste
MFC after:      1 week
Differential Revision:  https://reviews.freebsd.org/D36511
2022-09-16 14:29:30 +01:00
Ed Maste
9054e29681 Retire ISA sound card DMA support
As all ISA sound card drivers have been removed sndbuf_dma no longer
serves any purpose.

Reviewed by:	mav
Relnotes: 	Yes
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D34671
2022-09-15 10:07:23 -04:00
Pavel Timofeev
d88dc1b0b9 hda: add patch for Framework laptop v2 headphone jack
Fix headphone (12th gen Intel laptops) and mic jack (both 11th and
12th gen) switching.

PR:		262579
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D36354
2022-09-13 12:16:26 -04:00
Neel Chauhan
c4e591c9ab snd_hda: Remove duplicate erroneous HDA_INTEL_ALLKPS line
MFC after:		3 days
Differential Revision:	https://reviews.freebsd.org/D36483
2022-09-07 11:17:26 -07:00
Neel Chauhan
22ecfc580b snd_hda: Add the full Intel AlderLake HD Audio PCI IDs
This is based off the Linux file sound/hda/intel-dsp-config.c.

Reviewed by:		imp (src)
Tested on:		HP Spectre x360 16-f0023dx
MFC after:		3 days
Differential Revision:	https://reviews.freebsd.org/D36476
2022-09-07 09:03:56 -07:00
Gordon Bergling
ac34f366cc sound(4): Fix a typo in asource code comment
- s/overriden/overridden/

MFC after:	3 days
2022-09-03 15:30:39 +02:00
Gleb Popov
5abe178970 hda: Add a patch for ASUS ROG GL553VE.
Summary:
This change enables headset detection on the laptop.

PR: 256169

Approved by: mav

Differential Revision: https://reviews.freebsd.org/D36007
2022-08-04 13:57:32 +03:00
Ed Maste
716924cb48 Retire snd_sbc ISA sound card driver
Along with the snd_sb8 and snd_sb16 drivers.  They supported ISA
Creative Sound Blaster and compatible sound cards.

Note that isa/sb.h is not removed, as it is still used by some PCI
sound card drivers.

ISA sound card drivers are deprecated as discussed on the current[1] and
stable[2] mailing lists.  Deprecation notices were added in e39ec8933b
and MFCd to stable branches.

Driver removals are being committed individually so that specific
drivers can be restored if necessary (either in FreeBSD or by downstream
projects).

[1] https://lists.freebsd.org/archives/freebsd-current/2022-March/001680.html
[2] https://lists.freebsd.org/archives/freebsd-stable/2022-March/000585.html

Reviewed by:	mav
Relnotes:	Yes
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D34671
2022-06-21 14:50:04 -04:00
Ed Maste
5126e5eeeb Retire snd_mss ISA sound card driver
The snd_mss driver supported Microsoft Sound System sound cards.

ISA sound card drivers are deprecated as discussed on the current[1] and
stable[2] mailing lists.  Deprecation notices were added in e39ec8933b
and MFCd to stable branches.

Driver removals are being committed individually so that specific
drivers can be restored if necessary (either in FreeBSD or by downstream
projects).

[1] https://lists.freebsd.org/archives/freebsd-current/2022-March/001680.html
[2] https://lists.freebsd.org/archives/freebsd-stable/2022-March/000585.html

Reviewed by:	mav
Relnotes:	yes
Sponsored by:	The FreeBSD Foundation
Differential Revision:	Thttps://reviews.freebsd.org/D34671
2022-06-21 14:50:04 -04:00
Ed Maste
754decef38 Retire snd_gusc ISA sound card driver
snd_gusc supported the Gravis UltraSound MAX and UltraSound PnP sound
cards.

ISA sound card drivers are deprecated as discussed on the current[1] and
stable[2] mailing lists.  Deprecation notices were added in e39ec8933b
and MFCd to stable branches.

Driver removals are being committed individually so that specific
drivers can be restored if necessary (either in FreeBSD or by downstream
projects).

[1] https://lists.freebsd.org/archives/freebsd-current/2022-March/001680.html
[2] https://lists.freebsd.org/archives/freebsd-stable/2022-March/000585.html

Reviewed by:	mav
Relnotes:	Yes
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D34671
2022-06-21 14:50:04 -04:00
Ed Maste
aa83e9b189 Retire snd_ess ISA sound card driver
snd_ess supported sound cards using the ESS 18xx chipset.

ISA sound card drivers are deprecated as discussed on the current[1] and
stable[2] mailing lists.  Deprecation notices were added in e39ec8933b
and MFCd to stable branches.

Driver removals are being committed individually so that specific
drivers can be restored if necessary (either in FreeBSD or by downstream
projects).

[1] https://lists.freebsd.org/archives/freebsd-current/2022-March/001680.html
[2] https://lists.freebsd.org/archives/freebsd-stable/2022-March/000585.html

Reviewed by:	mav
Relnotes:	Yes
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D34671
2022-06-21 14:50:04 -04:00
Ed Maste
df51e63eb5 Retire snd_ad1816 ISA sound card driver
snd_ad1816 supported ISA sound cards based on the Analog Devices
AD1816A "SoundPort® Controller".

ISA sound card drivers are deprecated as discussed on the current[1] and
stable[2] mailing lists.  Deprecation notices were added in e39ec8933b
and MFCd to stable branches.

Driver removals are being committed individually so that specific
drivers can be restored if necessary (either in FreeBSD or by downstream
projects).

[1] https://lists.freebsd.org/archives/freebsd-current/2022-March/001680.html
[2] https://lists.freebsd.org/archives/freebsd-stable/2022-March/000585.html

Reviewed by:	mav
Relnotes:	Yes
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D34671
2022-06-21 14:50:04 -04:00
Gordon Bergling
70311ccffc sound(4): Fix a typo in a source code comment
- s/alltogether/altogether/

MFC after:	3 days
2022-06-04 12:11:06 +02:00
John Baldwin
3390adfe42 sound: Remove unused devclass arguments to DRIVER_MODULE. 2022-05-06 15:46:56 -07:00
John Baldwin
2287364e04 Remove pcm_devclass from DRIVER_MODULE invocations. 2022-05-06 15:46:56 -07:00
John Baldwin
13bebcd35f pcm: Initialize pcm_devclass in sound_modevent.
Reviewed by:	imp
Differential Revision:	https://reviews.freebsd.org/D34998
2022-04-21 10:29:14 -07:00
John Baldwin
8109ec9d89 pcm: Remove dead code from sound_modevent.
Reviewed by:	imp
Differential Revision:	https://reviews.freebsd.org/D34997
2022-04-21 10:29:14 -07:00
John Baldwin
b8ef5a7ea0 sound aoa: Mark variable only used in debug trace as unused. 2022-04-12 14:58:58 -07:00
John Baldwin
56f5947a71 Remove checks for __GNUCLIKE_ASM assuming it is always true.
All supported compilers (modern versions of GCC and clang) support
this.

Many places didn't have an #else so would just silently do the wrong
thing.  Ancient versions of icc (the original motivation for this) are
no longer a compiler FreeBSD supports.

PR:		263102 (exp-run)
Reviewed by:	brooks, imp
Differential Revision:	https://reviews.freebsd.org/D34797
2022-04-12 10:05:45 -07:00
Gordon Bergling
35fbe62477 sound(4): Fix a typo in a source code comment
- s/Miscellanious/Miscellaneous/

MFC after:	3 days
2022-04-09 09:23:37 +02:00
John Baldwin
bdfc2fc0c4 pcm mss: Quiet unused variable warnings.
- Remove dummy variable for a register read.  Keep the register
  read despite the dubious comment.

- Move all references to set_res under #if 0.
2022-04-07 17:01:29 -07:00
John Baldwin
eda611e45e pcm via82c686: Remove unused variables. 2022-04-07 17:01:29 -07:00
John Baldwin
11fd7ec044 pcm hdspe: Remove unused variable. 2022-04-07 17:01:29 -07:00
John Baldwin
92e7c96648 pcm envy24: Remove some dead code and associated unused variables.
The dead code was commented out in the initial import and hasn't
changed since.
2022-04-07 17:01:29 -07:00
John Baldwin
0025422091 pcm emu10k1: Remove dead code in channel_setblocksize callbacks. 2022-04-07 17:01:29 -07:00
John Baldwin
3e4aa9c629 pcm atiixp: Remove dead variable.
The Linux driver clears ATI_REG_CMD_AC_RESET and sets
ATI_REG_CMD_POWERDOWN, so writing the calculated value that sets both
would seem to be wrong.  This could be updated to match Linux's
behavior, but instead I've just left it as-is.
2022-04-07 17:01:28 -07:00
John Baldwin
4afc92cd6e ac97_initmixer: Remove write-only variables. 2022-04-06 16:45:27 -07:00
John Baldwin
546629073d cmi: Mark rsp as unused.
If the DEB macro is manually enabled to enable tracing then this
variable is used.  This doesn't use __diagused since it is dependent
on a non-standard debugging macro.
2022-04-06 16:45:27 -07:00
Warner Losh
ad1b7fd714 hdspe_dmapsetmap: eliminate write only variable sc
Sponsored by:		Netflix
2022-04-04 22:30:22 -06:00
Warner Losh
557627dda9 hdaa_eld_dump: eliminate write only variable len
Sponsored by:		Netflix
2022-04-04 22:30:17 -06:00
Warner Losh
8717135d37 emu10kx: eliminate write only variables val, r and move i to loop
Sponsored by:		Netflix
2022-04-04 22:30:13 -06:00
Warner Losh
451f54707a emu10kx-pci: eliminate write only variable r
Sponsored by:		Netflix
2022-04-04 22:30:11 -06:00
Warner Losh
7387abd342 emu_midi_probe: eliminate write only variable r
Sponsored by:		Netflix
2022-04-04 22:30:09 -06:00
Warner Losh
33985865b2 pcmcsa_attach: eliminate write only variable unit
Sponsored by:		Netflix
2022-04-04 22:30:07 -06:00
Warner Losh
3e423419cf midicsa_attach: eliminate write only variable func
Sponsored by:		Netflix
2022-04-04 22:30:06 -06:00
Warner Losh
0c64fe0068 cs4281: eliminate write only variable codecno
Sponsored by:		Netflix
2022-04-04 22:30:04 -06:00
Warner Losh
635a4068d2 sb_probe: eliminate write only variable r
Sponsored by:		Netflix
2022-04-04 22:30:02 -06:00
Warner Losh
668986eae9 sb16_probe: eliminate write only variable r
Sponsored by:		Netflix
2022-04-04 22:30:01 -06:00
Warner Losh
3a7365acc8 ess_probe: eliminate write only variable r
Sponsored by:		Netflix
2022-04-04 22:29:59 -06:00
Gordon Bergling
0ce9617620 sound(4): Fix a typo in a source code comment
- s/exisitng/existing/

MFC after:	3 days
2022-04-02 14:40:10 +02:00
Gordon Bergling
24498b53ef sound(4): Fix a typo in a source code comment
- s/immediatly/immediately/

MFC after:	3 days
2022-04-02 10:50:03 +02:00
Gordon Bergling
dc8d33b368 snd_csa(4): Fix a few common typos in source code comments
- s/hander/handler/

MFC after:	3 days
2022-04-02 10:30:52 +02:00
Ed Maste
a10c85e0f9 hda: whitespace fix for realtek pin patches 2022-03-23 20:54:51 -04:00
Ed Maste
da03ac41c9 sound: test PCM_REGISTERED before PCM_DETACHING
PCM_REGISTERED(d) tests that d is not NULL, so perform that check first
as we may have cases where devclass_get_softc has a null entry.

PR:		262671
Reviewed by:	hselasky
MFC after:	1 week
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D34648
2022-03-23 20:10:00 -04:00
Ed Maste
0a4b561f8a Remove unused snd_ds1 file ds1-fw.h
Fixes:		92e6b4712b ("Retire broken snd_ds1 and ...")
Reported by:	joel
2022-03-21 14:21:03 -04:00
Ed Maste
e39ec8933b Add deprecation notices to ISA sound cards
ISA sound cards (and ISA itself) are long obsolete.  NYCBUG dmesgd has
no entries for any of these devices after 2005.

Add deprecation notices to device attach routines and man pages for:

snd_ad1816  Analog Devices AD1816 SoundPort
snd_ess     Ensoniq ESS
snd_gusc    Gravis UltraSound
snd_mss     Microsoft Sound System
snd_sbc     Creative Sound Blaster

Reviewed by:	cy, mav
MFC after:	3 days
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D34604
2022-03-19 14:57:26 -04:00
Ed Maste
92e6b4712b Retire broken snd_ds1 and snd_maestro drivers
In 2012 joel@ reported[1] that these were not functional, and they do
not appear to have been fixed since.

[1] https://lists.freebsd.org/pipermail/freebsd-multimedia/2012-January/012751.html

Reported by:	joel
Relnotes:	Yes
Sponsored by:	The FreeBSD Foundation
2022-03-18 20:33:19 -04:00
Ed Maste
ef5dec7cc7 Remove snd_aureal driver source
This driver was not finished when it was committed in 1999 and was never
connected to the build.

A version of the driver used to be available in ports as
audio/aureal-kmod, but it has been removed.  It did not build on FreeBSD
10.x or later and the binary objects it required were not available
after Google Code disappeared.

PR:		124343
Reported by:	joel
MFC after:	1 week
Sponsored by:	The FreeBSD Foundation
2022-03-18 16:27:35 -04:00