From: David Fries Date: Sun, 20 Nov 2011 21:29:46 +0000 (-0600) Subject: PCI: pci_has_legacy_pm_support add driver and device to WARN X-Git-Tag: firefly_0821_release~3680^2~3753^2~69 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=82440a8253e09047410ff4df5c202be15645573f;p=firefly-linux-kernel-4.4.55.git PCI: pci_has_legacy_pm_support add driver and device to WARN Include the driver name and device in warning when a pci driver supports both legacy pm and new framework as just the stack trace gives no way to identify the driver. Signed-off-by: David Fries Acked-by: Rafael J. Wysocki Signed-off-by: Jesse Barnes --- diff --git a/drivers/pci/pci-driver.c b/drivers/pci/pci-driver.c index 12d1e81a8abe..3623d65f8b86 100644 --- a/drivers/pci/pci-driver.c +++ b/drivers/pci/pci-driver.c @@ -604,7 +604,8 @@ static bool pci_has_legacy_pm_support(struct pci_dev *pci_dev) * supported as well. Drivers are supposed to support either the * former, or the latter, but not both at the same time. */ - WARN_ON(ret && drv->driver.pm); + WARN(ret && drv->driver.pm, "driver %s device %04x:%04x\n", + drv->name, pci_dev->vendor, pci_dev->device); return ret; }