diff options
author | David Fries <David@Fries.net> | 2011-11-20 16:29:46 -0500 |
---|---|---|
committer | Jesse Barnes <jbarnes@virtuousgeek.org> | 2012-01-06 15:10:30 -0500 |
commit | 82440a8253e09047410ff4df5c202be15645573f (patch) | |
tree | 9cb1f4f208a5d26079aef26bbef3fad54630d120 /drivers/pci/pci-driver.c | |
parent | d5dea7d95c48d7bc951cee4910a7fd9c0cd26fb0 (diff) |
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 <David@Fries.net>
Acked-by: Rafael J. Wysocki <rjw@sisk.pl>
Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
Diffstat (limited to 'drivers/pci/pci-driver.c')
-rw-r--r-- | drivers/pci/pci-driver.c | 3 |
1 files changed, 2 insertions, 1 deletions
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) | |||
604 | * supported as well. Drivers are supposed to support either the | 604 | * supported as well. Drivers are supposed to support either the |
605 | * former, or the latter, but not both at the same time. | 605 | * former, or the latter, but not both at the same time. |
606 | */ | 606 | */ |
607 | WARN_ON(ret && drv->driver.pm); | 607 | WARN(ret && drv->driver.pm, "driver %s device %04x:%04x\n", |
608 | drv->name, pci_dev->vendor, pci_dev->device); | ||
608 | 609 | ||
609 | return ret; | 610 | return ret; |
610 | } | 611 | } |