Skip to contentSkip to conversation

Forwarding Debian bugs + patches

PATCH Jordi Mallach 1 participant 1 message Apr 12, 2003

lore
Share & tools
lore
#0 lore raw

Hello Alsa team!

We have a few bugs we'd like to report, and a pair of patches against 0.9.2.

*** Bug#187831: sparc64 compilation problems and fixes
Fabio Massimo Di Nitto reports that ALSA 0.9.2 doesn't compile on sparc64. He provides a patch that fixes the compilation, but he gets an unresolved symbol: virt_to_bus_not_defined_use_pci_map, which apparently unveils non-portable code. The problem isn't present in 2.5.x ALSA. The patch is attached.
http://bugs.debian.org/187831

*** Bug#187818: AC97 does not respond - RESET (EMU10K1/Audigy)
Fabio reports he's getting messages like
ALSA ../../alsa-kernel/pci/ac97/ac97_codec.c:1960: AC'97 0:0 does not respond - RESET EMU10K1/Audigy soundcard not found or device busy

with an Audigy 2 Platinum EX with card ID 0004.

Fabio has no problem providing a shell account to alsa developers. If you need it, please contact me.
http://bugs.debian.org/187818

*** Bug#186403: Kernel oops on unloading snd-pcm-oss Darren Salt reports that after trying to remove the alsa modules, he gets an oops. Ksymoops are attached to this mail. Steve thinks it's a devfs bug.
http://bugs.debian.org/186403, emu10k1 sound card.
This was reported against 0.9.1.

*** Bug#186240: alsa-source: ooops with 2.4.20
Kernel oops whenever he tries to use sound. ksymoops attached to the bug report, too.
http://bugs.debian.org/186240

*** Bug#176166: alsa-source: alsa-driver .deb does not build with make -j We just got a patch to Rules.make which fix this. Attached.

*** Bug#173291: alsa-source: cannot unload snd-trident-synth Andrea can't unload the sound modules because modprobe -r snd-trident-synth says the module is in use, even in single user mode. He recently tried 0.9.2, no luck still.
http://bugs.debian.org/173291

*** Bug#183315: Opening /dev/sequencer will eventually cause a segfault or state D [emu10k1] Darren has had this problem for some time now, which I reported on my
last mail, and some action was taken. Before, /dev/sequencer would
return ENOMEM with emu10k1. After the fixes in the rc8 series, the
ENOMEM problem was gone, but he started getting segfaults and sleeping processes. We have no more input from success/failure on 0.9.2.
http://bugs.debian.org/183315.

*** Bug#183316: OSS-emulation MIDI timer problems
Quoting the bug seems quite appropiate:

Quoted 11 lines

SEQ_START_TIMER(), if used more than once for a given /dev/sequencer session, causes odd things to happen. I'm not quite sure what's going on here, but investigaton using lxmusserv and rosegarden shows that timer events seem to be occurring in bursts.

With Doom, let some piece of music be repeated then try to do something (start a game, quit) and you'll find that it doesn't happen immediately; instead, it happens some time later; mwanwhile, the same music continues to be played as the game engine is blocked, waiting for musserv to read in the new music data.

Quoted 5 lines

With rosegarden, the effect can be seen by starting, stopping and restarting the music: watch the timer apparently make several large jumps (each corresponding to many SNDCTL_SEQ_SYNC + SEQ_WAIT_TIME pairs) instead of lots of small jumps (each of which corresponds to one SNDCTL_SEQ_SYNC + SEQ_WAIT_TIME pair).

I can't remember if this was included in our last mail. It was reported against rc7, and we have no more info about it.

*** Bug#168448: 0.9rc5 impossible to load intel8x0 with 2.2.20 kernel Reporter says that he can't load intel8x0 with 2.2.20, since he upgraded from beta10 to rc5. He gets the following message:
PCI: Increasing latency timer of device 00:01 to 64
ALSA ../alsa-kernel/pci/intel8x0.c:1739: AC'97 warm reset still in progress? [0xf0000907] Intel ICH soundcard not found or device busy

Steve, from the Debian team, says he can reproduce it (has the hardware), and would be happy to test possible patches, etc.

