summaryrefslogtreecommitdiff
path: root/net/rose
diff options
context:
space:
mode:
authorBernard Pidoux <f6bvp@free.fr>2011-02-14 13:33:49 -0800
committerDavid S. Miller <davem@davemloft.net>2011-02-14 13:33:49 -0800
commit68aa3fd551e9d54d98794852714dc1edbb21df77 (patch)
treeaa8baf67245bf29c748d6410d005e7e4f64d4dff /net/rose
parentc5d8b24ad0a9a45e163a6769b4eb7e7f1fb9aa7f (diff)
downloadlwn-68aa3fd551e9d54d98794852714dc1edbb21df77.tar.gz
lwn-68aa3fd551e9d54d98794852714dc1edbb21df77.zip
ROSE: AX25: finding routes simplification
With previous patch, rose_get_neigh() routine investigates the full list of neighbor nodes until it finds or not an already connected node whether it is called locally or through a level 3 transit frame. If no routes are opened through an adjacent connected node then a classical connect request is attempted. Then there is no more reason for an extra loop such as the one removed by this patch. Signed-off-by: Bernard Pidoux <f6bvp@free.fr> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/rose')
-rw-r--r--net/rose/af_rose.c7
1 files changed, 0 insertions, 7 deletions
diff --git a/net/rose/af_rose.c b/net/rose/af_rose.c
index d952e7eac188..5ee0c62046a0 100644
--- a/net/rose/af_rose.c
+++ b/net/rose/af_rose.c
@@ -803,7 +803,6 @@ static int rose_connect(struct socket *sock, struct sockaddr *uaddr, int addr_le
rose_insert_socket(sk); /* Finish the bind */
}
-rose_try_next_neigh:
rose->dest_addr = addr->srose_addr;
rose->dest_call = addr->srose_call;
rose->rand = ((long)rose & 0xFFFF) + rose->lci;
@@ -865,12 +864,6 @@ rose_try_next_neigh:
}
if (sk->sk_state != TCP_ESTABLISHED) {
- /* Try next neighbour */
- rose->neighbour = rose_get_neigh(&addr->srose_addr, &cause, &diagnostic, 0);
- if (rose->neighbour)
- goto rose_try_next_neigh;
-
- /* No more neighbours */
sock->state = SS_UNCONNECTED;
err = sock_error(sk); /* Always set at this point */
goto out_release;