Date: Sun, 29 Aug 2004 23:59:42 +0300 From: Ruslan Ermilov <ru@FreeBSD.org> To: Mathew Kanner <mat@cnd.mcgill.ca> Cc: current@FreeBSD.org Subject: Re: [PATCH] sound(4) related manpages 5.3 TODO item Message-ID: <20040829205942.GC39813@ip.net.ua> In-Reply-To: <20040829190833.GA9796@cnd.mcgill.ca> References: <20040828142503.GA52613@ip.net.ua> <20040829190833.GA9796@cnd.mcgill.ca>
next in thread | previous in thread | raw e-mail | index | archive | help
--M/SuVGWktc5uNpra Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun, Aug 29, 2004 at 03:08:33PM -0400, Mathew Kanner wrote: > On Aug 28, Ruslan Ermilov wrote: >=20 > Hello Ruslan, >=20 > > One and most important thing I'm not sure I understand, and > > that's causing a lot of confusion, is why "device pcm" was > > renamed to "device sound" in the first place? I believe the > > reason is that "device sound" is a generic sound driver, > > which has support for PCM playback, mixer, /dev/sndstat, > > eventually MIDI, sequencer, and so on. Individual sound > > drivers are free to implement either of these interfaces. > > Most of them implement "pcm" nowadays, so saying that > > "pcm was renamed to sound" is not quite correct. In other > > words, the sound.ko module provides the infrastructure for > > more than just PCM, and the sound(4) manpage should eventually > > document more than just PCM. Does that sound correct? >=20 > Sounds correct on all accounts. Also, the synopsis should > indicate that the preferred method to load sound is to set > sound_load=3D"YES" in loader.conf and barely mention kernel options, and > otherwise ignore ISA and PNP. >=20 Um, what's wrong with ISA and PnP hints, and what's wrong with "device sound"? OK, I've briefly read your midi2-patch-aug22.diff patch, and I see that it implements "device midi" and the midi.ko module, and they are not part of "device sound", as I thought they would be. So I wonder, if it's correct to rename the pcm(4) manpage to sound(4), or will the sound(4) manpage be updated to document midi(4) as well? Also, the pcm(4) manpage (whether it's renamed to sound(4) or not) is seriously outdated. First, it talks only about pcm(4), and unless there are plans to update it with more than PCM, it should probably stay pcm(4). Its SYNOPSIS still assumes that "device pcm" provides all sound drivers (like it does in 4.x). The whole manpage needs to be revised and updated. Are you willing to help? > > 3. After repo-copies and deletes, the attached patch should be > > applied. It's mostly mechanical (foo -> snd_foo, pcm -> sound), > > with the following notable exceptions: > >=20 > > - Note that non-PnP ISA cards, such as those handled by snd_mss(4) > > and snd_ad1816(4), still require hints of the form > >=20 > > hint.pcm.0.at=3D"isa" > > hint.pcm.0.irq=3D"5" > > hint.pcm.0.drq=3D"1" > > hint.pcm.0.flags=3D"0x0" > >=20 > > because they implement device "pcm". Granted, the difference > > between module and driver name is confusing enough that Seigo > > misspelled hints names in sys/conf/NOTES, and Simon misspelled > > them in the new snd_ad1816(4) manpage. The patch corrects the > > hints names in the snd_ad1816(4) manpage and NOTES. The patch > > removes the "hint.snd_mss" from NOTES because (like was said) > > the snd_mss(4) module implements the "pcm" device, hence the > > hints start with "hint.pcm", and this is already documented > > in the sound(4) manpage. Module snd_sbc(4) and snd_gusc(4) > > are special in that they implement PCM support through the > > bridge device ("sbc" and "gusc", respectively), with "pcm" > > device as a child. For them, ISA hints should be spelled > > "hint.sbc" and "hint.gusc", respectively. This is also fixed > > in NOTES. >=20 > This is a very good catch, I never noticed this. >=20 I wish there would be more consistency in naming. Previously, we had the csa(4) manpage, "device csa", and /dev/csa* entries. Now we will have the snd_csa(4) manpage, "device snd_csa", but still /dev/csaX entry. Also, in the old world, "midi" devices were created as children of "pcm" devices, so "hint.pcm.0" hints for non-PnP ISA devices looked correct. In new world with your updated midi(4), what will be the hints for the ISA device that implements PCM and MIDI? hint.pcm.0 and hint.midi.0? ;) All is so plain in the old good 4.x world: /sys/i386/isa/sound/sb_card.c /sys/i386/isa/sound/sb_dsp.c /sys/i386/isa/sound/sb_midi.c /sys/i386/isa/sound/sb_mixer.c Cheers, --=20 Ruslan Ermilov ru@FreeBSD.org FreeBSD committer --M/SuVGWktc5uNpra Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.5 (FreeBSD) iD8DBQFBMkO+qRfpzJluFF4RAkDIAJ42JHH6V+Ocsh31XY0Bv0OlFhleeACfZuBL J3citDWqvci+h45zh6O+mBA= =U25R -----END PGP SIGNATURE----- --M/SuVGWktc5uNpra--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040829205942.GC39813>