lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 11 Mar 2021 08:46:25 +0100
From:   Frederic Barrat <fbarrat@...ux.ibm.com>
To:     Laurent Dufour <ldufour@...ux.ibm.com>, ajd@...ux.ibm.com,
        arnd@...db.de, gregkh@...uxfoundation.org
Cc:     linuxppc-dev@...ts.ozlabs.org, linux-kernel@...r.kernel.org,
        clombard@...ux.ibm.com
Subject: Re: [PATCH] cxl: don't manipulate the mm.mm_users field directly



On 10/03/2021 18:44, Laurent Dufour wrote:
> It is better to rely on the API provided by the MM layer instead of
> directly manipulating the mm_users field.
> 
> Signed-off-by: Laurent Dufour <ldufour@...ux.ibm.com>
> ---


Thanks!
Acked-by: Frederic Barrat <fbarrat@...ux.ibm.com>



>   drivers/misc/cxl/fault.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/misc/cxl/fault.c b/drivers/misc/cxl/fault.c
> index 01153b74334a..60c829113299 100644
> --- a/drivers/misc/cxl/fault.c
> +++ b/drivers/misc/cxl/fault.c
> @@ -200,7 +200,7 @@ static struct mm_struct *get_mem_context(struct cxl_context *ctx)
>   	if (ctx->mm == NULL)
>   		return NULL;
>   
> -	if (!atomic_inc_not_zero(&ctx->mm->mm_users))
> +	if (!mmget_not_zero(ctx->mm))
>   		return NULL;
>   
>   	return ctx->mm;
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