Re: devres and requesting resources
From: Alan Cox
Date: Fri Feb 29 2008 - 09:07:20 EST
> Only rare PCI devices are shareable among multiple drivers.
Really. Let me see
AGP & EDAC
Serial/Parallel combo ports
MPIIX
CS5520
Lots of I2C bus stuff
VGA v 3D
There are quite a few, and some are already quite fun enough with our pci
struct model.
> sata_* at least intentionally used pci_request_regions() because it is
> obvious from the hardware spec that multiple regions accessed by
> multiple drivers is highly unlikely, without the driver being
> specifically coded to support such sharing. Such sharing code is far
> beyond simple resource reservation, to avoid stepping on toes when there
> is a single MMIO region and set of interrupt clearing registers.
>
> So reading your email it sounds like there are valid cases for both
> configurations.
>
> Its a design choice either way, not a bug either way.
It is a flaw: devres that assumes it should grab all resources is unusable
for some other drivers - it is no longer generic and that makes it far
less useful. I've got no problem with the idea of a devres way to say
"and I want it all, mine mine mine" but that should not be the only
behaviour.
Alan
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/