[PATCH] phy: qcom-qmp-usb: Fix an NULL vs IS_ERR() bug

Johan Hovold johan at kernel.org
Mon Apr 14 00:40:13 PDT 2025


On Mon, Apr 14, 2025 at 09:30:19AM +0200, Krzysztof Kozlowski wrote:
> On 13/04/2025 23:25, Chenyuan Yang wrote:
> > In qmp_usb_iomap(), one branch returns the result of devm_ioremap(), which
> > can be NULL. Since IS_ERR() does not catch a NULL pointer,
> 
> No, that's not true. NAK.

I'm afraid you're mistaken here. See __devm_ioremap() which can return
NULL.

Johan



More information about the linux-phy mailing list