On 07/20/2018 05:08 PM, Boris Ostrovsky wrote:Now I see this warning which seems to be a false positive.
On 07/20/2018 05:01 AM, Oleksandr Andrushchenko wrote:The above warnings already have a fix [1] which is expected in 4.19
From: Oleksandr Andrushchenko <oleksandr_andrushchenko@xxxxxxxx>
This work is in response to my previous attempt to introduce Xen/DRM
zero-copy driver [1] to enable Linux dma-buf API [2] for Xen based
frontends/backends. There is also an existing hyper_dmabuf approach
available [3] which, if reworked to utilize the proposed solution,
can greatly benefit as well.
Lot of warnings on i386 build:
In file included from
/data/upstream/linux-xen/drivers/gpu/drm/xen/xen_drm_front.c:24:
/data/upstream/linux-xen/drivers/gpu/drm/xen/xen_drm_front.h: In
function âxen_drm_front_fb_to_cookieâ:
/data/upstream/linux-xen/drivers/gpu/drm/xen/xen_drm_front.h:129:9:
warning: cast from pointer to integer of different size
[-Wpointer-to-int-cast]
ÂÂ return (u64)fb;
ÂÂÂÂÂÂÂÂÂ ^
/data/upstream/linux-xen/drivers/gpu/drm/xen/xen_drm_front.h: In
function âxen_drm_front_dbuf_to_cookieâ:
/data/upstream/linux-xen/drivers/gpu/drm/xen/xen_drm_front.h:134:9:
warning: cast from pointer to integer of different size
[-Wpointer-to-int-cast]
ÂÂ return (u64)gem_obj;
ÂÂÂÂÂÂÂÂÂ ^
ÂÂ CC [M]Â net/netfilter/ipset/ip_set_hash_ipport.o
ÂÂ CCÂÂÂÂÂ drivers/media/rc/keymaps/rc-tango.o
ÂÂ CC [M]Â drivers/gpu/drm/vmwgfx/vmwgfx_fifo.o
ÂÂ ARÂÂÂÂÂ drivers/misc/built-in.a
In file included from
/data/upstream/linux-xen/drivers/gpu/drm/xen/xen_drm_front_kms.c:20:
/data/upstream/linux-xen/drivers/gpu/drm/xen/xen_drm_front.h: In
function âxen_drm_front_fb_to_cookieâ:
ÂÂ CC [M]Â drivers/gpu/drm/xen/xen_drm_front_conn.o
/data/upstream/linux-xen/drivers/gpu/drm/xen/xen_drm_front.h:129:9:
warning: cast from pointer to integer of different size
[-Wpointer-to-int-cast]
ÂÂ return (u64)fb;
(and more)
Strangely, but my i386 build goes smooth.
and then
data/upstream/linux-xen/drivers/xen/gntdev-dmabuf.c: In function
âgntdev_ioctl_dmabuf_exp_from_refsâ:
/data/upstream/linux-xen/drivers/xen/gntdev-dmabuf.c:503:6: warning:
âargs.fdâ may be used uninitialized in this function [-Wmaybe-uninitialized]
ÂÂ *fd = args.fd;
ÂÂ ~~~~^~~~~~~~~
/data/upstream/linux-xen/drivers/xen/gntdev-dmabuf.c:467:35: note:
âargs.fdâ was declared here
ÂÂ struct gntdev_dmabuf_export_args args;
ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂ ^~~~
Which version of gcc you use and could you please give me your
.config, so I can test the same?
Thank you,
-boris
Oleksandr
[1] https://cgit.freedesktop.org/drm/drm-misc/commit/?id=9eece5d9c6e0316f17091e37ff3ec87331bdedf3