Skip to content

Commit b794dc1

Browse files
dhowellskuba-moo
authored andcommitted
rxrpc: Allow the app to store private data on peer structs
Provide a way for the application (e.g. the afs filesystem) to store private data on the rxrpc_peer structs for later retrieval via the call object. This will allow afs to store a pointer to the afs_server object on the rxrpc_peer struct, thereby obviating the need for afs to keep lookup tables by which it can associate an incoming call with server that transmitted it. Signed-off-by: David Howells <[email protected]> cc: Marc Dionne <[email protected]> cc: Simon Horman <[email protected]> cc: [email protected] Link: https://patch.msgid.link/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
1 parent 7a7513a commit b794dc1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

net/rxrpc/oob.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -272,7 +272,7 @@ enum rxrpc_oob_type rxrpc_kernel_query_oob(struct sk_buff *oob,
272272
switch (type) {
273273
case RXRPC_OOB_CHALLENGE:
274274
*_peer = sp->chall.conn->peer;
275-
*_peer_appdata = 0; /* TODO: retrieve appdata */
275+
*_peer_appdata = sp->chall.conn->peer->app_data;
276276
break;
277277
default:
278278
WARN_ON_ONCE(1);
@@ -347,7 +347,7 @@ void rxrpc_kernel_query_challenge(struct sk_buff *challenge,
347347
struct rxrpc_skb_priv *sp = rxrpc_skb(challenge);
348348

349349
*_peer = sp->chall.conn->peer;
350-
*_peer_appdata = 0; /* TODO: retrieve appdata */
350+
*_peer_appdata = sp->chall.conn->peer->app_data;
351351
*_service_id = sp->hdr.serviceId;
352352
*_security_index = sp->hdr.securityIndex;
353353
}

0 commit comments

Comments
 (0)