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:   Fri, 18 Jun 2021 10:40:28 +0000
From:   刘海龙(DuckBuBee) <liuhailong@...o.com>
To:     Greg KH <gregkh@...uxfoundation.org>
CC:     "arve@...roid.com" <arve@...roid.com>,
        "tkjos@...roid.com" <tkjos@...roid.com>,
        "maco@...roid.com" <maco@...roid.com>,
        "joel@...lfernandes.org" <joel@...lfernandes.org>,
        "christian@...uner.io" <christian@...uner.io>,
        "hridya@...gle.com" <hridya@...gle.com>,
        "surenb@...gle.com" <surenb@...gle.com>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "linux-staging@...ts.linux.dev" <linux-staging@...ts.linux.dev>
Subject: 回复: [PATCH] staging: android: ashmem: add size field in procfs fdinfo

Hi 
No user tools use this proc file as I know, I added this line can help user locate shmem leak issue.

tks

-----邮件原件-----
发件人: Greg KH <gregkh@...uxfoundation.org> 
发送时间: 2021年6月18日 18:23
收件人: 刘海龙(DuckBuBee) <liuhailong@...o.com>
抄送: arve@...roid.com; tkjos@...roid.com; maco@...roid.com; joel@...lfernandes.org; christian@...uner.io; hridya@...gle.com; surenb@...gle.com; linux-kernel@...r.kernel.org; linux-staging@...ts.linux.dev
主题: Re: [PATCH] staging: android: ashmem: add size field in procfs fdinfo

On Fri, Jun 18, 2021 at 05:50:35PM +0800, liuhailong wrote:
> add this information to help user to find ashmem problem.
> 
> ashmem leak scenario:
> -000|fd = ashmem_create_region
> -001|mmap and pagefault
> -002|munmap
> -003|forget close(fd) <---- which lead to ashmem leak
> 
> Signed-off-by: liuhailong <liuhailong@...o.com>
> ---
>  drivers/staging/android/ashmem.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/drivers/staging/android/ashmem.c 
> b/drivers/staging/android/ashmem.c
> index d66a64e42273..ee2fd75111d8 100644
> --- a/drivers/staging/android/ashmem.c
> +++ b/drivers/staging/android/ashmem.c
> @@ -894,6 +894,8 @@ static void ashmem_show_fdinfo(struct seq_file *m, struct file *file)
>  		seq_printf(m, "name:\t%s\n",
>  			   asma->name + ASHMEM_NAME_PREFIX_LEN);
>  
> +	seq_printf(m, "size:\t%zu\n", asma->size);
> +
>  	mutex_unlock(&ashmem_mutex);
>  }
>  #endif
> --
> 2.30.2
> 
> 

As you are changing a user-facing proc file, what tools will break now that you have added a new line?

What tools do you use to look at this file and what has been modified to handle the change?

thanks,

greg k-h

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