All of lore.kernel.org
 help / color / mirror / Atom feed
* [dlemoal-libata:ata-msg 34/61] drivers/ata/sata_fsl.c:316:17: error: passing argument 2 of '_dev_printk' from incompatible pointer type
@ 2021-12-08 12:16 ` kernel test robot
  0 siblings, 0 replies; 2+ messages in thread
From: kernel test robot @ 2021-12-08 12:16 UTC (permalink / raw)
  To: Hannes Reinecke; +Cc: kbuild-all, linux-kernel, Damien Le Moal

tree:   git://git.kernel.org/pub/scm/linux/kernel/git/dlemoal/libata.git ata-msg
head:   7d6ff0ace26c7e7f01d532d244de0b9811765f47
commit: efab2a8f108886fa8d2d0108941bb1ccb36f8526 [34/61] sata_fsl: move DPRINTK to ata debugging
config: powerpc-mpc837x_rdb_defconfig (https://download.01.org/0day-ci/archive/20211208/202112081937.KKQZRXYI-lkp@intel.com/config)
compiler: powerpc-linux-gcc (GCC) 11.2.0
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # https://git.kernel.org/pub/scm/linux/kernel/git/dlemoal/libata.git/commit/?id=efab2a8f108886fa8d2d0108941bb1ccb36f8526
        git remote add dlemoal-libata git://git.kernel.org/pub/scm/linux/kernel/git/dlemoal/libata.git
        git fetch --no-tags dlemoal-libata ata-msg
        git checkout efab2a8f108886fa8d2d0108941bb1ccb36f8526
        # save the config file to linux build tree
        mkdir build_dir
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=powerpc SHELL=/bin/bash

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

All errors (new ones prefixed by >>):

   In file included from include/linux/device.h:15,
                    from include/linux/platform_device.h:13,
                    from drivers/ata/sata_fsl.c:15:
   drivers/ata/sata_fsl.c: In function 'fsl_sata_set_irq_coalescing':
>> drivers/ata/sata_fsl.c:316:17: error: passing argument 2 of '_dev_printk' from incompatible pointer type [-Werror=incompatible-pointer-types]
     316 |         dev_dbg(&host->dev, "interrupt coalescing, count = 0x%x, ticks = %x\n",
         |                 ^~~~~~~~~~
         |                 |
         |                 struct device **
   include/linux/dev_printk.h:129:36: note: in definition of macro 'dev_printk'
     129 |                 _dev_printk(level, dev, fmt, ##__VA_ARGS__);            \
         |                                    ^~~
   drivers/ata/sata_fsl.c:316:9: note: in expansion of macro 'dev_dbg'
     316 |         dev_dbg(&host->dev, "interrupt coalescing, count = 0x%x, ticks = %x\n",
         |         ^~~~~~~
   include/linux/dev_printk.h:41:58: note: expected 'const struct device *' but argument is of type 'struct device **'
      41 | void _dev_printk(const char *level, const struct device *dev,
         |                                     ~~~~~~~~~~~~~~~~~~~~~^~~
   drivers/ata/sata_fsl.c:318:17: error: passing argument 2 of '_dev_printk' from incompatible pointer type [-Werror=incompatible-pointer-types]
     318 |         dev_dbg(&host->dev, "ICC register status: (hcr base: 0x%x) = 0x%x\n",
         |                 ^~~~~~~~~~
         |                 |
         |                 struct device **
   include/linux/dev_printk.h:129:36: note: in definition of macro 'dev_printk'
     129 |                 _dev_printk(level, dev, fmt, ##__VA_ARGS__);            \
         |                                    ^~~
   drivers/ata/sata_fsl.c:318:9: note: in expansion of macro 'dev_dbg'
     318 |         dev_dbg(&host->dev, "ICC register status: (hcr base: 0x%x) = 0x%x\n",
         |         ^~~~~~~
   include/linux/dev_printk.h:41:58: note: expected 'const struct device *' but argument is of type 'struct device **'
      41 | void _dev_printk(const char *level, const struct device *dev,
         |                                     ~~~~~~~~~~~~~~~~~~~~~^~~
   drivers/ata/sata_fsl.c:318:29: warning: format '%x' expects argument of type 'unsigned int', but argument 4 has type 'void *' [-Wformat=]
     318 |         dev_dbg(&host->dev, "ICC register status: (hcr base: 0x%x) = 0x%x\n",
         |                             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/dev_printk.h:129:41: note: in definition of macro 'dev_printk'
     129 |                 _dev_printk(level, dev, fmt, ##__VA_ARGS__);            \
         |                                         ^~~
   include/linux/dev_printk.h:163:45: note: in expansion of macro 'dev_fmt'
     163 |                 dev_printk(KERN_DEBUG, dev, dev_fmt(fmt), ##__VA_ARGS__); \
         |                                             ^~~~~~~
   drivers/ata/sata_fsl.c:318:9: note: in expansion of macro 'dev_dbg'
     318 |         dev_dbg(&host->dev, "ICC register status: (hcr base: 0x%x) = 0x%x\n",
         |         ^~~~~~~
   drivers/ata/sata_fsl.c:318:65: note: format string is defined here
     318 |         dev_dbg(&host->dev, "ICC register status: (hcr base: 0x%x) = 0x%x\n",
         |                                                                ~^
         |                                                                 |
         |                                                                 unsigned int
         |                                                                %p
   In file included from include/linux/device.h:15,
                    from include/linux/platform_device.h:13,
                    from drivers/ata/sata_fsl.c:15:
   drivers/ata/sata_fsl.c: In function 'sata_fsl_init_controller':
>> drivers/ata/sata_fsl.c:1361:22: error: 'ap' undeclared (first use in this function); did you mean 'up'?
    1361 |         ata_port_dbg(ap, "icc = 0x%x\n", ioread32(hcr_base + ICC));
         |                      ^~
   include/linux/dev_printk.h:129:36: note: in definition of macro 'dev_printk'
     129 |                 _dev_printk(level, dev, fmt, ##__VA_ARGS__);            \
         |                                    ^~~
   include/linux/libata.h:1502:9: note: in expansion of macro 'dev_dbg'
    1502 |         dev_dbg(&ap->tdev, "%s: " fmt, __func__, ##__VA_ARGS__)
         |         ^~~~~~~
   drivers/ata/sata_fsl.c:1361:9: note: in expansion of macro 'ata_port_dbg'
    1361 |         ata_port_dbg(ap, "icc = 0x%x\n", ioread32(hcr_base + ICC));
         |         ^~~~~~~~~~~~
   drivers/ata/sata_fsl.c:1361:22: note: each undeclared identifier is reported only once for each function it appears in
    1361 |         ata_port_dbg(ap, "icc = 0x%x\n", ioread32(hcr_base + ICC));
         |                      ^~
   include/linux/dev_printk.h:129:36: note: in definition of macro 'dev_printk'
     129 |                 _dev_printk(level, dev, fmt, ##__VA_ARGS__);            \
         |                                    ^~~
   include/linux/libata.h:1502:9: note: in expansion of macro 'dev_dbg'
    1502 |         dev_dbg(&ap->tdev, "%s: " fmt, __func__, ##__VA_ARGS__)
         |         ^~~~~~~
   drivers/ata/sata_fsl.c:1361:9: note: in expansion of macro 'ata_port_dbg'
    1361 |         ata_port_dbg(ap, "icc = 0x%x\n", ioread32(hcr_base + ICC));
         |         ^~~~~~~~~~~~
   drivers/ata/sata_fsl.c: At top level:
   drivers/ata/sata_fsl.c:1399:22: warning: initialized field overwritten [-Woverride-init]
    1399 |         .can_queue = SATA_FSL_QUEUE_DEPTH,
         |                      ^~~~~~~~~~~~~~~~~~~~
   drivers/ata/sata_fsl.c:1399:22: note: (near initialization for 'sata_fsl_sht.can_queue')
   In file included from include/linux/device.h:15,
                    from include/linux/platform_device.h:13,
                    from drivers/ata/sata_fsl.c:15:
   drivers/ata/sata_fsl.c: In function 'sata_fsl_probe':
   drivers/ata/sata_fsl.c:1470:22: error: 'ap' undeclared (first use in this function); did you mean 'up'?
    1470 |         ata_port_dbg(ap, "@reset i/o = 0x%x\n", ioread32(csr_base + TRANSCFG));
         |                      ^~
   include/linux/dev_printk.h:129:36: note: in definition of macro 'dev_printk'
     129 |                 _dev_printk(level, dev, fmt, ##__VA_ARGS__);            \
         |                                    ^~~
   include/linux/libata.h:1502:9: note: in expansion of macro 'dev_dbg'
    1502 |         dev_dbg(&ap->tdev, "%s: " fmt, __func__, ##__VA_ARGS__)
         |         ^~~~~~~
   drivers/ata/sata_fsl.c:1470:9: note: in expansion of macro 'ata_port_dbg'
    1470 |         ata_port_dbg(ap, "@reset i/o = 0x%x\n", ioread32(csr_base + TRANSCFG));
         |         ^~~~~~~~~~~~
   cc1: some warnings being treated as errors


vim +/_dev_printk +316 drivers/ata/sata_fsl.c

   290	
   291	static void fsl_sata_set_irq_coalescing(struct ata_host *host,
   292			unsigned int count, unsigned int ticks)
   293	{
   294		struct sata_fsl_host_priv *host_priv = host->private_data;
   295		void __iomem *hcr_base = host_priv->hcr_base;
   296		unsigned long flags;
   297	
   298		if (count > ICC_MAX_INT_COUNT_THRESHOLD)
   299			count = ICC_MAX_INT_COUNT_THRESHOLD;
   300		else if (count < ICC_MIN_INT_COUNT_THRESHOLD)
   301			count = ICC_MIN_INT_COUNT_THRESHOLD;
   302	
   303		if (ticks > ICC_MAX_INT_TICKS_THRESHOLD)
   304			ticks = ICC_MAX_INT_TICKS_THRESHOLD;
   305		else if ((ICC_MIN_INT_TICKS_THRESHOLD == ticks) &&
   306				(count > ICC_MIN_INT_COUNT_THRESHOLD))
   307			ticks = ICC_SAFE_INT_TICKS;
   308	
   309		spin_lock_irqsave(&host->lock, flags);
   310		iowrite32((count << 24 | ticks), hcr_base + ICC);
   311	
   312		intr_coalescing_count = count;
   313		intr_coalescing_ticks = ticks;
   314		spin_unlock_irqrestore(&host->lock, flags);
   315	
 > 316		dev_dbg(&host->dev, "interrupt coalescing, count = 0x%x, ticks = %x\n",
   317				intr_coalescing_count, intr_coalescing_ticks);
   318		dev_dbg(&host->dev, "ICC register status: (hcr base: 0x%x) = 0x%x\n",
   319				hcr_base, ioread32(hcr_base + ICC));
   320	}
   321	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

^ permalink raw reply	[flat|nested] 2+ messages in thread

* [dlemoal-libata:ata-msg 34/61] drivers/ata/sata_fsl.c:316:17: error: passing argument 2 of '_dev_printk' from incompatible pointer type
@ 2021-12-08 12:16 ` kernel test robot
  0 siblings, 0 replies; 2+ messages in thread
