All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Michael S. Tsirkin" <mst@redhat.com>
To: Gerd Hoffmann <kraxel@redhat.com>
Cc: Jiri Slaby <jslaby@suse.cz>,
	virtualization@lists.linux-foundation.org,
	Linux kernel mailing list <linux-kernel@vger.kernel.org>,
	David Airlie <airlied@linux.ie>,
	dri-devel@lists.freedesktop.org
Subject: virtio gpu sparse warning
Date: Thu, 24 Nov 2016 04:57:11 +0200	[thread overview]
Message-ID: <20161124045101-mutt-send-email-mst@kernel.org> (raw)
In-Reply-To: <1479301975.25611.23.camel@redhat.com>

sparse produces these warnings:

drivers/gpu/drm/virtio/virtgpu_fb.c:340:27: warning: incorrect type in
assignment (different address spaces)
drivers/gpu/drm/virtio/virtgpu_fb.c:340:27:    expected char [noderef]
<asn:2>*screen_base
drivers/gpu/drm/virtio/virtgpu_fb.c:340:27:    got void *vmap

This is because the expected type is void __iomem *, while
virtio gpu object is void *vmap.

We could just cast the warning away but I'm not sure this
is not a symptom of an actual problem. For example, might
some code call iounmap on this address?

-- 
MST

WARNING: multiple messages have this Message-ID (diff)
From: "Michael S. Tsirkin" <mst@redhat.com>
To: Gerd Hoffmann <kraxel@redhat.com>
Cc: David Airlie <airlied@linux.ie>, Jiri Slaby <jslaby@suse.cz>,
	Linux kernel mailing list <linux-kernel@vger.kernel.org>,
	dri-devel@lists.freedesktop.org,
	virtualization@lists.linux-foundation.org
Subject: virtio gpu sparse warning
Date: Thu, 24 Nov 2016 04:57:11 +0200	[thread overview]
Message-ID: <20161124045101-mutt-send-email-mst@kernel.org> (raw)
In-Reply-To: <1479301975.25611.23.camel@redhat.com>

sparse produces these warnings:

drivers/gpu/drm/virtio/virtgpu_fb.c:340:27: warning: incorrect type in
assignment (different address spaces)
drivers/gpu/drm/virtio/virtgpu_fb.c:340:27:    expected char [noderef]
<asn:2>*screen_base
drivers/gpu/drm/virtio/virtgpu_fb.c:340:27:    got void *vmap

This is because the expected type is void __iomem *, while
virtio gpu object is void *vmap.

We could just cast the warning away but I'm not sure this
is not a symptom of an actual problem. For example, might
some code call iounmap on this address?

-- 
MST

  reply	other threads:[~2016-11-24  2:57 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-07  8:43 BUG: 'list_empty(&vgdev->free_vbufs)' is true! Jiri Slaby
2016-11-08 20:37 ` Michael S. Tsirkin
2016-11-08 20:37   ` Michael S. Tsirkin
2016-11-09  8:01   ` Gerd Hoffmann
2016-11-09  8:01     ` Gerd Hoffmann
2016-11-11 16:28     ` Jiri Slaby
2016-11-11 16:28     ` Jiri Slaby
2016-11-15  8:46       ` Gerd Hoffmann
2016-11-15  8:46       ` Gerd Hoffmann
2016-11-15  8:46         ` Gerd Hoffmann
2016-11-15  8:55         ` Jiri Slaby
2016-11-15  8:55         ` Jiri Slaby
2016-11-15  8:55           ` Jiri Slaby
2016-11-15  9:05           ` Gerd Hoffmann
2016-11-15  9:05           ` Gerd Hoffmann
2016-11-16 13:12       ` Gerd Hoffmann
2016-11-16 13:12         ` Gerd Hoffmann
2016-11-24  2:57         ` Michael S. Tsirkin [this message]
2016-11-24  2:57           ` virtio gpu sparse warning Michael S. Tsirkin
2016-11-28  7:50           ` Gerd Hoffmann
2016-11-28  7:50           ` Gerd Hoffmann
2016-11-28  7:50             ` Gerd Hoffmann
2016-12-15 13:01         ` BUG: 'list_empty(&vgdev->free_vbufs)' is true! Jiri Slaby
2016-12-15 13:01           ` Jiri Slaby
2016-11-11 14:35   ` Jiri Slaby
2016-11-11 14:35   ` Jiri Slaby
2016-11-08 20:37 ` Michael S. Tsirkin

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=20161124045101-mutt-send-email-mst@kernel.org \
    --to=mst@redhat.com \
    --cc=airlied@linux.ie \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=jslaby@suse.cz \
    --cc=kraxel@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=virtualization@lists.linux-foundation.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.