virt/kvm/iommu.c: Add leading zeros to device's BDF notation in debug messages
authorAndre Richter <andre.o.richter@gmail.com>
Wed, 2 Oct 2013 10:23:26 +0000 (12:23 +0200)
committerChristoffer Dall <christoffer.dall@linaro.org>
Thu, 2 Oct 2014 15:18:09 +0000 (17:18 +0200)
commit708854902d50f40783a81a629c4131383249236d
tree9acf7acc6b33825bf969ab6417a18560b949ad44
parent89c774beb24924963aa146784a149e47efb29d82
virt/kvm/iommu.c: Add leading zeros to device's BDF notation in debug messages

When KVM (de)assigns PCI(e) devices to VMs, a debug message is printed
including the BDF notation of the respective device. Currently, the BDF
notation does not have the commonly used leading zeros. This produces
messages like "assign device 0:1:8.0", which look strange at first sight.

The patch fixes this by exchanging the printk(KERN_DEBUG ...) with dev_info()
and also inserts "kvm" into the debug message, so that it is obvious where
the message comes from. Also reduces LoC.

Acked-by: Alex Williamson <alex.williamson@redhat.com>
Signed-off-by: Andre Richter <andre.o.richter@gmail.com>
Signed-off-by: Gleb Natapov <gleb@redhat.com>
(cherry picked from commit 29242cb5c63b1f8e12e8055ba1a6c3e0004fa86d)
Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org>
virt/kvm/iommu.c