Re: New kernel/resource.c

Linus Torvalds (torvalds@transmeta.com)
Fri, 16 Jul 1999 22:35:58 -0700 (PDT)


On Fri, 16 Jul 1999, Jonathan Walther wrote:
>
> I'll submit to your decision here, but I hope we don't become too
> PC-centric. I thought you were moving towards broadening the scope of the
> kernel... The FreeBSD guys did the same thing, they let PC-isms creep into
> their "system".

THE NEW RESOURCE MANAGER IS DESIGNED TO BE GENERIC!!

You can have a "pci_io_resource" and a "vme_area_resource" active at the
same time. And a "sbus_area_resource". And ANYTHING. It doesn't even have
to be an IO bus. It could be used to keep track of memory allocations. It
can be used to maintain a list of just about _anything_ that can be
enumerated.

A "resource" is anything that can be used and can be doled out to
different entities, be they drivers or filesystems or users.. But that
also means that you cannot and should not use a single resource for
everything. You should NAME your resources when you actually want to start
talking about a specific type of resource.

Gods, people. It's not being PC-centric. It's a matter of specifying what
the hell the resource IS! It could be anything, but when it comes to
PCMCIA we're now talking about one specific instance of a resource type.

So when we're talking about PC hardware drivers, the resource is a area in
a PCI-like memory or IO space.

If somebody does drivers for something that doesn't have anything to do
with PCI, they would use ANOTHER resource altogether. And THAT is why I
don't like "bus_resource" or names like that. That is too generic, and is
no longer an instantiation of one particular resource.

PC-specific? No.

Specific to the type of bus that the PC made successful? Yes. And that's
the whole POINT.

Linus

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