summaryrefslogtreecommitdiffstats
path: root/lib/devres.c
diff options
context:
space:
mode:
authorBen Dooks <ben.dooks@codethink.co.uk>2023-06-21 18:30:50 +0200
committerAndrew Morton <akpm@linux-foundation.org>2023-06-24 02:04:04 +0200
commit875e0c31f84cb264d4d7b1569a1966cedcc4d459 (patch)
tree7f6ef09ab5c34c27f094d774272bec7fad39baad /lib/devres.c
parentwatchdog/hardlockup: define HARDLOCKUP_DETECTOR_ARCH (diff)
downloadlinux-875e0c31f84cb264d4d7b1569a1966cedcc4d459.tar.xz
linux-875e0c31f84cb264d4d7b1569a1966cedcc4d459.zip
devres: show which resource was invalid in __devm_ioremap_resource()
The other error prints in this call show the resource which wsan't valid, so add this to the first print when it checks for basic validity of the resource. Link: https://lkml.kernel.org/r/20230621163050.477668-1-ben.dooks@codethink.co.uk Signed-off-by: Ben Dooks <ben.dooks@codethink.co.uk> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'lib/devres.c')
-rw-r--r--lib/devres.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/devres.c b/lib/devres.c
index 6baf43902ead..c44f104b58d5 100644
--- a/lib/devres.c
+++ b/lib/devres.c
@@ -129,7 +129,7 @@ __devm_ioremap_resource(struct device *dev, const struct resource *res,
BUG_ON(!dev);
if (!res || resource_type(res) != IORESOURCE_MEM) {
- dev_err(dev, "invalid resource\n");
+ dev_err(dev, "invalid resource %pR\n", res);
return IOMEM_ERR_PTR(-EINVAL);
}