Commit Graph

125 Commits

Author SHA1 Message Date
Warner Losh
031beb4e23 sys: Remove $FreeBSD$: one-line sh pattern
Remove /^\s*#[#!]?\s*\$FreeBSD\$.*$\n/
2023-08-16 11:54:58 -06: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
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
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
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
Konstantin Belousov
5bb3134a8c Fix some modules to export more used symbols
and remove non-present symbols that are now reported by kmod_syms.awk.

Reviewed by:	emaste
Sponsored by:	The FreeBSD Foundation
MFC after:	1 week
Differential revision:	https://reviews.freebsd.org/D32878
2021-11-18 15:56:23 +02:00
Warner Losh
58aa35d429 Remove sparc64 kernel support
Remove all sparc64 specific files
Remove all sparc64 ifdefs
Removee indireeect sparc64 ifdefs
2020-02-03 17:35:11 +00:00
Glen Barber
bf466ddcff Revert r338423, reapplying r338422, which did get approval but
communication lines got crossed.

Apologies to avatar@ for the confusion.

Approved by:	re (implicit)
Sponsored by:	The FreeBSD Foundation
2018-09-01 15:07:38 +00:00
Glen Barber
b5a3b728c5 Revert r338422, which was did not get official approval from re@.
Approved by:	re (implicit)
Sponsored by:	The FreeBSD Foundation
2018-09-01 13:43:14 +00:00
Tai-hwa Liang
8578932ddb Adding support for CS46xx MIDI output. With this patch, users can
play the MIDI files through /dev/sequencer device with tools like
playmidi. The audio output will go through the external MIDI device
such like wavetable synthesis card.

Reviewed by:	matk (a long time ago), kib
Approved by:	re (kib)
Tested with: 	Terratec SiXPack 5.1+ + Yamaha DB50XG
MFC after:	4 weeks
2018-09-01 11:26:53 +00:00
Enji Cooper
193d9e768b sys/modules: normalize .CURDIR-relative paths to SRCTOP
This simplifies make output/logic

Tested with:	`cd sys/modules; make ALL_MODULES=` on amd64
MFC after:	1 month
Sponsored by:	Dell EMC Isilon
2017-03-04 10:10:17 +00:00
Yoshihiro Takahashi
2b375b4edd Remove pc98 support completely.
I thank all developers and contributors for pc98.

Relnotes:	yes
2017-01-28 02:22:15 +00:00
Warner Losh
528013d5a8 Retire the '@' symlink. It isn't really needed and causes more
problems than it solves. SYSDIR is already defined almost always and
can be used instead. Working around the one case where it isn't is
much easier than working around the fact that @ may not exist in 18
other places.

Differential Revision: https://reviews.freebsd.org/D1100
2014-11-06 16:48:37 +00:00
Warner Losh
df3394b3de Remove dependence on source tree options. Move all kernel module
options into kern.opts.mk and change all the places where we use
src.opts.mk to pull in the options. Conditionally define SYSDIR and
use SYSDIR/conf/kern.opts.mk instead of a CURDIR path. Replace all
instances of CURDIR/../../etc with STSDIR, but only in the affected
files.

As a special compatibility hack, include bsd.owm.mk at the top of
kern.opts.mk to allow the bare build of sys/modules to work on older
systems. If the defaults ever change between 9.x, 10.x and current for
these options, however, you'll wind up with the host OS' defaults
rather than the -current defaults. This hack will be removed when
we no longer need to support this build scenario.

Reviewed by: jhb
Differential Revision: https://phabric.freebsd.org/D529
2014-08-11 14:50:49 +00:00
Marcel Moolenaar
e7d939bda2 Remove ia64.
This includes:
o   All directories named *ia64*
o   All files named *ia64*
o   All ia64-specific code guarded by __ia64__
o   All ia64-specific makefile logic
o   Mention of ia64 in comments and documentation

This excludes:
o   Everything under contrib/
o   Everything under crypto/
o   sys/xen/interface
o   sys/sys/elf_common.h

Discussed at: BSDcan
2014-07-07 00:27:09 +00:00
John Baldwin
d0345bb310 Re-enable -Werror for these modules. It is already enabled for the same
files when built as part of a kernel.
2014-06-09 20:48:38 +00:00
Hans Petter Selasky
a3837e481c Change the USB audio kernel module linking order, so that the USB
audio device driver is detached first and not its children. This fixes
a panic in some cases when unloading "snd_uaudio" while a USB device
is plugged. The linking order affects the order in which the module
dependencies are registered.

