crypto: iaa - Remove unnecessary debugfs_create_dir() error check in iaa_crypto_debugfs_init()
Subsystems (2)
PATCH 1/1 crypto: iaa - Remove unnecessary debugfs_create_dir() error check in iaa_crypto_debugfs_init()
This patch removes the debugfs_create_dir() error checking in iaa_crypto_debugfs_init(). Because the debugfs_create_dir() is developed in a way that the caller can safely handle the errors that occur during the creation of DebugFS nodes.
--- drivers/crypto/intel/iaa/iaa_crypto_stats.c | 2 -- 1 file changed, 2 deletions(-)
drivers/crypto/intel/iaa/iaa_crypto_stats.c +0 -2
@@ -275,8 +275,6 @@ int __init iaa_crypto_debugfs_init(void)return -ENODEV ; iaa_crypto_debugfs_root =debugfs_create_dir ("iaa_crypto" ,NULL ); -if (!iaa_crypto_debugfs_root) -return -ENOMEM ;debugfs_create_u64 ("max_comp_delay_ns" ,0644 , iaa_crypto_debugfs_root, &max_comp_delay_ns);
Signature · 1 line
2.39.0
Quoted 7 lines · Minjie Du
This patch removes the
debugfs_create_dir()error checking iniaa_crypto_debugfs_init(). Because thedebugfs_create_dir()is developed
in a way that the caller can safely handle the errors that occur during the creation of DebugFS nodes.Signed-off-by Minjie Du <[email protected]>
Thanks Minjie,
Tom
Quoted 20 lines
---
drivers/crypto/intel/iaa/iaa_crypto_stats.c | 2 --1 file changed, 2 deletions(-)drivers/crypto/intel/iaa/iaa_crypto_stats.c +0
-0@@ -275,8 +275,6 @@ int __init iaa_crypto_debugfs_init(void) return -ENODEV;
iaa_crypto_debugfs_root =debugfs_create_dir("iaa_crypto", NULL);
- if (!iaa_crypto_debugfs_root)
- return-ENOMEM;
debugfs_create_u64("max_comp_delay_ns", 0644,iaa_crypto_debugfs_root,&max_comp_delay_ns);
Herbert Xu
maintainerQuoted 9 lines · Minjie Du
This patch removes the
debugfs_create_dir()error checking iniaa_crypto_debugfs_init(). Because thedebugfs_create_dir()is developed in a way that the caller can safely handle the errors that occur during the creation of DebugFS nodes.Signed-off-by Minjie Du <[email protected]>--- drivers/crypto/intel/iaa/iaa_crypto_stats.c | 2 -- 1 file changed, 2 deletions(-)
Patch applied. Thanks.
Signature · 3 lines
Email: Herbert Xu <[email protected]> Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt