lkml.org 
[lkml]   [1999]   [Nov]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRE: Specifying properly the PCI driver model on all linux archite ctur es, (ioremap(), bus_to_virt() ...)
Date
Jeff Garzik [mailto:jgarzik@mandrakesoft.com] wrote:
> Bret Indrelee wrote:
> > Based on a lot of reading between the lines, I believe you
> do not have to
> > ever call check_region() or region_request() to claim your
> PCI address
> > space. I think these routines are only used for ISA.
>
> No. For I/O port addresses, you use {check,request}_region. For MMIO
> addresses, you use {check,request}_mem_region. You _must_ do this.
> Many old drivers do not do this, and this is also a bug. I dream of a
> kernel with perfect resource allocation ;-) You can do lots of cool
> things.

Just to clarify something, it looks as if check_mem_region() and ilk were
added in the 2.3 kernel. I can't find any code that use these routines in
the linux-2.3.24 drivers sources contained in the char or block
subdirectories.

What are 2.2 drivers supposed to do when claiming PCI memory space, and are
these routines actually used by any drivers? At a guess, I would just
duplicate the macro from the 2.3 sources back into 2.2 so that the driver
works with either but uses the new names.

-Bret

-------------------------------------------------------------
SBS Technologies, Connectivity Products
... solutions for real-time connectivity

Bret Indrelee, Engineer
SBS Technologies, Inc., Connectivity Products
1284 Corporate Center Drive, St. Paul MN 55121
Direct: (651) 905-4731
Main: (651) 905-4700 Fax: (651) 905-4701
E-mail: bindrelee@sbs-cp.com http://www.sbs.com
-------------------------------------------------------------

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:54    [W:0.031 / U:1.148 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site