Thanks for the comments,
Jordi

Signature · 3 lines
Jordi Mallach Pérez  --  Debian developer     http://www.debian.org/
[email protected]     [email protected]     http://www.sindominio.net/
GnuPG public key information available at http://oskuro.net/~jordi/

#!/bin/sh -e

# 01_sparc_fixes.dpatch by Steve Kowalik and Fabio Massimo Di Nitto

# DP: Correct build-failure on sparc64.

. debian/patches/patch-opts

if [ $# -ne 1 ]; then
echo >&2 "basename $0: script expects -patch|-unpatch as argument" exit 1
fi
case "$1" in

    -patch) patch $patch_opts < $0;;
    -unpatch) patch $patch_opts -R < $0;;
    *)
        echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
        exit 1;;

esac

exit 0

include/adriver.h +0 -1
diff -Naurd alsa-driver.ORIG/include/adriver.h alsa-driver/include/adriver.h
@@ -323,7 +323,6 @@
 /* vmalloc_to_page wrapper */
 #ifndef CONFIG_HAVE_VMALLOC_TO_PAGE
 struct page *snd_compat_vmalloc_to_page(void *addr);
-#define vmalloc_to_page(addr) snd_compat_vmalloc_to_page(addr)
 #endif
 
 #include "amagic.h"

*) 64bit call to ld

configure +1 -1
diff -Naurd alsa-driver.ORIG/configure alsa-driver/configure
@@ -3385,7 +3385,7 @@
     $CC -m64 -mcmodel=medlow -S -o /dev/null -xc /dev/null >/dev/null 2>&1 && NEW_GCC=y
     $LD --version 2>&1 | grep 'elf64_sparc' > /dev/null && NEW_GAS=y
     $CC -c -x assembler /dev/null -Wa,--help | grep undeclared-regs > /dev/null || CC_UNDECL="-Wa,--undeclared-regs"
-    if test $NEW_GAS != y; then
+    if test $NEW_GAS = y; then
       LD=sparc64-linux-ld
     else
       LD="$LD -m elf64_sparc"
configure.in +1 -1
diff -Naurd alsa-driver.ORIG/configure.in alsa-driver/configure.in
@@ -542,7 +542,7 @@
     $CC -m64 -mcmodel=medlow -S -o /dev/null -xc /dev/null >/dev/null 2>&1 && NEW_GCC=y
     $LD --version 2>&1 | grep 'elf64_sparc' > /dev/null && NEW_GAS=y
     $CC -c -x assembler /dev/null -Wa,--help | grep undeclared-regs > /dev/null || CC_UNDECL="-Wa,--undeclared-regs"
-    if test $NEW_GAS != y; then
+    if test $NEW_GAS = y; then
       LD=sparc64-linux-ld
     else
       LD="$LD -m elf64_sparc"

*) sbus dma call

alsa-kernel/core/memalloc.c +1 -1
diff -Naurd alsa-driver.ORIG/alsa-kernel/core/memalloc.c alsa-driver/alsa-kernel/core/memalloc.c
@@ -181,7 +181,7 @@
 #endif
 #ifdef CONFIG_SBUS
 	case SNDRV_DMA_TYPE_SBUS:
-		snd_free_sbus_pages(dev->dev.sbus, dmab->size, dmab->are, dmab->addr);
+		snd_free_sbus_pages(dev->dev.sbus, dmab->bytes, dmab->area, dmab->addr);
 		break;
 #endif
 	default:

*) ioctl32 compilation