MFC after:	1 week
2014-05-14 07:33:06 +00:00
Hans Petter Selasky
827ac19dc2 Invert platform check.
Suggested by:	imp @
MFC after:	2 weeks
2014-05-09 14:35:07 +00:00
Warner Losh
c6063d0da8 Use src.opts.mk in preference to bsd.own.mk except where we need stuff
from the latter.
2014-05-06 04:22:01 +00:00
Hans Petter Selasky
957aad08a4 Build the kernel sound module without ISA DMA support for ARM and MIPS
platforms, because these platforms do not implement the ISA DMA
API. Else the sound modules cannot be loaded when running these
platforms.

MFC after:	2 weeks
2014-05-05 14:31:34 +00:00
Andreas Tobler
7447f978d3 The onyx codec works also as module, so add it.
MFC after:	1 month
2014-01-13 21:44:17 +00:00
Pedro F. Giffuni
646a7fea0c Clean some 'svn:executable' properties in the tree.
Submitted by:	Christoph Mallon
MFC after:	3 days
2013-01-26 22:08:21 +00:00
Alexander Motin
e4afd792df Add driver for the RME HDSPe AIO/RayDAT sound cards -- snd_hdspe(4).
Cards are expensive and so rare, so leave the driver as module.

Submitted by:	Ruslan Bukin <br@bsdpad.com>
MFC after:	2 weeks
2012-03-01 13:10:18 +00:00
Robert Millan
4a47892c81 Add MK_SOURCELESS build option. Setting MK_SOURCELESS to "no" will disable
kernel modules that include binary-only code.

More fine-grained control is provided via MK_SOURCELESS_HOST (for native code
that runs on host CPU) and MK_SOURCELESS_UCODE (for microcode).

Reviewed by:	julian, delphij, freebsd-arch
Approved by:	kib (mentor)
MFC after:	2 weeks
2012-02-04 00:54:43 +00:00
Joel Dahl
ca5a2a70ab Remove leftovers from previous commits.
Approved by:	jhb
2012-02-02 17:25:39 +00:00
Pedro F. Giffuni
b7c60aadbb Cleanup some sound headers that don't need to be in the modules makefiles.
Approved by:	jhb (mentor)
MFC after:	1 week
2012-02-02 00:10:20 +00:00
Pedro F. Giffuni
5dcd37b17d Replace GPLd headers from the Maestro3 driver with BSD licensed
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
2012-01-20 22:37:10 +00:00
Alexander Motin
7c6b05d280 Major snd_hda driver rewrite:
- Huge old hdac driver was split into three independent pieces: HDA
controller driver (hdac), HDA CODEC driver (hdacc) and HDA sudio function
driver (hdaa).
 - Support for multichannel recording was added. Now, as specification
defines, driver checks input associations for pins with sequence numbers
14 and 15, and if found (usually) -- works as before, mixing signals
together. If it doesn't, it configures input association as multichannel.
 - Signal tracer was improved to look for cases where several DACs/ADCs in
CODEC can work with the same audio signal. If such case found, driver
registers additional playback/record stream (channel) for the pcm device.
 - New controller streams reservation mechanism was implemented. That
allows to have more pcm devices then streams supported by the controller
(usually 4 in each direction). Now it limits only number of simultaneously
transferred audio streams, that is rarely reachable and properly reported
if happens.
 - Codec pins and GPIO signals configuration was exported via set of
writable sysctls. Another sysctl dev.hdaa.X.reconfig allows to trigger
driver reconfiguration in run-time.
 - Driver now decodes pins location and connector type names. In some cases
it allows to hint user where on the system case connectors, related to the
pcm device, are located. Number of channels supported by pcm device,
reported now (if it is not 2), should also make search easier.
 - Added workaround for digital mic on some Asus laptops/netbooks.

MFC after:	2 months
Sponsored by:	iXsystems, Inc.
2012-01-15 13:21:36 +00:00
Pedro F. Giffuni
70e0bbedef Replace GPL'd headers in the emu10kx snd driver code.
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
2012-01-11 21:17:14 +00:00
Pedro F. Giffuni
c7e0c9db2b Replace a GPL'd header in the emu10k1 snd driver code.
This brings in the emuxkireg.h from NetBSD (dev/pci) which
is used for the same purpose but is smaller. The emu10k1
is now free from the GPL.

