All of lore.kernel.org
 help / color / mirror / Atom feed
* [mkl-can-next:mcp25xxfd 55/57] drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c:7:0: warning: "DEBUG" redefined
@ 2019-10-10 16:36 kbuild test robot
  0 siblings, 0 replies; only message in thread
From: kbuild test robot @ 2019-10-10 16:36 UTC (permalink / raw)
  To: kbuild-all

[-- Attachment #1: Type: text/plain, Size: 11249 bytes --]

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/mkl/linux-can-next.git mcp25xxfd
head:   fc940214e54b37f338dc9e308cd6501b96fcdb0a
commit: 08fa78503af70452b6501631cf86c7b2c1d4de91 [55/57] can: mcp25xxfd: remap: add debugging
config: x86_64-allyesconfig (attached as .config)
compiler: gcc-7 (Debian 7.4.0-13) 7.4.0
reproduce:
        git checkout 08fa78503af70452b6501631cf86c7b2c1d4de91
        # save the attached .config to linux build tree
        make ARCH=x86_64 

If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp@intel.com>

All warnings (new ones prefixed by >>):

>> drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c:7:0: warning: "DEBUG" redefined
    #define DEBUG
    
   <command-line>:0:0: note: this is the location of the previous definition
   In file included from include/linux/printk.h:332:0,
                    from include/linux/kernel.h:15,
                    from include/linux/list.h:9,
                    from include/linux/module.h:9,
                    from drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c:9:
   drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c: In function 'mcp25xxfd_regmap_gather_write':
>> drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c:34:3: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
      (u32)reg, *(u8 *)reg, *(u8 *)(reg+1), *(u8 *)(reg+2), *(u8 *)(reg+3), reg_len,
      ^
   include/linux/dynamic_debug.h:125:15: note: in definition of macro '__dynamic_func_call'
      func(&id, ##__VA_ARGS__);  \
                  ^~~~~~~~~~~
   include/linux/dynamic_debug.h:157:2: note: in expansion of macro '_dynamic_func_call'
     _dynamic_func_call(fmt,__dynamic_dev_dbg,   \
     ^~~~~~~~~~~~~~~~~~
   include/linux/device.h:1509:2: note: in expansion of macro 'dynamic_dev_dbg'
     dynamic_dev_dbg(dev, dev_fmt(fmt), ##__VA_ARGS__)
     ^~~~~~~~~~~~~~~
>> drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c:33:2: note: in expansion of macro 'dev_dbg'
     dev_dbg(&priv->spi->dev, "%s: reg(0x%08x)=%02x %02x %02x %02x, reg_len=%d, val_len=%d val=0x%08x\n", __func__,
     ^~~~~~~
   drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c:35:12: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
      val_len, (u32)val);
               ^
   include/linux/dynamic_debug.h:125:15: note: in definition of macro '__dynamic_func_call'
      func(&id, ##__VA_ARGS__);  \
                  ^~~~~~~~~~~
   include/linux/dynamic_debug.h:157:2: note: in expansion of macro '_dynamic_func_call'
     _dynamic_func_call(fmt,__dynamic_dev_dbg,   \
     ^~~~~~~~~~~~~~~~~~
   include/linux/device.h:1509:2: note: in expansion of macro 'dynamic_dev_dbg'
     dynamic_dev_dbg(dev, dev_fmt(fmt), ##__VA_ARGS__)
     ^~~~~~~~~~~~~~~
>> drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c:33:2: note: in expansion of macro 'dev_dbg'
     dev_dbg(&priv->spi->dev, "%s: reg(0x%08x)=%02x %02x %02x %02x, reg_len=%d, val_len=%d val=0x%08x\n", __func__,
     ^~~~~~~
>> drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c:33:27: warning: format '%d' expects argument of type 'int', but argument 10 has type 'size_t {aka long unsigned int}' [-Wformat=]
     dev_dbg(&priv->spi->dev, "%s: reg(0x%08x)=%02x %02x %02x %02x, reg_len=%d, val_len=%d val=0x%08x\n", __func__,
                              ^
   include/linux/dynamic_debug.h:125:15: note: in definition of macro '__dynamic_func_call'
      func(&id, ##__VA_ARGS__);  \
                  ^~~~~~~~~~~
   include/linux/dynamic_debug.h:157:2: note: in expansion of macro '_dynamic_func_call'
     _dynamic_func_call(fmt,__dynamic_dev_dbg,   \
     ^~~~~~~~~~~~~~~~~~
   include/linux/device.h:1509:2: note: in expansion of macro 'dynamic_dev_dbg'
     dynamic_dev_dbg(dev, dev_fmt(fmt), ##__VA_ARGS__)
     ^~~~~~~~~~~~~~~
   include/linux/device.h:1509:23: note: in expansion of macro 'dev_fmt'
     dynamic_dev_dbg(dev, dev_fmt(fmt), ##__VA_ARGS__)
                          ^~~~~~~
>> drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c:33:2: note: in expansion of macro 'dev_dbg'
     dev_dbg(&priv->spi->dev, "%s: reg(0x%08x)=%02x %02x %02x %02x, reg_len=%d, val_len=%d val=0x%08x\n", __func__,
     ^~~~~~~
   drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c:33:27: warning: format '%d' expects argument of type 'int', but argument 11 has type 'size_t {aka long unsigned int}' [-Wformat=]
     dev_dbg(&priv->spi->dev, "%s: reg(0x%08x)=%02x %02x %02x %02x, reg_len=%d, val_len=%d val=0x%08x\n", __func__,
                              ^
   include/linux/dynamic_debug.h:125:15: note: in definition of macro '__dynamic_func_call'
      func(&id, ##__VA_ARGS__);  \
                  ^~~~~~~~~~~
   include/linux/dynamic_debug.h:157:2: note: in expansion of macro '_dynamic_func_call'
     _dynamic_func_call(fmt,__dynamic_dev_dbg,   \
     ^~~~~~~~~~~~~~~~~~
   include/linux/device.h:1509:2: note: in expansion of macro 'dynamic_dev_dbg'
     dynamic_dev_dbg(dev, dev_fmt(fmt), ##__VA_ARGS__)
     ^~~~~~~~~~~~~~~
   include/linux/device.h:1509:23: note: in expansion of macro 'dev_fmt'
     dynamic_dev_dbg(dev, dev_fmt(fmt), ##__VA_ARGS__)
                          ^~~~~~~
>> drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c:33:2: note: in expansion of macro 'dev_dbg'
     dev_dbg(&priv->spi->dev, "%s: reg(0x%08x)=%02x %02x %02x %02x, reg_len=%d, val_len=%d val=0x%08x\n", __func__,
     ^~~~~~~
   drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c: In function 'mcp25xxfd_regmap_read':
   drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c:70:3: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
      (u32)reg, *(u8 *)reg, *(u8 *)(reg+1), *(u8 *)(reg+2), *(u8 *)(reg+3), reg_len,
      ^
   include/linux/dynamic_debug.h:125:15: note: in definition of macro '__dynamic_func_call'
      func(&id, ##__VA_ARGS__);  \
                  ^~~~~~~~~~~
   include/linux/dynamic_debug.h:157:2: note: in expansion of macro '_dynamic_func_call'
     _dynamic_func_call(fmt,__dynamic_dev_dbg,   \
     ^~~~~~~~~~~~~~~~~~
   include/linux/device.h:1509:2: note: in expansion of macro 'dynamic_dev_dbg'
     dynamic_dev_dbg(dev, dev_fmt(fmt), ##__VA_ARGS__)
     ^~~~~~~~~~~~~~~
   drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c:69:2: note: in expansion of macro 'dev_dbg'
     dev_dbg(&priv->spi->dev, "%s: reg(0x%08x)=%02x %02x %02x %02x, reg_len=%d, val_len=%d val=0x%08x\n", __func__,
     ^~~~~~~
   drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c:71:12: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
      val_len, (u32)val_buf);
               ^
   include/linux/dynamic_debug.h:125:15: note: in definition of macro '__dynamic_func_call'
      func(&id, ##__VA_ARGS__);  \
                  ^~~~~~~~~~~
   include/linux/dynamic_debug.h:157:2: note: in expansion of macro '_dynamic_func_call'
     _dynamic_func_call(fmt,__dynamic_dev_dbg,   \
     ^~~~~~~~~~~~~~~~~~
   include/linux/device.h:1509:2: note: in expansion of macro 'dynamic_dev_dbg'
     dynamic_dev_dbg(dev, dev_fmt(fmt), ##__VA_ARGS__)
     ^~~~~~~~~~~~~~~
   drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c:69:2: note: in expansion of macro 'dev_dbg'
     dev_dbg(&priv->spi->dev, "%s: reg(0x%08x)=%02x %02x %02x %02x, reg_len=%d, val_len=%d val=0x%08x\n", __func__,
     ^~~~~~~
   drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c:69:27: warning: format '%d' expects argument of type 'int', but argument 10 has type 'size_t {aka long unsigned int}' [-Wformat=]
     dev_dbg(&priv->spi->dev, "%s: reg(0x%08x)=%02x %02x %02x %02x, reg_len=%d, val_len=%d val=0x%08x\n", __func__,
                              ^
   include/linux/dynamic_debug.h:125:15: note: in definition of macro '__dynamic_func_call'
      func(&id, ##__VA_ARGS__);  \
                  ^~~~~~~~~~~
   include/linux/dynamic_debug.h:157:2: note: in expansion of macro '_dynamic_func_call'
     _dynamic_func_call(fmt,__dynamic_dev_dbg,   \
     ^~~~~~~~~~~~~~~~~~
   include/linux/device.h:1509:2: note: in expansion of macro 'dynamic_dev_dbg'
     dynamic_dev_dbg(dev, dev_fmt(fmt), ##__VA_ARGS__)
     ^~~~~~~~~~~~~~~
   include/linux/device.h:1509:23: note: in expansion of macro 'dev_fmt'
     dynamic_dev_dbg(dev, dev_fmt(fmt), ##__VA_ARGS__)
                          ^~~~~~~
   drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c:69:2: note: in expansion of macro 'dev_dbg'
     dev_dbg(&priv->spi->dev, "%s: reg(0x%08x)=%02x %02x %02x %02x, reg_len=%d, val_len=%d val=0x%08x\n", __func__,
     ^~~~~~~
   drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c:69:27: warning: format '%d' expects argument of type 'int', but argument 11 has type 'size_t {aka long unsigned int}' [-Wformat=]
     dev_dbg(&priv->spi->dev, "%s: reg(0x%08x)=%02x %02x %02x %02x, reg_len=%d, val_len=%d val=0x%08x\n", __func__,
                              ^
   include/linux/dynamic_debug.h:125:15: note: in definition of macro '__dynamic_func_call'
      func(&id, ##__VA_ARGS__);  \
                  ^~~~~~~~~~~
   include/linux/dynamic_debug.h:157:2: note: in expansion of macro '_dynamic_func_call'
     _dynamic_func_call(fmt,__dynamic_dev_dbg,   \
     ^~~~~~~~~~~~~~~~~~
   include/linux/device.h:1509:2: note: in expansion of macro 'dynamic_dev_dbg'
     dynamic_dev_dbg(dev, dev_fmt(fmt), ##__VA_ARGS__)
     ^~~~~~~~~~~~~~~
   include/linux/device.h:1509:23: note: in expansion of macro 'dev_fmt'
     dynamic_dev_dbg(dev, dev_fmt(fmt), ##__VA_ARGS__)
                          ^~~~~~~
   drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c:69:2: note: in expansion of macro 'dev_dbg'
     dev_dbg(&priv->spi->dev, "%s: reg(0x%08x)=%02x %02x %02x %02x, reg_len=%d, val_len=%d val=0x%08x\n", __func__,
     ^~~~~~~

vim +/DEBUG +7 drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c

   > 7	#define DEBUG
     8	
   > 9	#include <linux/module.h>
    10	#include <linux/spi/spi.h>
    11	
    12	#include <mcp25xxfd_cmd.h>
    13	#include <mcp25xxfd_priv.h>
    14	
    15	static int mcp25xxfd_regmap_gather_write(void *context,
    16						 const void *reg, size_t reg_len,
    17						 const void *val, size_t val_len)
    18	{
    19		struct mcp25xxfd_priv *priv = context;
    20		struct spi_message m;
    21		struct spi_transfer t[] = {
    22			{
    23				.tx_buf = reg,
    24				.len = sizeof(__be16),
    25				.speed_hz = priv->spi_use_speed_hz,
    26			}, {
    27				.tx_buf = val,
    28				.len = val_len,
    29				.speed_hz = priv->spi_use_speed_hz,
    30			},
    31		};
    32	
  > 33		dev_dbg(&priv->spi->dev, "%s: reg(0x%08x)=%02x %02x %02x %02x, reg_len=%d, val_len=%d val=0x%08x\n", __func__,
  > 34			(u32)reg, *(u8 *)reg, *(u8 *)(reg+1), *(u8 *)(reg+2), *(u8 *)(reg+3), reg_len,
    35			val_len, (u32)val);
    36	
    37		spi_message_init(&m);
    38		spi_message_add_tail(&t[0], &m);
    39		spi_message_add_tail(&t[1], &m);
    40	
    41		return spi_sync(priv->spi, &m);
    42	}
    43	

---
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: 69529 bytes --]

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2019-10-10 16:36 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-10-10 16:36 [mkl-can-next:mcp25xxfd 55/57] drivers/net/can/spi/mcp25xxfd/mcp25xxfd_regmap.c:7:0: warning: "DEBUG" redefined kbuild test robot

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.