* [usb:usb-linus 12/16] drivers/usb/host/xhci-ring.c:676:19: warning: format '%ld' expects argument of type 'long int', but argument 3 has type 'size_t {aka unsigned int}'
@ 2019-05-22 12:54 kbuild test robot
2019-05-22 13:08 ` Greg Kroah-Hartman
0 siblings, 1 reply; 2+ messages in thread
From: kbuild test robot @ 2019-05-22 12:54 UTC (permalink / raw)
To: Henry Lin; +Cc: kbuild-all, linux-usb, Greg Kroah-Hartman, Mathias Nyman
[-- Attachment #1: Type: text/plain, Size: 3504 bytes --]
tree: https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git usb-linus
head: f7fac17ca925faa03fc5eb854c081a24075f8bad
commit: 597c56e372dab2c7f79b8d700aad3a5deebf9d1b [12/16] xhci: update bounce buffer with correct sg num
config: i386-randconfig-x018-201920 (attached as .config)
compiler: gcc-7 (Debian 7.3.0-1) 7.3.0
reproduce:
git checkout 597c56e372dab2c7f79b8d700aad3a5deebf9d1b
# save the attached .config to linux build tree
make ARCH=i386
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp@intel.com>
All warnings (new ones prefixed by >>):
In file included from include/linux/dma-mapping.h:7:0,
from drivers/usb/host/xhci-ring.c:57:
drivers/usb/host/xhci-ring.c: In function 'xhci_unmap_td_bounce_buffer':
>> drivers/usb/host/xhci-ring.c:676:19: warning: format '%ld' expects argument of type 'long int', but argument 3 has type 'size_t {aka unsigned int}' [-Wformat=]
xhci_warn(xhci, "WARN Wrong bounce buffer read length: %ld != %d\n",
^
include/linux/device.h:1400:22: note: in definition of macro 'dev_fmt'
#define dev_fmt(fmt) fmt
^~~
>> drivers/usb/host/xhci.h:1920:2: note: in expansion of macro 'dev_warn'
dev_warn(xhci_to_hcd(xhci)->self.controller , fmt , ## args)
^~~~~~~~
>> drivers/usb/host/xhci-ring.c:676:3: note: in expansion of macro 'xhci_warn'
xhci_warn(xhci, "WARN Wrong bounce buffer read length: %ld != %d\n",
^~~~~~~~~
drivers/usb/host/xhci-ring.c: In function 'xhci_align_td':
drivers/usb/host/xhci-ring.c:3169:5: warning: format '%ld' expects argument of type 'long int', but argument 3 has type 'size_t {aka unsigned int}' [-Wformat=]
"WARN Wrong bounce buffer write length: %ld != %d\n",
^
include/linux/device.h:1400:22: note: in definition of macro 'dev_fmt'
#define dev_fmt(fmt) fmt
^~~
>> drivers/usb/host/xhci.h:1920:2: note: in expansion of macro 'dev_warn'
dev_warn(xhci_to_hcd(xhci)->self.controller , fmt , ## args)
^~~~~~~~
drivers/usb/host/xhci-ring.c:3168:4: note: in expansion of macro 'xhci_warn'
xhci_warn(xhci,
^~~~~~~~~
vim +676 drivers/usb/host/xhci-ring.c
652
653 static void xhci_unmap_td_bounce_buffer(struct xhci_hcd *xhci,
654 struct xhci_ring *ring, struct xhci_td *td)
655 {
656 struct device *dev = xhci_to_hcd(xhci)->self.controller;
657 struct xhci_segment *seg = td->bounce_seg;
658 struct urb *urb = td->urb;
659 size_t len;
660
661 if (!ring || !seg || !urb)
662 return;
663
664 if (usb_urb_dir_out(urb)) {
665 dma_unmap_single(dev, seg->bounce_dma, ring->bounce_buf_len,
666 DMA_TO_DEVICE);
667 return;
668 }
669
670 dma_unmap_single(dev, seg->bounce_dma, ring->bounce_buf_len,
671 DMA_FROM_DEVICE);
672 /* for in tranfers we need to copy the data from bounce to sg */
673 len = sg_pcopy_from_buffer(urb->sg, urb->num_sgs, seg->bounce_buf,
674 seg->bounce_len, seg->bounce_offs);
675 if (len != seg->bounce_len)
> 676 xhci_warn(xhci, "WARN Wrong bounce buffer read length: %ld != %d\n",
677 len, seg->bounce_len);
678 seg->bounce_len = 0;
679 seg->bounce_offs = 0;
680 }
681
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 37207 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [usb:usb-linus 12/16] drivers/usb/host/xhci-ring.c:676:19: warning: format '%ld' expects argument of type 'long int', but argument 3 has type 'size_t {aka unsigned int}'
2019-05-22 12:54 [usb:usb-linus 12/16] drivers/usb/host/xhci-ring.c:676:19: warning: format '%ld' expects argument of type 'long int', but argument 3 has type 'size_t {aka unsigned int}' kbuild test robot
@ 2019-05-22 13:08 ` Greg Kroah-Hartman
0 siblings, 0 replies; 2+ messages in thread
From: Greg Kroah-Hartman @ 2019-05-22 13:08 UTC (permalink / raw)
To: Henry Lin, kbuild-all, linux-usb, Mathias Nyman; +Cc: kbuild test robot
On Wed, May 22, 2019 at 08:54:56PM +0800, kbuild test robot wrote:
> tree: https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git usb-linus
> head: f7fac17ca925faa03fc5eb854c081a24075f8bad
> commit: 597c56e372dab2c7f79b8d700aad3a5deebf9d1b [12/16] xhci: update bounce buffer with correct sg num
> config: i386-randconfig-x018-201920 (attached as .config)
> compiler: gcc-7 (Debian 7.3.0-1) 7.3.0
> reproduce:
> git checkout 597c56e372dab2c7f79b8d700aad3a5deebf9d1b
> # save the attached .config to linux build tree
> make ARCH=i386
>
> If you fix the issue, kindly add following tag
> Reported-by: kbuild test robot <lkp@intel.com>
>
> All warnings (new ones prefixed by >>):
>
> In file included from include/linux/dma-mapping.h:7:0,
> from drivers/usb/host/xhci-ring.c:57:
> drivers/usb/host/xhci-ring.c: In function 'xhci_unmap_td_bounce_buffer':
> >> drivers/usb/host/xhci-ring.c:676:19: warning: format '%ld' expects argument of type 'long int', but argument 3 has type 'size_t {aka unsigned int}' [-Wformat=]
> xhci_warn(xhci, "WARN Wrong bounce buffer read length: %ld != %d\n",
> ^
> include/linux/device.h:1400:22: note: in definition of macro 'dev_fmt'
> #define dev_fmt(fmt) fmt
> ^~~
> >> drivers/usb/host/xhci.h:1920:2: note: in expansion of macro 'dev_warn'
> dev_warn(xhci_to_hcd(xhci)->self.controller , fmt , ## args)
> ^~~~~~~~
> >> drivers/usb/host/xhci-ring.c:676:3: note: in expansion of macro 'xhci_warn'
> xhci_warn(xhci, "WARN Wrong bounce buffer read length: %ld != %d\n",
> ^~~~~~~~~
> drivers/usb/host/xhci-ring.c: In function 'xhci_align_td':
> drivers/usb/host/xhci-ring.c:3169:5: warning: format '%ld' expects argument of type 'long int', but argument 3 has type 'size_t {aka unsigned int}' [-Wformat=]
> "WARN Wrong bounce buffer write length: %ld != %d\n",
> ^
> include/linux/device.h:1400:22: note: in definition of macro 'dev_fmt'
> #define dev_fmt(fmt) fmt
> ^~~
> >> drivers/usb/host/xhci.h:1920:2: note: in expansion of macro 'dev_warn'
> dev_warn(xhci_to_hcd(xhci)->self.controller , fmt , ## args)
> ^~~~~~~~
> drivers/usb/host/xhci-ring.c:3168:4: note: in expansion of macro 'xhci_warn'
> xhci_warn(xhci,
> ^~~~~~~~~
Can someone send me a follow-on patch to fix this up please?
thanks,
greg k-h
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2019-05-22 13:08 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-05-22 12:54 [usb:usb-linus 12/16] drivers/usb/host/xhci-ring.c:676:19: warning: format '%ld' expects argument of type 'long int', but argument 3 has type 'size_t {aka unsigned int}' kbuild test robot
2019-05-22 13:08 ` Greg Kroah-Hartman
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.