[RXRPC]: Decrease number of pointer derefs in connection.c

Decrease the number of pointer derefs in net/rxrpc/connection.c

Benefits of the patch:
- Fewer pointer dereferences should make the code slightly faster.
- Size of generated code is smaller
- improved readability

Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Jesper Juhl and committed by
David S. Miller
ea2e90df ad8e4b75

+8 -6
+8 -6
net/rxrpc/connection.c
··· 220 { 221 struct rxrpc_connection *conn, *candidate = NULL; 222 struct list_head *_p; 223 int ret, fresh = 0; 224 __be32 x_epoch, x_connid; 225 __be16 x_port, x_servid; ··· 230 _enter("%p{{%hu}},%u,%hu", 231 peer, 232 peer->trans->port, 233 - ntohs(msg->pkt->h.uh->source), 234 ntohs(msg->hdr.serviceId)); 235 236 - x_port = msg->pkt->h.uh->source; 237 x_epoch = msg->hdr.epoch; 238 x_clflag = msg->hdr.flags & RXRPC_CLIENT_INITIATED; 239 x_connid = htonl(ntohl(msg->hdr.cid) & RXRPC_CIDMASK); ··· 268 /* fill in the specifics */ 269 candidate->addr.sin_family = AF_INET; 270 candidate->addr.sin_port = x_port; 271 - candidate->addr.sin_addr.s_addr = msg->pkt->nh.iph->saddr; 272 candidate->in_epoch = x_epoch; 273 candidate->out_epoch = x_epoch; 274 candidate->in_clientflag = RXRPC_CLIENT_INITIATED; ··· 676 struct rxrpc_message *msg) 677 { 678 struct rxrpc_message *pmsg; 679 struct list_head *_p; 680 unsigned cix, seq; 681 int ret = 0; ··· 712 713 call->pkt_rcv_count++; 714 715 - if (msg->pkt->dst && msg->pkt->dst->dev) 716 conn->peer->if_mtu = 717 - msg->pkt->dst->dev->mtu - 718 - msg->pkt->dst->dev->hard_header_len; 719 720 /* queue on the call in seq order */ 721 rxrpc_get_message(msg);
··· 220 { 221 struct rxrpc_connection *conn, *candidate = NULL; 222 struct list_head *_p; 223 + struct sk_buff *pkt = msg->pkt; 224 int ret, fresh = 0; 225 __be32 x_epoch, x_connid; 226 __be16 x_port, x_servid; ··· 229 _enter("%p{{%hu}},%u,%hu", 230 peer, 231 peer->trans->port, 232 + ntohs(pkt->h.uh->source), 233 ntohs(msg->hdr.serviceId)); 234 235 + x_port = pkt->h.uh->source; 236 x_epoch = msg->hdr.epoch; 237 x_clflag = msg->hdr.flags & RXRPC_CLIENT_INITIATED; 238 x_connid = htonl(ntohl(msg->hdr.cid) & RXRPC_CIDMASK); ··· 267 /* fill in the specifics */ 268 candidate->addr.sin_family = AF_INET; 269 candidate->addr.sin_port = x_port; 270 + candidate->addr.sin_addr.s_addr = pkt->nh.iph->saddr; 271 candidate->in_epoch = x_epoch; 272 candidate->out_epoch = x_epoch; 273 candidate->in_clientflag = RXRPC_CLIENT_INITIATED; ··· 675 struct rxrpc_message *msg) 676 { 677 struct rxrpc_message *pmsg; 678 + struct dst_entry *dst; 679 struct list_head *_p; 680 unsigned cix, seq; 681 int ret = 0; ··· 710 711 call->pkt_rcv_count++; 712 713 + dst = msg->pkt->dst; 714 + if (dst && dst->dev) 715 conn->peer->if_mtu = 716 + dst->dev->mtu - dst->dev->hard_header_len; 717 718 /* queue on the call in seq order */ 719 rxrpc_get_message(msg);