net/rxrpc/ar-internal.h
Source file repositories/reference/linux-study-clean/net/rxrpc/ar-internal.h
File Facts
- System
- Linux kernel
- Corpus path
net/rxrpc/ar-internal.h- Extension
.h- Size
- 61977 bytes
- Lines
- 1725
- Domain
- Networking Core
- Bucket
- Sockets, Protocols, Packet Path, And Network Policy
- Inferred role
- Networking Core: implementation source
- Status
- source implementation candidate
Why This File Exists
Networking stack implementation surface: socket APIs, protocol dispatch, packet flow, routing, filtering, and network namespaces.
- Networking stack implementation surface: socket APIs, protocol dispatch, packet flow, routing, filtering, and network namespaces.
- Uses kernel synchronization; read lock ordering, sleepability, and interrupt context assumptions before translating.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/atomic.hlinux/seqlock.hlinux/win_minmax.hnet/net_namespace.hnet/netns/generic.hnet/sock.hnet/af_rxrpc.hkeys/rxrpc-type.hprotocol.htrace/events/rxrpc.h
Detected Declarations
struct fcrypt_keystruct rxrpc_cryptstruct des_ctxstruct key_preparsed_payloadstruct rxrpc_connectionstruct rxrpc_txbufstruct rxrpc_txqueuestruct rxgk_contextstruct rxrpc_netstruct rxrpc_backlogstruct rxrpc_sockstruct rxrpc_host_headerstruct rxrpc_skb_privstruct rxrpc_securitystruct rxrpc_localstruct rxrpc_peerstruct rxrpc_conn_protostruct rxrpc_conn_parametersstruct rxrpc_bundlestruct rxrpc_connectionstruct rxrpc_channelstruct rxrpc_callstruct rxrpc_ack_summarystruct rxrpc_call_paramsstruct rxrpc_send_paramsstruct rxrpc_txbufstruct rxrpc_txqueuestruct rxrpc_send_data_reqenum rxrpc_skb_markenum rxrpc_call_completionenum rxrpc_conn_flagenum rxrpc_conn_eventenum rxrpc_conn_proto_stateenum rxrpc_call_flagenum rxrpc_call_eventenum rxrpc_call_stateenum rxrpc_ca_stateenum rxrpc_rack_timer_modeenum rxrpc_commandfunction rxrpc_to_serverfunction rxrpc_to_clientfunction rxrpc_sending_to_serverfunction rxrpc_sending_to_clientfunction rxrpc_get_next_serialfunction rxrpc_get_next_serialsfunction rxrpc_is_service_callfunction rxrpc_is_client_callfunction rxrpc_set_call_state
Annotated Snippet
struct fcrypt_key {
__be32 sched[FCRYPT_ROUNDS];
};
#define FCRYPT_BSIZE 8
struct rxrpc_crypt {
union {
u8 x[FCRYPT_BSIZE];
__be32 n[2];
};
} __attribute__((aligned(8)));
void fcrypt_preparekey(struct fcrypt_key *key, const u8 raw_key[FCRYPT_BSIZE]);
void fcrypt_pcbc_encrypt(const struct fcrypt_key *key,
const u8 iv[FCRYPT_BSIZE], const void *src, void *dst,
size_t nblocks);
void fcrypt_pcbc_decrypt(const struct fcrypt_key *key,
const u8 iv[FCRYPT_BSIZE], const void *src, void *dst,
size_t nblocks);
#if IS_ENABLED(CONFIG_KUNIT)
struct des_ctx;
void des_pcbc_decrypt_inplace(const struct des_ctx *key, __le64 iv, u8 *data,
size_t len);
#endif
#define rxrpc_queue_work(WS) queue_work(rxrpc_workqueue, (WS))
#define rxrpc_queue_delayed_work(WS,D) \
queue_delayed_work(rxrpc_workqueue, (WS), (D))
struct key_preparsed_payload;
struct rxrpc_connection;
struct rxrpc_txbuf;
struct rxrpc_txqueue;
struct rxgk_context;
/*
* Mark applied to socket buffers in skb->mark. skb->priority is used
* to pass supplementary information.
*/
enum rxrpc_skb_mark {
RXRPC_SKB_MARK_PACKET, /* Received packet */
RXRPC_SKB_MARK_ERROR, /* Error notification */
RXRPC_SKB_MARK_CHALLENGE, /* Challenge notification */
RXRPC_SKB_MARK_SERVICE_CONN_SECURED, /* Service connection response has been verified */
RXRPC_SKB_MARK_REJECT_BUSY, /* Reject with BUSY */
RXRPC_SKB_MARK_REJECT_ABORT, /* Reject with ABORT (code in skb->priority) */
RXRPC_SKB_MARK_REJECT_CONN_ABORT, /* Reject with connection ABORT (code in skb->priority) */
};
/*
* sk_state for RxRPC sockets
*/
enum {
RXRPC_UNBOUND = 0,
RXRPC_CLIENT_UNBOUND, /* Unbound socket used as client */
RXRPC_CLIENT_BOUND, /* client local address bound */
RXRPC_SERVER_BOUND, /* server local address bound */
RXRPC_SERVER_BOUND2, /* second server local address bound */
RXRPC_SERVER_LISTENING, /* server listening for connections */
RXRPC_SERVER_LISTEN_DISABLED, /* server listening disabled */
RXRPC_CLOSE, /* socket is being closed */
};
/*
* Per-network namespace data.
*/
struct rxrpc_net {
struct proc_dir_entry *proc_net; /* Subdir in /proc/net */
u32 epoch; /* Local epoch for detecting local-end reset */
struct list_head calls; /* List of calls active in this namespace */
spinlock_t call_lock; /* Lock for ->calls */
atomic_t nr_calls; /* Count of allocated calls */
atomic_t nr_conns;
struct list_head bundle_proc_list; /* List of bundles for proc */
struct list_head conn_proc_list; /* List of conns in this namespace for proc */
struct list_head service_conns; /* Service conns in this namespace */
rwlock_t conn_lock; /* Lock for ->conn_proc_list, ->service_conns */
struct work_struct service_conn_reaper;
struct timer_list service_conn_reap_timer;
bool live;
atomic_t nr_client_conns;
struct hlist_head local_endpoints;
struct mutex local_mutex; /* Lock for ->local_endpoints */
DECLARE_HASHTABLE (peer_hash, 10);
spinlock_t peer_hash_lock; /* Lock for ->peer_hash */
Annotation
- Immediate include surface: `linux/atomic.h`, `linux/seqlock.h`, `linux/win_minmax.h`, `net/net_namespace.h`, `net/netns/generic.h`, `net/sock.h`, `net/af_rxrpc.h`, `keys/rxrpc-type.h`.
- Detected declarations: `struct fcrypt_key`, `struct rxrpc_crypt`, `struct des_ctx`, `struct key_preparsed_payload`, `struct rxrpc_connection`, `struct rxrpc_txbuf`, `struct rxrpc_txqueue`, `struct rxgk_context`, `struct rxrpc_net`, `struct rxrpc_backlog`.
- Atlas domain: Networking Core / Sockets, Protocols, Packet Path, And Network Policy.
- Implementation status: source implementation candidate.
- Synchronization appears in or near this file; preserve lock ordering, sleepability, and interrupt-context constraints.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.