From: Paul Moore Date: Tue, 6 Oct 2015 19:03:53 +0000 (-0400) Subject: af_unix: constify the sock parameter in unix_sk() X-Git-Tag: firefly_0821_release~176^2~903^2~33 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=c72eda0608a30ca6aa8722d4afdbd2557b3c9345;p=firefly-linux-kernel-4.4.55.git af_unix: constify the sock parameter in unix_sk() Make unix_sk() just like inet[6]_sk() by constify'ing the sock parameter. Signed-off-by: Paul Moore Signed-off-by: David S. Miller --- diff --git a/include/net/af_unix.h b/include/net/af_unix.h index cb1b9bbda332..b36d837c701e 100644 --- a/include/net/af_unix.h +++ b/include/net/af_unix.h @@ -64,7 +64,7 @@ struct unix_sock { struct socket_wq peer_wq; }; -static inline struct unix_sock *unix_sk(struct sock *sk) +static inline struct unix_sock *unix_sk(const struct sock *sk) { return (struct unix_sock *)sk; }