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  linux-cve-announce  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:   Mon, 22 Aug 2016 19:40:41 +0530
From:   Kedari Appana <kedare06@...il.com>
To:     Wei Yongjun <weiyj.lk@...il.com>
Cc:     f.fainelli@...il.com, michal.simek@...inx.com,
        soren.brinkmann@...inx.com, Andrew Lunn <andrew@...n.ch>,
        David Miller <davem@...emloft.net>, netdev@...r.kernel.org,
        linux-arm-kernel@...ts.infradead.org
Subject: Re: [PATCH -next v2] net: phy: Add missing of_node_put() in xgmiitorgmii_probe()

Hi ,


On Mon, Aug 22, 2016 at 4:16 AM, Wei Yongjun <weiyj.lk@...il.com> wrote:
> This node pointer is returned by of_parse_phandle() with
> refcount incremented in this function. of_node_put() on it
> before exitting this function.
>
> This is detected by Coccinelle semantic patch.
>
> Signed-off-by: Wei Yongjun <weiyj.lk@...il.com>

Reviewed-by: Kedareswara rao Appana <appanad@...inx.com>

Thanks,
Kedar.

> ---
> v1 -> v2: release it unconditionally as Andrew and David's suggestion
> ---
>  drivers/net/phy/xilinx_gmii2rgmii.c | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/drivers/net/phy/xilinx_gmii2rgmii.c b/drivers/net/phy/xilinx_gmii2rgmii.c
> index cad6e19..73b50f3 100644
> --- a/drivers/net/phy/xilinx_gmii2rgmii.c
> +++ b/drivers/net/phy/xilinx_gmii2rgmii.c
> @@ -73,6 +73,7 @@ int xgmiitorgmii_probe(struct mdio_device *mdiodev)
>         }
>
>         priv->phy_dev = of_phy_find_device(phy_node);
> +       of_node_put(phy_node);
>         if (!priv->phy_dev) {
>                 dev_info(dev, "Couldn't find phydev\n");
>                 return -EPROBE_DEFER;
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