nvidia-detect: move pci_lookup_name() out of loop

move pci_lookup_name() out of loop so we're only doing it once per
device.

Signed-off-by: Philip J Perry <phil@elrepo.org>