I backed off from trying to just eliminate this variable, since
transforming atomic_inc_return() into atomic_inc() takes away
the memory barriers.
Signed-off-by: David S. Miller <davem@davemloft.net>
/* we can now add the new candidate to the list */
peer = candidate;
candidate = NULL;
+ usage = atomic_read(&peer->usage);
list_add_tail(&peer->link, &rxrpc_peers);
write_unlock_bh(&rxrpc_peer_lock);
&peer->srx.transport.sin.sin_addr,
ntohs(peer->srx.transport.sin.sin_port));
- _leave(" = %p {u=%d}", peer, atomic_read(&peer->usage));
+ _leave(" = %p {u=%d}", peer, usage);
return peer;
/* we found the peer in the list immediately */