1. 26 Sep, 2018 2 commits
  2. 25 Sep, 2018 16 commits
  3. 21 Sep, 2018 4 commits
  4. 20 Sep, 2018 2 commits
  5. 19 Sep, 2018 7 commits
  6. 14 Sep, 2018 2 commits
  7. 13 Sep, 2018 5 commits
  8. 12 Sep, 2018 2 commits
    • Maxime Ripard's avatar
      drm/sun4i: fix build failure with CONFIG_DRM_SUN8I_MIXER=m · 185e0beb
      Maxime Ripard authored
      Having DRM_SUN4I built-in but DRM_SUN8I_MIXER as a loadable module results in
      a link error, as we try to access a symbol from the sun8i_tcon_top.ko module:
      
      ERROR: "sun8i_tcon_top_de_config" [drivers/gpu/drm/sun4i/sun4i-tcon.ko] undefined!
      ERROR: "sun8i_tcon_top_set_hdmi_src" [drivers/gpu/drm/sun4i/sun4i-tcon.ko] undefined!
      ERROR: "sun8i_tcon_top_of_table" [drivers/gpu/drm/sun4i/sun4i-tcon.ko] undefined!
      
      This solves the problem by adding a silent symbol for the tcon_top module,
      building it as a separate module in exactly the cases that we need it,
      but in a way that it is reachable by the other modules.
      
      Fixes: cf77d79b ("drm/sun4i: tcon: Add another way for matching mixers with tcon")
      Fixes: 0305189a ("drm/sun4i: tcon: Add support for R40 TCON")
      Reviewed-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
      Tested-by: default avatarJon Hunter <jonathanh@nvidia.com>
      Tested-by: default avatarMatt Hart <matthew.hart@linaro.org>
      Signed-off-by: default avatarMaxime Ripard <maxime.ripard@bootlin.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20180911113325.11024-1-maxime.ripard@bootlin.com
      185e0beb
    • Peter Wu's avatar
      qxl: refactor to use drm_fb_helper_fbdev_setup · bf8744e4
      Peter Wu authored
      Lots of code can be removed by relying on fb-helper:
      - "struct drm_framebuffer" moves to fb_helper.fb.
      - "struct drm_gem_object" moves to fb_helper.obj[0].
      - "struct qxl_device" can be inferred as drm_fb_helper is embedded.
      - qxl_user_framebuffer_create -> drm_gem_fb_create.
      - qxl_user_framebuffer_destroy -> drm_gem_fb_destroy.
      - qxl_fbdev_destroy -> drm_fb_helper_fbdev_teardown + vfree(shadow).
      
      Remove unused code:
      - qxl_fbdev_qobj_is_fb, qxl_fbdev_set_suspend.
      - Unused fields of qxl_fbdev: delayed_ops, delayed_ops_lock, size.
      
      Misc notes:
      - The dirty callback is preserved as it is necessary to trigger update
        commands in the hw (the screen stays black otherwise).
      - No idea when .create_handle in drm_framebuffer_funcs is used, but use
        the same drm_gem_fb_create_handle to match drm_gem_fb_funcs.
      - I don't know why qxl_fb_find_or_create_single used to check for an
        existing framebuffer and removed that check to match other drivers.
      - Use of drm_fb_helper_fbdev_teardown also requires "info->fbdefio" to
        be dynamically allocated. Replace the existing defio config by
        drm_fb_helper_defio_init to accomodate this.
      
      Testing results: startx with fbdev, modesetting and qxl all seems to
      work. Tested also with CONFIG_DRM_FBDEV_EMULATION=n, fbdev obviously
      fails but others are fine. QEMU -spice and QEMU -spice with vdagent and
      multiple (resized) displays (via remote-viewer) also works.
      unbind vtconsole and rmmod has *not* regressed (i.e. it still trips on a
      use-after-free in qxl_check_idle via qxl_ttm_fini).
      
      Ideally setup/teardown is replaced by drm_fbdev_generic_setup as that
      would result in further code reduction, improve error handling (like not
      leaking shadow memory), but unfortunately QXL has no implementation for
      qxl_gem_prime_vmap.
      Signed-off-by: default avatarPeter Wu <peter@lekensteyn.nl>
      Link: http://patchwork.freedesktop.org/patch/msgid/20180910132156.23201-1-peter@lekensteyn.nlSigned-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
      bf8744e4