dst.c (371bb62158d53c1fc33e2fb9b6aeb9522caf6cf4) | dst.c (8d7017fd621d02ff0d47d19484350c2356828483) |
---|---|
1// SPDX-License-Identifier: GPL-2.0-only 2/* 3 * net/core/dst.c Protocol independent destination cache. 4 * 5 * Authors: Alexey Kuznetsov, <kuznet@ms2.inr.ac.ru> 6 * 7 */ 8 --- 146 unchanged lines hidden (view full) --- 155{ 156 struct net_device *dev = dst->dev; 157 158 dst->obsolete = DST_OBSOLETE_DEAD; 159 if (dst->ops->ifdown) 160 dst->ops->ifdown(dst, dev, true); 161 dst->input = dst_discard; 162 dst->output = dst_discard_out; | 1// SPDX-License-Identifier: GPL-2.0-only 2/* 3 * net/core/dst.c Protocol independent destination cache. 4 * 5 * Authors: Alexey Kuznetsov, <kuznet@ms2.inr.ac.ru> 6 * 7 */ 8 --- 146 unchanged lines hidden (view full) --- 155{ 156 struct net_device *dev = dst->dev; 157 158 dst->obsolete = DST_OBSOLETE_DEAD; 159 if (dst->ops->ifdown) 160 dst->ops->ifdown(dst, dev, true); 161 dst->input = dst_discard; 162 dst->output = dst_discard_out; |
163 dst->dev = dev_net(dst->dev)->loopback_dev; | 163 dst->dev = blackhole_netdev; |
164 dev_hold(dst->dev); 165 dev_put(dev); 166} 167EXPORT_SYMBOL(dst_dev_put); 168 169void dst_release(struct dst_entry *dst) 170{ 171 if (dst) { --- 161 unchanged lines hidden --- | 164 dev_hold(dst->dev); 165 dev_put(dev); 166} 167EXPORT_SYMBOL(dst_dev_put); 168 169void dst_release(struct dst_entry *dst) 170{ 171 if (dst) { --- 161 unchanged lines hidden --- |