/* A device has been removed, remove its routes.  */
void x25_route_device_down(struct net_device *dev)
/* A device has been removed, remove its routes.  */
void x25_route_device_down(struct net_device *dev)
{
	struct x25_route *rt;
	struct list_head *entry, *tmp;
	write_lock_bh(&x25_route_list_lock);
	list_for_each_safe(entry, tmp, &x25_route_list) {
		rt = list_entry(entry, struct x25_route, node);
		if (rt->dev == dev)
			__x25_remove_route(rt);
	}
	write_unlock_bh(&x25_route_list_lock);
	x25_clear_forward_by_dev(dev);
}