/* A device has been removed, remove its links.  */
void x25_link_device_down(struct net_device *dev)
/* A device has been removed, remove its links.  */
void x25_link_device_down(struct net_device *dev)
{
	struct x25_neigh *nb;
	struct list_head *entry, *tmp;
	write_lock_bh(&x25_neigh_list_lock);
	list_for_each_safe(entry, tmp, &x25_neigh_list) {
		nb = list_entry(entry, struct x25_neigh, node);
		if (nb->dev == dev) {
			__x25_remove_neigh(nb);
			dev_put(dev);
		}
	}
	write_unlock_bh(&x25_neigh_list_lock);
}