[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <201801212010.4rD9vlNa%fengguang.wu@intel.com>
Date: Sun, 21 Jan 2018 21:17:27 +0800
From: kbuild test robot <lkp@...el.com>
To: John Garry <john.garry@...wei.com>
Cc: kbuild-all@...org, mika.westerberg@...ux.intel.com,
rafael@...nel.org, lorenzo.pieralisi@....com, rjw@...ysocki.net,
robh+dt@...nel.org, bhelgaas@...gle.com, arnd@...db.de,
mark.rutland@....com, olof@...om.net, hanjun.guo@...aro.org,
dann.frazier@...onical.com, benh@...nel.crashing.org,
linux-kernel@...r.kernel.org, linux-acpi@...r.kernel.org,
linuxarm@...wei.com, linux-pci@...r.kernel.org, minyard@....org,
devicetree@...r.kernel.org, linux-arch@...r.kernel.org,
Zhichang Yuan <yuanzhichang@...ilicon.com>,
Gabriele Paoloni <gabriele.paoloni@...wei.com>,
John Garry <john.garry@...wei.com>
Subject: Re: [PATCH v11 1/9] LIB: Introduce a generic PIO mapping method
Hi Zhichang,
Thank you for the patch! Perhaps something to improve:
[auto build test WARNING on linus/master]
[also build test WARNING on v4.15-rc8 next-20180119]
[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/John-Garry/LPC-legacy-ISA-I-O-support/20180121-194832
config: i386-defconfig (attached as .config)
compiler: gcc-7 (Debian 7.2.0-12) 7.2.1 20171025
reproduce:
# save the attached .config to linux build tree
make ARCH=i386
All warnings (new ones prefixed by >>):
In file included from include/linux/printk.h:7:0,
from include/linux/kernel.h:14,
from include/linux/list.h:9,
from include/linux/kobject.h:20,
from include/linux/of.h:21,
from lib/logic_pio.c:19:
lib/logic_pio.c: In function 'logic_pio_trans_hwaddr':
include/linux/kern_levels.h:5:18: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 2 has type 'resource_size_t {aka unsigned int}' [-Wformat=]
#define KERN_SOH "\001" /* ASCII Start Of Header */
^
include/linux/kern_levels.h:11:18: note: in expansion of macro 'KERN_SOH'
#define KERN_ERR KERN_SOH "3" /* error conditions */
^~~~~~~~
include/linux/printk.h:301:9: note: in expansion of macro 'KERN_ERR'
printk(KERN_ERR pr_fmt(fmt), ##__VA_ARGS__)
^~~~~~~~
>> lib/logic_pio.c:175:3: note: in expansion of macro 'pr_err'
pr_err("resource size 0x%llx cannot fit in IO range size 0x%llx\n",
^~~~~~
lib/logic_pio.c:175:30: note: format string is defined here
pr_err("resource size 0x%llx cannot fit in IO range size 0x%llx\n",
~~~^
%x
In file included from include/linux/printk.h:7:0,
from include/linux/kernel.h:14,
from include/linux/list.h:9,
from include/linux/kobject.h:20,
from include/linux/of.h:21,
from lib/logic_pio.c:19:
include/linux/kern_levels.h:5:18: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 3 has type 'resource_size_t {aka unsigned int}' [-Wformat=]
#define KERN_SOH "\001" /* ASCII Start Of Header */
^
include/linux/kern_levels.h:11:18: note: in expansion of macro 'KERN_SOH'
#define KERN_ERR KERN_SOH "3" /* error conditions */
^~~~~~~~
include/linux/printk.h:301:9: note: in expansion of macro 'KERN_ERR'
printk(KERN_ERR pr_fmt(fmt), ##__VA_ARGS__)
^~~~~~~~
>> lib/logic_pio.c:175:3: note: in expansion of macro 'pr_err'
pr_err("resource size 0x%llx cannot fit in IO range size 0x%llx\n",
^~~~~~
lib/logic_pio.c:175:65: note: format string is defined here
pr_err("resource size 0x%llx cannot fit in IO range size 0x%llx\n",
~~~^
%x
vim +/pr_err +175 lib/logic_pio.c
157
158 /*
159 * This function is generic for translating a hardware address to logical PIO.
160 * @hw_addr: the hardware address of host, can be CPU address or host-local
161 * address;
162 */
163 unsigned long
164 logic_pio_trans_hwaddr(struct fwnode_handle *fwnode, resource_size_t addr,
165 resource_size_t size)
166 {
167 struct logic_pio_hwaddr *range;
168
169 range = find_io_range_by_fwnode(fwnode);
170 if (!range || range->flags == PIO_CPU_MMIO) {
171 pr_err("range not found or invalid\n");
172 return -1;
173 }
174 if (range->size < size) {
> 175 pr_err("resource size 0x%llx cannot fit in IO range size 0x%llx\n",
176 size, range->size);
177 return -1;
178 }
179 return addr - range->hw_start + range->io_start;
180 }
181
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
Download attachment ".config.gz" of type "application/gzip" (26739 bytes)
Powered by blists - more mailing lists