Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

PCI: cpqphp: Use DEFINE_SPINLOCK() for int15_lock

Initialize the static int15_lock spinlock with DEFINE_SPINLOCK() rather
than explicitly calling spin_lock_init().

Link: https://lore.kernel.org/r/1617710797-48903-1-git-send-email-huangguobin4@huawei.com
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Guobin Huang <huangguobin4@huawei.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>

authored by

Guobin Huang and committed by
Bjorn Helgaas
3a306a5b 3bbfd319

+1 -4
+1 -4
drivers/pci/hotplug/cpqphp_nvram.c
··· 80 80 static void __iomem *compaq_int15_entry_point; 81 81 82 82 /* lock for ordering int15_bios_call() */ 83 - static spinlock_t int15_lock; 83 + static DEFINE_SPINLOCK(int15_lock); 84 84 85 85 86 86 /* This is a series of function that deals with ··· 415 415 compaq_int15_entry_point = (rom_start + ROM_INT15_PHY_ADDR - ROM_PHY_ADDR); 416 416 417 417 dbg("int15 entry = %p\n", compaq_int15_entry_point); 418 - 419 - /* initialize our int15 lock */ 420 - spin_lock_init(&int15_lock); 421 418 } 422 419 423 420