lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 16 Sep 2020 17:24:31 -0700 (PDT)
From:   David Miller <davem@...emloft.net>
To:     olteanv@...il.com
Cc:     netdev@...r.kernel.org, yangbo.lu@....com,
        xiaoliang.yang_1@....com, UNGLinuxDriver@...rochip.com,
        claudiu.manoil@....com, alexandre.belloni@...tlin.com,
        andrew@...n.ch, vivien.didelot@...il.com, f.fainelli@...il.com,
        kuba@...nel.org
Subject: Re: [PATCH net 5/7] net: mscc: ocelot: error checking when calling
 ocelot_init()

From: Vladimir Oltean <olteanv@...il.com>
Date: Tue, 15 Sep 2020 21:22:27 +0300

> diff --git a/drivers/net/ethernet/mscc/ocelot_vsc7514.c b/drivers/net/ethernet/mscc/ocelot_vsc7514.c
> index 99872f1b7460..91a915d0693f 100644
> --- a/drivers/net/ethernet/mscc/ocelot_vsc7514.c
> +++ b/drivers/net/ethernet/mscc/ocelot_vsc7514.c
> @@ -1000,7 +1000,10 @@ static int mscc_ocelot_probe(struct platform_device *pdev)
>  	ocelot->vcap_is2_actions = vsc7514_vcap_is2_actions;
>  	ocelot->vcap = vsc7514_vcap_props;
>  
> -	ocelot_init(ocelot);
> +	err = ocelot_init(ocelot);
> +	if (err)
> +		return err;
> +

This also leaks the OF device 'ports' object.

Powered by blists - more mailing lists