net: Rename dst_get_neighbour{, _raw} to dst_get_neighbour_noref{, _raw}.

To reflect the fact that a refrence is not obtained to the
resulting neighbour entry.

Signed-off-by: David S. Miller <[email protected]>
Acked-by: Roland Dreier <[email protected]>
This commit is contained in:
David Miller 2011-12-02 16:52:08 +00:00 • committed by David S. Miller
commit 2721745501
29 changed files with 58 additions and 58 deletions

View file

@ -217,7 +217,7 @@ static int addr4_resolve(struct sockaddr_in *src_in,
neigh = neigh_lookup(&arp_tbl, &rt->rt_gateway, rt->dst.dev);
if (!neigh || !(neigh->nud_state & NUD_VALID)) {
rcu_read_lock();
neigh_event_send(dst_get_neighbour(&rt->dst), NULL);
neigh_event_send(dst_get_neighbour_noref(&rt->dst), NULL);
rcu_read_unlock();
ret = -ENODATA;
if (neigh)
@ -277,7 +277,7 @@ static int addr6_resolve(struct sockaddr_in6 *src_in,
}
rcu_read_lock();
neigh = dst_get_neighbour(dst);
neigh = dst_get_neighbour_noref(dst);
if (!neigh || !(neigh->nud_state & NUD_VALID)) {
if (neigh)
neigh_event_send(neigh, NULL);

View file

@ -1376,7 +1376,7 @@ static int pass_accept_req(struct t3cdev *tdev, struct sk_buff *skb, void *ctx)
}
dst = &rt->dst;
rcu_read_lock();
neigh = dst_get_neighbour(dst);
neigh = dst_get_neighbour_noref(dst);
l2t = t3_l2t_get(tdev, neigh, neigh->dev);
rcu_read_unlock();
if (!l2t) {
@ -1949,7 +1949,7 @@ int iwch_connect(struct iw_cm_id *cm_id, struct iw_cm_conn_param *conn_param)
ep->dst = &rt->dst;
rcu_read_lock();
neigh = dst_get_neighbour(ep->dst);
neigh = dst_get_neighbour_noref(ep->dst);
/* get a l2t entry */
ep->l2t = t3_l2t_get(ep->com.tdev, neigh, neigh->dev);

View file

@ -1597,7 +1597,7 @@ static int pass_accept_req(struct c4iw_dev *dev, struct sk_buff *skb)
}
dst = &rt->dst;
rcu_read_lock();
neigh = dst_get_neighbour(dst);
neigh = dst_get_neighbour_noref(dst);
if (neigh->dev->flags & IFF_LOOPBACK) {
pdev = ip_dev_find(&init_net, peer_ip);
BUG_ON(!pdev);
@ -1825,7 +1825,7 @@ static int c4iw_reconnect(struct c4iw_ep *ep)
ep->dst = &rt->dst;
rcu_read_lock();
neigh = dst_get_neighbour(ep->dst);
neigh = dst_get_neighbour_noref(ep->dst);
/* get a l2t entry */
if (neigh->dev->flags & IFF_LOOPBACK) {
@ -2308,7 +2308,7 @@ int c4iw_connect(struct iw_cm_id *cm_id, struct iw_cm_conn_param *conn_param)
ep->dst = &rt->dst;
rcu_read_lock();
neigh = dst_get_neighbour(ep->dst);
neigh = dst_get_neighbour_noref(ep->dst);
/* get a l2t entry */
if (neigh->dev->flags & IFF_LOOPBACK) {

View file

@ -1379,7 +1379,7 @@ static int nes_addr_resolve_neigh(struct nes_vnic *nesvnic, u32 dst_ip, int arpi
if ((neigh == NULL) || (!(neigh->nud_state & NUD_VALID))) {
rcu_read_lock();
neigh_event_send(dst_get_neighbour(&rt->dst), NULL);
neigh_event_send(dst_get_neighbour_noref(&rt->dst), NULL);
rcu_read_unlock();
}
ip_rt_put(rt);

View file

@ -564,7 +564,7 @@ static void neigh_add_path(struct sk_buff *skb, struct net_device *dev)
struct neighbour *n;
unsigned long flags;
n = dst_get_neighbour(skb_dst(skb));
n = dst_get_neighbour_noref(skb_dst(skb));
neigh = ipoib_neigh_alloc(n, skb->dev);
if (!neigh) {
++dev->stats.tx_dropped;
@ -645,7 +645,7 @@ static void ipoib_path_lookup(struct sk_buff *skb, struct net_device *dev)
struct neighbour *n;
/* Look up path record for unicasts */
n = dst_get_neighbour(dst);
n = dst_get_neighbour_noref(dst);
if (n->ha[4] != 0xff) {
neigh_add_path(skb, dev);
return;
@ -724,7 +724,7 @@ static int ipoib_start_xmit(struct sk_buff *skb, struct net_device *dev)
rcu_read_lock();
if (likely(skb_dst(skb)))
n = dst_get_neighbour(skb_dst(skb));
n = dst_get_neighbour_noref(skb_dst(skb));
if (likely(n)) {
if (unlikely(!*to_ipoib_neigh(n))) {
@ -841,7 +841,7 @@ static int ipoib_hard_header(struct sk_buff *skb,
dst = skb_dst(skb);
n = NULL;
if (dst)
n = dst_get_neighbour_raw(dst);
n = dst_get_neighbour_noref_raw(dst);
if ((!dst || !n) && daddr) {
struct ipoib_pseudoheader *phdr =
(struct ipoib_pseudoheader *) skb_push(skb, sizeof *phdr);

View file

@ -269,7 +269,7 @@ static int ipoib_mcast_join_finish(struct ipoib_mcast *mcast,
skb->dev = dev;
if (dst)
n = dst_get_neighbour_raw(dst);
n = dst_get_neighbour_noref_raw(dst);
if (!dst || !n) {
/* put pseudoheader back on for next time */
skb_push(skb, sizeof (struct ipoib_pseudoheader));
@ -728,7 +728,7 @@ out:
rcu_read_lock();
if (dst)
n = dst_get_neighbour(dst);
n = dst_get_neighbour_noref(dst);
if (n && !*to_ipoib_neigh(n)) {
struct ipoib_neigh *neigh = ipoib_neigh_alloc(n,
skb->dev);