libpciaccess on GNU/Hurd
damien at zamaudio.com
Mon Nov 5 11:56:32 UTC 2018
I wish to propose an additional api call to libpciaccess.
Before I submit a patch, I wish to get some feedback from the devs.
In GNU/Hurd currently, applications use the x86 backend from
libpciaccess. This poses concurrency issues when multiple applications
run at the same time accessing pci.
Thus we want to make libpciaccess do operations through an arbiter.
The pci arbiter would use libpciaccess to access the x86 methods, but
then we wish to make applications use the hurd method on top of that.
Since our arbiter links to the same libpciaccess.so as the user's one,
we need a way to force the x86 method to start up the arbiter instead of
relying on the compiled in single-shot autodetection method
(which will attempt to use the hurd method every time on GNU/Hurd and
thus break because the arbiter has not started yet - a chicken/egg problem).
Having an API call would be useful such as:
int pci_system_init_force(enum access_method method);
where the enum contains all access methods, but the implementation of
the function could restrict the allowed methods to ones relevant to the
architecture the library is compiled on.
Please let me know your thoughts.
More information about the xorg-devel