Merge v5.0-rc7 into drm-next
authorDave Airlie <airlied@redhat.com>
Mon, 18 Feb 2019 03:27:15 +0000 (13:27 +1000)
committerDave Airlie <airlied@redhat.com>
Mon, 18 Feb 2019 03:27:15 +0000 (13:27 +1000)
Backmerging for nouveau and imx that needed some fixes for next pulls.

Signed-off-by: Dave Airlie <airlied@redhat.com>
40 files changed:
1  2 
MAINTAINERS
drivers/acpi/pmic/intel_pmic_xpower.c
drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c
drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
drivers/gpu/drm/amd/amdgpu/nbio_v7_4.c
drivers/gpu/drm/amd/amdgpu/psp_v11_0.c
drivers/gpu/drm/amd/amdgpu/soc15.c
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_debugfs.c
drivers/gpu/drm/amd/display/dc/dce/dce_clk_mgr.c
drivers/gpu/drm/bridge/tc358767.c
drivers/gpu/drm/drm_atomic_uapi.c
drivers/gpu/drm/drm_fb_helper.c
drivers/gpu/drm/drm_lease.c
drivers/gpu/drm/drm_modes.c
drivers/gpu/drm/i915/gvt/handlers.c
drivers/gpu/drm/i915/gvt/hypercall.h
drivers/gpu/drm/i915/gvt/kvmgt.c
drivers/gpu/drm/i915/gvt/mpt.h
drivers/gpu/drm/i915/gvt/scheduler.c
drivers/gpu/drm/i915/gvt/scheduler.h
drivers/gpu/drm/i915/intel_opregion.c
drivers/gpu/drm/imx/imx-ldb.c
drivers/gpu/drm/meson/meson_crtc.c
drivers/gpu/drm/meson/meson_drv.c
drivers/gpu/drm/msm/msm_drv.h
drivers/gpu/drm/msm/msm_gem.c
drivers/gpu/drm/qxl/qxl_drv.c
drivers/gpu/drm/qxl/qxl_prime.c
drivers/gpu/drm/rockchip/rockchip_rgb.c
drivers/gpu/drm/sun4i/sun4i_backend.c
drivers/gpu/drm/sun4i/sun4i_hdmi_enc.c
drivers/gpu/drm/sun4i/sun4i_tcon.c
drivers/gpu/drm/virtio/virtgpu_drv.c
drivers/gpu/drm/virtio/virtgpu_drv.h
drivers/gpu/drm/vkms/vkms_crtc.c
drivers/gpu/drm/vkms/vkms_drv.c
drivers/gpu/drm/vkms/vkms_output.c
drivers/gpu/drm/vmwgfx/vmwgfx_drv.c
include/drm/drm_dp_mst_helper.h

