linux-mips
[Top] [All Lists]

Re: [PATCH 2.6] PCI I/O region starting from zero is valid

To: Ralf Baechle <ralf@linux-mips.org>
Subject: Re: [PATCH 2.6] PCI I/O region starting from zero is valid
From: Geert Uytterhoeven <geert@linux-m68k.org>
Date: Sat, 13 Dec 2003 13:15:28 +0100 (MET)
Cc: Vivien Chappelier <vivienc@nerim.net>, "Ilya A. Volynets-Evenbakh" <ilya@theIlya.com>, jsun@mvista.com, Linux/MIPS Development <linux-mips@linux-mips.org>
In-reply-to: <20031213032459.GE22448@linux-mips.org>
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <Pine.LNX.4.21.0312130147150.24966-100000@melkor> <20031213032459.GE22448@linux-mips.org>
Sender: linux-mips-bounce@linux-mips.org
On Sat, 13 Dec 2003, Ralf Baechle wrote:
> On Sat, Dec 13, 2003 at 01:54:27AM +0100, Vivien Chappelier wrote:
> >     PCI devices can have I/O mapped at a region starting from
> > 0x0000. The O2 actually has one of its onboard SCSI controller here...
> > This code looks like a incorrect copy/paste from the x86 code where this
> > I/O range is used by legacy ISA.
> >
> > --- arch/mips/pci/pci.c     2003-11-12 16:51:09.000000000 +0100
> > +++ arch/mips/pci/pci.c     2003-12-13 00:57:56.000000000 +0100
> > @@ -173,10 +173,6 @@
> >                     continue;
> >
> >             r = &dev->resource[idx];
> > -           if (!r->start && r->end) {
> > -                   printk(KERN_ERR "PCI: Device %s not available because 
> > of resource collisions\n", pci_name(dev));
> > -                   return -EINVAL;
> > -           }
> >             if (r->flags & IORESOURCE_IO)
> >                     cmd |= PCI_COMMAND_IO;
> >             if (r->flags & IORESOURCE_MEM)
>
> I tend to agree with Vivien.  There's another unsolved problem with
> pcibios_enable_device - how many resources should it enable?  Jun once
> changed it to PCI_NUM_RESOURCES but that broke other systems though it
> seems the logic thing to do ...

IMHO it should enable all resources, and you should add quirks for devices that
can't live with it.

Gr{oetje,eeting}s,

                                                Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                                            -- Linus Torvalds

<Prev in Thread] Current Thread [Next in Thread>