Re: kernel/resource.c breakage

David Hinds (dhinds@zen.stanford.edu)
Sat, 3 Jul 1999 22:49:44 -0700


On Sat, Jul 03, 1999 at 09:33:52PM -0400, Jeff Garzik wrote:
> >
> > The main problem is release_region(). Previously it would
> > discard all information about the region. Now it _keeps_
> > the region description (base+extent), but gives it a magic
> > marker (name==NULL). The new check_region() and request_region()
> > will allow an existing "magic" region to be reallocated in its
> > entirety. Other allocations that partially interfere with a
> > "magic" region will not succeed.
>
> There was disagreement from several people about this... Several people
> thought that the resource allocation code should not leave info around
> after it has been released, resulting in the behavior you describe.

It is only a temporary accident that it appears easy to undo this
change, because the resource management changes are being done in an
incremental fashion. The "leaving info around" is going to happen
because it's the whole point. To safely configure a new device,
you've got to know what resources are used by other hardware, whether
or not a driver happens to currently own those resources. At the
moment, the only things leaving info around are the existing drivers,
but soon that info will be left around by the PCI subsystem and some
PnP code.

A consequence of this is that if multiple drivers use one piece of
hardware, they're going to have to agree on what resource ranges
describe that piece of hardware, and not try to grab arbitrary subsets
of resources. That seems like a reasonably minor restriction.

-- Dave Hinds

-
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/