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:   Wed, 23 Nov 2022 12:54:07 +0200
From:   Adrian Hunter <adrian.hunter@...el.com>
To:     Ye Bin <yebin@...weicloud.com>, ulf.hansson@...aro.org,
        wsa+renesas@...g-engineering.com, kvalo@...nel.org,
        linux-mmc@...r.kernel.org
Cc:     linux-kernel@...r.kernel.org, yebin10@...wei.com
Subject: Re: [PATCH] mmc: mmc_test: fix missing assignment of 'file' when
 register debugfs file

On 23/11/22 11:55, Ye Bin wrote:
> From: Ye Bin <yebin10@...wei.com>
> 
> Now, 'file' is always NULL. obviously, 'file' is used to store return value of
> 'debugfs_create_file()'.

'file' is used to remove debugfs files when the mmc_test module is removed.

> 
> Fixes: a04c50aaa916 ("mmc: core: no need to check return value of debugfs_create functions")
> Signed-off-by: Ye Bin <yebin10@...wei.com>

Acked-by: Adrian Hunter <adrian.hunter@...el.com>

> ---
>  drivers/mmc/core/mmc_test.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/mmc/core/mmc_test.c b/drivers/mmc/core/mmc_test.c
> index 6cd6f8a94a71..156d34b2ed4d 100644
> --- a/drivers/mmc/core/mmc_test.c
> +++ b/drivers/mmc/core/mmc_test.c
> @@ -3174,7 +3174,8 @@ static int __mmc_test_register_dbgfs_file(struct mmc_card *card,
>  	struct mmc_test_dbgfs_file *df;
>  
>  	if (card->debugfs_root)
> -		debugfs_create_file(name, mode, card->debugfs_root, card, fops);
> +		file = debugfs_create_file(name, mode, card->debugfs_root,
> +					   card, fops);
>  
>  	df = kmalloc(sizeof(*df), GFP_KERNEL);
>  	if (!df) {

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