All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: [microchip-ung-linux-upstream:v5.10-webstax 61/88] drivers/mfd/microchip_sparx5_pci.c:491:11: warning: format '%llu' expects argument of type 'long long unsigned int', but argument 7 has type 'resource_size_t' {aka 'unsigned int'}
Date: Mon, 14 Dec 2020 21:58:20 +0800	[thread overview]
Message-ID: <202012142116.EGaWRVXR-lkp@intel.com> (raw)

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

tree:   https://github.com/microchip-ung/linux-upstream.git v5.10-webstax
head:   0c603c93d534e71ceee9485bfe1b0b75561efb0e
commit: 5b4a9de85b60edf37f6322a88a2c37970c81b875 [61/88] mfd: Add sparx5 and jaguar2 PCIe mfd drivers
config: xtensa-allyesconfig (attached as .config)
compiler: xtensa-linux-gcc (GCC) 9.3.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://github.com/microchip-ung/linux-upstream/commit/5b4a9de85b60edf37f6322a88a2c37970c81b875
        git remote add microchip-ung-linux-upstream https://github.com/microchip-ung/linux-upstream.git
        git fetch --no-tags microchip-ung-linux-upstream v5.10-webstax
        git checkout 5b4a9de85b60edf37f6322a88a2c37970c81b875
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=xtensa 

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

All warnings (new ones prefixed by >>):

   In file included from include/linux/kernel.h:16,
                    from drivers/mfd/microchip_sparx5_pci.c:7:
   drivers/mfd/microchip_sparx5_pci.c: In function 'microchip_sparx5_mfd_probe':