diff --cc MAINTAINERS
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
index 5e01cc8d9b166a2992f5bd9b5b942065d380d9de,e1675a00df1269913ff73de8ab5ea17b20f6bb9e..4862fb12778e096fd35ee5e71b8b27dc87a1ba9e
@@@ -43,11 -38,10 +43,11 @@@ enum hypervisor_type 
   * both Xen and KVM by providing dedicated hypervisor-related MPT modules.
   */
  struct intel_gvt_mpt {
 +      enum hypervisor_type type;
        int (*host_init)(struct device *dev, void *gvt, const void *ops);
 -      void (*host_exit)(struct device *dev, void *gvt);
 +      void (*host_exit)(struct device *dev);
        int (*attach_vgpu)(void *vgpu, unsigned long *handle);
-       void (*detach_vgpu)(unsigned long handle);
+       void (*detach_vgpu)(void *vgpu);
        int (*inject_msi)(unsigned long handle, u32 addr, u16 data);
        unsigned long (*from_virt_to_mfn)(void *p);
        int (*enable_page_track)(unsigned long handle, u64 gfn);
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
index 22e1faf0473aa625b1d72fdbda8c12f29d28d4af,df65d3c1a7b892a23470ba502173a8b75f8d1bd0..8b448eca1cd996a4ffba1931e369b9ba02fc4ad6
@@@ -37,36 -35,13 +37,22 @@@ int qxl_gem_prime_pin(struct drm_gem_ob
  
  void qxl_gem_prime_unpin(struct drm_gem_object *obj)
  {
 -      WARN_ONCE(1, "not implemented");
 +      struct qxl_bo *bo = gem_to_qxl_bo(obj);
 +
 +      qxl_bo_unpin(bo);
  }
  
- struct sg_table *qxl_gem_prime_get_sg_table(struct drm_gem_object *obj)
- {
-       WARN_ONCE(1, "not implemented");
-       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)
- {
-       WARN_ONCE(1, "not implemented");
-       return ERR_PTR(-ENOSYS);
- }
  void *qxl_gem_prime_vmap(struct drm_gem_object *obj)
  {
 -      WARN_ONCE(1, "not implemented");
 -      return ERR_PTR(-ENOSYS);
 +      struct qxl_bo *bo = gem_to_qxl_bo(obj);
 +      void *ptr;
 +      int ret;
 +
 +      ret = qxl_bo_kmap(bo, &ptr);
 +      if (ret < 0)
 +              return ERR_PTR(ret);
 +
 +      return ptr;
  }
  
  void qxl_gem_prime_vunmap(struct drm_gem_object *obj, void *vaddr)
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
index c5b16efed51ab1f9de90792892ba4d38c0f0e89f,4173e4f483341307965aeed3c9a20376d8ae9f2f..3b162b25312ece5932e0e1befcbbc968925815a1
@@@ -1,14 -1,8 +1,8 @@@
- // SPDX-License-Identifier: GPL-2.0
- /*
-  * This program is free software; you can redistribute it and/or modify
-  * it under the terms of the GNU General Public License as published by
-  * the Free Software Foundation; either version 2 of the License, or
-  * (at your option) any later version.
-  */
+ // SPDX-License-Identifier: GPL-2.0+
  
  #include "vkms_drv.h"
 -#include <drm/drm_crtc_helper.h>
  #include <drm/drm_atomic_helper.h>
 +#include <drm/drm_probe_helper.h>
  
  static void vkms_connector_destroy(struct drm_connector *connector)
  {
Simple merge
index 451d020f0137b924218967990bf7e76a62141041,727af08e5ea6fc356d04d5539aeb5fe1d2cf2fcd..8c97a5f92c470384a3dbd96deac600233f40d93a
@@@ -641,118 -616,17 +641,119 @@@ void drm_dp_mst_dump_topology(struct se
                              struct drm_dp_mst_topology_mgr *mgr);
  
  void drm_dp_mst_topology_mgr_suspend(struct drm_dp_mst_topology_mgr *mgr);
- int drm_dp_mst_topology_mgr_resume(struct drm_dp_mst_topology_mgr *mgr);
+ int __must_check
+ drm_dp_mst_topology_mgr_resume(struct drm_dp_mst_topology_mgr *mgr);
  struct drm_dp_mst_topology_state *drm_atomic_get_mst_topology_state(struct drm_atomic_state *state,
                                                                    struct drm_dp_mst_topology_mgr *mgr);
 -int drm_dp_atomic_find_vcpi_slots(struct drm_atomic_state *state,
 -                                struct drm_dp_mst_topology_mgr *mgr,
 -                                struct drm_dp_mst_port *port, int pbn);
 -int drm_dp_atomic_release_vcpi_slots(struct drm_atomic_state *state,
 -                                   struct drm_dp_mst_topology_mgr *mgr,
 -                                   int slots);
 +int __must_check
 +drm_dp_atomic_find_vcpi_slots(struct drm_atomic_state *state,
 +                            struct drm_dp_mst_topology_mgr *mgr,
 +                            struct drm_dp_mst_port *port, int pbn);
 +int __must_check
 +drm_dp_atomic_release_vcpi_slots(struct drm_atomic_state *state,
 +                               struct drm_dp_mst_topology_mgr *mgr,
 +                               struct drm_dp_mst_port *port);
  int drm_dp_send_power_updown_phy(struct drm_dp_mst_topology_mgr *mgr,
                                 struct drm_dp_mst_port *port, bool power_up);
 +int __must_check drm_dp_mst_atomic_check(struct drm_atomic_state *state);
 +
 +void drm_dp_mst_get_port_malloc(struct drm_dp_mst_port *port);
 +void drm_dp_mst_put_port_malloc(struct drm_dp_mst_port *port);
 +
 +extern const struct drm_private_state_funcs drm_dp_mst_topology_state_funcs;
 +
 +/**
 + * __drm_dp_mst_state_iter_get - private atomic state iterator function for
 + * macro-internal use
 + * @state: &struct drm_atomic_state pointer
 + * @mgr: pointer to the &struct drm_dp_mst_topology_mgr iteration cursor
 + * @old_state: optional pointer to the old &struct drm_dp_mst_topology_state
 + * iteration cursor
 + * @new_state: optional pointer to the new &struct drm_dp_mst_topology_state
 + * iteration cursor
 + * @i: int iteration cursor, for macro-internal use
 + *
 + * Used by for_each_oldnew_mst_mgr_in_state(),
 + * for_each_old_mst_mgr_in_state(), and for_each_new_mst_mgr_in_state(). Don't
 + * call this directly.
 + *
 + * Returns:
 + * True if the current &struct drm_private_obj is a &struct
 + * drm_dp_mst_topology_mgr, false otherwise.
 + */
 +static inline bool
 +__drm_dp_mst_state_iter_get(struct drm_atomic_state *state,
 +                          struct drm_dp_mst_topology_mgr **mgr,
 +                          struct drm_dp_mst_topology_state **old_state,
 +                          struct drm_dp_mst_topology_state **new_state,
 +                          int i)
 +{
 +      struct __drm_private_objs_state *objs_state = &state->private_objs[i];
 +
 +      if (objs_state->ptr->funcs != &drm_dp_mst_topology_state_funcs)
 +              return false;
 +
 +      *mgr = to_dp_mst_topology_mgr(objs_state->ptr);
 +      if (old_state)
 +              *old_state = to_dp_mst_topology_state(objs_state->old_state);
 +      if (new_state)
 +              *new_state = to_dp_mst_topology_state(objs_state->new_state);
 +
 +      return true;
 +}
 +
 +/**
 + * for_each_oldnew_mst_mgr_in_state - iterate over all DP MST topology
 + * managers in an atomic update
 + * @__state: &struct drm_atomic_state pointer
 + * @mgr: &struct drm_dp_mst_topology_mgr iteration cursor
 + * @old_state: &struct drm_dp_mst_topology_state iteration cursor for the old
 + * state
 + * @new_state: &struct drm_dp_mst_topology_state iteration cursor for the new
 + * state
 + * @__i: int iteration cursor, for macro-internal use
 + *
 + * This iterates over all DRM DP MST topology managers in an atomic update,
 + * tracking both old and new state. This is useful in places where the state
 + * delta needs to be considered, for example in atomic check functions.
 + */
 +#define for_each_oldnew_mst_mgr_in_state(__state, mgr, old_state, new_state, __i) \
 +      for ((__i) = 0; (__i) < (__state)->num_private_objs; (__i)++) \
 +              for_each_if(__drm_dp_mst_state_iter_get((__state), &(mgr), &(old_state), &(new_state), (__i)))
 +
 +/**
 + * for_each_old_mst_mgr_in_state - iterate over all DP MST topology managers
 + * in an atomic update
 + * @__state: &struct drm_atomic_state pointer
 + * @mgr: &struct drm_dp_mst_topology_mgr iteration cursor
 + * @old_state: &struct drm_dp_mst_topology_state iteration cursor for the old
 + * state
 + * @__i: int iteration cursor, for macro-internal use
 + *
 + * This iterates over all DRM DP MST topology managers in an atomic update,
 + * tracking only the old state. This is useful in disable functions, where we
 + * need the old state the hardware is still in.
 + */
 +#define for_each_old_mst_mgr_in_state(__state, mgr, old_state, __i) \
 +      for ((__i) = 0; (__i) < (__state)->num_private_objs; (__i)++) \
 +              for_each_if(__drm_dp_mst_state_iter_get((__state), &(mgr), &(old_state), NULL, (__i)))
 +
 +/**
 + * for_each_new_mst_mgr_in_state - iterate over all DP MST topology managers
 + * in an atomic update
 + * @__state: &struct drm_atomic_state pointer
 + * @mgr: &struct drm_dp_mst_topology_mgr iteration cursor
 + * @new_state: &struct drm_dp_mst_topology_state iteration cursor for the new
 + * state
 + * @__i: int iteration cursor, for macro-internal use
 + *
 + * This iterates over all DRM DP MST topology managers in an atomic update,
 + * tracking only the new state. This is useful in enable functions, where we
 + * need the new state the hardware should be in when the atomic commit
 + * operation has completed.
 + */
 +#define for_each_new_mst_mgr_in_state(__state, mgr, new_state, __i) \
 +      for ((__i) = 0; (__i) < (__state)->num_private_objs; (__i)++) \
 +              for_each_if(__drm_dp_mst_state_iter_get((__state), &(mgr), NULL, &(new_state), (__i)))
  
  #endif