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:   Thu, 24 Sep 2020 03:10:51 +0200
From:   Andrew Lunn <andrew@...n.ch>
To:     Ioana Ciornei <ioana.ciornei@....com>
Cc:     davem@...emloft.net, netdev@...r.kernel.org, linux@...linux.org.uk
Subject: Re: [PATCH net-next v2 3/3] dpaa2-mac: add PCS support through the
 Lynx module

> +static int dpaa2_pcs_create(struct dpaa2_mac *mac,
> +			    struct device_node *dpmac_node, int id)
> +{
> +	struct mdio_device *mdiodev;
> +	struct device_node *node;
> +
> +	node = of_parse_phandle(dpmac_node, "pcs-handle", 0);
> +	if (!node) {
> +		/* do not error out on old DTS files */
> +		netdev_warn(mac->net_dev, "pcs-handle node not found\n");
> +		return 0;
> +	}
> +
> +	if (!of_device_is_available(node) ||
> +	    !of_device_is_available(node->parent)) {
> +		netdev_err(mac->net_dev, "pcs-handle node not available\n");
> +		return -ENODEV;
> +	}

Can a child be available when its parent is not? I've no idea!

Reviewed-by: Andrew Lunn <andrew@...n.ch>

    Andrew

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