Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 15 Dec 95 18:45:34 +0900
From:      Mihoko Tanaka <m_tanaka@pa.yokogawa.co.jp>
To:        freebsd-hackers@freebsd.org
Subject:   SMC EtherPower doesn't work. 
Message-ID:  <9512150945.AA18887@cabbage.pa.yokogawa.co.jp>

next in thread | raw e-mail | index | archive | help

Hello all,

I use FreeBSD-2.1.0R on HP Vectra VL590. and I try to install the network
card 'SMC EtherPowerPCI BT'.
but it could not be recognized. The error message is:

        pci_map_port failed: device's iorange 0xff80-0xffff
  	     is incompatible with its bridge's range 0x0-0xffff

But the bridge's iorange '0x0-0xffff' includes the device's iorange 
'0xff80-0xffff'. I think the device's iorange is right.
Is it a bug of pci driver ?

I change the driver source code by following and it is working well.



In /usr/src/sys/pci/pci.c: 


int pci_map_port (pcici_t tag, u_long reg, u_short* pa)
{
[...]
        iosize = -(data &  PCI_MAP_IO_ADDRESS_MASK);
        if (ioaddr < pcicb->pcicb_iobase
                || ioaddr + iosize > pcicb->pcicb_iolimit) {
		   ~~~~~~~~~~~~~~~~
		 it should be (ioaddr + iosize - 1)

                printf ("pci_map_port failed: device's iorange 0x%x-0x%x "
                        "is incompatible with its bridge's range 0x%x-0x%x\n",
                        (unsigned) ioaddr, (unsigned) ioaddr + iosize - 1,
                        (unsigned) pcicb->pcicb_iobase,
                        (unsigned) pcicb->pcicb_iolimit);
                return (0);
        }
[...]
}


-------------------- cut here -----------------------------------------
--- pci.c  Mon Oct  9 15:35:59 1995
+++ pci.c.new       Thu Dec 14 12:09:19 1995
@@ -922,7 +922,7 @@
        };
        iosize = -(data &  PCI_MAP_IO_ADDRESS_MASK);
        if (ioaddr < pcicb->pcicb_iobase
-               || ioaddr + iosize > pcicb->pcicb_iolimit) {
+               || (ioaddr + iosize -1) > pcicb->pcicb_iolimit) {
                printf ("pci_map_port failed: device's iorange 0x%x-0x%x "
                        "is incompatible with its bridge's range 0x%x-0x%x\n",
                        (unsigned) ioaddr, (unsigned) ioaddr + iosize - 1,
-------------------- cut here -----------------------------------------


--
Mihoko Tanaka 
<m_tanaka@pa.yokogawa.co.jp>     
	



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?9512150945.AA18887>