* Re: [PATCH V7 4/7] LPC: Support the device-tree LPC host on Hip06/Hip07 (fwd)
@ 2017-03-14 5:37 Julia Lawall
2017-03-14 7:07 ` zhichang.yuan
0 siblings, 1 reply; 2+ messages in thread
From: Julia Lawall @ 2017-03-14 5:37 UTC (permalink / raw)
To: zhichang.yuan
Cc: catalin.marinas, will.deacon, robh+dt, frowand.list, bhelgaas,
rafael, mark.rutland, rjw, arnd, linux-arm-kernel, linux-acpi,
lorenzo.pieralisi, benh, linux-kernel, linuxarm, devicetree,
linux-pci, linux-serial, minyard, liviu.dudau, zourongrong,
john.garry, gabriele.paoloni, zhichang.yuan02, kantyzc, xuwei5,
zhichang.yuan, kbuild-all
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.
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
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH V7 4/7] LPC: Support the device-tree LPC host on Hip06/Hip07 (fwd)
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
0 siblings, 0 replies; 2+ messages in thread
From: zhichang.yuan @ 2017-03-14 7:07 UTC (permalink / raw)
To: Julia Lawall
Cc: catalin.marinas, will.deacon, robh+dt, frowand.list, bhelgaas,
rafael, mark.rutland, rjw, arnd, linux-arm-kernel, linux-acpi,
lorenzo.pieralisi, benh, linux-kernel, linuxarm, devicetree,
linux-pci, linux-serial, minyard, liviu.dudau, zourongrong,
john.garry, gabriele.paoloni, zhichang.yuan02, kantyzc, xuwei5,
kbuild-all
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
>
> .
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2017-03-14 7:08 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
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 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).