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]
Message-ID: <YGCcQnFHXEMW9Jz/@kroah.com>
Date:   Sun, 28 Mar 2021 17:09:54 +0200
From:   Greg KH <gregkh@...uxfoundation.org>
To:     Hui Tang <tanghui20@...wei.com>
Cc:     herbert@...dor.apana.org.au, davem@...emloft.net,
        linux-crypto@...r.kernel.org, xuzaibo@...wei.com,
        wangzhou1@...ilicon.com, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] crypto: hisilicon - check if debugfs opened

On Sat, Mar 27, 2021 at 04:33:00PM +0800, Hui Tang wrote:
> 'xx_debugfs_init' check if debugfs opened.
> 
> Signed-off-by: Hui Tang <tanghui20@...wei.com>
> ---
>  drivers/crypto/hisilicon/hpre/hpre_main.c | 5 ++++-
>  drivers/crypto/hisilicon/qm.c             | 3 +++
>  drivers/crypto/hisilicon/sec2/sec_main.c  | 5 ++++-
>  drivers/crypto/hisilicon/zip/zip_main.c   | 3 +++
>  4 files changed, 14 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/crypto/hisilicon/hpre/hpre_main.c b/drivers/crypto/hisilicon/hpre/hpre_main.c
> index c7ab06d..f2605c4 100644
> --- a/drivers/crypto/hisilicon/hpre/hpre_main.c
> +++ b/drivers/crypto/hisilicon/hpre/hpre_main.c
> @@ -779,6 +779,9 @@ static int hpre_debugfs_init(struct hisi_qm *qm)
>  	struct device *dev = &qm->pdev->dev;
>  	int ret;
>  
> +	if (!debugfs_initialized())
> +		return -ENOENT;

Why?  What does this help with?  Why does the code care if debugfs is
running or not?

thanks,

greg k-h

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