summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLiao Pingfang <liao.pingfang@zte.com.cn>2020-07-09 10:28:28 +0300
committerBjorn Helgaas <bhelgaas@google.com>2020-07-10 00:01:09 +0300
commitc7c337c5eded50a5a1265a0e8918db66e5982f47 (patch)
tree266f9d9b71d3f6909534862d0517aef5922f34e8
parent16bbbc874f7f98e6598784896ed4719f0f1ed844 (diff)
downloadlinux-c7c337c5eded50a5a1265a0e8918db66e5982f47.tar.xz
PCI: Fix error in panic message
Use kzalloc() instead of kmalloc() in the panic message. [bhelgaas: drop similar ibmphp_pci.c change since it's not obviously correct] Link: https://lore.kernel.org/r/1594279708-34369-1-git-send-email-wang.yi59@zte.com.cn Signed-off-by: Liao Pingfang <liao.pingfang@zte.com.cn> Signed-off-by: Yi Wang <wang.yi59@zte.com.cn> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
-rw-r--r--drivers/pci/setup-bus.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/pci/setup-bus.c b/drivers/pci/setup-bus.c
index 9b94b1f16d80..4d870ed89385 100644
--- a/drivers/pci/setup-bus.c
+++ b/drivers/pci/setup-bus.c
@@ -152,7 +152,7 @@ static void pdev_sort_resources(struct pci_dev *dev, struct list_head *head)
tmp = kzalloc(sizeof(*tmp), GFP_KERNEL);
if (!tmp)
- panic("pdev_sort_resources(): kmalloc() failed!\n");
+ panic("%s: kzalloc() failed!\n", __func__);
tmp->res = r;
tmp->dev = dev;