Skip to content
  1. Jan 17, 2019
  2. Jan 16, 2019
  3. Jan 15, 2019
  4. Jan 11, 2019
  5. Jan 10, 2019
    • José Roberto de Souza's avatar
      drm: Fix documentation generation for DP_DPCD_QUIRK_NO_PSR · f299e0bd
      José Roberto de Souza authored
      The DP_DPCD_QUIRK_NO_PSR comment is missing colon causing this
      warning when generating kernel documentation.
      
      ./include/drm/drm_dp_helper.h:1374: warning: Incorrect use of kernel-doc format:          * @DP_DPCD_QUIRK_NO_PSR
      
      Fixes: 1035f4a6
      
       ("drm/i915: Disable PSR in Apple panels")
      Cc: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
      Signed-off-by: default avatarJosé Roberto de Souza <jose.souza@intel.com>
      Reviewed-by: default avatarDhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20181205184850.13218-1-jose.souza@intel.com
      (cherry picked from commit ed17b555
      
      )
      Signed-off-by: default avatarJani Nikula <jani.nikula@intel.com>
      f299e0bd
    • Daniele Ceraolo Spurio's avatar
      drm/i915: init per-engine WAs for all engines · 70e31424
      Daniele Ceraolo Spurio authored
      commit 4a15c75c ("drm/i915: Introduce per-engine workarounds")
      refactored the workaround code to have functions per-engine, but didn't
      call any of them from logical_xcs_ring_init. Since we do have a non-RCS
      workaround for KBL (WaKBLVECSSemaphoreWaitPoll) we do need to call
      intel_engine_init_workarounds for non-RCS engines.
      Note that whitelist is still RCS-only.
      
      v2: move the call to logical_ring_init (Chris)
      
      Fixes: 4a15c75c
      
       ("drm/i915: Introduce per-engine workarounds")
      Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
      Cc: Chris Wilson <chris@chris-wilson.co.uk>
      Signed-off-by: default avatarDaniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
      Reviewed-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
      Signed-off-by: default avatarTvrtko Ursulin <tvrtko.ursulin@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20190110013232.8972-2-daniele.ceraolospurio@intel.com
      (cherry picked from commit a60acb22
      
      )
      Signed-off-by: default avatarJani Nikula <jani.nikula@intel.com>
      70e31424
    • Chris Wilson's avatar
      drm/i915: Unwind failure on pinning the gen7 ppgtt · 280d479b
      Chris Wilson authored
      If we fail to pin the ggtt vma slot for the ppgtt page tables, we need
      to unwind the locals before reporting the error. Or else on subsequent
      attempts to bind the page tables into the ggtt, we will already believe
      that the vma has been pinned and continue on blithely. If something else
      should happen to be at that location, choas ensues.
      
      Fixes: a2bbf714
      
       ("drm/i915/gtt: Only keep gen6 page directories pinned while active")
      Signed-off-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
      Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
      Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
      Cc: Matthew Auld <matthew.william.auld@gmail.com>
      Cc: <stable@vger.kernel.org> # v4.19+
      Reviewed-by: default avatarMatthew Auld <matthew.william.auld@gmail.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20181222030623.21710-1-chris@chris-wilson.co.uk
      (cherry picked from commit d4de7535
      
      )
      Signed-off-by: default avatarJani Nikula <jani.nikula@intel.com>
      280d479b
    • Chris Wilson's avatar
      drm/i915: Skip the ERR_PTR error state · 107c595c
      Chris Wilson authored
      Although commit fb6f0b64 ("drm/i915: Prevent machine hang from
      Broxton's vtd w/a and error capture") applied cleanly after a 24 month
      hiatus, the code had moved on with new methods for peeking and fetching
      the captured gpu info. Make sure we catch all uses of the stashed error
      state and avoid dereferencing the error pointer.
      
      v2: Move error pointer determination into i915_gpu_capture_state
      v3: Restore early check to avoid capturing and then throwing away
      subsequent GPU error states.
      
      Fixes: fb6f0b64
      
       ("drm/i915: Prevent machine hang from Broxton's vtd w/a and error capture")
      Signed-off-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
      Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
      Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
      Reviewed-by: default avatarTvrtko Ursulin <tvrtko.ursulin@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20181207110554.19897-1-chris@chris-wilson.co.uk
      (cherry picked from commit e6154e4c
      
      )
      Signed-off-by: default avatarJani Nikula <jani.nikula@intel.com>
      107c595c
    • José Roberto de Souza's avatar
      drm/i915: Disable PSR in Apple panels · 1035f4a6
      José Roberto de Souza authored
      i915 yet don't support PSR in Apple panels, so lets keep it disabled
      while we work on that.
      
      v2: Renamed DP_DPCD_QUIRK_PSR_NOT_CURRENTLY_SUPPORTED to
      DP_DPCD_QUIRK_NO_PSR (Ville)
      
      v3:
      Adding documentation to DP_DPCD_QUIRK_NO_PSR(Dhinakaran and Jani)
      Fixed typo in comment of the new quirk entry(Jani)
      
      Fixes: 598c6cfe
      
       (drm/i915/psr: Enable PSR1 on gen-9+ HW)
      Cc: Jani Nikula <jani.nikula@intel.com>
      Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
      Cc: Rodrigo Vivi <rodrigo.vivi@intel.com>
      Cc: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
      Reviewed-by: default avatarDhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
      Signed-off-by: default avatarJosé Roberto de Souza <jose.souza@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20181204003403.23361-1-jose.souza@intel.com
      (cherry picked from commit 7c5c641a
      
      )
      Signed-off-by: default avatarJani Nikula <jani.nikula@intel.com>
      1035f4a6
    • Jani Nikula's avatar
      Merge tag 'gvt-fixes-2019-01-09' of https://github.com/intel/gvt-linux into drm-intel-fixes · 038a0a8d
      Jani Nikula authored
      
      
      gvt-fixes-2019-01-09
      
      - Fix one race issue between pre-scan of guest workload with submission
      
      Signed-off-by: default avatarJani Nikula <jani.nikula@intel.com>
      From: Zhenyu Wang <zhenyuw@linux.intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20190109050151.GL11631@zhen-hp.sh.intel.com
      038a0a8d
    • Tetsuo Handa's avatar
      gpu/drm: Fix lock held when returning to user space. · 4089e272
      Tetsuo Handa authored
      
      
      We need to call drm_modeset_acquire_fini() when drm_atomic_state_alloc()
      failed or call drm_modeset_acquire_init() after drm_atomic_state_alloc()
      succeeded.
      
      Signed-off-by: default avatarTetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
      Reported-by: default avatarsyzbot <syzbot+6ea337c427f5083ebdf2@syzkaller.appspotmail.com>
      Signed-off-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
      Link: https://patchwork.freedesktop.org/patch/msgid/1547115571-21219-1-git-send-email-penguin-kernel@I-love.SAKURA.ne.jp
      4089e272
    • Ivan Mironov's avatar
      drm/fb-helper: Ignore the value of fb_var_screeninfo.pixclock · 66a8d5bf
      Ivan Mironov authored
      
      
      Strict requirement of pixclock to be zero breaks support of SDL 1.2
      which contains hardcoded table of supported video modes with non-zero
      pixclock values[1].
      
      To better understand which pixclock values are considered valid and how
      driver should handle these values, I briefly examined few existing fbdev
      drivers and documentation in Documentation/fb/. And it looks like there
      are no strict rules on that and actual behaviour varies:
      
      	* some drivers treat (pixclock == 0) as "use defaults" (uvesafb.c);
      	* some treat (pixclock == 0) as invalid value which leads to
      	  -EINVAL (clps711x-fb.c);
      	* some pass converted pixclock value to hardware (uvesafb.c);
      	* some are trying to find nearest value from predefined table
                (vga16fb.c, video_gx.c).
      
      Given this, I believe that it should be safe to just ignore this value if
      changing is not supported. It seems that any portable fbdev application
      which was not written only for one specific device working under one
      specific kernel version should not rely on any particular behaviour of
      pixclock anyway.
      
      However, while enabling SDL1 applications to work out of the box when
      there is no /etc/fb.modes with valid settings, this change affects the
      video mode choosing logic in SDL. Depending on current screen
      resolution, contents of /etc/fb.modes and resolution requested by
      application, this may lead to user-visible difference (not always):
      image will be displayed in a right way, but it will be aligned to the
      left instead of center. There is no "right behaviour" here as well, as
      emulated fbdev, opposing to old fbdev drivers, simply ignores any
      requsts of video mode changes with resolutions smaller than current.
      
      The easiest way to reproduce this problem is to install sdl-sopwith[2],
      remove /etc/fb.modes file if it exists, and then try to run sopwith
      from console without X. At least in Fedora 29, sopwith may be simply
      installed from standard repositories.
      
      [1] SDL 1.2.15 source code, src/video/fbcon/SDL_fbvideo.c, vesa_timings
      [2] http://sdl-sopwith.sourceforge.net/
      
      Signed-off-by: default avatarIvan Mironov <mironov.ivan@gmail.com>
      Cc: stable@vger.kernel.org
      Fixes: 79e53945 ("DRM: i915: add mode setting support")
      Fixes: 771fe6b9 ("drm/radeon: introduce kernel modesetting for radeon hardware")
      Fixes: 785b93ef
      
       ("drm/kms: move driver specific fb common code to helper functions (v2)")
      Signed-off-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
      Link: https://patchwork.freedesktop.org/patch/msgid/20190108072353.28078-3-mironov.ivan@gmail.com
      66a8d5bf
    • Ivan Mironov's avatar
      drm/fb-helper: Partially bring back workaround for bugs of SDL 1.2 · 62d85b3b
      Ivan Mironov authored
      SDL 1.2 sets all fields related to the pixel format to zero in some
      cases[1]. Prior to commit db05c481
      
       ("drm: fb-helper: Reject all
      pixel format changing requests"), there was an unintentional workaround
      for this that existed for more than a decade. First in device-specific DRM
      drivers, then here in drm_fb_helper.c.
      
      Previous code containing this workaround just ignores pixel format fields
      from userspace code. Not a good thing either, as this way, driver may
      silently use pixel format different from what client actually requested,
      and this in turn will lead to displaying garbage on the screen. I think
      that returning EINVAL to userspace in this particular case is the right
      option, so I decided to left code from problematic commit untouched
      instead of just reverting it entirely.
      
      Here is the steps required to reproduce this problem exactly:
      	1) Compile fceux[2] with SDL 1.2.15 and without GTK or OpenGL
      	   support. SDL should be compiled with fbdev support (which is
      	   on by default).
      	2) Create /etc/fb.modes with following contents (values seems
      	   not used, and just required to trigger problematic code in
      	   SDL):
      
      		mode "test"
      		    geometry 1 1 1 1 1
      		    timings 1 1 1 1 1 1 1
      		endmode
      
      	3) Create ~/.fceux/fceux.cfg with following contents:
      
      		SDL.Hotkeys.Quit = 27
      		SDL.DoubleBuffering = 1
      
      	4) Ensure that screen resolution is at least 1280x960 (e.g.
      	   append "video=Virtual-1:1280x960-32" to the kernel cmdline
      	   for qemu/QXL).
      
      	5) Try to run fceux on VT with some ROM file[3]:
      
      		# ./fceux color_test.nes
      
      [1] SDL 1.2.15 source code, src/video/fbcon/SDL_fbvideo.c,
          FB_SetVideoMode()
      [2] http://www.fceux.com
      [3] Example ROM: https://github.com/bokuweb/rustynes/blob/master/roms/color_test.nes
      
      Reported-by: default avatarsaahriktu <mail@saahriktu.org>
      Suggested-by: default avatarsaahriktu <mail@saahriktu.org>
      Cc: stable@vger.kernel.org
      Fixes: db05c481
      
       ("drm: fb-helper: Reject all pixel format changing requests")
      Signed-off-by: default avatarIvan Mironov <mironov.ivan@gmail.com>
      [danvet: Delete misleading comment.]
      Signed-off-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
      Link: https://patchwork.freedesktop.org/patch/msgid/20190108072353.28078-2-mironov.ivan@gmail.com
      Link: https://patchwork.freedesktop.org/patch/msgid/20190108072353.28078-2-mironov.ivan@gmail.com
      62d85b3b
    • Christian König's avatar
      drm/amdgpu: disable system memory page tables for now · 1c1eba86
      Christian König authored
      
      
      We hit a problem with IOMMU with that. Disable until we have time to
      debug further.
      
      Signed-off-by: default avatarChristian König <christian.koenig@amd.com>
      Reviewed-by: default avatarMichel Dänzer <michel.daenzer@amd.com>
      Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
      1c1eba86
    • Jim Qu's avatar
      drm/amdgpu: set WRITE_BURST_LENGTH to 64B to workaround SDMA1 hang · 0c6c8125
      Jim Qu authored
      
      
      effect asics: VEGA10 and VEGA12
      
      Signed-off-by: default avatarJim Qu <Jim.Qu@amd.com>
      Acked-by: default avatarAlex Deucher <alexander.deucher@amd.com>
      Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
      0c6c8125
    • Tao Zhou's avatar
      drm/amdgpu: fix CPDMA hang in PRT mode for VEGA20 · 3e958fe6
      Tao Zhou authored
      
      
      Fix CPDMA hang in PRT mode for both VEGA10 and VEGA20
      
      Signed-off-by: default avatarTao Zhou <tao.zhou1@amd.com>
      Tested-by: default avatarYukun.Li <yukun1.li@amd.com>
      Acked-by: default avatarAlex Deucher <alexander.deucher@amd.com>
      Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
      3e958fe6
  6. Jan 09, 2019