Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id ; Wed, 13 Dec 2000 19:54:47 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id ; Wed, 13 Dec 2000 19:54:37 -0500 Received: from melancholia.danann.net ([203.36.211.210]:32273 "HELO melancholia.danann.net") by vger.kernel.org with SMTP id ; Wed, 13 Dec 2000 19:54:27 -0500 To: linux-kernel@vger.kernel.org Cc: Zach Brown Subject: [PATCH] Maestro 2 sound driver update. Keywords: patch,multiple,dsp From: Daniel Pittman Organization: Not today, thank you, Mother. X-Homepage: http://danann.net/ X-spies: Area 51 SDI plutonium constitution NSA World Trade Center Clinton Marxist Peking Delta Force Kennedy FSF spy militia bomb Date: 13 Dec 2000 23:24:48 +1100 Message-ID: <87d7ewpkz3.fsf@inanna.rimspace.net> Lines: 31 User-Agent: Gnus/5.0808 (Gnus v5.8.8) XEmacs/21.2 (Peisino,Ak(B) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org --=-=-= The attached patch, against 2.4.0-test12, makes some changes to the Maestro 2 sound driver for Linux. The main changes are: * allow multiple opens of /dev/dsp * support persistent DMA buffer allocation * default number of channels at compile time * support kernel command line arguments The multiple open of /dev/dsp is the most interesting change. Now, multiple processes can open the device at the same time. Previously the driver would export one dsp device per channel. This is an incompatible change so, if you use the patch, be aware of that. This needs more testing before being ready to submit for inclusion in the kernel proper. If you do try it, could you please send me reports (by private mail) about your success or failure? Thanks, Daniel --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=maestro-multi-open-2.4.0-pre12.patch diff -u --recursive linux/Documentation/Configure.help linux.dp/Documentation/Configure.help --- linux/Documentation/Configure.help Tue Dec 12 15:17:13 2000 +++ linux.dp/Documentation/Configure.help Tue Dec 12 14:42:08 2000 @@ -14464,6 +14464,22 @@ of PCI sound chips. These include the Maestro 1, Maestro 2, and Maestro 2E. See Documentation/sound/Maestro for more details. +The number of DSP device to create. +CONFIG_MAESTRO_CHANNELS + The number of DSP devices to allocate. Each device functions as + a fully independent sound system. The more devices allocated, + however, the larger the memory requirement for the driver. + You can allocate up to four DSP devices, but only in multiples + of two. This allows one, two or four devices. + +Allocate memory for DSP devices persistently +CONFIG_MAESTRO_PERSIST + If you say Y to this, the memory for the DSP devices provided + by the Maestro device will be retained even when the sound + system is not in use. + This is beneficial if you find that sound cannot be used after + doing other things on the machine for a while. + Are you using a crosscompiler CONFIG_CROSSCOMPILE Say Y here if you are compiling the kernel on a different Only in linux.dp/Documentation: Configure.help~ diff -u --recursive linux/Documentation/sound/Maestro linux.dp/Documentation/sound/Maestro --- linux/Documentation/sound/Maestro Sat Jul 29 05:50:52 2000 +++ linux.dp/Documentation/sound/Maestro Tue Dec 12 14:42:08 2000 @@ -80,16 +80,32 @@ an IRQ. This operation is incredibly system specific, so you're on your own. Sometimes the magic lies in 'PNP Capable Operating System' settings. -There are very few options to the driver. One is 'debug' which will -tell the driver to print minimal debugging information as it runs. This -can be collected with 'dmesg' or through the klogd daemon. - -The other, more interesting option, is 'dsps_order'. Typically at -install time the driver will only register one available /dev/dsp device -for its use. The 'dsps_order' module parameter allows for more devices -to be allocated, as a power of two. Up to 4 devices can be registered -( dsps_order=2 ). These devices act as fully distinct units and use -separate channels in the maestro. +There are very few options to the driver. Options can be specified as either +module options or on the kernel command line. Command line arguments are in +the form 'maestro=