Randy.Dunlap | 23 Dec 2004 00:01

[PATCH] wavefront: reduce stack usage


Reduce local stack usage in wavefront_load_gus_patch()
from 984 bytes to 140 bytes (on x86-32) by using kmalloc()
instead of stack for these 840 bytes:
	wavefront_patch_info samp, pat, prog; // 3 * 280

Signed-off-by: Randy Dunlap <rddunlap <at> osdl.org>

diffstat:=
 sound/oss/wavfront.c |   56 +++++++++++++++++++++++++++++++--------------------
 1 files changed, 35 insertions(+), 21 deletions(-)

diff -Naurp ./sound/oss/wavfront.c~wavfront_stack ./sound/oss/wavfront.c
--- ./sound/oss/wavfront.c~wavfront_stack	2004-10-18 14:54:32.000000000 -0700
+++ ./sound/oss/wavfront.c	2004-12-22 14:44:22.330034016 -0800
 <at>  <at>  -1516,45 +1516,56  <at>  <at>  wavefront_load_gus_patch (int devno, int
 			  int offs, int count, int pmgr_flag)
 {
 	struct patch_info guspatch;
-	wavefront_patch_info samp, pat, prog;
+	wavefront_patch_info *samp, *pat, *prog;
 	wavefront_patch *patp;
 	wavefront_sample *sampp;
 	wavefront_program *progp;

 	int i,base_note;
 	long sizeof_patch;
+	int rc = -ENOMEM;
+
+	samp = kmalloc(3 * sizeof(wavefront_patch_info), GFP_KERNEL);
(Continue reading)

Bill Davidsen | 26 Dec 2004 01:31

Using more than 2 channels with i810

I would have sworn there was a module load parameter to use more than 
two channels on this chip, but the only way I see in the source is to 
use an ioctl which doesn't seem to be available in any common software. 
Much as I would like to get another user to move from Windows to Linux, 
I'm not going to hack one of the mixer programs for him to use all the 
channels.

Any thoughts?

ASUS P4P800, i82801EB/ER chipset AC97, i810_audio driver in FC1 (2.4.22 
base).

--

-- 
bill davidsen <davidsen <at> tmr.com>
   CTO TMR Associates, Inc
   Doing interesting things with small computers since 1979
-
To unsubscribe from this list: send the line "unsubscribe linux-sound" in
the body of a message to majordomo <at> vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Georg C. F. Greve | 27 Dec 2004 13:05
Gravatar

USB Headset: no sound / keyboard freeze, occasional kbd freeze or crash when unplugging

Hi all,

sorry for the crossposting, but I am not sure whether this problem is
USB or ALSA related, since the ALSA code *seems* to work just
perfectly fine, but no sound ever comes out of the Headset, so it
*may* be a transport layer problem.

Got myself a Logitech USB Headset recently and tried to get it to work
on my workplace machine & laptop. Both machines showed the same
effects (running Kernel 2.6.9 initially and 2.6.10 now): Sound seems
to work, ALSA claims everything is fine but no sound is ever audible. [*]

Strangely, when first plugging it into the workplace machine, I could
get it to work: the snd-usb-audio module of ALSA was missing, so I
recompiled the kernel with that module and -- being too lazy -- did
not reboot, but simply installed the new kernel on disk in place of
the old one (which was still running) and loaded the module. Things
worked perfectly then, as far as I could tell -- crystal clear sound,
good recording.

Only after rebooting into the kernel that had been recompiled along
with the module did things stop working.

When unplugging/replugging the headset trying to get it to work, I
experienced strange phenomena: the keyboard would stop working, and
once it didn't work when I booted the machine with the headset plugged
in. In one case, I got a kernel crash reported to syslog.

Unfortunately, I could not reproduce this with a debugging enabled
kernel, so there is not much information, but what I had was filed as
(Continue reading)


Gmane