[PATCH] Fix variable type to be 'bool' instead of incorrect 'int'.

Casey Schaufler casey at schaufler-ca.com
Thu May 15 14:22:38 UTC 2025


On 5/15/2025 2:24 AM, Kalevi Kolttonen wrote:
> Signed-off-by: Kalevi Kolttonen <kalevi at kolttonen.fi>

This needs to be sent to the LSM list: linux-security-module at vger.kernel.org

There is a major rework of the LSM initialization process. You may want to
base future patches on that.

https://lore.kernel.org/linux-security-module/20250409185019.238841-31-paul@paul-moore.com/

> ---
>  security/security.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/security/security.c b/security/security.c
> index fb57e8fddd91..02336de43ba9 100644
> --- a/security/security.c
> +++ b/security/security.c
> @@ -288,7 +288,7 @@ static void __init lsm_set_blob_sizes(struct lsm_blob_sizes *needed)
>  /* Prepare LSM for initialization. */
>  static void __init prepare_lsm(struct lsm_info *lsm)
>  {
> -	int enabled = lsm_allowed(lsm);
> +	bool enabled = lsm_allowed(lsm);
>  
>  	/* Record enablement (to handle any following exclusive LSMs). */
>  	set_enabled(lsm, enabled);



More information about the Linux-security-module-archive mailing list