From: kernel test robot <lkp@intel.com>
To: Otavio Salvador <otavio@ossystems.com.br>
Cc: oe-kbuild-all@lists.linux.dev
Subject: [freescale-fslc:pr/637 3481/12466] drivers/staging/ethosu/ethosu_buffer.c:253:18: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 8 has type 'phys_addr_t' {aka 'unsigned int'}
Date: Wed, 19 Jul 2023 19:15:54 +0800 [thread overview]
Message-ID: <202307191949.1eESStGd-lkp@intel.com> (raw)
tree: https://github.com/Freescale/linux-fslc pr/637
head: ec33c7fc43bef23fa0b69db996fee0ba601875e9
commit: 95ce4103b59b6af5d3c264fc137f9dd174e78d3e [3481/12466] npu: ethosu: Add Arm ethos-u driver
config: i386-allyesconfig (https://download.01.org/0day-ci/archive/20230719/202307191949.1eESStGd-lkp@intel.com/config)
compiler: gcc-12 (Debian 12.2.0-14) 12.2.0
reproduce: (https://download.01.org/0day-ci/archive/20230719/202307191949.1eESStGd-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202307191949.1eESStGd-lkp@intel.com/
All warnings (new ones prefixed by >>):
| ~~~^
| |
| long long unsigned int
| %x
drivers/staging/ethosu/ethosu_buffer.c:108:30: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 5 has type 'dma_addr_t' {aka 'unsigned int'} [-Wformat=]
108 | dev_dbg(dev, "daddr=0x%llx, paddr=0x%llx, size=0x%llx\n",
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/dynamic_debug.h:223:29: note: in definition of macro '__dynamic_func_call_cls'
223 | func(&id, ##__VA_ARGS__); \
| ^~~~~~~~~~~
include/linux/dynamic_debug.h:249:9: note: in expansion of macro '_dynamic_func_call_cls'
249 | _dynamic_func_call_cls(_DPRINTK_CLASS_DFLT, fmt, func, ##__VA_ARGS__)
| ^~~~~~~~~~~~~~~~~~~~~~
include/linux/dynamic_debug.h:272:9: note: in expansion of macro '_dynamic_func_call'
272 | _dynamic_func_call(fmt, __dynamic_dev_dbg, \
| ^~~~~~~~~~~~~~~~~~
include/linux/dev_printk.h:155:9: note: in expansion of macro 'dynamic_dev_dbg'
155 | dynamic_dev_dbg(dev, dev_fmt(fmt), ##__VA_ARGS__)
| ^~~~~~~~~~~~~~~
include/linux/dev_printk.h:155:30: note: in expansion of macro 'dev_fmt'
155 | dynamic_dev_dbg(dev, dev_fmt(fmt), ##__VA_ARGS__)
| ^~~~~~~
drivers/staging/ethosu/ethosu_buffer.c:108:17: note: in expansion of macro 'dev_dbg'
108 | dev_dbg(dev, "daddr=0x%llx, paddr=0x%llx, size=0x%llx\n",
| ^~~~~~~
drivers/staging/ethosu/ethosu_buffer.c:108:56: note: format string is defined here
108 | dev_dbg(dev, "daddr=0x%llx, paddr=0x%llx, size=0x%llx\n",
| ~~~^
| |
| long long unsigned int
| %x
drivers/staging/ethosu/ethosu_buffer.c:108:30: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 6 has type 'dma_addr_t' {aka 'unsigned int'} [-Wformat=]
108 | dev_dbg(dev, "daddr=0x%llx, paddr=0x%llx, size=0x%llx\n",
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/dynamic_debug.h:223:29: note: in definition of macro '__dynamic_func_call_cls'
223 | func(&id, ##__VA_ARGS__); \
| ^~~~~~~~~~~
include/linux/dynamic_debug.h:249:9: note: in expansion of macro '_dynamic_func_call_cls'
249 | _dynamic_func_call_cls(_DPRINTK_CLASS_DFLT, fmt, func, ##__VA_ARGS__)
| ^~~~~~~~~~~~~~~~~~~~~~
include/linux/dynamic_debug.h:272:9: note: in expansion of macro '_dynamic_func_call'
272 | _dynamic_func_call(fmt, __dynamic_dev_dbg, \
| ^~~~~~~~~~~~~~~~~~
include/linux/dev_printk.h:155:9: note: in expansion of macro 'dynamic_dev_dbg'
155 | dynamic_dev_dbg(dev, dev_fmt(fmt), ##__VA_ARGS__)
| ^~~~~~~~~~~~~~~
include/linux/dev_printk.h:155:30: note: in expansion of macro 'dev_fmt'
155 | dynamic_dev_dbg(dev, dev_fmt(fmt), ##__VA_ARGS__)
| ^~~~~~~
drivers/staging/ethosu/ethosu_buffer.c:108:17: note: in expansion of macro 'dev_dbg'
108 | dev_dbg(dev, "daddr=0x%llx, paddr=0x%llx, size=0x%llx\n",
| ^~~~~~~
drivers/staging/ethosu/ethosu_buffer.c:108:69: note: format string is defined here
108 | dev_dbg(dev, "daddr=0x%llx, paddr=0x%llx, size=0x%llx\n",
| ~~~^
| |
| long long unsigned int
| %x
In file included from include/linux/device.h:15,
from include/linux/mailbox_client.h:11,
from drivers/staging/ethosu/ethosu_mailbox.h:30,
from drivers/staging/ethosu/ethosu_device.h:29,
from drivers/staging/ethosu/ethosu_buffer.c:27:
drivers/staging/ethosu/ethosu_buffer.c: In function 'ethosu_buffer_create':
drivers/staging/ethosu/ethosu_buffer.c:253:18: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 6 has type 'dma_addr_t' {aka 'unsigned int'} [-Wformat=]
253 | "Buffer create. handle=0x%pK, capacity=%zu, cpu_addr=0x%pK, dma_addr=0x%llx, dma_addr_orig=0x%llx, phys_addr=0x%llx\n",
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/dev_printk.h:110:30: note: in definition of macro 'dev_printk_index_wrap'
110 | _p_func(dev, fmt, ##__VA_ARGS__); \
| ^~~
include/linux/dev_printk.h:150:58: note: in expansion of macro 'dev_fmt'
150 | dev_printk_index_wrap(_dev_info, KERN_INFO, dev, dev_fmt(fmt), ##__VA_ARGS__)
| ^~~~~~~
drivers/staging/ethosu/ethosu_buffer.c:252:9: note: in expansion of macro 'dev_info'
252 | dev_info(buf->edev->dev,
| ^~~~~~~~
drivers/staging/ethosu/ethosu_buffer.c:253:92: note: format string is defined here
253 | "Buffer create. handle=0x%pK, capacity=%zu, cpu_addr=0x%pK, dma_addr=0x%llx, dma_addr_orig=0x%llx, phys_addr=0x%llx\n",
| ~~~^
| |
| long long unsigned int
| %x
drivers/staging/ethosu/ethosu_buffer.c:253:18: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 7 has type 'dma_addr_t' {aka 'unsigned int'} [-Wformat=]
253 | "Buffer create. handle=0x%pK, capacity=%zu, cpu_addr=0x%pK, dma_addr=0x%llx, dma_addr_orig=0x%llx, phys_addr=0x%llx\n",
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/dev_printk.h:110:30: note: in definition of macro 'dev_printk_index_wrap'
110 | _p_func(dev, fmt, ##__VA_ARGS__); \
| ^~~
include/linux/dev_printk.h:150:58: note: in expansion of macro 'dev_fmt'
150 | dev_printk_index_wrap(_dev_info, KERN_INFO, dev, dev_fmt(fmt), ##__VA_ARGS__)
| ^~~~~~~
drivers/staging/ethosu/ethosu_buffer.c:252:9: note: in expansion of macro 'dev_info'
252 | dev_info(buf->edev->dev,
| ^~~~~~~~
drivers/staging/ethosu/ethosu_buffer.c:253:114: note: format string is defined here
253 | "Buffer create. handle=0x%pK, capacity=%zu, cpu_addr=0x%pK, dma_addr=0x%llx, dma_addr_orig=0x%llx, phys_addr=0x%llx\n",
| ~~~^
| |
| long long unsigned int
| %x
>> drivers/staging/ethosu/ethosu_buffer.c:253:18: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 8 has type 'phys_addr_t' {aka 'unsigned int'} [-Wformat=]
253 | "Buffer create. handle=0x%pK, capacity=%zu, cpu_addr=0x%pK, dma_addr=0x%llx, dma_addr_orig=0x%llx, phys_addr=0x%llx\n",
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/dev_printk.h:110:30: note: in definition of macro 'dev_printk_index_wrap'
110 | _p_func(dev, fmt, ##__VA_ARGS__); \
| ^~~
include/linux/dev_printk.h:150:58: note: in expansion of macro 'dev_fmt'
150 | dev_printk_index_wrap(_dev_info, KERN_INFO, dev, dev_fmt(fmt), ##__VA_ARGS__)
| ^~~~~~~
drivers/staging/ethosu/ethosu_buffer.c:252:9: note: in expansion of macro 'dev_info'
252 | dev_info(buf->edev->dev,
| ^~~~~~~~
drivers/staging/ethosu/ethosu_buffer.c:253:132: note: format string is defined here
253 | "Buffer create. handle=0x%pK, capacity=%zu, cpu_addr=0x%pK, dma_addr=0x%llx, dma_addr_orig=0x%llx, phys_addr=0x%llx\n",
| ~~~^
| |
| long long unsigned int
| %x
vim +253 drivers/staging/ethosu/ethosu_buffer.c
218
219 int ethosu_buffer_create(struct ethosu_device *edev,
220 size_t capacity)
221 {
222 struct ethosu_buffer *buf;
223 int ret = -ENOMEM;
224
225 buf = devm_kzalloc(edev->dev, sizeof(*buf), GFP_KERNEL);
226 if (!buf)
227 return -ENOMEM;
228
229 buf->edev = edev;
230 buf->capacity = capacity;
231 buf->offset = 0;
232 buf->size = 0;
233 kref_init(&buf->kref);
234
235 buf->cpu_addr = dma_alloc_coherent(buf->edev->dev, capacity,
236 &buf->dma_addr_orig, GFP_KERNEL);
237 if (!buf->cpu_addr)
238 goto free_buf;
239
240 buf->dma_addr = ethosu_buffer_dma_ranges(buf->edev->dev,
241 buf->dma_addr_orig,
242 buf->capacity);
243
244 ret = anon_inode_getfd("ethosu-buffer", ðosu_buffer_fops, buf,
245 O_RDWR | O_CLOEXEC);
246 if (ret < 0)
247 goto free_dma;
248
249 buf->file = fget(ret);
250 fput(buf->file);
251
252 dev_info(buf->edev->dev,
> 253 "Buffer create. handle=0x%pK, capacity=%zu, cpu_addr=0x%pK, dma_addr=0x%llx, dma_addr_orig=0x%llx, phys_addr=0x%llx\n",
254 buf, capacity, buf->cpu_addr, buf->dma_addr,
255 buf->dma_addr_orig, virt_to_phys(buf->cpu_addr));
256
257 return ret;
258
259 free_dma:
260 dma_free_coherent(buf->edev->dev, buf->capacity, buf->cpu_addr,
261 buf->dma_addr_orig);
262
263 free_buf:
264 devm_kfree(buf->edev->dev, buf);
265
266 return ret;
267 }
268
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
reply other threads:[~2023-07-19 11:16 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=202307191949.1eESStGd-lkp@intel.com \
--to=lkp@intel.com \
--cc=oe-kbuild-all@lists.linux.dev \
--cc=otavio@ossystems.com.br \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.