From: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
To: Thierry Reding <thierry.reding@gmail.com>
Cc: kbuild test robot <fengguang.wu@intel.com>,
Shawn Lin <shawn.lin@rock-chips.com>,
kbuild-all@01.org, linux-kernel@vger.kernel.org,
Bjorn Helgaas <helgaas@kernel.org>,
Jonathan Hunter <jonathanh@nvidia.com>,
linux-tegra@vger.kernel.org, linux-pci@vger.kernel.org
Subject: Re: [PATCH] PCI: fix ptr_ret.cocci warnings
Date: Tue, 18 Sep 2018 17:30:50 +0100 [thread overview]
Message-ID: <20180918163050.GC31440@e107981-ln.cambridge.arm.com> (raw)
In-Reply-To: <20180918144737.GA30386@ulmo>
On Tue, Sep 18, 2018 at 04:47:37PM +0200, Thierry Reding wrote:
> On Tue, Sep 18, 2018 at 03:18:38PM +0100, Lorenzo Pieralisi wrote:
> > On Thu, Jul 12, 2018 at 07:30:41AM +0800, kbuild test robot wrote:
> > > From: kbuild test robot <fengguang.wu@intel.com>
> > >
> > > drivers/pci/controller/pci-tegra.c:1132:1-3: WARNING: PTR_ERR_OR_ZERO can be used
> > >
> > >
> > > Use PTR_ERR_OR_ZERO rather than if(IS_ERR(...)) + PTR_ERR
> > >
> > > Generated by: scripts/coccinelle/api/ptr_ret.cocci
> > >
> > > Fixes: 6e0832fa432e ("PCI: Collect all native drivers under drivers/pci/controller/")
> > > CC: Shawn Lin <shawn.lin@rock-chips.com>
> > > Signed-off-by: kbuild test robot <fengguang.wu@intel.com>
> > > ---
> > >
> > > pci-tegra.c | 5 +----
> > > 1 file changed, 1 insertion(+), 4 deletions(-)
> >
> > Thierry,
> >
> > are you OK with this change ? I will remove the Fixes: tag since
> > this does not fix anything AFAICS.
>
> This has been proposed several times in the past and each time Bjorn and
> I have agreed that we'd rather not merge that change. I think the
> original is clearer and allows the code to be more easily extended.
>
> I don't know if there's a way to "whitelist" certain drivers or sub-
> systems where these kinds of changes are known not to be desired. Or
> perhaps there's some way to trick coccinelle into not recognizing this
> particular instance.
>
> Then again, it seems wrong to have to work around over-ambitious
> semantic patches...
I agree with you and Bjorn, I will drop the patches but you have a
point. Certainly these patches aren't fixing anything unless I am
missing something obvious.
Lorenzo
next prev parent reply other threads:[~2018-09-18 16:30 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-07-11 23:30 drivers/pci/controller/pci-tegra.c:1132:1-3: WARNING: PTR_ERR_OR_ZERO can be used kbuild test robot
2018-07-11 23:30 ` [PATCH] PCI: fix ptr_ret.cocci warnings kbuild test robot
2018-09-18 14:18 ` Lorenzo Pieralisi
2018-09-18 14:47 ` Thierry Reding
2018-09-18 16:30 ` Lorenzo Pieralisi [this message]
2018-07-19 23:42 drivers/pci/controller/dwc/pcie-kirin.c:141:1-3: WARNING: PTR_ERR_OR_ZERO can be used kbuild test robot
2018-07-19 23:42 ` [PATCH] PCI: fix ptr_ret.cocci warnings kbuild test robot
2018-09-18 14:21 ` Lorenzo Pieralisi
2018-09-19 0:40 ` Songxiaowei (Kirin_DRV)
2019-12-27 12:18 drivers/pci/controller/pci-tegra.c:1365:1-3: WARNING: PTR_ERR_OR_ZERO can be used kbuild test robot
2019-12-27 12:18 ` [PATCH] PCI: fix ptr_ret.cocci warnings kbuild test robot
2020-01-05 7:21 drivers/pci/controller/dwc/pci-exynos.c:95:1-3: WARNING: PTR_ERR_OR_ZERO can be used kbuild test robot
2020-01-05 7:21 ` [PATCH] PCI: fix ptr_ret.cocci warnings kbuild test robot
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=20180918163050.GC31440@e107981-ln.cambridge.arm.com \
--to=lorenzo.pieralisi@arm.com \
--cc=fengguang.wu@intel.com \
--cc=helgaas@kernel.org \
--cc=jonathanh@nvidia.com \
--cc=kbuild-all@01.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=linux-tegra@vger.kernel.org \
--cc=shawn.lin@rock-chips.com \
--cc=thierry.reding@gmail.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®