From: "zhichang.yuan" <yuanzhichang@hisilicon.com>
To: Julia Lawall <julia.lawall@lip6.fr>
Cc: catalin.marinas@arm.com, will.deacon@arm.com, robh+dt@kernel.org,
frowand.list@gmail.com, bhelgaas@google.com, rafael@kernel.org,
mark.rutland@arm.com, rjw@rjwysocki.net, arnd@arndb.de,
linux-arm-kernel@lists.infradead.org, linux-acpi@vger.kernel.org,
lorenzo.pieralisi@arm.com, benh@kernel.crashing.org,
linux-kernel@vger.kernel.org, linuxarm@huawei.com,
devicetree@vger.kernel.org, linux-pci@vger.kernel.org,
linux-serial@vger.kernel.org, minyard@acm.org,
liviu.dudau@arm.com, zourongrong@gmail.com,
john.garry@huawei.com, gabriele.paoloni@huawei.com,
zhichang.yuan02@gmail.com, kantyzc@163.com, xuwei5@hisilicon.com,
kbuild-all@01.org
Subject: Re: [PATCH V7 4/7] LPC: Support the device-tree LPC host on Hip06/Hip07 (fwd)
Date: Tue, 14 Mar 2017 15:07:35 +0800 [thread overview]
Message-ID: <58C796B7.9060505@hisilicon.com> (raw)
In-Reply-To: <alpine.DEB.2.20.1703140635090.3516@hadrien>
Hi, Julia,
On 2017/3/14 13:37, Julia Lawall wrote:
> Line 460 looks suspicious. Can tmprange be different than range but not
> be an ERR_PTR? If so, lpcdev->io_host will have an invalid value.
>
Thanks for your pointing out!
You are right!
miss a line of 'return 0;'
if (tmprange != range) {
kfree(range);
if (IS_ERR(tmprange))
return -EFAULT;
return 0;
}
Thanks again!
Zhichang
> julia
>
> ---------- Forwarded message ----------
> Date: Tue, 14 Mar 2017 13:12:05 +0800
> From: kbuild test robot <fengguang.wu@intel.com>
> To: kbuild@01.org
> Cc: Julia Lawall <julia.lawall@lip6.fr>
> Subject: Re: [PATCH V7 4/7] LPC: Support the device-tree LPC host on Hip06/Hip07
>
> Hi zhichang.yuan,
>
> [auto build test WARNING on linus/master]
> [also build test WARNING on v4.11-rc2 next-20170310]
> [if your patch is applied to the wrong git tree, please drop us a note to help improve the system]
>
> url: https://github.com/0day-ci/linux/commits/zhichang-yuan/LPC-legacy-ISA-I-O-support/20170314-114635
> :::::: branch date: 85 minutes ago
> :::::: commit date: 85 minutes ago
>
>>> drivers/bus/hisi_lpc.c:465:19-24: ERROR: reference preceded by free on line 460
>
> git remote add linux-review https://github.com/0day-ci/linux
> git remote update linux-review
> git checkout 4e05ad6c3274fa75c903c7809ef0b51329a31ab2
> vim +465 drivers/bus/hisi_lpc.c
>
> 4e05ad6c zhichang.yuan 2017-03-13 454 range->flags = IO_HOST_INDIRECT;
> 4e05ad6c zhichang.yuan 2017-03-13 455 range->size = LPC_BUS_IO_SIZE;
> 4e05ad6c zhichang.yuan 2017-03-13 456 range->hw_start = LPC_MIN_BUS_RANGE;
> 4e05ad6c zhichang.yuan 2017-03-13 457
> 4e05ad6c zhichang.yuan 2017-03-13 458 tmprange = register_libio_range(range);
> 4e05ad6c zhichang.yuan 2017-03-13 459 if (tmprange != range) {
> 4e05ad6c zhichang.yuan 2017-03-13 @460 kfree(range);
> 4e05ad6c zhichang.yuan 2017-03-13 461 if (IS_ERR(tmprange))
> 4e05ad6c zhichang.yuan 2017-03-13 462 return -EFAULT;
> 4e05ad6c zhichang.yuan 2017-03-13 463 }
> 4e05ad6c zhichang.yuan 2017-03-13 464
> 4e05ad6c zhichang.yuan 2017-03-13 @465 lpcdev->io_host = range;
> 4e05ad6c zhichang.yuan 2017-03-13 466
> 4e05ad6c zhichang.yuan 2017-03-13 467 return 0;
> 4e05ad6c zhichang.yuan 2017-03-13 468 }
>
> ---
> 0-DAY kernel test infrastructure Open Source Technology Center
> https://lists.01.org/pipermail/kbuild-all Intel Corporation
>
> .
>
prev parent reply other threads:[~2017-03-14 7:08 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-14 5:37 [PATCH V7 4/7] LPC: Support the device-tree LPC host on Hip06/Hip07 (fwd) Julia Lawall
2017-03-14 7:07 ` zhichang.yuan [this message]
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=58C796B7.9060505@hisilicon.com \
--to=yuanzhichang@hisilicon.com \
--cc=arnd@arndb.de \
--cc=benh@kernel.crashing.org \
--cc=bhelgaas@google.com \
--cc=catalin.marinas@arm.com \
--cc=devicetree@vger.kernel.org \
--cc=frowand.list@gmail.com \
--cc=gabriele.paoloni@huawei.com \
--cc=john.garry@huawei.com \
--cc=julia.lawall@lip6.fr \
--cc=kantyzc@163.com \
--cc=kbuild-all@01.org \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=linux-serial@vger.kernel.org \
--cc=linuxarm@huawei.com \
--cc=liviu.dudau@arm.com \
--cc=lorenzo.pieralisi@arm.com \
--cc=mark.rutland@arm.com \
--cc=minyard@acm.org \
--cc=rafael@kernel.org \
--cc=rjw@rjwysocki.net \
--cc=robh+dt@kernel.org \
--cc=will.deacon@arm.com \
--cc=xuwei5@hisilicon.com \
--cc=zhichang.yuan02@gmail.com \
--cc=zourongrong@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