mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Ben Skeggs <bskeggs@nvidia.com>
Cc: oe-kbuild-all@lists.linux.dev, linux-kernel@vger.kernel.org,
	Dave Airlie <airlied@redhat.com>, Timur Tabi <ttabi@nvidia.com>
Subject: drivers/gpu/drm/nouveau/nvif/chan.c:38:51: sparse: sparse: incorrect type in initializer (different address spaces)
Date: Fri, 12 Dec 2025 13:22:27 +0800	[thread overview]
Message-ID: <202512121331.N9I5gDz3-lkp@intel.com> (raw)

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   d358e5254674b70f34c847715ca509e46eb81e6f
commit: 862450a85b85a3e88e9065c9d2421f3ef17d054c drm/nouveau/gf100-: track chan progress with non-WFI semaphore release
date:   7 months ago
config: i386-randconfig-061-20251212 (https://download.01.org/0day-ci/archive/20251212/202512121331.N9I5gDz3-lkp@intel.com/config)
compiler: gcc-14 (Debian 14.2.0-19) 14.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20251212/202512121331.N9I5gDz3-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
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202512121331.N9I5gDz3-lkp@intel.com/

sparse warnings: (new ones prefixed by >>)
   drivers/gpu/drm/nouveau/nvif/chan.c:11:32: sparse: sparse: cast removes address space '__iomem' of expression
>> drivers/gpu/drm/nouveau/nvif/chan.c:38:51: sparse: sparse: incorrect type in initializer (different address spaces) @@     expected unsigned int const [usertype] *map @@     got void [noderef] __iomem *ptr @@
   drivers/gpu/drm/nouveau/nvif/chan.c:38:51: sparse:     expected unsigned int const [usertype] *map
   drivers/gpu/drm/nouveau/nvif/chan.c:38:51: sparse:     got void [noderef] __iomem *ptr
   drivers/gpu/drm/nouveau/nvif/chan.c:98:29: sparse: sparse: incorrect type in assignment (different address spaces) @@     expected void [noderef] __iomem *ptr @@     got void *userd @@
   drivers/gpu/drm/nouveau/nvif/chan.c:98:29: sparse:     expected void [noderef] __iomem *ptr
   drivers/gpu/drm/nouveau/nvif/chan.c:98:29: sparse:     got void *userd
   drivers/gpu/drm/nouveau/nvif/chan.c:100:30: sparse: sparse: incorrect type in assignment (different address spaces) @@     expected void [noderef] __iomem *ptr @@     got void *gpfifo @@
   drivers/gpu/drm/nouveau/nvif/chan.c:100:30: sparse:     expected void [noderef] __iomem *ptr
   drivers/gpu/drm/nouveau/nvif/chan.c:100:30: sparse:     got void *gpfifo
   drivers/gpu/drm/nouveau/nvif/chan.c:104:39: sparse: sparse: incorrect type in assignment (different address spaces) @@     expected void [noderef] __iomem *ptr @@     got void *push @@
   drivers/gpu/drm/nouveau/nvif/chan.c:104:39: sparse:     expected void [noderef] __iomem *ptr
   drivers/gpu/drm/nouveau/nvif/chan.c:104:39: sparse:     got void *push
   drivers/gpu/drm/nouveau/nvif/chan.c:116:32: sparse: sparse: cast removes address space '__iomem' of expression
   drivers/gpu/drm/nouveau/nvif/chan.c:152:22: sparse: sparse: cast removes address space '__iomem' of expression

vim +38 drivers/gpu/drm/nouveau/nvif/chan.c

     6	
     7	static void
     8	nvif_chan_gpfifo_push_kick(struct nvif_push *push)
     9	{
    10		struct nvif_chan *chan = container_of(push, typeof(*chan), push);
  > 11		u32 put = push->bgn - (u32 *)chan->push.mem.object.map.ptr;
    12		u32 cnt;
    13	
    14		if (chan->func->gpfifo.post) {
    15			if (push->end - push->cur < chan->func->gpfifo.post_size)
    16				push->end = push->cur + chan->func->gpfifo.post_size;
    17	
    18			WARN_ON(nvif_chan_gpfifo_post(chan));
    19		}
    20	
    21		cnt = push->cur - push->bgn;
    22	
    23		chan->func->gpfifo.push(chan, true, chan->push.addr + (put << 2), cnt << 2, false);
    24		chan->func->gpfifo.kick(chan);
    25	}
    26	
    27	static int
    28	nvif_chan_gpfifo_push_wait(struct nvif_push *push, u32 push_nr)
    29	{
    30		struct nvif_chan *chan = container_of(push, typeof(*chan), push);
    31	
    32		return nvif_chan_gpfifo_wait(chan, 1, push_nr);
    33	}
    34	
    35	int
    36	nvif_chan_gpfifo_post(struct nvif_chan *chan)
    37	{
  > 38		const u32 *map = chan->push.mem.object.map.ptr;
    39		const u32 pbptr = (chan->push.cur - map) + chan->func->gpfifo.post_size;
    40		const u32 gpptr = (chan->gpfifo.cur + 1) & chan->gpfifo.max;
    41	
    42		return chan->func->gpfifo.post(chan, gpptr, pbptr);
    43	}
    44	

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

                 reply	other threads:[~2025-12-12  5:23 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=202512121331.N9I5gDz3-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=airlied@redhat.com \
    --cc=bskeggs@nvidia.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=oe-kbuild-all@lists.linux.dev \
    --cc=ttabi@nvidia.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®