[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZNRRFny6lQmRYd+F@Laptop-X1>
Date: Thu, 10 Aug 2023 10:53:10 +0800
From: Hangbin Liu <liuhangbin@...il.com>
To: Zhengchao Shao <shaozhengchao@...wei.com>
Cc: netdev@...r.kernel.org, davem@...emloft.net, edumazet@...gle.com,
kuba@...nel.org, pabeni@...hat.com, j.vosburgh@...il.com,
andy@...yhouse.net, weiyongjun1@...wei.com, yuehaibing@...wei.com
Subject: Re: [PATCH net-next 2/5] bonding: remove warning printing in
bond_create_debugfs
On Wed, Aug 09, 2023 at 08:41:04PM +0800, Zhengchao Shao wrote:
> Because debugfs_create_dir returns ERR_PTR, so warning printing will never
> be invoked in bond_create_debugfs, remove it. If failed to create
> directory, failure information will be printed in debugfs_create_dir.
>
> Signed-off-by: Zhengchao Shao <shaozhengchao@...wei.com>
> ---
> drivers/net/bonding/bond_debugfs.c | 3 ---
> 1 file changed, 3 deletions(-)
>
> diff --git a/drivers/net/bonding/bond_debugfs.c b/drivers/net/bonding/bond_debugfs.c
> index 94c2f35e3bfc..e4e7f4ee48e0 100644
> --- a/drivers/net/bonding/bond_debugfs.c
> +++ b/drivers/net/bonding/bond_debugfs.c
> @@ -87,9 +87,6 @@ void bond_debug_reregister(struct bonding *bond)
> void __init bond_create_debugfs(void)
> {
> bonding_debug_root = debugfs_create_dir("bonding", NULL);
> -
> - if (!bonding_debug_root)
debugfs_create_dir() does not print information for all failures. We can use
IS_ERR(bonding_debug_root) to check the value here.
Thanks
Hangbin
> - pr_warn("Warning: Cannot create bonding directory in debugfs\n");
> }
>
> void bond_destroy_debugfs(void)
> --
> 2.34.1
>
Powered by blists - more mailing lists