From: Adrian Hunter <adrian.hunter@intel.com>
To: Ye Bin <yebin@huaweicloud.com>,
ulf.hansson@linaro.org, wsa+renesas@sang-engineering.com,
kvalo@kernel.org, linux-mmc@vger.kernel.org
Cc: linux-kernel@vger.kernel.org, yebin10@huawei.com
Subject: Re: [PATCH] mmc: mmc_test: fix missing assignment of 'file' when register debugfs file
Date: Wed, 23 Nov 2022 12:54:07 +0200 [thread overview]
Message-ID: <5bf820c6-8b07-cf0c-438b-a411815c202c@intel.com> (raw)
In-Reply-To: <20221123095506.1965691-1-yebin@huaweicloud.com>
On 23/11/22 11:55, Ye Bin wrote:
> From: Ye Bin <yebin10@huawei.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@huawei.com>
Acked-by: Adrian Hunter <adrian.hunter@intel.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) {
next prev parent reply other threads:[~2022-11-23 11:00 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-23 9:55 Ye Bin
2022-11-23 10:54 ` Adrian Hunter [this message]
2022-11-29 12:54 ` Ulf Hansson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5bf820c6-8b07-cf0c-438b-a411815c202c@intel.com \
--to=adrian.hunter@intel.com \
--cc=kvalo@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mmc@vger.kernel.org \
--cc=ulf.hansson@linaro.org \
--cc=wsa+renesas@sang-engineering.com \
--cc=yebin10@huawei.com \
--cc=yebin@huaweicloud.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®