Merge tag ‘drm-misc-fixes-2019-05-02’ of git://anongit.freedesktop.org/drm/drm-misc into drm-fixes [Linux 5.1]

Merge tag ‘drm-misc-fixes-2019-05-02’ of git://anongit.freedesktop.org/drm/drm-misc into drm-fixes [Linux 5.1]

This Linux kernel change "Merge tag ‘drm-misc-fixes-2019-05-02’ of git://anongit.freedesktop.org/drm/drm-misc into drm-fixes" is included in the Linux 5.1 release. This change is authored by Dave Airlie <airlied [at] redhat.com> on Fri May 3 09:36:24 2019 +1000. The commit for this change in Linux stable tree is 1daa044 (patch). Other info about this change: Merge: 37624b5 ab042b8

Merge tag 'drm-misc-fixes-2019-05-02' of git://anongit.freedesktop.org/drm/drm-misc into drm-fixes

- One revert for QXL for a DRI3 breakage

Signed-off-by: Dave Airlie <[email protected]>

From: Maxime Ripard <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]

There is no are 0 lines of Linux source code added/deleted in this change. Code changes to Linux kernel are as follows.

 drivers/gpu/drm/qxl/qxl_drv.c   |  4 ++++
 drivers/gpu/drm/qxl/qxl_prime.c | 12 ++++++++++++
 2 files changed, 16 insertions(+)

diff --git a/drivers/gpu/drm/qxl/qxl_drv.c b/drivers/gpu/drm/qxl/qxl_drv.c
index 578d867a..f33e349 100644
--- a/drivers/gpu/drm/qxl/qxl_drv.c
+++ b/drivers/gpu/drm/qxl/qxl_drv.c
@@ -255,10 +255,14 @@ static int qxl_pm_restore(struct device *dev)
 #if defined(CONFIG_DEBUG_FS)
    .debugfs_init = qxl_debugfs_init,
 #endif
+   .prime_handle_to_fd = drm_gem_prime_handle_to_fd,
+   .prime_fd_to_handle = drm_gem_prime_fd_to_handle,
    .gem_prime_export = drm_gem_prime_export,
    .gem_prime_import = drm_gem_prime_import,
    .gem_prime_pin = qxl_gem_prime_pin,
    .gem_prime_unpin = qxl_gem_prime_unpin,
+   .gem_prime_get_sg_table = qxl_gem_prime_get_sg_table,
+   .gem_prime_import_sg_table = qxl_gem_prime_import_sg_table,
    .gem_prime_vmap = qxl_gem_prime_vmap,
    .gem_prime_vunmap = qxl_gem_prime_vunmap,
    .gem_prime_mmap = qxl_gem_prime_mmap,
diff --git a/drivers/gpu/drm/qxl/qxl_prime.c b/drivers/gpu/drm/qxl/qxl_prime.c
index 8b448ec..114653b 100644
--- a/drivers/gpu/drm/qxl/qxl_prime.c
+++ b/drivers/gpu/drm/qxl/qxl_prime.c
@@ -42,6 +42,18 @@ void qxl_gem_prime_unpin(struct drm_gem_object *obj)
    qxl_bo_unpin(bo);
 }

+struct sg_table *qxl_gem_prime_get_sg_table(struct drm_gem_object *obj)
+{
+   return ERR_PTR(-ENOSYS);
+}
+
+struct drm_gem_object *qxl_gem_prime_import_sg_table(
+   struct drm_device *dev, struct dma_buf_attachment *attach,
+   struct sg_table *table)
+{
+   return ERR_PTR(-ENOSYS);
+}
+
 void *qxl_gem_prime_vmap(struct drm_gem_object *obj)
 {
    struct qxl_bo *bo = gem_to_qxl_bo(obj);

Leave a Reply

Your email address will not be published. Required fields are marked *