Re: [PATCH v6 2/3] net: ethernet: renesas: Add support for "Ethernet Switch"

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> +	for (i = 0; i < RSWITCH_NUM_PORTS; i++) {
> +		err = register_netdev(priv->rdev[i]->ndev);
> +		if (err) {
> +			for (i--; i >= 0; i--)
> +				unregister_netdev(priv->rdev[i]->ndev);
> +			goto err_register_netdev;
> +		}
> +	}
> +
> +	err = rswitch_ether_port_init_all(priv);
> +	if (err)
> +		goto err_ether_port_init_all;

As soon as you call register_netdev() the devices are active, and can
be in use. E.G. NFS root can start mounting the filesystem before
register_netdev() even returns. Is it safe to call driver operations
before rswitch_ether_port_init_all().

	Andrew



[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux