diff --git a/drivers/regulator/core.c b/drivers/regulator/core.c index d015d99cb59d..7486f6e4e613 100644 --- a/drivers/regulator/core.c +++ b/drivers/regulator/core.c @@ -1849,7 +1849,6 @@ struct regulator *_regulator_get(struct device *dev, const char *id, { struct regulator_dev *rdev; struct regulator *regulator; - const char *devname = dev ? dev_name(dev) : "deviceless"; struct device_link *link; int ret; @@ -1887,9 +1886,7 @@ struct regulator *_regulator_get(struct device *dev, const char *id, * enabled, even if it isn't hooked up, and just * provide a dummy. */ - dev_warn(dev, - "%s supply %s not found, using dummy regulator\n", - devname, id); + dev_warn(dev, "supply %s not found, using dummy regulator\n", id); rdev = dummy_regulator_rdev; get_device(&rdev->dev); break;