From: Tang Bin <tangbin@cmss.chinamobile.com>
To: minyard@acm.org
Cc: arnd@arndb.de, gregkh@linuxfoundation.org,
openipmi-developer@lists.sourceforge.net,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3]ipmi:bt-bmc:Avoid unnecessary judgement
Date: Mon, 13 Apr 2020 23:44:49 +0800 [thread overview]
Message-ID: <3894dab2-0660-999c-6f4c-4b5b9ff57773@cmss.chinamobile.com> (raw)
In-Reply-To: <20200413142348.GD3587@minyard.net>
Hi Corey:
On 2020/4/13 22:23, Corey Minyard wrote:
>> Can I consider that the patch will be applied in 5.8?
> It's in my queue, so that's the plan.
>
>>> I
>>> changed the title to be "Avoid unnecessary check".
>> You have modified it, which means I don't need to submit a new patch?
> Correct.
Thank you very much, I am waiting for the applied.
Then, I have some questions to ask you:
I have checked the file bt-bmc.c carefully, and found that there
are another two problems.Please help me analyze them, if you think it is
feasible, then I will submit the patch.
Q1: About Format Problem
In the 469~471 line, the first letter should be indented,
please check if the writing here is reasonable?
Q2: About the function bt_bmc_config_irq()
1)In the function bt_bmc_probe(), the return value of
bt_bmc_config_irq() made no judgement, whether it is suitable? (If your
view is don't need to judge, the following will change.)
2)According to the kernel interface of platform_get_irq(),the
return value is negative,
if (!bt_bmc->irq)
return -ENODEV;
so the check here is invalid.The standard way to write is:
if (bt_bmc->irq < 0)
return bt_bmc->irq;
But consider if failed, "bt_bmc->irq" must be assigned
to "0",the easiest way is to delete the 403~404 line, handled
directly by the function devm_request_irq().
Q3:About dev_warm()
KERN_WARNING is higher than KERN_INFO, the same to
dev_warn() and dev_info(). When the function bt_bmc_probe() uses
dev_info() to print error message, the dev_warm() in the line of 409
should be redundant.
I am waiting for your replay, and thank you for your guidance.
Tang Bin
next prev parent reply other threads:[~2020-04-13 15:43 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-08 11:59 [PATCH v3]ipmi:bt-bmc:Avoid unnecessary judgement Tang Bin
2020-04-13 11:32 ` Corey Minyard
2020-04-13 11:56 ` Tang Bin
2020-04-13 14:23 ` Corey Minyard
2020-04-13 15:44 ` Tang Bin [this message]
2020-04-13 21:59 ` Corey Minyard
2020-04-14 9:42 ` Tang Bin
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=3894dab2-0660-999c-6f4c-4b5b9ff57773@cmss.chinamobile.com \
--to=tangbin@cmss.chinamobile.com \
--cc=arnd@arndb.de \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=minyard@acm.org \
--cc=openipmi-developer@lists.sourceforge.net \
/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;
as well as URLs for NNTP newsgroup(s).