From: Wolfram Sang Date: Tue, 20 Sep 2011 17:41:17 +0000 (+0200) Subject: drivers: base: print rejected matches with DEBUG_DRIVER X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=bcbe4f94d15ae1c985336bb3c35605e595fdde0d;p=mv-sheeva.git drivers: base: print rejected matches with DEBUG_DRIVER When DEBUG_DRIVER is activated, be verbose and explicitly state when a device<->driver match was rejected by the probe-function of the driver. Now all code-paths report what is currently happening which helps debugging, because you don't have to remember that no printout means the match is rejected (and then you still don't know if it was because of ENODEV or ENXIO). Signed-off-by: Wolfram Sang Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/base/dd.c b/drivers/base/dd.c index 6658da743c3..142e3d600f1 100644 --- a/drivers/base/dd.c +++ b/drivers/base/dd.c @@ -147,6 +147,9 @@ probe_failed: printk(KERN_WARNING "%s: probe of %s failed with error %d\n", drv->name, dev_name(dev), ret); + } else { + pr_debug("%s: probe of %s rejects match %d\n", + drv->name, dev_name(dev), ret); } /* * Ignore errors returned by ->probe so that the next driver can try