All of lore.kernel.org
 help / color / mirror / Atom feed
* [bug] sbawe: the PnP won't stop
@ 2013-03-24  2:25 David Flater
  2013-03-26  1:04 ` David Flater
  0 siblings, 1 reply; 2+ messages in thread
From: David Flater @ 2013-03-24  2:25 UTC (permalink / raw)
  To: alsa-devel

I've got an ISA PnP SB AWE type card in a system with a non-working DMA 5.
Without intervention, the Sound Blaster always gets the broken DMA.  I have
no BIOS options to control the allocation of DMAs, and the PnP configuration
done within ALSA ignores /etc/isapnp.conf [*].  DMA 6 works fine if I can get
sbawe to stop re-initializing the PnP and just use it.

# Use setup from isapnp with dma16 moved to 6.
modprobe snd-sbawe isapnp=0 port=0x220 mpu_port=0x330 fm_port=0x388 awe_port=0x620 irq=5 dma8=1 dma16=6
modprobe snd-emu8000-synth

Problem is, regardless whether isapnp is 0 or 1, sbawe always PnPs the card
and puts it back on broken DMA 5.  If I have already got the card correctly
configured with /sbin/isapnp beforehand, sbawe leaves the original resources
tied up as a ghost card and allocates again (/proc/dma):

 1: SoundBlaster - 8bit
 2: floppy
 3: SoundBlaster - 8bit
 4: cascade
 5: SoundBlaster - 16bit
 6: SoundBlaster - 16bit

To get it working I ripped the following lines of code out of kernel 3.8.4,
blocking PnP completely.  As for a proper nondestructive fix, I'm not sure
whether the intent was (A) you were only supposed to get one of the two
registrations, or (B) the PnP registration was not supposed to reinit
everything if it was already set up.

--- sound/isa/sb/sb16.c~	2013-03-14 14:27:14.000000000 -0400
+++ sound/isa/sb/sb16.c	2013-03-23 20:18:50.137987332 -0400
@@ -674,13 +674,6 @@
 #ifdef CONFIG_PNP
 	if (!err)
 		isa_registered = 1;
-
-	err = pnp_register_card_driver(&sb16_pnpc_driver);
-	if (!err)
-		pnp_registered = 1;
-
-	if (isa_registered)
-		err = 0;
 #endif
 	return err;
 }


[*] So is there a different config file for PnP within ALSA?

-- DWF

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [bug] sbawe: the PnP won't stop
  2013-03-24  2:25 [bug] sbawe: the PnP won't stop David Flater
@ 2013-03-26  1:04 ` David Flater
  0 siblings, 0 replies; 2+ messages in thread
From: David Flater @ 2013-03-26  1:04 UTC (permalink / raw)
  To: alsa-devel

This problem now appears to be bigger than just sbawe or ALSA.

- The clone-and-reallocate behavior happened with the gameport too, even
  though I didn't mess with that at all.  The gameport is discovered by some
  driver as a legacy port, then later rediscovered and reallocated with
  different resources as a PnP gameport.

- The kernel parameter pnp_reserve_dma, which ought to be the right way to
  avoid getting DMA 5, doesn't do anything.

The cleanest workaround seems to be to noisapnp the kernel, use the userspace
/sbin/isapnp tool, and provide ALSA module options as for a non-PnP card.

On 03/23/2013 10:25 PM, David Flater wrote:
> I've got an ISA PnP SB AWE type card in a system with a non-working DMA 5.
> Without intervention, the Sound Blaster always gets the broken DMA.  I have
> no BIOS options to control the allocation of DMAs, and the PnP configuration
> done within ALSA ignores /etc/isapnp.conf [*].  DMA 6 works fine if I can get
> sbawe to stop re-initializing the PnP and just use it.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2013-03-26  1:05 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-03-24  2:25 [bug] sbawe: the PnP won't stop David Flater
2013-03-26  1:04 ` David Flater

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.