phy: phy-brcm-usb-init: fix use of integer as pointer
authorBen Dooks <ben.dooks@codethink.co.uk>
Tue, 15 Oct 2019 16:03:32 +0000 (17:03 +0100)
committerKishon Vijay Abraham I <kishon@ti.com>
Wed, 23 Oct 2019 07:50:31 +0000 (13:20 +0530)
The xhci_ec_base variable is a pointer, so don't compare
it with an integer.

Signed-off-by: Ben Dooks <ben.dooks@codethink.co.uk>
Reviewed-by: Andrew Murray <andrew.murray@arm.com>
Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com>
drivers/phy/broadcom/phy-brcm-usb-init.c

index fa6dd11..91b5b09 100644 (file)
@@ -707,7 +707,7 @@ static void brcmusb_usb3_otp_fix(struct brcm_usb_init_params *params)
        void __iomem *xhci_ec_base = params->xhci_ec_regs;
        u32 val;
 
-       if (params->family_id != 0x74371000 || xhci_ec_base == 0)
+       if (params->family_id != 0x74371000 || !xhci_ec_base)
                return;
        brcmusb_writel(0xa20c, USB_XHCI_EC_REG(xhci_ec_base, IRAADR));
        val = brcmusb_readl(USB_XHCI_EC_REG(xhci_ec_base, IRADAT));