From: Kylene Jo Hall The socket_post_create LSM hook has gone from a void return to an int. This patch properly updates the SLIM hook definition and return to reflect this change. Signed-off-by: Mimi Zohar Signed-of-by: Kylene Hall Signed-off-by: Andrew Morton --- security/slim/slm_main.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletion(-) diff -puN security/slim/slm_main.c~slim-main-patch-socket_post_create-hook-return-code security/slim/slm_main.c --- a/security/slim/slm_main.c~slim-main-patch-socket_post_create-hook-return-code +++ a/security/slim/slm_main.c @@ -970,7 +970,7 @@ int slm_socket_create(int family, int ty /* * Didn't have the family type previously, so update the inode security now. */ -static void slm_socket_post_create(struct socket *sock, int family, +static int slm_socket_post_create(struct socket *sock, int family, int type, int protocol, int kern) { struct slm_tsec_data *cur_tsec = current->security; @@ -986,6 +986,7 @@ static void slm_socket_post_create(struc } else set_level_untrusted(&slm_isec->level); spin_unlock(&slm_isec->lock); + return 0; } /* _