Fixes a message output at deldp time:
unregister_netdevice: waiting for of0 to become free. Usage count = 1
Thanks to Murphy and Justin for reporting this bug.
{
struct net_bridge_port *p;
- dp_dev_destroy(dp);
kthread_stop(dp->dp_task);
/* Drop references to DP. */
del_switch_port(p);
rcu_assign_pointer(dps[dp->dp_idx], NULL);
+ /* Destroy dp->netdev. (Must follow deleting switch ports since
+ * dp->local_port has a reference to it.) */
+ dp_dev_destroy(dp);
+
/* Wait until no longer in use, then destroy it. */
synchronize_rcu();
chain_destroy(dp->chain);