Skip to content

Commit 2507789

Browse files
kraxelmstsirkin
authored andcommitted
drm/virtio: implement virtio_gpu_shutdown
Calling drm_dev_unplug() is the drm way to say the device is gone and can not be accessed any more. Cc: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Reviewed-by: Eric Auger <eric.auger@redhat.com> Tested-by: Eric Auger <eric.auger@redhat.com> Message-Id: <20250507082821.2710706-1-kraxel@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
1 parent 89a216e commit 2507789

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

drivers/gpu/drm/virtio/virtgpu_drv.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -130,10 +130,10 @@ static void virtio_gpu_remove(struct virtio_device *vdev)
130130

131131
static void virtio_gpu_shutdown(struct virtio_device *vdev)
132132
{
133-
/*
134-
* drm does its own synchronization on shutdown.
135-
* Do nothing here, opt out of device reset.
136-
*/
133+
struct drm_device *dev = vdev->priv;
134+
135+
/* stop talking to the device */
136+
drm_dev_unplug(dev);
137137
}
138138

139139
static void virtio_gpu_config_changed(struct virtio_device *vdev)

0 commit comments

Comments
 (0)