Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

phy: bcm-ns-usb2: improve printing ref clk errors

Improve message & use dev_err_probe() helper which prints actual error
(helpful for debugging) and deals with -EPROBE_DEFER.

Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Link: https://lore.kernel.org/r/20211123221521.25323-1-zajec5@gmail.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>

authored by

Rafał Miłecki and committed by
Vinod Koul
97ba12d3 97004c1a

+1 -1
+1 -1
drivers/phy/broadcom/phy-bcm-ns-usb2.c
··· 132 132 133 133 usb2->ref_clk = devm_clk_get(dev, "phy-ref-clk"); 134 134 if (IS_ERR(usb2->ref_clk)) { 135 - dev_err(dev, "Clock not defined\n"); 135 + dev_err_probe(dev, PTR_ERR(usb2->ref_clk), "failed to get ref clk\n"); 136 136 return PTR_ERR(usb2->ref_clk); 137 137 } 138 138