[RFC PATCH 4/5] audit: convert audit_ever_enabled to a boolean

Richard Guy Briggs rgb at redhat.com
Sun Sep 3 03:41:19 UTC 2017


On 2017-09-01 09:44, Paul Moore wrote:
> From: Paul Moore <paul at paul-moore.com>
> 
> We were treating it as a boolean, let's make it a boolean to help
> avoid future mistakes.
> 
> Signed-off-by: Paul Moore <paul at paul-moore.com>

Reviewed-by: Richard Guy Briggs <rgb at redhat.com>

> ---
>  kernel/audit.c |    2 +-
>  kernel/audit.h |    2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/kernel/audit.c b/kernel/audit.c
> index 9df2ef4d3e53..01bf1e479a8c 100644
> --- a/kernel/audit.c
> +++ b/kernel/audit.c
> @@ -86,7 +86,7 @@ static int	audit_initialized;
>  #define AUDIT_ON	1
>  #define AUDIT_LOCKED	2
>  u32		audit_enabled = AUDIT_OFF;
> -u32		audit_ever_enabled = !!AUDIT_OFF;
> +bool		audit_ever_enabled = !!AUDIT_OFF;
>  
>  EXPORT_SYMBOL_GPL(audit_enabled);
>  
> diff --git a/kernel/audit.h b/kernel/audit.h
> index b331d9b83f63..6bdaf6bd377e 100644
> --- a/kernel/audit.h
> +++ b/kernel/audit.h
> @@ -208,7 +208,7 @@ struct audit_context {
>  	struct audit_proctitle proctitle;
>  };
>  
> -extern u32 audit_ever_enabled;
> +extern bool audit_ever_enabled;
>  
>  extern void audit_copy_inode(struct audit_names *name,
>  			     const struct dentry *dentry,
> 
> --
> Linux-audit mailing list
> Linux-audit at redhat.com
> https://www.redhat.com/mailman/listinfo/linux-audit

- RGB

--
Richard Guy Briggs <rgb at redhat.com>
Sr. S/W Engineer, Kernel Security, Base Operating Systems
Remote, Ottawa, Red Hat Canada
IRC: rgb, SunRaycer
Voice: +1.647.777.2635, Internal: (81) 32635




More information about the Linux-audit mailing list