And welcome to LQ!
To the best of my knowledge PCI addresses are handed out by the machine
BIOS, not picked by the OS. As for your program I'd suggest that find
a different method of identifying the device you want to talk to then
the port address which it has on your machine.