alsa-kernel/core/ioctl32/pcm32.c +0 -3
diff -Naurd alsa-driver.ORIG/alsa-kernel/core/ioctl32/pcm32.c alsa-driver/alsa-kernel/core/ioctl32/pcm32.c
@@ -138,7 +138,6 @@
 
 struct timeval32 {
 	s32 tv_sec;
-	s32 tv_usec;
 } __attribute__((packed));
 
 struct sndrv_pcm_status32 {
@@ -159,9 +158,7 @@
 {\
 	COPY(state);\
 	COPY(trigger_tstamp.tv_sec);\
-	COPY(trigger_tstamp.tv_usec);\
 	COPY(tstamp.tv_sec);\
-	COPY(tstamp.tv_usec);\
 	COPY(appl_ptr);\
 	COPY(hw_ptr);\
 	COPY(delay);\
alsa-kernel/core/ioctl32/rawmidi32.c +0 -2
diff -Naurd alsa-driver.ORIG/alsa-kernel/core/ioctl32/rawmidi32.c alsa-driver/alsa-kernel/core/ioctl32/rawmidi32.c
@@ -44,7 +44,6 @@
 
 struct timeval32 {
 	s32 tv_sec;
-	s32 tv_usec;
 } __attribute__((packed));
 
 struct sndrv_rawmidi_status32 {
@@ -59,7 +58,6 @@
 {\
 	COPY(stream);\
 	COPY(tstamp.tv_sec);\
-	COPY(tstamp.tv_usec);\
 	COPY(avail);\
 	COPY(xruns);\
 }
alsa-kernel/core/ioctl32/timer32.c +0 -4
diff -Naurd alsa-driver.ORIG/alsa-kernel/core/ioctl32/timer32.c alsa-driver/alsa-kernel/core/ioctl32/timer32.c
@@ -31,7 +31,6 @@
 	s32 card;
 	unsigned char id[64];
 	unsigned char name[80];
-	u32 ticks;
 	u32 resolution;
 	unsigned char reserved[64];
 };
@@ -42,13 +41,11 @@
 	COPY(card);\
 	memcpy(dst->id, src->id, sizeof(src->id));\
 	memcpy(dst->name, src->name, sizeof(src->name));\
-	COPY(ticks);\
 	COPY(resolution);\
 }
 
 struct timeval32 {
 	s32 tv_sec;
-	s32 tv_usec;
 };
 
 struct sndrv_timer_status32 {
@@ -63,7 +60,6 @@
 #define CVT_sndrv_timer_status()\
 {\
 	COPY(tstamp.tv_sec);\
-	COPY(tstamp.tv_usec);\
 	COPY(resolution);\
 	COPY(lost);\
 	COPY(overrun);\

#!/bin/sh -e

# 04_make_minus_j_fix.dpatch by Steve Kowalik and Colm Buckley

# DP: Fix building with 'make -j'.

. debian/patches/patch-opts

if [ $# -ne 1 ]; then
echo >&2 "basename $0: script expects -patch|-unpatch as argument" exit 1
fi

case "$1" in

       -patch) patch $patch_opts -p1 < $0;;
       -unpatch) patch $patch_opts -p1 -R < $0;;
        *)
                echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
                exit 1;;

esac

exit 0

Rules.make renamed from Rules.make~ +8 -7
diff -urNad alsa-driver/Rules.make~ alsa-driver/Rules.make
@@ -221,7 +221,7 @@
 	genksyms_smp_prefix := 
 endif
 
-$(MODINCL)/$(MODPREFIX)%.ver: %.c
+$(MODINCL)/$(MODPREFIX)%.ver: %.c update-sndvers
 	@if [ ! -r $(MODINCL)/$(MODPREFIX)$*.stamp -o $(MODINCL)/$(MODPREFIX)$*.stamp -ot $< ]; then \
 		echo '$(CC) -D__KERNEL__ $(CFLAGS) $(EXTRA_CFLAGS) -E -D__GENKSYMS__ $<'; \
 		echo '| $(GENKSYMS) $(genksyms_smp_prefix) > [email protected]'; \
@@ -239,7 +239,8 @@
 endif # export-objs 
 
 define update-sndvers
-	@(echo "#ifndef _LINUX_SNDVERSIONS_H"; \
+	(tmpfile=`mktemp $(SNDVERSIONS).XXXXXXXXXXXX`; \
+	(echo "#ifndef _LINUX_SNDVERSIONS_H"; \
 	  echo "#define _LINUX_SNDVERSIONS_H"; \
 	  echo "#include <linux/modsetver.h>"; \
 	  cd $(TOPDIR)/include/modules; \
@@ -247,14 +248,14 @@
 	    if [ -f $$f ]; then echo "#include \"modules/$${f}\""; fi; \
 	  done; \
 	  echo "#endif"; \
-	) > $(SNDVERSIONS).tmp
-	@if [ -r $(SNDVERSIONS) ] && cmp -s $(SNDVERSIONS) $(SNDVERSIONS).tmp; then \
+	) > $${tmpfile}; \
+	if [ -r $(SNDVERSIONS) ] && cmp -s $(SNDVERSIONS) $${tmpfile}; then \
 		echo $(SNDVERSIONS) was not updated; \
-		rm -f $(SNDVERSIONS).tmp; \
+		rm -f $${tmpfile}; \
 	else \
 		echo $(SNDVERSIONS) was updated; \
-		mv -f $(SNDVERSIONS).tmp $(SNDVERSIONS); \
-	fi
+		mv -f $${tmpfile} $(SNDVERSIONS); \
+	fi)
 endef
 
 $(SNDVERSIONS):
steven@broken:~$ ksymoops -k ./ksyms -l ./modules-2.4.20-1-k7-smp -o
/lib/modules/2.4.20-1-k7-smp -m /boot/System.map-2.4.20-1-k7-smp 
ksymoops 2.4.8 on i686 2.4.20-1-k7-smp.  Options used
     -V (default)
     -k ./ksyms (specified)
     -l ./modules-2.4.20-1-k7-smp (specified)
     -o /lib/modules/2.4.20-1-k7-smp (specified)
     -m /boot/System.map-2.4.20-1-k7-smp (specified)

Warning (expand_objects): object /lib/modules/2.4.20-1-k7-smp/kernel/fs/ext3/ext
3.o for module ext3 has changed since load
Warning (expand_objects): object /lib/modules/2.4.20-1-k7-smp/kernel/fs/jbd/jbd.
o for module jbd has changed since load
Warning (expand_objects): object /lib/modules/2.4.20-1-k7-smp/kernel/drivers/ide /ide-disk.o for module ide-disk has changed since load Warning (expand_objects): object /lib/modules/2.4.20-1-k7-smp/kernel/drivers/ide /ide-probe-mod.o for module ide-probe-mod has changed since load Warning (expand_objects): object /lib/modules/2.4.20-1-k7-smp/kernel/drivers/ide /ide-mod.o for module ide-mod has changed since load Warning (expand_objects): object /lib/modules/2.4.20-1-k7-smp/kernel/net/unix/un
ix.o for module unix has changed since load
Reading Oops report from the terminal

Unable to handle kernel paging request at virtual address 67150277
 printing eip:
c0167323
*pde = 00000000
Oops: 0002
CPU:    1
EIP:    0010:[<c0167323>]    Tainted: P 
EFLAGS: 00010216
eax: 67150277   ebx: de269340   ecx: d982b840   edx: e09c5fd0
esi: 00000004   edi: 00000000   ebp: d982b800   esp: c35cdf10
ds: 0018   es: 0018   ss: 0018
Process modprobe (pid: 31266, stackpage=c35cd000)
Stack: dd0b3400 e09c5144 de269340 00000003 e09c528c e09c5fd0 00000004
e09c5435 
       e09c5fd0 00000004 e09cd5b2 00000004 d1a71400 e0aa48c4 e09f7c00
bfffec08 
       e09cf884 e0a9fa8c 00000002 d1a71600 00000000 d1a71400 e0a9facb
d1a71400 
Call Trace:    [<e09c5144>] [<e09c528c>] [<e09c5fd0>] [<e09c5435>]

[<e09c5fd0>]
[<e09cd5b2>] [<e0aa48c4>] [<e09f7c00>] [<e09cf884>] [<e0a9fa8c>]
[<e0a9facb>]
[<e09ea52d>] [<e0a9fbac>] [<e0aa48c4>] [<c011cff7>] [<c011c29f>]
[<c0108b97>]

Code: f0 81 28 00 00 00 01 0f 85 39 25 00 00 53 8b 43 20 50 e8 36 
Unable to handle kernel paging request at virtual address 67150277
c0167323
*pde = 00000000
Oops: 0002
CPU:    1
EIP:    0010:[<c0167323>]    Tainted: P 

Using defaults from ksymoops -t elf32-i386 -a i386
EFLAGS: 00010216
eax: 67150277 ebx: de269340 ecx: d982b840 edx: e09c5fd0
esi: 00000004 edi: 00000000 ebp: d982b800 esp: c35cdf10
ds: 0018 es: 0018 ss: 0018
Process modprobe (pid: 31266, stackpage=c35cd000)

Stack: dd0b3400 e09c5144 de269340 00000003 e09c528c e09c5fd0 00000004
e09c5435 
       e09c5fd0 00000004 e09cd5b2 00000004 d1a71400 e0aa48c4 e09f7c00
bfffec08 
       e09cf884 e0a9fa8c 00000002 d1a71600 00000000 d1a71400 e0a9facb
d1a71400 
Call Trace:    [<e09c5144>] [<e09c528c>] [<e09c5fd0>] [<e09c5435>]

[<e09c5fd0>]
[<e09cd5b2>] [<e0aa48c4>] [<e09f7c00>] [<e09cf884>] [<e0a9fa8c>]
[<e0a9facb>]
[<e09ea52d>] [<e0a9fbac>] [<e0aa48c4>] [<c011cff7>] [<c011c29f>]
[<c0108b97>]

Code: f0 81 28 00 00 00 01 0f 85 39 25 00 00 53 8b 43 20 50 e8 36 
Quoted 7 lines
Quoted 7 lines

EIP; c0167323 <devfs_unregister+13/40> <=====

ebx; de269340 <_end+1df7dbd0/205218f0>
ecx; d982b840 <_end+195400d0/205218f0>
edx; e09c5fd0 <[soundcore].data.end+49/20d9>
ebp; d982b800 <_end+19540090/205218f0>
esp; c35cdf10 <_end+32e27a0/205218f0>

Trace; e09c5144 <[soundcore]__sound_remove_unit+24/60> Trace; e09c528c <[soundcore]sound_remove_unit+1c/30> Trace; e09c5fd0 <[soundcore].data.end+49/20d9>
Trace; e09c5435 <[soundcore]unregister_sound_special+15/20> Trace; e09c5fd0 <[soundcore].data.end+49/20d9>
Trace; e09cd5b2 <[snd]snd_unregister_oss_device+d2/110> Trace; e0aa48c4 <[snd-pcm-oss]snd_pcm_oss_notify+0/14> Trace; e09f7c00 <[snd-pcm]snd_pcm_devices+0/1460> Trace; e09cf884 <[snd]sound_oss_mutex+0/14>
Trace; e0a9fa8c <[snd-pcm-oss]snd_pcm_oss_disconnect_minor+2c/60> Trace; e0a9facb <[snd-pcm-oss]snd_pcm_oss_unregister_minor+b/50> Trace; e09ea52d <[snd-pcm]snd_pcm_notify+4d/b0>
Trace; e0a9fbac <[snd-pcm-oss]alsa_pcm_oss_exit+c/10> Trace; e0aa48c4 <[snd-pcm-oss]snd_pcm_oss_notify+0/14> Trace; c011cff7 <free_module+17/b0>
Trace; c011c29f <sys_delete_module+11f/240>
Trace; c0108b97 <system_call+33/38>

Code; c0167323 <devfs_unregister+13/40>
00000000 <_EIP>:
Code; c0167323 <devfs_unregister+13/40> <=====
0: f0 81 28 00 00 00 01 lock subl $0x1000000,(%eax) <=====
Code; c016732a <devfs_unregister+1a/40>
7: 0f 85 39 25 00 00 jne 2546 <_EIP+0x2546>
Code; c0167330 <devfs_unregister+20/40>
d: 53 push %ebx
Code; c0167331 <devfs_unregister+21/40>
e: 8b 43 20 mov 0x20(%ebx),%eax
Code; c0167334 <devfs_unregister+24/40>
11: 50 push %eax
Code; c0167335 <devfs_unregister+25/40>
12: e8 36 00 00 00 call 4d <_EIP+0x4d>

This looks to be a bug in the depths of devfs, but I don't know.

Signature · 4 lines
                                           Steve
* vorlon installs ntop to look at the copyright file, and finds that he
          can't purge it because of a broken maintainer script. Heh.
<luca> vorlon: this is your punishment for questioning the Luca