PR:		153901
Obtained from:	NetBSD
Approved by:	core (mentor implicit)
MFC after:	2 weeks
2012-01-03 21:04:54 +00:00
Warner Losh
146fce53d8 MFtbemd: use MACHINE_CPUARCH 2010-09-13 02:05:42 +00:00
Warner Losh
c09808d0d6 MFtbemd:
Use MACHINE_CPUARCH in preference to MACHINE_ARCH.  The former is the
source code location of the machine, the latter the binary output.  In
general, we want to use MACHINE_CPUARCH instead of MACHINE_ARCH unless
we're tesitng for a specific target.  The isn't even moot for
i386/amd64 where there's momemntum towards a MACHINE_CPUARCH == x86,
although a specific cleanup for that likely would be needed...
2010-08-23 06:13:29 +00:00
Nathan Whitehorn
a393ae13a4 Make kernel modules build correctly on 64-bit PowerPC. 2010-07-13 12:47:31 +00:00
Ariff Abdullah
f6f8d7b601 Last (hopefully) attempt to fix both parallel build and
cyclic dependencies, in a simmilar fashion to kmod.mk.

Discussed with:		bde, bz
2009-06-12 07:39:10 +00:00
Ariff Abdullah
abfbe0c17a Attempt to fix parallel build. 2009-06-10 11:33:47 +00:00
Ariff Abdullah
0f40c3f162 Move all sound related scripts to its own 'sound' subdir.
Suggested by:	jmallett
2009-06-10 06:49:45 +00:00
Ariff Abdullah
5b9505f5d1 Each generated file should depend its own generator as well. 2009-06-09 10:17:22 +00:00
Bjoern A. Zeeb
93a885572c Depend on @ machine (_ILINKS) as we do with other modules so that @
is there for parallel (-jN) builds.  Ideally beforedepends in kmod.mk
should do the right thing but it seems it does not.
2009-06-09 09:03:13 +00:00
Ariff Abdullah
90da2b2859 Sound Mega-commit. Expect further cleanup until code freeze.
For a slightly thorough explaination, please refer to
	[1] http://people.freebsd.org/~ariff/SOUND_4.TXT.html .

Summary of changes includes:

1 Volume Per-Channel (vpc).  Provides private / standalone volume control
  unique per-stream pcm channel without touching master volume / pcm.
  Applications can directly use SNDCTL_DSP_[GET|SET][PLAY|REC]VOL, or for
  backwards compatibility, SOUND_MIXER_PCM through the opened dsp device
  instead of /dev/mixer.  Special "bypass" mode is enabled through
  /dev/mixer which will automatically detect if the adjustment is made
  through /dev/mixer and forward its request to this private volume
  controller.  Changes to this volume object will not interfere with
  other channels.

  Requirements:
    - SNDCTL_DSP_[GET|SET][PLAY|REC]_VOL are newer ioctls (OSSv4) which
      require specific application modifications (preferred).
    - No modifications required for using bypass mode, so applications
      like mplayer or xmms should work out of the box.

  Kernel hints:
    - hint.pcm.%d.vpc (0 = disable vpc).

  Kernel sysctls:
    - hw.snd.vpc_mixer_bypass (default: 1).  Enable or disable /dev/mixer
      bypass mode.
    - hw.snd.vpc_autoreset (default: 1).  By default, closing/opening
      /dev/dsp will reset the volume back to 0 db gain/attenuation.
      Setting this to 0 will preserve its settings across device
      closing/opening.
    - hw.snd.vpc_reset (default: 0).  Panic/reset button to reset all
      volume settings back to 0 db.
    - hw.snd.vpc_0db (default: 45).  0 db relative to linear mixer value.

