virtio-gpu: disallow vIOMMU
-----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (GNU/Linux) iQIcBAABAgAGBQJadCH4AAoJEEy22O7T6HE4BL0P/i7dew95tTYJLobhXv/ThYGM omouEZA55K7nrQuLHi9vAbAVw7bRQZrxOdOnRjdqFsp/pTKK57gOJ9YE/P50BGh0 ukkdNht+QB+EEVYT1jh5vQLHjS26eHiK2KQBF15juZzZPCNA95SLBKNDH88eXZUN NkU3MkVbPD9ppHnWiCiAdjY8+raheL8gAkpQHY07S9tphZRnt4aVLa1/ChKSl8N0 1Xcef7VrVDy4oZ+aIu7sqFCO3+z6VTR3qApT89V6TRLlqs32hHOoZRxI6nyIhSrm wUV+lfz4+K5JMvZXN+XBt1PSvLfHDqKhXvXGTu3Yv7HdUCraUkwibqJZBmOTUb5M uAglVAv2VO24NVEj3E4246sXqabqVj3+vmGFAprYecjl6NbVllsI9mZ3kD26Qylk eoLrt3DtBDZEwCkz/zYlMBDD18mGnpa/gerGvtw+wbNkajWugQFkHkE2SBjhds8o RKSLc3a6WtWPGT8qnXeOI9V3PqdGNUugYhsZKa1DMkY7WvabYMDYSn1+nBVZu/gz 9bHF05ttN9i5NLKqeX3U6x7IxzP/LoAiNCRjFVjCBT08zzodtUNpScPP8xDEhTFq X5jZqDC6wK+sNlgWc0mggu+VoL37k1aXBTIYyJHZlrFDMmtxqvO26wWVFzq5LbQZ QTSsch6xo1z9G2R1C2C/ =reIz -----END PGP SIGNATURE----- Merge remote-tracking branch 'remotes/kraxel/tags/vga-20180202-pull-request' into staging virtio-gpu: disallow vIOMMU # gpg: Signature made Fri 02 Feb 2018 08:31:52 GMT # gpg: using RSA key 4CB6D8EED3E87138 # gpg: Good signature from "Gerd Hoffmann (work) <kraxel@redhat.com>" # gpg: aka "Gerd Hoffmann <gerd@kraxel.org>" # gpg: aka "Gerd Hoffmann (private) <kraxel@gmail.com>" # Primary key fingerprint: A032 8CFF B93A 17A7 9901 FE7D 4CB6 D8EE D3E8 7138 * remotes/kraxel/tags/vga-20180202-pull-request: virtio-gpu: disallow vIOMMU Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
commit
fb2516ef94
@ -28,10 +28,16 @@ static void virtio_gpu_pci_realize(VirtIOPCIProxy *vpci_dev, Error **errp)
|
||||
VirtIOGPU *g = &vgpu->vdev;
|
||||
DeviceState *vdev = DEVICE(&vgpu->vdev);
|
||||
int i;
|
||||
Error *local_error = NULL;
|
||||
|
||||
qdev_set_parent_bus(vdev, BUS(&vpci_dev->bus));
|
||||
virtio_pci_force_virtio_1(vpci_dev);
|
||||
object_property_set_bool(OBJECT(vdev), true, "realized", errp);
|
||||
object_property_set_bool(OBJECT(vdev), true, "realized", &local_error);
|
||||
|
||||
if (local_error) {
|
||||
error_propagate(errp, local_error);
|
||||
return;
|
||||
}
|
||||
|
||||
for (i = 0; i < g->conf.max_outputs; i++) {
|
||||
object_property_set_link(OBJECT(g->scanout[i].con),
|
||||
|
@ -1173,6 +1173,11 @@ static void virtio_gpu_device_realize(DeviceState *qdev, Error **errp)
|
||||
Error *local_err = NULL;
|
||||
int i;
|
||||
|
||||
if (virtio_host_has_feature(vdev, VIRTIO_F_IOMMU_PLATFORM)) {
|
||||
error_setg(errp, "virtio-gpu does not support vIOMMU yet");
|
||||
return;
|
||||
}
|
||||
|
||||
if (g->conf.max_outputs > VIRTIO_GPU_MAX_SCANOUTS) {
|
||||
error_setg(errp, "invalid max_outputs > %d", VIRTIO_GPU_MAX_SCANOUTS);
|
||||
return;
|
||||
|
Loading…
Reference in New Issue
Block a user