All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Mikko Rapeli <mikko.rapeli@linaro.org>
Cc: oe-kbuild-all@lists.linux.dev, linux-kernel@vger.kernel.org,
	Ulf Hansson <ulf.hansson@linaro.org>
Subject: drivers/mmc/host/mxcmmc.c:545:24: sparse: sparse: incorrect type in assignment (different base types)
Date: Fri, 11 Sep 2026 06:33:34 +0800	[thread overview]
Message-ID: <202609110632.72NLMuJo-lkp@intel.com> (raw)

Hi Mikko,

First bad commit (maybe != root cause):

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   50d05c7c76c96b90462f24debacca971d2e86713
commit: 7cd8db0fb0b2bf309163d56fec585c0f9e0964d1 mmc: add COMPILE_TEST to multiple drivers
date:   12 months ago
config: powerpc-randconfig-r132-20260910 (https://download.01.org/0day-ci/archive/20260911/202609110632.72NLMuJo-lkp@intel.com/config)
compiler: clang version 18.1.8 (https://github.com/llvm/llvm-project 3b5b5c1ec4a3095ab096dd780e84d7ab81f3d7ff)
sparse: v0.6.5-rc1
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260911/202609110632.72NLMuJo-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
| Fixes: 7cd8db0fb0b2 ("mmc: add COMPILE_TEST to multiple drivers")
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202609110632.72NLMuJo-lkp@intel.com/

sparse warnings: (new ones prefixed by >>)
>> drivers/mmc/host/mxcmmc.c:545:24: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned int [usertype] @@     got restricted __le32 [usertype] @@
   drivers/mmc/host/mxcmmc.c:545:24: sparse:     expected unsigned int [usertype]
   drivers/mmc/host/mxcmmc.c:545:24: sparse:     got restricted __le32 [usertype]
   drivers/mmc/host/mxcmmc.c:557:21: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned int [usertype] tmp @@     got restricted __le32 [usertype] @@
   drivers/mmc/host/mxcmmc.c:557:21: sparse:     expected unsigned int [usertype] tmp
   drivers/mmc/host/mxcmmc.c:557:21: sparse:     got restricted __le32 [usertype]
   drivers/mmc/host/mxcmmc.c:572:37: sparse: sparse: incorrect type in argument 2 (different base types) @@     expected unsigned int [usertype] val @@     got restricted __le32 [usertype] @@
   drivers/mmc/host/mxcmmc.c:572:37: sparse:     expected unsigned int [usertype] val
   drivers/mmc/host/mxcmmc.c:572:37: sparse:     got restricted __le32 [usertype]
   drivers/mmc/host/mxcmmc.c:585:37: sparse: sparse: incorrect type in argument 2 (different base types) @@     expected unsigned int [usertype] val @@     got restricted __le32 [usertype] @@
   drivers/mmc/host/mxcmmc.c:585:37: sparse:     expected unsigned int [usertype] val
   drivers/mmc/host/mxcmmc.c:585:37: sparse:     got restricted __le32 [usertype]

vim +545 drivers/mmc/host/mxcmmc.c

d96be879ff4697 Sascha Hauer       2009-01-06  535  
12658af54f2ed1 Linus Walleij      2024-01-27  536  static int mxcmci_pull(struct mxcmci_host *host, u32 *buf, int bytes)
d96be879ff4697 Sascha Hauer       2009-01-06  537  {
d96be879ff4697 Sascha Hauer       2009-01-06  538  	unsigned int stat;
d96be879ff4697 Sascha Hauer       2009-01-06  539  
d96be879ff4697 Sascha Hauer       2009-01-06  540  	while (bytes > 3) {
d96be879ff4697 Sascha Hauer       2009-01-06  541  		stat = mxcmci_poll_status(host,
d96be879ff4697 Sascha Hauer       2009-01-06  542  				STATUS_BUF_READ_RDY | STATUS_READ_OP_DONE);
d96be879ff4697 Sascha Hauer       2009-01-06  543  		if (stat)
d96be879ff4697 Sascha Hauer       2009-01-06  544  			return stat;
c7ceab02543f8a Anatolij Gustschin 2013-04-08 @545  		*buf++ = cpu_to_le32(mxcmci_readl(host, MMC_REG_BUFFER_ACCESS));
d96be879ff4697 Sascha Hauer       2009-01-06  546  		bytes -= 4;
d96be879ff4697 Sascha Hauer       2009-01-06  547  	}
d96be879ff4697 Sascha Hauer       2009-01-06  548  
d96be879ff4697 Sascha Hauer       2009-01-06  549  	if (bytes) {
d96be879ff4697 Sascha Hauer       2009-01-06  550  		u8 *b = (u8 *)buf;
d96be879ff4697 Sascha Hauer       2009-01-06  551  		u32 tmp;
d96be879ff4697 Sascha Hauer       2009-01-06  552  
d96be879ff4697 Sascha Hauer       2009-01-06  553  		stat = mxcmci_poll_status(host,
d96be879ff4697 Sascha Hauer       2009-01-06  554  				STATUS_BUF_READ_RDY | STATUS_READ_OP_DONE);
d96be879ff4697 Sascha Hauer       2009-01-06  555  		if (stat)
d96be879ff4697 Sascha Hauer       2009-01-06  556  			return stat;
c7ceab02543f8a Anatolij Gustschin 2013-04-08  557  		tmp = cpu_to_le32(mxcmci_readl(host, MMC_REG_BUFFER_ACCESS));
d96be879ff4697 Sascha Hauer       2009-01-06  558  		memcpy(b, &tmp, bytes);
d96be879ff4697 Sascha Hauer       2009-01-06  559  	}
d96be879ff4697 Sascha Hauer       2009-01-06  560  
d96be879ff4697 Sascha Hauer       2009-01-06  561  	return 0;
d96be879ff4697 Sascha Hauer       2009-01-06  562  }
d96be879ff4697 Sascha Hauer       2009-01-06  563  

:::::: The code at line 545 was first introduced by commit
:::::: c7ceab02543f8a03b4df3d4465b089c8117a5e09 mmc: mxcmmc: add mpc512x SDHC support

:::::: TO: Anatolij Gustschin <agust@denx.de>
:::::: CC: Chris Ball <cjb@laptop.org>

--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

             reply	other threads:[~2026-09-10 22:34 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-10 22:33 kernel test robot [this message]
  -- strict thread matches above, loose matches on Subject: below --
2026-06-01 14:26 drivers/mmc/host/mxcmmc.c:545:24: sparse: sparse: incorrect type in assignment (different base types) kernel test robot

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=202609110632.72NLMuJo-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mikko.rapeli@linaro.org \
    --cc=oe-kbuild-all@lists.linux.dev \
    --cc=ulf.hansson@linaro.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.