Skip to content

Commit

Permalink
mptcp: add ro_after_init for tcp{,v6}_prot_override
Browse files Browse the repository at this point in the history
Add __ro_after_init labels for the variables tcp_prot_override and
tcpv6_prot_override, just like other variables adjacent to them, to
indicate that they are initialised from the init hooks and no writes
occur afterwards.

Fixes: b19bc29 ("mptcp: implement delegated actions")
Fixes: 51fa7f8 ("mptcp: mark ops structures as ro_after_init")
Signed-off-by: Geliang Tang <geliang.tang@suse.com>
Reviewed-by: Matthieu Baerts <matthieu.baerts@tessares.net>
  • Loading branch information
geliangtang authored and jenkins-tessares committed Mar 2, 2023
1 parent 152014a commit 8deb661
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions net/mptcp/subflow.c
Original file line number Diff line number Diff line change
Expand Up @@ -628,7 +628,7 @@ static struct request_sock_ops mptcp_subflow_v6_request_sock_ops __ro_after_init
static struct tcp_request_sock_ops subflow_request_sock_ipv6_ops __ro_after_init;
static struct inet_connection_sock_af_ops subflow_v6_specific __ro_after_init;
static struct inet_connection_sock_af_ops subflow_v6m_specific __ro_after_init;
static struct proto tcpv6_prot_override;
static struct proto tcpv6_prot_override __ro_after_init;

static int subflow_v6_conn_request(struct sock *sk, struct sk_buff *skb)
{
Expand Down Expand Up @@ -926,7 +926,7 @@ static struct sock *subflow_syn_recv_sock(const struct sock *sk,
}

static struct inet_connection_sock_af_ops subflow_specific __ro_after_init;
static struct proto tcp_prot_override;
static struct proto tcp_prot_override __ro_after_init;

enum mapping_status {
MAPPING_OK,
Expand Down

0 comments on commit 8deb661

Please sign in to comment.