drivers/video/fbdev/grvga.c:151:26: sparse: sparse: incorrect type in argument 2 (different address spaces)
From: kernel test robot
Date: Sun Aug 09 2020 - 23:59:58 EST
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: fc80c51fd4b23ec007e88d4c688f2cac1b8648e7
commit: 670d0a4b10704667765f7d18f7592993d02783aa sparse: use identifiers to define address spaces
date: 7 weeks ago
config: sparc-randconfig-s032-20200810 (attached as .config)
compiler: sparc-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.2-118-ge1578773-dirty
git checkout 670d0a4b10704667765f7d18f7592993d02783aa
# 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__' ARCH=sparc
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@xxxxxxxxx>
sparse warnings: (new ones prefixed by >>)
>> drivers/video/fbdev/grvga.c:151:26: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *addr @@ got unsigned int * @@
drivers/video/fbdev/grvga.c:151:26: sparse: expected void volatile [noderef] __iomem *addr
drivers/video/fbdev/grvga.c:151:26: sparse: got unsigned int *
drivers/video/fbdev/grvga.c:154:26: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *addr @@ got unsigned int * @@
drivers/video/fbdev/grvga.c:154:26: sparse: expected void volatile [noderef] __iomem *addr
drivers/video/fbdev/grvga.c:154:26: sparse: got unsigned int *
drivers/video/fbdev/grvga.c:157:26: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *addr @@ got unsigned int * @@
drivers/video/fbdev/grvga.c:157:26: sparse: expected void volatile [noderef] __iomem *addr
drivers/video/fbdev/grvga.c:157:26: sparse: got unsigned int *
drivers/video/fbdev/grvga.c:161:26: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *addr @@ got unsigned int * @@
drivers/video/fbdev/grvga.c:161:26: sparse: expected void volatile [noderef] __iomem *addr
drivers/video/fbdev/grvga.c:161:26: sparse: got unsigned int *
drivers/video/fbdev/grvga.c:182:26: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *addr @@ got unsigned int * @@
drivers/video/fbdev/grvga.c:182:26: sparse: expected void volatile [noderef] __iomem *addr
drivers/video/fbdev/grvga.c:182:26: sparse: got unsigned int *
drivers/video/fbdev/grvga.c:215:34: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *addr @@ got unsigned int * @@
drivers/video/fbdev/grvga.c:215:34: sparse: expected void volatile [noderef] __iomem *addr
drivers/video/fbdev/grvga.c:215:34: sparse: got unsigned int *
drivers/video/fbdev/grvga.c:249:26: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *addr @@ got unsigned int * @@
drivers/video/fbdev/grvga.c:249:26: sparse: expected void volatile [noderef] __iomem *addr
drivers/video/fbdev/grvga.c:249:26: sparse: got unsigned int *
drivers/video/fbdev/grvga.c:390:19: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct grvga_regs *regs @@ got void [noderef] __iomem * @@
drivers/video/fbdev/grvga.c:390:19: sparse: expected struct grvga_regs *regs
drivers/video/fbdev/grvga.c:390:19: sparse: got void [noderef] __iomem *
drivers/video/fbdev/grvga.c:485:42: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *addr @@ got unsigned int * @@
drivers/video/fbdev/grvga.c:485:42: sparse: expected void volatile [noderef] __iomem *addr
drivers/video/fbdev/grvga.c:485:42: sparse: got unsigned int *
drivers/video/fbdev/grvga.c:486:38: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const volatile [noderef] __iomem *addr @@ got unsigned int * @@
drivers/video/fbdev/grvga.c:486:38: sparse: expected void const volatile [noderef] __iomem *addr
drivers/video/fbdev/grvga.c:486:38: sparse: got unsigned int *
drivers/video/fbdev/grvga.c:487:26: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void volatile [noderef] __iomem *addr @@ got unsigned int * @@
drivers/video/fbdev/grvga.c:487:26: sparse: expected void volatile [noderef] __iomem *addr
drivers/video/fbdev/grvga.c:487:26: sparse: got unsigned int *
drivers/video/fbdev/grvga.c:493:26: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void volatile [noderef] __iomem *addr @@ got void * @@
drivers/video/fbdev/grvga.c:493:26: sparse: expected void volatile [noderef] __iomem *addr
drivers/video/fbdev/grvga.c:493:26: sparse: got void *
drivers/video/fbdev/grvga.c:499:42: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void [noderef] __iomem *base @@ got struct grvga_regs *regs @@
drivers/video/fbdev/grvga.c:499:42: sparse: expected void [noderef] __iomem *base
drivers/video/fbdev/grvga.c:499:42: sparse: got struct grvga_regs *regs
drivers/video/fbdev/grvga.c:517:53: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void [noderef] __iomem *base @@ got struct grvga_regs *regs @@
drivers/video/fbdev/grvga.c:517:53: sparse: expected void [noderef] __iomem *base
drivers/video/fbdev/grvga.c:517:53: sparse: got struct grvga_regs *regs
drivers/video/fbdev/grvga.c:523:32: sparse: sparse: cast removes address space '__iomem' of expression
vim +151 drivers/video/fbdev/grvga.c
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 146
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 147 u32 func = 0;
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 148 struct grvga_par *par = info->par;
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 149
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 150 __raw_writel(((info->var.yres - 1) << 16) | (info->var.xres - 1),
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 @151 &par->regs->video_length);
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 152
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 153 __raw_writel((info->var.lower_margin << 16) | (info->var.right_margin),
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 154 &par->regs->front_porch);
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 155
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 156 __raw_writel((info->var.vsync_len << 16) | (info->var.hsync_len),
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 157 &par->regs->sync_length);
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 158
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 159 __raw_writel(((info->var.yres + info->var.lower_margin + info->var.upper_margin + info->var.vsync_len - 1) << 16) |
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 160 (info->var.xres + info->var.right_margin + info->var.left_margin + info->var.hsync_len - 1),
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 161 &par->regs->line_length);
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 162
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 163 switch (info->var.bits_per_pixel) {
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 164 case 8:
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 165 info->fix.visual = FB_VISUAL_PSEUDOCOLOR;
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 166 func = 1;
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 167 break;
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 168 case 16:
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 169 info->fix.visual = FB_VISUAL_TRUECOLOR;
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 170 func = 2;
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 171 break;
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 172 case 24:
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 173 case 32:
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 174 info->fix.visual = FB_VISUAL_TRUECOLOR;
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 175 func = 3;
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 176 break;
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 177 default:
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 178 return -EINVAL;
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 179 }
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 180
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 181 __raw_writel((par->clk_sel << 6) | (func << 4) | 1,
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 182 &par->regs->status);
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 183
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 184 info->fix.line_length = (info->var.xres_virtual*info->var.bits_per_pixel)/8;
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 185 return 0;
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 186 }
a4b8f97a8fdeb9 drivers/video/grvga.c Kristoffer Glembo 2011-07-05 187
:::::: The code at line 151 was first introduced by commit
:::::: a4b8f97a8fdeb94492738c36fddbd2cf822ed138 video: Add Aeroflex Gaisler GRVGA framebuffer device driver
:::::: TO: Kristoffer Glembo <kristoffer@xxxxxxxxxxx>
:::::: CC: Paul Mundt <lethal@xxxxxxxxxxxx>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx
Attachment:
.config.gz
Description: application/gzip