On 08/01/17 08:18 PM, Tom Herbert wrote: > > -static int tls_init(struct sock *sk) > +static int tls_init(struct sock *sk, char __user *optval, int len) > { > - struct inet_connection_sock *icsk = inet_csk(sk); > struct tls_context *ctx; > int rc = 0; > > @@ -450,7 +449,7 @@ static int tls_init(struct sock *sk) > rc = -ENOMEM; > goto out; > } > - icsk->icsk_ulp_data = ctx; > + sk->sk_ulp_data = ctx; > ctx->setsockopt = sk->sk_prot->setsockopt; > ctx->getsockopt = sk->sk_prot->getsockopt; > sk->sk_prot = &tls_base_prot; > @@ -458,7 +457,7 @@ static int tls_init(struct sock *sk) > return rc; > }
It looks like tls_init should be checking if this is a tcp socket now also, and failing if not