USB: gadget: udc: s3c2410_udc: fix return value check in s3c2410_udc_probe()
In case of error, the function devm_platform_ioremap_resource() returns ERR_PTR() and never returns NULL. The NULL test in the return value check should be replaced with IS_ERR(). Fixes: 188db443 ("usb: gadget: s3c: use platform resources") Cc: stable <stable@vger.kernel.org> Reported-by: NHulk Robot <hulkci@huawei.com> Reviewed-by: NArnd Bergmann <arnd@arndb.de> Reviewed-by: NKrzysztof Kozlowski <krzysztof.kozlowski@canonical.com> Signed-off-by: NWei Yongjun <weiyongjun1@huawei.com> Link: https://lore.kernel.org/r/20210305034927.3232386-1-weiyongjun1@huawei.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Showing
想要评论请 注册 或 登录