lkml.org 
[lkml]   [1999]   [Jul]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: New kernel/resource.c
On Fri, Jul 09, 1999 at 06:21:32PM -0700, Linus Torvalds wrote:
>
> I got tired of the problems with the resource management - lack of
> hierarchy, and the stupid and utterly horrible static allocation.

In principle, I like the heirarchical arrangement because it is
"right", but since we have no infrastructure for communicating
resource information between bus drivers and device drivers, it
doesn't look like there is any way for me to use this capability
without significant driver updates.

Martin Mares and I had recently written code so that the PCI subsystem
would pre-occupy all IO and memory regions that are committed to PCI
devices. In the new system, I guess this information would all go
into one tier of the resource tree, and drivers would then need to
request resources from nodes in that tier, instead of from the root IO
and memory resource nodes.

So the tree would really need to look like:

- we have a "Root IO" resource, 0-0xffff
- one of many "PCI IO" resources is 0x60-0x6f
- the keyboard driver allocates 0x60-0x6f from this node
- one of several "PCMCIA IO" resources is 0x1000-0x100f
- the IDE driver allocates 0x1000-0x100f from this node
- a "PCI IO" resources is 0x2000-0x21ff for a CardBus bridge IO window
- one "CardBus IO" resource is 0x2000-0x20ff
- the 3c575_cb driver allocates 0x2000-0x20ff for PCI base 0
- another "CardBus IO" resource is 0x2100-0x21ff
- the 3c575_cb driver allocates 0x2100-0x21ff for PCI base 1

For PCI, this might not be too hard to add, since we could add sets of
pointers to resource nodes to the pci_dev structure. For ISA devices,
things are more complicated since there is no device structure to
stuff things in.

-- Dave

-
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:52    [W:0.337 / U:0.056 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site