stubs: Add stubs for udmabuf helpers
This is needed to ensure that virtio-gpu device works for non-linux builds. Cc: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Vivek Kasireddy <vivek.kasireddy@intel.com> Message-Id: <20210526231429.1045476-5-vivek.kasireddy@intel.com> [ kraxel: add virtio-gpu-udmabuf.c stubs only when building system emulation ] Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
This commit is contained in:
parent
9b60cdf987
commit
9192a40655
@ -1899,7 +1899,7 @@ util_ss.add_all(trace_ss)
|
|||||||
util_ss = util_ss.apply(config_all, strict: false)
|
util_ss = util_ss.apply(config_all, strict: false)
|
||||||
libqemuutil = static_library('qemuutil',
|
libqemuutil = static_library('qemuutil',
|
||||||
sources: util_ss.sources() + stub_ss.sources() + genh,
|
sources: util_ss.sources() + stub_ss.sources() + genh,
|
||||||
dependencies: [util_ss.dependencies(), m, glib, socket, malloc])
|
dependencies: [util_ss.dependencies(), m, glib, socket, malloc, pixman])
|
||||||
qemuutil = declare_dependency(link_with: libqemuutil,
|
qemuutil = declare_dependency(link_with: libqemuutil,
|
||||||
sources: genh + version_res)
|
sources: genh + version_res)
|
||||||
|
|
||||||
|
@ -52,6 +52,7 @@ if have_system
|
|||||||
stub_ss.add(files('semihost.c'))
|
stub_ss.add(files('semihost.c'))
|
||||||
stub_ss.add(files('usb-dev-stub.c'))
|
stub_ss.add(files('usb-dev-stub.c'))
|
||||||
stub_ss.add(files('xen-hw-stub.c'))
|
stub_ss.add(files('xen-hw-stub.c'))
|
||||||
|
stub_ss.add(files('virtio-gpu-udmabuf.c'))
|
||||||
else
|
else
|
||||||
stub_ss.add(files('qdev.c'))
|
stub_ss.add(files('qdev.c'))
|
||||||
endif
|
endif
|
||||||
|
18
stubs/virtio-gpu-udmabuf.c
Normal file
18
stubs/virtio-gpu-udmabuf.c
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
#include "qemu/osdep.h"
|
||||||
|
#include "hw/virtio/virtio-gpu.h"
|
||||||
|
|
||||||
|
bool virtio_gpu_have_udmabuf(void)
|
||||||
|
{
|
||||||
|
/* nothing (stub) */
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
void virtio_gpu_init_udmabuf(struct virtio_gpu_simple_resource *res)
|
||||||
|
{
|
||||||
|
/* nothing (stub) */
|
||||||
|
}
|
||||||
|
|
||||||
|
void virtio_gpu_fini_udmabuf(struct virtio_gpu_simple_resource *res)
|
||||||
|
{
|
||||||
|
/* nothing (stub) */
|
||||||
|
}
|
Loading…
x
Reference in New Issue
Block a user