2 High quality fixed-point Bandlimited SINC sampling rate converter,
  based on Julius O'Smith's Digital Audio Resampling -
  http://ccrma.stanford.edu/~jos/resample/.  It includes a filter design
  script written in awk (the clumsiest joke I've ever written)
    - 100% 32bit fixed-point, 64bit accumulator.
    - Possibly among the fastest (if not fastest) of its kind.
    - Resampling quality is tunable, either runtime or during kernel
      compilation (FEEDER_RATE_PRESETS).
    - Quality can be further customized during kernel compilation by
      defining FEEDER_RATE_PRESETS in /etc/make.conf.

  Kernel sysctls:
    - hw.snd.feeder_rate_quality.
      0 - Zero-order Hold (ZOH).  Fastest, bad quality.
      1 - Linear Interpolation (LINEAR).  Slightly slower than ZOH,
          better quality but still does not eliminate aliasing.
      2 - (and above) - Sinc Interpolation(SINC).  Best quality.  SINC
          quality always start from 2 and above.

  Rough quality comparisons:
    - http://people.freebsd.org/~ariff/z_comparison/

3 Bit-perfect mode.  Bypasses all feeder/dsp effects.  Pure sound will be
  directly fed into the hardware.

4 Parametric (compile time) Software Equalizer (Bass/Treble mixer). Can
  be customized by defining FEEDER_EQ_PRESETS in /etc/make.conf.

5 Transparent/Adaptive Virtual Channel. Now you don't have to disable
  vchans in order to make digital format pass through.  It also makes
  vchans more dynamic by choosing a better format/rate among all the
  concurrent streams, which means that dev.pcm.X.play.vchanformat/rate
  becomes sort of optional.

6 Exclusive Stream, with special open() mode O_EXCL.  This will "mute"
  other concurrent vchan streams and only allow a single channel with
  O_EXCL set to keep producing sound.

Other Changes:
    * most feeder_* stuffs are compilable in userland. Let's not
      speculate whether we should go all out for it (save that for
      FreeBSD 16.0-RELEASE).
    * kobj signature fixups, thanks to Andriy Gapon <avg@freebsd.org>
    * pull out channel mixing logic out of vchan.c and create its own
      feeder_mixer for world justice.
    * various refactoring here and there, for good or bad.
    * activation of few more OSSv4 ioctls() (see [1] above).
    * opt_snd.h for possible compile time configuration:
      (mostly for debugging purposes, don't try these at home)
        SND_DEBUG
        SND_DIAGNOSTIC
        SND_FEEDER_MULTIFORMAT
        SND_FEEDER_FULL_MULTIFORMAT
        SND_FEEDER_RATE_HP
        SND_PCM_64
        SND_OLDSTEREO

Manual page updates are on the way.

Tested by:	joel, Olivier SMEDTS <olivier at gid0 d org>, too many
          	unsung / unnamed heroes.
2009-06-07 19:12:08 +00:00
Nathan Whitehorn
c299fae2cc PowerPC does not, in general, have ISA sound devices or an ISA bus,
so add PowerPC to list of platforms for which we don't want to depend
on ISA.
2009-05-10 16:00:41 +00:00
Andrew Thompson
3a3f90c6c3 Move the uaudio and ata-usb drivers into their correct locations. 2009-02-23 21:19:18 +00:00
Andrew Thompson
7d0d268b8a Hook up new USB modules. 2009-02-23 18:32:59 +00:00
Nathan Whitehorn
8486eb86a7 Add support for the I2S and davbus audio controllers found in Apple PowerPC
hardware.

Submitted by:	Marco Trillo
2009-01-25 18:20:15 +00:00
Rong-En Fan
fb898a2cc2 - Remove snd_au88x0 which seems never got compiled into kernel nor as a kernel
module. These files cause manual interaction when building
  ports/audio/aureal-kmod which provides a usable i386-only driver (it requires
  linking against some linux object files distributed by vendor which bankrupted
  back in 2000).

MFC after:	1 week
2009-01-07 03:15:22 +00:00
Marius Strobl
10eee905ca Restore SUBDIR+= accidentally removed in the previous revision.
Pointed out by:	ariff
2008-05-04 16:02:45 +00:00
Marius Strobl
07f35f4b9a Don't build unused SBus front-ends for sun4v, don't build EBus front-ends
which are also likely to be irrelevant for sun4v (there's no SBus on sun4v
and only some EBus devices). While at it fix some style bugs according to
style.Makefile(5) where appropriate.

MFC after:	3 days
2008-05-04 14:59:25 +00:00
Antoine Brodin
10f0bcab61 Remove option headers that do not exist and are not used
from the Makefiles in sys/modules.
(opt_devfs.h, opt_bdg.h, opt_emu10kx.h and opt_uslcom.h)

Approved by:	rwatson (mentor)
2008-03-27 20:38:03 +00:00
Ruslan Ermilov
995dc98447 Remove WARNS from here and compile with default kernel flags. 2008-02-21 11:09:59 +00:00