>> drivers/mfd/microchip_sparx5_pci.c:491:11: warning: format '%llu' expects argument of type 'long long unsigned int', but argument 7 has type 'resource_size_t' {aka 'unsigned int'} [-Wformat=]
     491 |  pr_debug("%s:%d %s: Region: %d, size: %lluMB, %llx-%llx => %px\n",
         |           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/printk.h:301:21: note: in definition of macro 'pr_fmt'
     301 | #define pr_fmt(fmt) fmt
         |                     ^~~
   include/linux/dynamic_debug.h:147:2: note: in expansion of macro '__dynamic_func_call'
     147 |  __dynamic_func_call(__UNIQUE_ID(ddebug), fmt, func, ##__VA_ARGS__)
         |  ^~~~~~~~~~~~~~~~~~~
   include/linux/dynamic_debug.h:157:2: note: in expansion of macro '_dynamic_func_call'
     157 |  _dynamic_func_call(fmt, __dynamic_pr_debug,  \
         |  ^~~~~~~~~~~~~~~~~~
   include/linux/printk.h:424:2: note: in expansion of macro 'dynamic_pr_debug'
     424 |  dynamic_pr_debug(fmt, ##__VA_ARGS__)
         |  ^~~~~~~~~~~~~~~~
   drivers/mfd/microchip_sparx5_pci.c:491:2: note: in expansion of macro 'pr_debug'
     491 |  pr_debug("%s:%d %s: Region: %d, size: %lluMB, %llx-%llx => %px\n",
         |  ^~~~~~~~
   drivers/mfd/microchip_sparx5_pci.c:491:43: note: format string is defined here
     491 |  pr_debug("%s:%d %s: Region: %d, size: %lluMB, %llx-%llx => %px\n",
         |                                        ~~~^
         |                                           |
         |                                           long long unsigned int
         |                                        %u
   In file included from include/linux/kernel.h:16,
                    from drivers/mfd/microchip_sparx5_pci.c:7:
>> drivers/mfd/microchip_sparx5_pci.c:491:11: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 8 has type 'phys_addr_t' {aka 'unsigned int'} [-Wformat=]
     491 |  pr_debug("%s:%d %s: Region: %d, size: %lluMB, %llx-%llx => %px\n",
         |           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/printk.h:301:21: note: in definition of macro 'pr_fmt'
     301 | #define pr_fmt(fmt) fmt
         |                     ^~~
   include/linux/dynamic_debug.h:147:2: note: in expansion of macro '__dynamic_func_call'
     147 |  __dynamic_func_call(__UNIQUE_ID(ddebug), fmt, func, ##__VA_ARGS__)
         |  ^~~~~~~~~~~~~~~~~~~
   include/linux/dynamic_debug.h:157:2: note: in expansion of macro '_dynamic_func_call'
     157 |  _dynamic_func_call(fmt, __dynamic_pr_debug,  \
         |  ^~~~~~~~~~~~~~~~~~
   include/linux/printk.h:424:2: note: in expansion of macro 'dynamic_pr_debug'
     424 |  dynamic_pr_debug(fmt, ##__VA_ARGS__)
         |  ^~~~~~~~~~~~~~~~
   drivers/mfd/microchip_sparx5_pci.c:491:2: note: in expansion of macro 'pr_debug'
     491 |  pr_debug("%s:%d %s: Region: %d, size: %lluMB, %llx-%llx => %px\n",
         |  ^~~~~~~~
   drivers/mfd/microchip_sparx5_pci.c:491:51: note: format string is defined here
     491 |  pr_debug("%s:%d %s: Region: %d, size: %lluMB, %llx-%llx => %px\n",
         |                                                ~~~^
         |                                                   |
         |                                                   long long unsigned int
         |                                                %x
   In file included from include/linux/kernel.h:16,
                    from drivers/mfd/microchip_sparx5_pci.c:7:
   drivers/mfd/microchip_sparx5_pci.c:491:11: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 9 has type 'phys_addr_t' {aka 'unsigned int'} [-Wformat=]
     491 |  pr_debug("%s:%d %s: Region: %d, size: %lluMB, %llx-%llx => %px\n",
         |           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/printk.h:301:21: note: in definition of macro 'pr_fmt'
     301 | #define pr_fmt(fmt) fmt
         |                     ^~~
   include/linux/dynamic_debug.h:147:2: note: in expansion of macro '__dynamic_func_call'
     147 |  __dynamic_func_call(__UNIQUE_ID(ddebug), fmt, func, ##__VA_ARGS__)
         |  ^~~~~~~~~~~~~~~~~~~
   include/linux/dynamic_debug.h:157:2: note: in expansion of macro '_dynamic_func_call'
     157 |  _dynamic_func_call(fmt, __dynamic_pr_debug,  \
         |  ^~~~~~~~~~~~~~~~~~
   include/linux/printk.h:424:2: note: in expansion of macro 'dynamic_pr_debug'
     424 |  dynamic_pr_debug(fmt, ##__VA_ARGS__)
         |  ^~~~~~~~~~~~~~~~
   drivers/mfd/microchip_sparx5_pci.c:491:2: note: in expansion of macro 'pr_debug'
     491 |  pr_debug("%s:%d %s: Region: %d, size: %lluMB, %llx-%llx => %px\n",
         |  ^~~~~~~~
   drivers/mfd/microchip_sparx5_pci.c:491:56: note: format string is defined here
     491 |  pr_debug("%s:%d %s: Region: %d, size: %lluMB, %llx-%llx => %px\n",
         |                                                     ~~~^
         |                                                        |
         |                                                        long long unsigned int
         |                                                     %x
   In file included from include/linux/kernel.h:16,
                    from drivers/mfd/microchip_sparx5_pci.c:7:
   drivers/mfd/microchip_sparx5_pci.c:498:11: warning: format '%llu' expects argument of type 'long long unsigned int', but argument 7 has type 'resource_size_t' {aka 'unsigned int'} [-Wformat=]
     498 |  pr_debug("%s:%d %s: Region: %d, size: %lluMB, %llx-%llx => %px\n",
         |           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/printk.h:301:21: note: in definition of macro 'pr_fmt'
     301 | #define pr_fmt(fmt) fmt
         |                     ^~~
   include/linux/dynamic_debug.h:147:2: note: in expansion of macro '__dynamic_func_call'
     147 |  __dynamic_func_call(__UNIQUE_ID(ddebug), fmt, func, ##__VA_ARGS__)
         |  ^~~~~~~~~~~~~~~~~~~
   include/linux/dynamic_debug.h:157:2: note: in expansion of macro '_dynamic_func_call'
     157 |  _dynamic_func_call(fmt, __dynamic_pr_debug,  \
         |  ^~~~~~~~~~~~~~~~~~
   include/linux/printk.h:424:2: note: in expansion of macro 'dynamic_pr_debug'
     424 |  dynamic_pr_debug(fmt, ##__VA_ARGS__)
         |  ^~~~~~~~~~~~~~~~
   drivers/mfd/microchip_sparx5_pci.c:498:2: note: in expansion of macro 'pr_debug'
     498 |  pr_debug("%s:%d %s: Region: %d, size: %lluMB, %llx-%llx => %px\n",
         |  ^~~~~~~~
   drivers/mfd/microchip_sparx5_pci.c:498:43: note: format string is defined here
     498 |  pr_debug("%s:%d %s: Region: %d, size: %lluMB, %llx-%llx => %px\n",
         |                                        ~~~^
         |                                           |
         |                                           long long unsigned int
         |                                        %u
   In file included from include/linux/kernel.h:16,
                    from drivers/mfd/microchip_sparx5_pci.c:7:
   drivers/mfd/microchip_sparx5_pci.c:498:11: warning: format '%llx' expects argument of type 'long long unsigned int', but argument 8 has type 'phys_addr_t' {aka 'unsigned int'} [-Wformat=]
     498 |  pr_debug("%s:%d %s: Region: %d, size: %lluMB, %llx-%llx => %px\n",
         |           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/printk.h:301:21: note: in definition of macro 'pr_fmt'
     301 | #define pr_fmt(fmt) fmt
         |                     ^~~
   include/linux/dynamic_debug.h:147:2: note: in expansion of macro '__dynamic_func_call'
     147 |  __dynamic_func_call(__UNIQUE_ID(ddebug), fmt, func, ##__VA_ARGS__)
         |  ^~~~~~~~~~~~~~~~~~~
   include/linux/dynamic_debug.h:157:2: note: in expansion of macro '_dynamic_func_call'
     157 |  _dynamic_func_call(fmt, __dynamic_pr_debug,  \
         |  ^~~~~~~~~~~~~~~~~~
   include/linux/printk.h:424:2: note: in expansion of macro 'dynamic_pr_debug'
     424 |  dynamic_pr_debug(fmt, ##__VA_ARGS__)
         |  ^~~~~~~~~~~~~~~~
   drivers/mfd/microchip_sparx5_pci.c:498:2: note: in expansion of macro 'pr_debug'
     498 |  pr_debug("%s:%d %s: Region: %d, size: %lluMB, %llx-%llx => %px\n",
         |  ^~~~~~~~
   drivers/mfd/microchip_sparx5_pci.c:498:51: note: format string is defined here
     498 |  pr_debug("%s:%d %s: Region: %d, size: %lluMB, %llx-%llx => %px\n",
         |                                                ~~~^
         |                                                   |
         |                                                   long long unsigned int

vim +491 drivers/mfd/microchip_sparx5_pci.c

   404	
   405	static int microchip_sparx5_mfd_probe(struct pci_dev *dev, 
   406					  const struct pci_device_id *id)
   407	{
   408		struct microchip_sparx5_uio *priv;
   409		struct uio_info *info;
   410		u32 chip_id;
   411		int ret = -ENODEV;
   412	
   413		if (!dev->dev.of_node) {
   414			dev_warn(&dev->dev, "No platform device nodes in PCIe device\n");
   415			return -ENODEV;
   416		}
   417		if (dev->devfn > 0) {
   418			dev_warn(&dev->dev, "Not accepting function 1 or higher\n");
   419			return -ENOENT;
   420		}
   421		priv = devm_kzalloc(&dev->dev, sizeof(*priv), GFP_KERNEL);
   422		if (!priv) {
   423			dev_err(&dev->dev, "No memory\n");
   424			return -ENOMEM;
   425		}
   426		spin_lock_init(&priv->lock);
   427		priv->flags = 0; /* interrupt is enabled to begin with */
   428		priv->pdev = dev;
   429	
   430		ret = pcim_enable_device(dev);
   431		if (ret) {
   432			dev_err(&dev->dev, "Could not enable PCI device\n");
   433			return ret;
   434		}
   435		pci_set_master(dev);
   436		dev_info(&dev->dev, "Device is master\n");
   437	
   438		info = &priv->uio;
   439		info->priv = priv;
   440		
   441		info->mem[0].name = "switch_regs";  /* Used by MESA */
   442		info->mem[0].addr = pci_resource_start(dev, SPARX5_SWITCH_BAR);
   443		info->mem[0].size = pci_resource_len(dev, SPARX5_SWITCH_BAR);
   444		info->mem[0].memtype = UIO_MEM_PHYS;
   445		if (!info->mem[0].addr) {
   446			dev_err(&dev->dev, "Could not map region: %d\n", 
   447				SPARX5_SWITCH_BAR);
   448			ret = -ENXIO;
   449			goto out_disable;
   450		}
   451		info->mem[0].internal_addr = ioremap(info->mem[0].addr, 
   452						     info->mem[0].size);
   453	
   454		info->mem[1].name = "cpu_regs";  /* Used by MESA */
   455		info->mem[1].addr = pci_resource_start(dev, SPARX5_CPU_BAR);
   456		info->mem[1].size = pci_resource_len(dev, SPARX5_CPU_BAR);
   457		info->mem[1].memtype = UIO_MEM_PHYS;
   458		if (!info->mem[1].addr) {
   459			dev_err(&dev->dev, "Could not map region: %d\n", 
   460				SPARX5_CPU_BAR);
   461			ret = -ENXIO;
   462			goto out_disable;
   463		}
   464		info->mem[1].internal_addr = ioremap(info->mem[1].addr, 
   465						     info->mem[1].size);
   466	
   467		pci_set_drvdata(dev, info);
   468		info->name = UIO_NAME;
   469		info->version = UIO_VERSION;
   470		/* info->irq = dev->irq; */
   471		info->irq = UIO_IRQ_CUSTOM;
   472		info->irqcontrol = microchip_sparx5_mfd_irqcontrol;
   473		ret = uio_register_device(&dev->dev, info);
   474		if (ret) {
   475			if (ret == -EPROBE_DEFER) {
   476				dev_info(&dev->dev, "Defer UIO registration\n");
   477			} else {
   478				dev_warn(&dev->dev, "Could not register UIO driver: %d\n", ret);
   479			}
   480			goto out_disable;
   481		}
   482	
   483		ret = microchip_sparx5_mfd_irq_common_init(priv, dev->dev.of_node);
   484		if (ret) {
   485			dev_err(&dev->dev, "Could not configure irqs: %d\n", ret);
   486			goto out_unregister;
   487		}
   488		chip_id = microchip_sparx5_mfd_readl(priv, DEVCPU_GCB_CHIP_REGS_ID_OFF);
   489		dev_info(&dev->dev, "Found %s, UIO device, IRQ %ld, chip id 0x%08x\n", 
   490			 info->name, info->irq, chip_id);
 > 491		pr_debug("%s:%d %s: Region: %d, size: %lluMB, %llx-%llx => %px\n", 
   492			__FILE__, __LINE__, __func__,
   493			0,
   494			info->mem[0].size >> 20,
   495			info->mem[0].addr,
   496			info->mem[0].addr + info->mem[0].size - 1,
   497			info->mem[0].internal_addr);
   498		pr_debug("%s:%d %s: Region: %d, size: %lluMB, %llx-%llx => %px\n", 
   499			__FILE__, __LINE__, __func__,
   500			1,
   501			info->mem[1].size >> 20,
   502			info->mem[1].addr,
   503			info->mem[1].addr + info->mem[1].size - 1,
   504			info->mem[1].internal_addr);
   505	
   506		/* Update PCIe PF0 BAR2 mask */
   507		{
   508			u32 dbi_access, orig;
   509			dbi_access = orig = microchip_sparx5_mfd_readl(priv, CPU_PCIE_CFG_OFF);
   510			dbi_access &= ~CPU_PCIE_CFG_DBI_ACCESS_ENA_M;
   511			dbi_access |= CPU_PCIE_CFG_DBI_ACCESS_ENA(3);
   512			microchip_sparx5_mfd_writel(priv, CPU_PCIE_PCIEMST_PF0_BAR2_MASK_LOW_OFF, 0xff000000);
   513			microchip_sparx5_mfd_writel(priv, CPU_PCIE_PCIEMST_PF0_BAR2_MASK_HIGH_OFF, 0xf);
   514			microchip_sparx5_mfd_writel(priv, CPU_PCIE_CFG_OFF, orig);
   515			pr_debug("%s:%d %s: Update PF0 BAR2 mask\n", 
   516			__FILE__, __LINE__, __func__);
   517		}
   518		return of_platform_default_populate(dev->dev.of_node, NULL, &dev->dev);
   519	
   520	out_unregister:
   521		uio_unregister_device(info);
   522	out_disable:
   523		pci_disable_device(dev);
   524		return ret;
   525	}
   526	

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

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 66287 bytes --]

                 reply	other threads:[~2020-12-14 13:58 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=202012142116.EGaWRVXR-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=kbuild-all@lists.01.org \
    /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.