Skip to content
Snippets Groups Projects
Commit 540ad493 authored by Boppana Prasad, Rajendra's avatar Boppana Prasad, Rajendra Committed by Oussama Ghorbel
Browse files

Merge pull request #16 in SW_UGW/linux from...

Merge pull request #16 in SW_UGW/linux from bugfix/UGW_SW-26630-cst-8.x-ftp-login-is-not-successful to ugw-grx500-linux-4.9.y

Fix on top of openwrt kernel patch 670-ipv6-allow-rejecting-with-source-address-failed-policy.patch which adds ip6_policy_failed_entry, but if it only ever calls in6_dev_get, which increments the refs we also need to call in6_dev_put to decrement the refs

* commit '520b592f5b2901591efe76853fa8be12ad260b84':
  Revert "Merge pull request #15 in SW_UGW/linux from bugfix/UGW_SW-26630-cst-8.x-ftp-login-is-not-successful to ugw-grx500-linux-4.9.y"
  UGW_SW-26630-Fix openwrt kernel patch 670-ipv6-allow-rejecting-with-source-address-failed-policy.patch adds ip6_policy_failed_entry, but if it only ever calls in6_dev_get, which increments the refs we also need to call in6_dev_put to decrement the refs
parent 260fc3e5
No related branches found
No related tags found
No related merge requests found
......@@ -3541,10 +3541,15 @@ static int ip6_route_dev_notify(struct notifier_block *this,
net->ipv6.ip6_blk_hole_entry->dst.dev = dev;
net->ipv6.ip6_blk_hole_entry->rt6i_idev = in6_dev_get(dev);
#endif
} else if (event == NETDEV_UNREGISTER) {
} else if (event == NETDEV_UNREGISTER &&
dev->reg_state != NETREG_UNREGISTERED) {
/* NETDEV_UNREGISTER could be fired for multiple times by
* netdev_wait_allrefs(). Make sure we only call this once.
*/
in6_dev_put(net->ipv6.ip6_null_entry->rt6i_idev);
#ifdef CONFIG_IPV6_MULTIPLE_TABLES
in6_dev_put(net->ipv6.ip6_prohibit_entry->rt6i_idev);
in6_dev_put(net->ipv6.ip6_policy_failed_entry->rt6i_idev);
in6_dev_put(net->ipv6.ip6_blk_hole_entry->rt6i_idev);
#endif
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment