Hi Neil,
[FYI, it's a private test report for your RFC patch.]
[auto build test WARNING on linus/master]
[also build test WARNING on v5.13-rc5 next-20210608]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url:
https://github.com/0day-ci/linux/commits/Neil-Armstrong/mmc-meson-gx-use-...
base:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
614124bea77e452aa6df7a8714e8bc820b489922
config: mips-randconfig-s031-20210608 (attached as .config)
compiler: mips-linux-gcc (GCC) 9.3.0
reproduce:
wget
https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O
~/bin/make.cross
chmod +x ~/bin/make.cross
# apt-get install sparse
# sparse version: v0.6.3-341-g8af24329-dirty
#
https://github.com/0day-ci/linux/commit/2058382d3f2ac13e79a3402e8992bf41b...
git remote add linux-review
https://github.com/0day-ci/linux
git fetch --no-tags linux-review
Neil-Armstrong/mmc-meson-gx-use-memcpy_to-fromio-for-dram-access-quirk/20210608-233729
git checkout 2058382d3f2ac13e79a3402e8992bf41bca22748
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1
CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' W=1 ARCH=mips
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
sparse warnings: (new ones prefixed by >>)
command-line: note: in included file:
builtin:1:9: sparse: sparse: preprocessor token __ATOMIC_ACQUIRE redefined
builtin:0:0: sparse: this was the original definition
builtin:1:9: sparse: sparse: preprocessor token __ATOMIC_SEQ_CST redefined
builtin:0:0: sparse: this was the original definition
builtin:1:9: sparse: sparse: preprocessor token __ATOMIC_ACQ_REL redefined
builtin:0:0: sparse: this was the original definition
builtin:1:9: sparse: sparse: preprocessor token __ATOMIC_RELEASE redefined
builtin:0:0: sparse: this was the original definition
> drivers/mmc/host/meson-gx-mmc.c:774:49: sparse: sparse: incorrect
type in argument 1 (different address spaces) @@ expected void volatile [noderef]
__iomem *dst @@ got void * @@
drivers/mmc/host/meson-gx-mmc.c:774:49: sparse:
expected void volatile [noderef] __iomem *dst
drivers/mmc/host/meson-gx-mmc.c:774:49: sparse: got void *
> drivers/mmc/host/meson-gx-mmc.c:776:63: sparse: sparse: incorrect
type in argument 2 (different address spaces) @@ expected void const volatile
[noderef] __iomem *src @@ got void * @@
drivers/mmc/host/meson-gx-mmc.c:776:63: sparse: expected void const volatile [noderef]
__iomem *src
drivers/mmc/host/meson-gx-mmc.c:776:63: sparse: got void *
drivers/mmc/host/meson-gx-mmc.c:1222:34: sparse: sparse: incorrect type in assignment
(different address spaces) @@ expected void *bounce_buf @@ got void [noderef]
__iomem * @@
drivers/mmc/host/meson-gx-mmc.c:1222:34: sparse: expected void *bounce_buf
drivers/mmc/host/meson-gx-mmc.c:1222:34: sparse: got void [noderef] __iomem *
vim +774 drivers/mmc/host/meson-gx-mmc.c
747
748 /* local sg copy to buffer version with _to/fromio usage for dram_access_quirk */
749 static void meson_mmc_copy_buffer(struct meson_host *host, struct mmc_data *data,
750 size_t buflen, bool to_buffer)
751 {
752 unsigned int sg_flags = SG_MITER_ATOMIC;
753 struct scatterlist *sgl = data->sg;
754 unsigned int nents = data->sg_len;
755 struct sg_mapping_iter miter;
756 void *buf = host->bounce_buf;
757 unsigned int offset = 0;
758
759 if (to_buffer)
760 sg_flags |= SG_MITER_FROM_SG;
761 else
762 sg_flags |= SG_MITER_TO_SG;
763
764 sg_miter_start(&miter, sgl, nents, sg_flags);
765
766 while ((offset < buflen) && sg_miter_next(&miter)) {
767 unsigned int len;
768
769 len = min(miter.length, buflen - offset);
770
771 /* When dram_access_quirk, the bounce buffer is a iomem mapping */
772 if (host->dram_access_quirk) {
773 if (to_buffer)
774 memcpy_toio(buf + offset, miter.addr, len);
775 else
776 memcpy_fromio(miter.addr, buf + offset, len);
777 } else {
778 if (to_buffer)
779 memcpy(buf + offset, miter.addr, len);
780 else
781 memcpy(miter.addr, buf + offset, len);
782 }
783
784 offset += len;
785 }
786
787 sg_miter_stop(&miter);
788 }
789
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org