[2.5.50][PnP]: Issue with SBAWE32 Gameport and Serial port & IDE controller conflict

[2.5.50][PnP]: Issue with SBAWE32 Gameport and Serial port & IDE controller conflict

Post by Shawn Star » Sat, 07 Dec 2002 23:50:09




cc: Linux Kernel Mailing List

There are problems with the new PnP interface.

Of notice:

Observation #1:
===============

display of /proc/iports in particular PCI slots:

ec00-ecff : ATI Technologies Inc 3D Rage I/II 215GT [
ef80-ef9f : Intel Corp. 82371SB PIIX3 USB [N
ffa0-ffaf : Intel Corp. 82371SB PIIX3 IDE [N

the string is cut off (trivial to fix). This appears to be only affecting PCI
device strings.

/sys/devices/pci0/00:00.0:
Intel Corp. 430HX - 82439HX TXC...
/sys/devices/pci0/00:07.0:
Intel Corp. 82371SB PIIX3 ISA [N....

So there is common code that is truncating the string, I could make  a patch
to fix this easily.

Observation #2:
===============

Not all devices in sysfs show resources when they should.

case in point:

/proc/ioports:

ffa0-ffaf : Intel Corp. 82371SB PIIX3 IDE [N
  ffa0-ffa7 : ide0
  ffa8-ffaf : ide1

Intel Corp. 82371SB PIIX3 IDE [N atoma/Triton II] (cut off portion)

Resources file is empty but should show: ffa0-ffaf

/sys/devices/pci0/00:07.1/ide0 has no resources file so it's resources are
 not shown anywhere.

but if there was a resource file it might show: ffa0-ffa7 for ide0.

Observation #3:
===============

When enabling PNP BIOS on BIOS: This bios seems to turn on an extra COM port
(This might be resolved by disabling the COM port being autodetected in
BIOS).

from /proc/iports:

02f8-02ff : serial
03e8-03ef : serial
03f8-03ff : serial

The problem is:

ide2: I/O resource 0x3EE-0x3EE not free.
ide2: ports already in use, skipping probe

The Sound Blaster IDE controller wants to use this port range (but it is not
the first pick from PnP).

/sys/devices/pnp1/01:01/er:
Generic ESDI/IDE/ATA compatible hard disk controller (from SB IDE
 Controller).

Possible locations found:

Dependent: 01 - Priority preferred
   port 0x168-0x168, align 0x0, size 0x8, 16-bit address decoding
   port 0x36e-0x36e, align 0x0, size 0x2, 16-bit address decoding
   irq 10 High-Edge

*THIS* should be selected by PnP but is not for some reason ^^^^^^^^^^^^^

Dependent: 02 - Priority acceptable
   port 0x1e8-0x1e8, align 0x0, size 0x8, 16-bit address decoding
   port 0x3ee-0x3ee, align 0x0, size 0x2, 16-bit address decoding
   irq 11 High-Edge

* This is not available due to 0x3ee being used by the serial port.

-----------------------------------------------------------------------------
----- Dependent: 03 - Priority acceptable
   port 0x100-0x1f8, align 0x7, size 0x8, 16-bit address decoding
   port 0x300-0x3fe, align 0x1, size 0x2, 16-bit address decoding
   irq 10,11,12,15 High-Edge

***: when manually enabling this device PnP has chosen:

io 0x100-0x107
io 0x300-0x301
irq 12

-----------------------------------------------------------------------------
----- Dependent: 04 - Priority functional
   port 0x170-0x170, align 0x0, size 0x8, 16-bit address decoding
   port 0x376-0x376, align 0x0, size 0x1, 16-bit address decoding
   irq 15 High-Edge

Observation #4:
===============

The Game-port on this Sound Blaster AWE32 seems to only use port 0x200-0x200.

From our code:

Also, here are my findings from debugging:

pnp: the driver 'ns558' has been registered
pnp: pnp: match found with the PnP device '01:01.03' and the driver 'ns558'
pnp: the driver 'ns558' has been registered

ns558: BEFORE LOOP: u = ff, v = ff, io = 200
ns558: u = ff, v = ff, io = 200
ns558: Any bits to change?

Code we're dying at:

/*
 * We must not be able to write arbitrary values to the port.
 * The lower two axis bits must be 1 after a write.
 */

        c = inb(io);
        outb(~c & ~3, io);
        if (~(u = v = inb(io)) & 3) {
                outb(c, io);
                return;
        }
/*
 * After a trigger, there must be at least some bits changing.
 */

                printk (KERN_INFO "ns558: BEFORE LOOP: u = %x, v = %x, io
=
%x\n", u, v, io);
        for (i = 0; i < 1000; i++) v &= inb(io);

                printk (KERN_INFO "ns558: u = %x, v = %x, io = %x\n", u,
v,
io);
        if (u == v) {           <================================ We die
Here.
                outb(c, io);
                printk (KERN_INFO "ns558: Any bits to change?\n");
                return;
        }
        wait_ms(3);

We never get to finish the function because in this case, u and v both
equal
ff which exits function without setting any lists.

Something is definately going odd here.

Shawn.


Quote:> Looking at a 2.4 /proc/iports I see this:

> Our error:
> ide2: I/O resource 0x3EE-0x3EE not free.

> Region in use:
> 03e8-03ef : serial(auto)

> If im not mistaken 0x3ee inside that range of 0x3e8 to 0x3ef.

> why Is the serial port conflicting? and oddly why is ISAPNP not choosing
> the best possibility (which is #1 not #2 which conflicts with the serial
> port).

> Hmm...

> Shawn.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in

More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/
 
 
 

1. PNP driver changes for 2.5.50


[PATCH] PnP bugfix

I forgot the errno.h.  Without this patch, things may not compile when
pnp support or pnp card support is disabled.

Hope you had a good trip.  I noticed a small mistake in pnp 0.93 and I have
a fix for it.

diff -Nru a/include/linux/pnp.h b/include/linux/pnp.h
--- a/include/linux/pnp.h       Fri Dec  6 10:38:37 2002

 #include <linux/device.h>
 #include <linux/list.h>
+#include <linux/errno.h>

 /*
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in

More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

2. Netscape can't see News Server (Win98)

3. I lose my gnome panels!

4. Linux PnP Support V0.93 - 2.5.50

5. Building a PPP-link with DIP

6. 2.5.50 - sound driver issues with i810_audio

7. finger only shows first line of .plan

8. IDE-SCSI module corrupts further module loading on 2.5.50

9. ide-scsi compile error in 2.5.50-mm1

10. 2.5.50 responsiveness

11. 2.5.50: unused code in link_path_walk()

12. 2.5.50 mpu401.h compilation error patches