added lock for PCI devices