lkml.org 
[lkml]   [2001]   [May]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: isa_read/write not available on ppc - solution suggestions ??
At 3:46 PM -0700 2001-05-01, Linus Torvalds wrote:
>On Tue, 1 May 2001, Russell King wrote:
> >
>> In which case, can we change the following in IO-mapping.txt please?
>
>Oh, sorry. I misread your question. The _return_ value is a cookie.
>
>The first argument should basically be the start of a "struct pci_dev"
>resource entry, but obviously architecture-specific code can (and does)
>know what the thing means. And the ISA space (ie 0xA0000-0x100000) has
>been considered an acceptable special case.
>
>So the only usage that is "portable" is to do something like
>
> cookie = ioremap(pdev->resource[0].start, pdev->resource[0].len);
>
>and I guess we should actually create some helper functions for that too.
>
>You can use ioremap in other ways, but there's nothing to say that they
>will work reliably across multiple PCI buses etc.

What's the Linu[sx] attitude to using a type to help control (and
illuminate) the use of these objects? I'm thinking here in particular
of the cookie returned by ioremap() and used by readx/writex, but I
suppose there might be similar applicability to its first parameter.
--
/Jonathan Lundell.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 12:52    [W:0.070 / U:6.876 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site