From: kernel test robot @ 2021-12-08 12:16 UTC (permalink / raw)
  To: kbuild-all

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

tree:   git://git.kernel.org/pub/scm/linux/kernel/git/dlemoal/libata.git ata-msg
head:   7d6ff0ace26c7e7f01d532d244de0b9811765f47
commit: efab2a8f108886fa8d2d0108941bb1ccb36f8526 [34/61] sata_fsl: move DPRINTK to ata debugging
config: powerpc-mpc837x_rdb_defconfig (https://download.01.org/0day-ci/archive/20211208/202112081937.KKQZRXYI-lkp(a)intel.com/config)
compiler: powerpc-linux-gcc (GCC) 11.2.0
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # https://git.kernel.org/pub/scm/linux/kernel/git/dlemoal/libata.git/commit/?id=efab2a8f108886fa8d2d0108941bb1ccb36f8526
        git remote add dlemoal-libata git://git.kernel.org/pub/scm/linux/kernel/git/dlemoal/libata.git
        git fetch --no-tags dlemoal-libata ata-msg
        git checkout efab2a8f108886fa8d2d0108941bb1ccb36f8526
        # save the config file to linux build tree
        mkdir build_dir
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=powerpc SHELL=/bin/bash

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

All errors (new ones prefixed by >>):

   In file included from include/linux/device.h:15,
                    from include/linux/platform_device.h:13,
                    from drivers/ata/sata_fsl.c:15:
   drivers/ata/sata_fsl.c: In function 'fsl_sata_set_irq_coalescing':
>> drivers/ata/sata_fsl.c:316:17: error: passing argument 2 of '_dev_printk' from incompatible pointer type [-Werror=incompatible-pointer-types]
     316 |         dev_dbg(&host->dev, "interrupt coalescing, count = 0x%x, ticks = %x\n",
         |                 ^~~~~~~~~~
         |                 |
         |                 struct device **
   include/linux/dev_printk.h:129:36: note: in definition of macro 'dev_printk'
     129 |                 _dev_printk(level, dev, fmt, ##__VA_ARGS__);            \
         |                                    ^~~
   drivers/ata/sata_fsl.c:316:9: note: in expansion of macro 'dev_dbg'
     316 |         dev_dbg(&host->dev, "interrupt coalescing, count = 0x%x, ticks = %x\n",
         |         ^~~~~~~
   include/linux/dev_printk.h:41:58: note: expected 'const struct device *' but argument is of type 'struct device **'
      41 | void _dev_printk(const char *level, const struct device *dev,
         |                                     ~~~~~~~~~~~~~~~~~~~~~^~~
   drivers/ata/sata_fsl.c:318:17: error: passing argument 2 of '_dev_printk' from incompatible pointer type [-Werror=incompatible-pointer-types]
     318 |         dev_dbg(&host->dev, "ICC register status: (hcr base: 0x%x) = 0x%x\n",
         |                 ^~~~~~~~~~
         |                 |
         |                 struct device **
   include/linux/dev_printk.h:129:36: note: in definition of macro 'dev_printk'
     129 |                 _dev_printk(level, dev, fmt, ##__VA_ARGS__);            \
         |                                    ^~~
   drivers/ata/sata_fsl.c:318:9: note: in expansion of macro 'dev_dbg'
     318 |         dev_dbg(&host->dev, "ICC register status: (hcr base: 0x%x) = 0x%x\n",
         |         ^~~~~~~
   include/linux/dev_printk.h:41:58: note: expected 'const struct device *' but argument is of type 'struct device **'
      41 | void _dev_printk(const char *level, const struct device *dev,
         |                                     ~~~~~~~~~~~~~~~~~~~~~^~~
   drivers/ata/sata_fsl.c:318:29: warning: format '%x' expects argument of type 'unsigned int', but argument 4 has type 'void *' [-Wformat=]
     318 |         dev_dbg(&host->dev, "ICC register status: (hcr base: 0x%x) = 0x%x\n",
         |                             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/dev_printk.h:129:41: note: in definition of macro 'dev_printk'
     129 |                 _dev_printk(level, dev, fmt, ##__VA_ARGS__);            \
         |                                         ^~~
   include/linux/dev_printk.h:163:45: note: in expansion of macro 'dev_fmt'
     163 |                 dev_printk(KERN_DEBUG, dev, dev_fmt(fmt), ##__VA_ARGS__); \
         |                                             ^~~~~~~
   drivers/ata/sata_fsl.c:318:9: note: in expansion of macro 'dev_dbg'
     318 |         dev_dbg(&host->dev, "ICC register status: (hcr base: 0x%x) = 0x%x\n",
         |         ^~~~~~~
   drivers/ata/sata_fsl.c:318:65: note: format string is defined here
     318 |         dev_dbg(&host->dev, "ICC register status: (hcr base: 0x%x) = 0x%x\n",
         |                                                                ~^
         |                                                                 |
         |                                                                 unsigned int
         |                                                                %p
   In file included from include/linux/device.h:15,
                    from include/linux/platform_device.h:13,
                    from drivers/ata/sata_fsl.c:15:
   drivers/ata/sata_fsl.c: In function 'sata_fsl_init_controller':
>> drivers/ata/sata_fsl.c:1361:22: error: 'ap' undeclared (first use in this function); did you mean 'up'?
    1361 |         ata_port_dbg(ap, "icc = 0x%x\n", ioread32(hcr_base + ICC));
         |                      ^~
   include/linux/dev_printk.h:129:36: note: in definition of macro 'dev_printk'
     129 |                 _dev_printk(level, dev, fmt, ##__VA_ARGS__);            \
         |                                    ^~~
   include/linux/libata.h:1502:9: note: in expansion of macro 'dev_dbg'
    1502 |         dev_dbg(&ap->tdev, "%s: " fmt, __func__, ##__VA_ARGS__)
         |         ^~~~~~~
   drivers/ata/sata_fsl.c:1361:9: note: in expansion of macro 'ata_port_dbg'
    1361 |         ata_port_dbg(ap, "icc = 0x%x\n", ioread32(hcr_base + ICC));
         |         ^~~~~~~~~~~~
   drivers/ata/sata_fsl.c:1361:22: note: each undeclared identifier is reported only once for each function it appears in
    1361 |         ata_port_dbg(ap, "icc = 0x%x\n", ioread32(hcr_base + ICC));
         |                      ^~
   include/linux/dev_printk.h:129:36: note: in definition of macro 'dev_printk'
     129 |                 _dev_printk(level, dev, fmt, ##__VA_ARGS__);            \
         |                                    ^~~
   include/linux/libata.h:1502:9: note: in expansion of macro 'dev_dbg'
    1502 |         dev_dbg(&ap->tdev, "%s: " fmt, __func__, ##__VA_ARGS__)
         |         ^~~~~~~
   drivers/ata/sata_fsl.c:1361:9: note: in expansion of macro 'ata_port_dbg'
    1361 |         ata_port_dbg(ap, "icc = 0x%x\n", ioread32(hcr_base + ICC));
         |         ^~~~~~~~~~~~
   drivers/ata/sata_fsl.c: At top level:
   drivers/ata/sata_fsl.c:1399:22: warning: initialized field overwritten [-Woverride-init]
    1399 |         .can_queue = SATA_FSL_QUEUE_DEPTH,
         |                      ^~~~~~~~~~~~~~~~~~~~
   drivers/ata/sata_fsl.c:1399:22: note: (near initialization for 'sata_fsl_sht.can_queue')
   In file included from include/linux/device.h:15,
                    from include/linux/platform_device.h:13,
                    from drivers/ata/sata_fsl.c:15:
   drivers/ata/sata_fsl.c: In function 'sata_fsl_probe':
   drivers/ata/sata_fsl.c:1470:22: error: 'ap' undeclared (first use in this function); did you mean 'up'?
    1470 |         ata_port_dbg(ap, "@reset i/o = 0x%x\n", ioread32(csr_base + TRANSCFG));
         |                      ^~
   include/linux/dev_printk.h:129:36: note: in definition of macro 'dev_printk'
     129 |                 _dev_printk(level, dev, fmt, ##__VA_ARGS__);            \
         |                                    ^~~
   include/linux/libata.h:1502:9: note: in expansion of macro 'dev_dbg'
    1502 |         dev_dbg(&ap->tdev, "%s: " fmt, __func__, ##__VA_ARGS__)
         |         ^~~~~~~
   drivers/ata/sata_fsl.c:1470:9: note: in expansion of macro 'ata_port_dbg'
    1470 |         ata_port_dbg(ap, "@reset i/o = 0x%x\n", ioread32(csr_base + TRANSCFG));
         |         ^~~~~~~~~~~~
   cc1: some warnings being treated as errors


vim +/_dev_printk +316 drivers/ata/sata_fsl.c

   290	
   291	static void fsl_sata_set_irq_coalescing(struct ata_host *host,
   292			unsigned int count, unsigned int ticks)
   293	{
   294		struct sata_fsl_host_priv *host_priv = host->private_data;
   295		void __iomem *hcr_base = host_priv->hcr_base;
   296		unsigned long flags;
   297	
   298		if (count > ICC_MAX_INT_COUNT_THRESHOLD)
   299			count = ICC_MAX_INT_COUNT_THRESHOLD;
   300		else if (count < ICC_MIN_INT_COUNT_THRESHOLD)
   301			count = ICC_MIN_INT_COUNT_THRESHOLD;
   302	
   303		if (ticks > ICC_MAX_INT_TICKS_THRESHOLD)
   304			ticks = ICC_MAX_INT_TICKS_THRESHOLD;
   305		else if ((ICC_MIN_INT_TICKS_THRESHOLD == ticks) &&
   306				(count > ICC_MIN_INT_COUNT_THRESHOLD))
   307			ticks = ICC_SAFE_INT_TICKS;
   308	
   309		spin_lock_irqsave(&host->lock, flags);
   310		iowrite32((count << 24 | ticks), hcr_base + ICC);
   311	
   312		intr_coalescing_count = count;
   313		intr_coalescing_ticks = ticks;
   314		spin_unlock_irqrestore(&host->lock, flags);
   315	
 > 316		dev_dbg(&host->dev, "interrupt coalescing, count = 0x%x, ticks = %x\n",
   317				intr_coalescing_count, intr_coalescing_ticks);
   318		dev_dbg(&host->dev, "ICC register status: (hcr base: 0x%x) = 0x%x\n",
   319				hcr_base, ioread32(hcr_base + ICC));
   320	}
   321	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-12-08 12:16 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-08 12:16 [dlemoal-libata:ata-msg 34/61] drivers/ata/sata_fsl.c:316:17: error: passing argument 2 of '_dev_printk' from incompatible pointer type kernel test robot
2021-12-08 12:16 ` kernel 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.