]> Git Repo - linux.git/log
linux.git
5 years agodrm/armada: replace the simple-framebuffer
Lubomir Rintel [Mon, 21 Jan 2019 06:01:57 +0000 (07:01 +0100)]
drm/armada: replace the simple-framebuffer

If there's a simple-framebuffer carried over from boot firmware, it's going
to stop working once we setup the LCDC for use via DRM. Kick it off from
the hardware.

Signed-off-by: Lubomir Rintel <[email protected]>
Signed-off-by: Russell King <[email protected]>
5 years agodrm/armada: redo CRTC debugfs files
Russell King [Sat, 7 Jul 2018 15:53:39 +0000 (16:53 +0100)]
drm/armada: redo CRTC debugfs files

Move the CRTC debugfs files into the CRTC specific directory.

Signed-off-by: Russell King <[email protected]>
5 years agoMerge tag 'drm-msm-next-2019-06-25' of https://gitlab.freedesktop.org/drm/msm into...
Dave Airlie [Thu, 27 Jun 2019 23:34:25 +0000 (09:34 +1000)]
Merge tag 'drm-msm-next-2019-06-25' of https://gitlab.freedesktop.org/drm/msm into drm-next

+ usual progress on cleanups
+ dsi vs EPROBE_DEFER fixes
+ msm8998 (snapdragon 835 support)
  + a540 gpu support (mesa support already landed)
  + dsi, dsi-phy support
+ mdp5 and dpu interconnect (bus/memory scaling) support
+ initial prep work for per-context pagetables (at least the parts that
  don't have external dependencies like iommu/arm-smmu)

There is one more patch for fixing DSI cmd mode panels (part of a set of
patches to get things working on nexus5), but it would be conflicty with
1cff7440a86e04a613665803b42034 in drm-next without rebasing or back-merge,
and since it doesn't conflict with anything in msm-next, I think it best
if Sean merges that through drm-mix-fixes instead.

(In other news, I've been making some progress w/ getting efifb working
properly on sdm850 laptop without horrible hacks, and drm/msm + clk stuff
not totally falling over when bootloader enables display and things are
already running when driver probes.. but not quite ready yet, hopefully
we can post some of that for 5.4.. should help for both the sdm835 and
sdm850 laptops.)

Signed-off-by: Dave Airlie <[email protected]>
From: Rob Clark <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/CAF6AEGsj3N4XzDLSDoa+4RHZ9wXObYmhcep0M3LjnRg48BeLvg@mail.gmail.com
5 years agodrm/amd/display: fix a couple of spelling mistakes
Colin Ian King [Wed, 26 Jun 2019 13:24:27 +0000 (14:24 +0100)]
drm/amd/display: fix a couple of spelling mistakes

There are a couple of spelling mistakes in dm_error messages and
a comment. Fix these.

Signed-off-by: Colin Ian King <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/powerplay: no memory activity support on Vega10
Evan Quan [Fri, 21 Jun 2019 01:46:14 +0000 (09:46 +0800)]
drm/amd/powerplay: no memory activity support on Vega10

Make mem_busy_percent sysfs interface invisible on Vega10.

Signed-off-by: Evan Quan <[email protected]>
Reviewed-by: Alex Deucher <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amdkfd: remove unnecessary warning message on gpu reset
shaoyunl [Wed, 26 Jun 2019 17:42:24 +0000 (13:42 -0400)]
drm/amdkfd: remove unnecessary warning message on gpu reset

In XGMI configuration, more than one asic can be reset at same time,
kfd is able to handle this and no need to trigger the warning

Signed-off-by: shaoyunl <[email protected]>
Reviewed-by: Andrey Grodzovsky <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amdgpu: Set queue_preemption_timeout_ms default value
Oak Zeng [Wed, 26 Jun 2019 15:16:56 +0000 (10:16 -0500)]
drm/amdgpu: Set queue_preemption_timeout_ms default value

Set default value of this kernel parameter to 9000

Signed-off-by: Oak Zeng <[email protected]>
Acked-by: Alex Deucher <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/powerplay: add missing smu_get_clk_info_from_vbios() call
Evan Quan [Tue, 25 Jun 2019 15:03:00 +0000 (23:03 +0800)]
drm/amd/powerplay: add missing smu_get_clk_info_from_vbios() call

This seems a merge error.

Signed-off-by: Evan Quan <[email protected]>
Reviewed-by: Hawking Zhang <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/powerplay: support runtime ppfeatures setting on Navi10
Evan Quan [Tue, 25 Jun 2019 03:06:08 +0000 (11:06 +0800)]
drm/amd/powerplay: support runtime ppfeatures setting on Navi10

Implement Navi10 backend for runtime ppfeatures status retrieving
and setting support.

Signed-off-by: Evan Quan <[email protected]>
Reviewed-by: Alex Deucher <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/powerplay: check prerequisite for VCN power gating
Evan Quan [Mon, 17 Jun 2019 09:27:49 +0000 (17:27 +0800)]
drm/amd/powerplay: check prerequisite for VCN power gating

VCN DPM is a necessary prerequisite for VCN power gating.

Signed-off-by: Evan Quan <[email protected]>
Reviewed-by: Kevin Wang <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/ttm: return -EBUSY if waiting for busy BO fails
Felix Kuehling [Wed, 26 Jun 2019 06:32:43 +0000 (02:32 -0400)]
drm/ttm: return -EBUSY if waiting for busy BO fails

Returning -EAGAIN prevents ttm_bo_mem_space from trying alternate
placements and can lead to live-locks in amdgpu_cs, retrying
indefinitely and never succeeding.

Fixes: d367bd2a5e2b12 ("drm/ttm: fix busy memory to fail other user v10")
Signed-off-by: Felix Kuehling <[email protected]>
Reviewed-by: Christian König <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amdgpu: drop copy/paste leftover to fix big endian
Alex Deucher [Thu, 27 Jun 2019 14:13:41 +0000 (09:13 -0500)]
drm/amdgpu: drop copy/paste leftover to fix big endian

The buf swap field doesn't exist on RB1.

Reviewed-by: Hawking Zhang <[email protected]>
Reviewed-by: Michel Dänzer <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amdgpu: fix warning on 32 bit
Alex Deucher [Thu, 27 Jun 2019 13:48:19 +0000 (08:48 -0500)]
drm/amdgpu: fix warning on 32 bit

Properly cast pointer to int.

Reviewed-by: Christian König <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/exynos: trigger build of all modules
Sam Ravnborg [Thu, 27 Jun 2019 11:00:54 +0000 (20:00 +0900)]
drm/exynos: trigger build of all modules

Add COMPILE_TEST dependency to force exynos driver to
built for more than arm and to built modules
that otherwise required other symbols to be de-selected.

This will increase build coverage of the exynos driver
thus allowing most trivial build errors to be detected/fixed early.

This introduces one warning when built using sh:
exynos7_drm_decon.c: In function ‘decon_remove’:
exynos7_drm_decon.c:769:24: warning: unused variable ‘ctx’
  struct decon_context *ctx = dev_get_drvdata(&pdev->dev);

This is due to the definition of iounmap() in sh,
and nothing that exynos driver can fix.

Include fix of exynos build for alpha.

Signed-off-by: Sam Ravnborg <[email protected]>
Cc: Inki Dae <[email protected]>
Cc: Joonyoung Shim <[email protected]>
Cc: Seung-Woo Kim <[email protected]>
Cc: Kyungmin Park <[email protected]>
Cc: David Airlie <[email protected]>
Cc: Daniel Vetter <[email protected]>
Cc: Kukjin Kim <[email protected]>
Cc: Krzysztof Kozlowski <[email protected]>
Cc: Jingoo Han <[email protected]>
Signed-off-by: Inki Dae <[email protected]>
5 years agodrm/i915: Make i945gm_vblank_work_func static
Chris Wilson [Wed, 26 Jun 2019 22:42:12 +0000 (23:42 +0100)]
drm/i915: Make i945gm_vblank_work_func static

drivers/gpu/drm/i915/i915_irq.c:3382:6: warning: symbol 'i945gm_vblank_work_func' was not declared. Should it be static?
  CC [M]  drivers/gpu/drm/i915/i915_irq.o
drivers/gpu/drm/i915/i915_irq.c:3382:6: error: no previous prototype for ‘i945gm_vblank_work_func’ [-Werror=missing-prototypes]
 void i945gm_vblank_work_func(struct work_struct *work)

Jani wrote the idential patch, so for posterity:

The static keyword was apparently accidentally removed in commit
08fa8fd0faa5 ("drm/i915: Switch to per-crtc vblank vfuncs"), leading to
sparse warning:

drivers/gpu/drm/i915/i915_irq.c:3382:6: warning: symbol
'i945gm_vblank_work_func' was not declared. Should it be static?

Make the function static again.

Meanwhile, the 0-day kbuilder also spotted the mistake.

Fixes: 08fa8fd0faa5 ("drm/i915: Switch to per-crtc vblank vfuncs")
Reported-by: kbuild test robot <[email protected]>
Signed-off-by: Chris Wilson <[email protected]>
Signed-off-by: Jani Nikula <[email protected]>
Cc: Ville Syrjälä <[email protected]>
Reviewed-by: Ville Syrjälä <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/exynos: drop drmP.h usage
Sam Ravnborg [Mon, 24 Jun 2019 13:06:28 +0000 (22:06 +0900)]
drm/exynos: drop drmP.h usage

Drop use of the deprecated drmP.h file.
Replace with forwards / externals as appropriate.

While touching the list of include files divide
them up in blocks and sort them.

v3:
- fix build errors in exynos_drm_g2d.c (Inki Dae)
  The exynos_drm_g2d.c file is not built in the
  standard configurations and was therefore missed.

Signed-off-by: Sam Ravnborg <[email protected]>
Cc: Inki Dae <[email protected]>
Cc: Joonyoung Shim <[email protected]>
Cc: Seung-Woo Kim <[email protected]>
Cc: Kyungmin Park <[email protected]>
Cc: David Airlie <[email protected]>
Cc: Daniel Vetter <[email protected]>
Cc: Kukjin Kim <[email protected]>
Cc: Krzysztof Kozlowski <[email protected]>
Cc: Jingoo Han <[email protected]>
Fixed merge conflict.
Signed-off-by: Inki Dae <[email protected]>
5 years agodrm/i915: make intel_uc_fw.h self-contained
Jani Nikula [Wed, 26 Jun 2019 14:40:19 +0000 (17:40 +0300)]
drm/i915: make intel_uc_fw.h self-contained

Add the minimal includes/declarations to make the header self-contained,
and ensure it stays that way.

Reviewed-by: Chris Wilson <[email protected]>
Signed-off-by: Jani Nikula <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915: make intel_gvt.h self-contained
Jani Nikula [Wed, 26 Jun 2019 14:40:18 +0000 (17:40 +0300)]
drm/i915: make intel_gvt.h self-contained

Add the minimal includes/declarations to make the header self-contained,
and ensure it stays that way.

Reviewed-by: Chris Wilson <[email protected]>
Signed-off-by: Jani Nikula <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915: make intel_guc_reg.h self-contained
Jani Nikula [Wed, 26 Jun 2019 14:40:17 +0000 (17:40 +0300)]
drm/i915: make intel_guc_reg.h self-contained

Add the minimal includes/declarations to make the header self-contained,
and ensure it stays that way.

v2: also include i915_reg.h (Michal)

Reviewed-by: Chris Wilson <[email protected]>
Signed-off-by: Jani Nikula <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915: make intel_guc_fwif.h self-contained
Jani Nikula [Wed, 26 Jun 2019 14:40:16 +0000 (17:40 +0300)]
drm/i915: make intel_guc_fwif.h self-contained

Add the minimal includes/declarations to make the header self-contained,
and ensure it stays that way.

Reviewed-by: Chris Wilson <[email protected]>
Signed-off-by: Jani Nikula <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915: make intel_guc_ct.h self-contained
Jani Nikula [Wed, 26 Jun 2019 14:40:15 +0000 (17:40 +0300)]
drm/i915: make intel_guc_ct.h self-contained

Add the minimal includes/declarations to make the header self-contained,
and ensure it stays that way.

Reviewed-by: Chris Wilson <[email protected]>
Signed-off-by: Jani Nikula <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915: make i915_vgpu.h self-contained
Jani Nikula [Wed, 26 Jun 2019 14:40:14 +0000 (17:40 +0300)]
drm/i915: make i915_vgpu.h self-contained

Add the minimal includes/declarations to make the header self-contained,
and ensure it stays that way.

Reviewed-by: Chris Wilson <[email protected]>
Signed-off-by: Jani Nikula <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915: make i915_pvinfo.h self-contained
Jani Nikula [Wed, 26 Jun 2019 14:40:13 +0000 (17:40 +0300)]
drm/i915: make i915_pvinfo.h self-contained

Add the minimal includes/declarations to make the header self-contained,
and ensure it stays that way.

Reviewed-by: Chris Wilson <[email protected]>
Signed-off-by: Jani Nikula <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915: make i915_globals.h self-contained
Jani Nikula [Wed, 26 Jun 2019 14:40:12 +0000 (17:40 +0300)]
drm/i915: make i915_globals.h self-contained

Add the minimal includes/declarations to make the header self-contained,
and ensure it stays that way.

Reviewed-by: Chris Wilson <[email protected]>
Signed-off-by: Jani Nikula <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915: make i915_fixed.h self-contained
Jani Nikula [Wed, 26 Jun 2019 14:40:10 +0000 (17:40 +0300)]
drm/i915: make i915_fixed.h self-contained

Add the minimal includes/declarations to make the header self-contained,
and ensure it stays that way.

Reviewed-by: Chris Wilson <[email protected]>
Signed-off-by: Jani Nikula <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915: add header search path to subdir Makefiles
Jani Nikula [Wed, 26 Jun 2019 14:36:18 +0000 (17:36 +0300)]
drm/i915: add header search path to subdir Makefiles

With the subdirectories we lost the ability to build individual files on
the command line, for example:

$ make drivers/gpu/drm/i915/display/intel_display.o

This was due to the top level directory missing from header search
path. Add the header search paths to subdir Makefiles.

Note that none of the other options in the top level i915 Makefile are
taken into account when building individual files. Usually this is not a
concern.

Reported-by: Imre Deak <[email protected]>
Reported-by: Ville Syrjälä <[email protected]>
Cc: Chris Wilson <[email protected]>
Reviewed-by: Chris Wilson <[email protected]>
Signed-off-by: Jani Nikula <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915: prefix header search path with $(srctree)/
Jani Nikula [Wed, 26 Jun 2019 14:36:17 +0000 (17:36 +0300)]
drm/i915: prefix header search path with $(srctree)/

Per commit 43068cb7ba1f ("drm: prefix header search paths with
$(srctree)/") this is what we should be doing. Follow suit.

Cc: Chris Wilson <[email protected]>
Reviewed-by: Chris Wilson <[email protected]>
Signed-off-by: Jani Nikula <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agoMerge tag 'drm-next-5.3-2019-06-25' of git://people.freedesktop.org/~agd5f/linux...
Dave Airlie [Thu, 27 Jun 2019 02:33:56 +0000 (12:33 +1000)]
Merge tag 'drm-next-5.3-2019-06-25' of git://people.freedesktop.org/~agd5f/linux into drm-next

drm-next-5.3-2019-06-25:

Merge drm-next

amdgpu:
- SR-IOV L1 policy fixes
- Removed no longer needed vram_page_split module parameter
- Add module parameter to override default ABM level
- Gamma fixes
- No need to check return values for debugfs
- Improve HMM error handling
- Avoid possible OOM situations when lots of thread are submitting with
  memory contention
- Improve hw i2c access abritration
- DSC (Display Stream Compression) support in DC
- Initial navi10 support
  * DC support
  * GFX/Compute support
  * SDMA support
  * Power Management support
  * VCN support
- Static checker fixes
- Misc cleanups
- fix long udelay on arm

amdkfd:
- Implement priority controls for gfx9
- Enable VEGAM
- Rework mqd allocation and init
- Circular locking fix
- Fix SDMA queue allocation race condition
- No need to check return values for debugfs
- Add proc style process information
- Initial navi10 support

radeon:
- No need to check return values for debugfs

UAPI changes:
- GDDR6 added to vram type query
- New Navi10 details added gpu info query
- Navi family added to asic family query

Signed-off-by: Dave Airlie <[email protected]>
From: Alex Deucher <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agoMerge tag 'for-airlie-tda998x' of git://git.armlinux.org.uk/~rmk/linux-arm into drm...
Dave Airlie [Thu, 27 Jun 2019 01:48:02 +0000 (11:48 +1000)]
Merge tag 'for-airlie-tda998x' of git://git.armlinux.org.uk/~rmk/linux-arm into drm-next

TDA998x updates:
- improve the driver's approach to audio, adding support for more I2S
  based formats, particularly other justifications, and preparing the
  driver to support other bclk ratios.

- add support for pixel repeated modes, tested with a Panasonic TV.

- correct the quantisation range handling; in particular, do not send
  full range RGB to the sink when the sink does not support full range
  RGB.

- Send the HDMI vendor info frame when required.

Signed-off-by: Dave Airlie <[email protected]>
From: Russell King <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915: Move OA files to separate folder
Michal Wajdeczko [Wed, 26 Jun 2019 12:38:26 +0000 (12:38 +0000)]
drm/i915: Move OA files to separate folder

OA files look to be auto-generated so we can keep them all in
dedicated subdirectory.

Signed-off-by: Michal Wajdeczko <[email protected]>
Cc: Lionel Landwerlin <[email protected]>
Cc: Chris Wilson <[email protected]>
Cc: Jani Nikula <[email protected]>
Acked-by: Chris Wilson <[email protected]>
Acked-by: Lionel Landwerlin <[email protected]>
Acked-by: Jani Nikula <[email protected]>
Reviewed-by: Umesh Nerlige Ramappa <[email protected]>
Signed-off-by: Chris Wilson <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915/ehl: Add voltage level requirement table
José Roberto de Souza [Wed, 26 Jun 2019 01:40:53 +0000 (18:40 -0700)]
drm/i915/ehl: Add voltage level requirement table

EHL has it own voltage level requirement depending on cd clock.

BSpec: 21809
Cc: Clint Taylor <[email protected]>
Cc: Matt Roper <[email protected]>
Cc: Ville Syrjälä <[email protected]>
Reviewed-by: Matt Roper <[email protected]>
Signed-off-by: José Roberto de Souza <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915/ehl: Remove unsupported cd clocks
José Roberto de Souza [Wed, 26 Jun 2019 01:40:52 +0000 (18:40 -0700)]
drm/i915/ehl: Remove unsupported cd clocks

EHL do not support 648 and 652.8 MHz.

v2:
- Limiting maximum CD clock by max_cdclk_freq instead of remove it
from icl_calc_cdclk()(Ville and Jani)

BSpec: 20598
Cc: Clint Taylor <[email protected]>
Cc: Matt Roper <[email protected]>
Cc: Ville Syrjälä <[email protected]>
Cc: Jani Nikula <[email protected]>
Reviewed-by: Matt Roper <[email protected]>
Signed-off-by: José Roberto de Souza <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915/icl: Add new supported CD clocks
José Roberto de Souza [Wed, 26 Jun 2019 01:40:51 +0000 (18:40 -0700)]
drm/i915/icl: Add new supported CD clocks

Now 180, 172.8 and 192 MHz are supported.

180 and 172.8 MHz CD clocks will only be used when audio is not
enabled as state by BSpec and implemented in
intel_crtc_compute_min_cdclk(), CD clock must be at least twice of
Azalia BCLK and BCLK by default is 96 MHz, it could be set to 48 MHz
but we are not reading it.

v3:
- making icl clock arrays static (Ville)

BSpec: 20598
BSpec: 15729
Cc: Clint Taylor <[email protected]>
Cc: Ville Syrjälä <[email protected]>
Reviewed-by: Matt Roper <[email protected]>
Signed-off-by: José Roberto de Souza <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915: Lift intel_engines_resume() to callers
Chris Wilson [Wed, 26 Jun 2019 15:45:49 +0000 (16:45 +0100)]
drm/i915: Lift intel_engines_resume() to callers

Since the reset path wants to recover the engines itself, it only wants
to reinitialise the hardware using i915_gem_init_hw(). Pull the call to
intel_engines_resume() to the module init/resume path so we can avoid it
during reset.

Fixes: 79ffac8599c4 ("drm/i915: Invert the GEM wakeref hierarchy")
Signed-off-by: Chris Wilson <[email protected]>
Reviewed-by: Mika Kuoppala <[email protected]>
Cc: Tvrtko Ursulin <[email protected]>
Cc: Imre Deak <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915: Only recover active engines
Chris Wilson [Wed, 26 Jun 2019 15:45:48 +0000 (16:45 +0100)]
drm/i915: Only recover active engines

If we issue a reset to a currently idle engine, leave it idle
afterwards. This is useful to excise a linkage between reset and the
shrinker. When waking the engine, we need to pin the default context
image which we use for overwriting a guilty context -- if the engine is
idle we do not need this pinned image! However, this pinning means that
waking the engine acquires the FS_RECLAIM, and so may trigger the
shrinker. The shrinker itself may need to wait upon the GPU to unbind
and object and so may require services of reset; ergo we should avoid
the engine wake up path.

The danger in skipping the recovery for idle engines is that we leave the
engine with no context defined, which may interfere with the operation of
the power context on some older platforms. In practice, we should only
be resetting an active GPU but it something to look out for on Ironlake
(if memory serves).

Fixes: 79ffac8599c4 ("drm/i915: Invert the GEM wakeref hierarchy")
Signed-off-by: Chris Wilson <[email protected]>
Reviewed-by: Mika Kuoppala <[email protected]>
Cc: Tvrtko Ursulin <[email protected]>
Cc: Imre Deak <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915: Add a wakeref getter for iff the wakeref is already active
Chris Wilson [Wed, 26 Jun 2019 15:45:47 +0000 (16:45 +0100)]
drm/i915: Add a wakeref getter for iff the wakeref is already active

For use in the next patch, we want to acquire a wakeref without having
to wake the device up -- i.e. only acquire the engine wakeref if the
engine is already active.

Signed-off-by: Chris Wilson <[email protected]>
Reviewed-by: Mika Kuoppala <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915: Initialize drm_driver vblank funcs at compile time
Ville Syrjälä [Wed, 19 Jun 2019 17:08:42 +0000 (20:08 +0300)]
drm/i915: Initialize drm_driver vblank funcs at compile time

Move the .get_vblank_timestamp() and .get_scanout_position()
initialization to happen at compile time. No point in delaying
it since we always assign the same functions.

Signed-off-by: Ville Syrjälä <[email protected]>
Reviewed-by: Chris Wilson <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915: Nuke drm_driver irq vfuncs
Ville Syrjälä [Thu, 20 Jun 2019 10:33:34 +0000 (13:33 +0300)]
drm/i915: Nuke drm_driver irq vfuncs

Stop using the irq vfuncs under drm_driver. That's not going to fly
in a mixed gen environment since the structure is shared between all
the devices.

v2: Allow intel_irq_uninstall() to be called twice due to
    intel_modeset_cleanup() calling it as well. Toss in a
    FIXME to remind us that this is not great.

Signed-off-by: Ville Syrjälä <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
Reviewed-by: Chris Wilson <[email protected]>
5 years agodrm/i915: Switch to per-crtc vblank vfuncs
Ville Syrjälä [Wed, 19 Jun 2019 17:08:40 +0000 (20:08 +0300)]
drm/i915: Switch to per-crtc vblank vfuncs

Switch from the driver-wide vblank vfuncs to the per-crtc ones so that
we don't have so many platform specific vfuncs in the driver struct.

We still need to do something about the rest fo the irq vfuncs...

v2: s/INTEL_GEN>=3/IS_GEN3/

Signed-off-by: Ville Syrjälä <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
Reviewed-by: Chris Wilson <[email protected]>
5 years agodrm/i915: Fix various tracepoints for gen2
Ville Syrjälä [Wed, 19 Jun 2019 17:08:39 +0000 (20:08 +0300)]
drm/i915: Fix various tracepoints for gen2

Gen2 doesn't have a frame counter and apparently we no longer provide
a fake .get_vblank_counter() hook for it. That means all tracepoints
calling that hook will oops. Update the tracepoints to use
intel_crtc_get_vblank_counter() which will gracefully fall back to
using the software counter. This is actually a better approach since
we now get (hopefully accurate) frame numbers in the traces.

This also gets rid of the raw driver->get_vblank_counter() calls, which
we need to do in order to switch to the per-crtc vblank vfuncs.

v2: Deal with new tracepoints
v3: Use a distinct variable name for the internal crtc iterator (Chris)

Cc: Shawn Guo <[email protected]>
Cc: Daniel Vetter <[email protected]>
Fixes: 967dd4841787 ("drm: remove drm_vblank_no_hw_counter assignment from driver code")
Signed-off-by: Ville Syrjälä <[email protected]>
Reviewed-by: Chris Wilson <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915/selftests: Fixup atomic reset checking
Chris Wilson [Wed, 26 Jun 2019 13:44:33 +0000 (14:44 +0100)]
drm/i915/selftests: Fixup atomic reset checking

We require that the intel_gpu_reset() was atomic, not the whole of
i915_reset() which is guarded by a mutex. However, we do require that
i915_reset_engine() is atomic for use from within the submission tasklet.

Signed-off-by: Chris Wilson <[email protected]>
Reviewed-by: Mika Kuoppala <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915/selftests: Drop manual request wakerefs around hangcheck
Chris Wilson [Wed, 26 Jun 2019 13:44:32 +0000 (14:44 +0100)]
drm/i915/selftests: Drop manual request wakerefs around hangcheck

We no longer need to manually acquire a wakeref for request emission, so
drop the redundant wakerefs, letting us test our wakeref handling more
precisely.

References: 79ffac8599c4 ("drm/i915: Invert the GEM wakeref hierarchy")
Signed-off-by: Chris Wilson <[email protected]>
Reviewed-by: Mika Kuoppala <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915/selftests: Serialise nop reset with retirement
Chris Wilson [Wed, 26 Jun 2019 13:44:31 +0000 (14:44 +0100)]
drm/i915/selftests: Serialise nop reset with retirement

In order for the reset count to be accurate across our selftest, we need
to prevent the background retire worker from modifying our expected
state. To preserve the intent of symmetry, we apply this to both
i915_reset and i915_reset_engine, even though it strictly only affects
i915_reset_engine currently.

Signed-off-by: Chris Wilson <[email protected]>
Reviewed-by: Mika Kuoppala <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915: Check backlight type while doing eDP backlight initializaiton
Lee Shawn C [Thu, 20 Jun 2019 15:44:16 +0000 (08:44 -0700)]
drm/i915: Check backlight type while doing eDP backlight initializaiton

If LFP backlight type setting from VBT was "VESA eDP AUX Interface".
Driver should check panel capability and try to initialize aux backlight.
No matter i915_modparams.enable_dpcd_backlight was enabled or not.

v2: access dev_priv->vbt.backlight.type directly and remove unused function.
v3: 1. Modify i915.enable_dpcd_backlight type from bool to int and give default
       value as 0 (disable).
    2. Add a judgement to check LFP backlight type was aux interface or not.

Cc: Ville Syrjälä <[email protected]>
Cc: Jani Nikula <[email protected]>
Cc: Jose Roberto de Souza <[email protected]>
Cc: Cooper Chiou <[email protected]>
Signed-off-by: Lee Shawn C <[email protected]>
Signed-off-by: Jani Nikula <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agoMerge tag 'topic/remove-fbcon-notifiers-2019-06-26' into drm-misc-next-fixes
Maarten Lankhorst [Wed, 26 Jun 2019 10:26:34 +0000 (12:26 +0200)]
Merge tag 'topic/remove-fbcon-notifiers-2019-06-26' into drm-misc-next-fixes

topic/remove-fbcon-notifiers:
- Export fbcon_update_vcs to fix sh_mobile_lcdcfb.c compilation.
- Rely on fbcon being builtin when vgaswitcheroo is builtin.

Signed-off-by: Maarten Lankhorst <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agoMerge remote-tracking branch 'drm/drm-next' into drm-misc-next-fixes
Maarten Lankhorst [Wed, 26 Jun 2019 10:22:54 +0000 (12:22 +0200)]
Merge remote-tracking branch 'drm/drm-next' into drm-misc-next-fixes

Some fixes have been accidentally pushed to this, so I cannot fost-forward.
Required to pull in the remove-fbcon-notifiers fixes.

Signed-off-by: Maarten Lankhorst <[email protected]>
5 years agodrm/i915/icl: Add missing device ID
Mika Kahola [Mon, 17 Jun 2019 08:24:13 +0000 (11:24 +0300)]
drm/i915/icl: Add missing device ID

We are missing PCI device ID for SKU ICLLP U GT 1.5F (0x8A54) as per BSPec.

BSpec: 19092

Signed-off-by: Mika Kahola <[email protected]>
Reviewed-by: Clint Taylor <[email protected]>
Signed-off-by: Maarten Lankhorst <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agovga_switcheroo: Depend upon fbcon being built-in, if enabled
Daniel Vetter [Mon, 24 Jun 2019 09:21:53 +0000 (11:21 +0200)]
vga_switcheroo: Depend upon fbcon being built-in, if enabled

Fixes linking fail when fbcon/fbdev is modular and vgaswitcheroo is
enabled:

x86_64-linux-gnu-ld: drivers/gpu/vga/vga_switcheroo.o: in function `vga_switchto_stage2':
vga_switcheroo.c:(.text+0x997): undefined reference to `fbcon_remap_all'

Unfortunately this means that in a default allmodconfig we will disable vgaswitcheroo.

v2: I first tried to fix this with an EXPORT_SYMBOL, but vga_switcheroo is
never a module, so this doesn't work.

Reported-by: Stephen Rothwell <[email protected]>
Reported-by: kbuild test robot <[email protected]>
Fixes: 1cd51b5d200d ("vgaswitcheroo: call fbcon_remap_all directly")
Signed-off-by: Daniel Vetter <[email protected]>
Cc: Stephen Rothwell <[email protected]>
Cc: Lukas Wunner <[email protected]>
Cc: Daniel Vetter <[email protected]>
Cc: Sam Ravnborg <[email protected]>
Cc: Maarten Lankhorst <[email protected]>
Cc: David Airlie <[email protected]>
Cc: Daniel Vetter <[email protected]>
Cc: Maxime Ripard <[email protected]>
Cc: Sean Paul <[email protected]>
Cc: Bartlomiej Zolnierkiewicz <[email protected]>
Cc: Hans de Goede <[email protected]>
Cc: Yisheng Xie <[email protected]>
Cc: [email protected]
Cc: Daniel Thompson <[email protected]>
Cc: Lee Jones <[email protected]>
Cc: [email protected]
Cc: [email protected]
Signed-off-by: Maarten Lankhorst <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915/gt: Add some debug tracing for context pinning
Chris Wilson [Tue, 25 Jun 2019 19:48:59 +0000 (20:48 +0100)]
drm/i915/gt: Add some debug tracing for context pinning

Add the context pin/unpin events to the trace for post-mortem debugging.

Signed-off-by: Chris Wilson <[email protected]>
Reviewed-by: Matthew Auld <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915/gt: Always call kref_init for the timeline
Chris Wilson [Tue, 25 Jun 2019 23:33:49 +0000 (00:33 +0100)]
drm/i915/gt: Always call kref_init for the timeline

Always initialise the refcount, even for the embedded timelines inside
mock devices.

Signed-off-by: Chris Wilson <[email protected]>
Reviewed-by: Matthew Auld <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915/gt: Drop stale commentary for timeline density
Chris Wilson [Tue, 25 Jun 2019 23:33:48 +0000 (00:33 +0100)]
drm/i915/gt: Drop stale commentary for timeline density

We no longer allocate a contiguous set of timeline ids for all engines
upon creation, so we no longer should assume that the timelines are
densely allocated within a context. Hopefully, the set of fences used
within a workload are still dense enough for us to take advantage of
the compressed radix tree used for the syncmap.

Signed-off-by: Chris Wilson <[email protected]>
Reviewed-by: Daniele Ceraolo Spurio <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915/selftests: Hold ref on request across waits
Chris Wilson [Tue, 25 Jun 2019 13:01:22 +0000 (14:01 +0100)]
drm/i915/selftests: Hold ref on request across waits

As we wait upon the request, we should be sure to hold our own reference
for our checks.

Signed-off-by: Chris Wilson <[email protected]>
Reviewed-by: Matthew Auld <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915: Rename intel_wakeref_[is]_active
Chris Wilson [Tue, 25 Jun 2019 13:01:14 +0000 (14:01 +0100)]
drm/i915: Rename intel_wakeref_[is]_active

Our general rule is to use is/has as the verb for boolean functions,
rename intel_wakeref_active to intel_wakeref_is_active so the question
being asked is clear.

Signed-off-by: Chris Wilson <[email protected]>
Reviewed-by: Matthew Auld <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915/gt: Pass intel_gt to pm routines
Chris Wilson [Tue, 25 Jun 2019 13:01:10 +0000 (14:01 +0100)]
drm/i915/gt: Pass intel_gt to pm routines

Switch from passing the i915 container to newly named struct intel_gt.

Signed-off-by: Chris Wilson <[email protected]>
Reviewed-by: Matthew Auld <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915/guc: Add debug capture of GuC exception
Robert M. Fosha [Tue, 25 Jun 2019 16:41:07 +0000 (09:41 -0700)]
drm/i915/guc: Add debug capture of GuC exception

Detect GuC firmware load failure due to an exception during execution
in GuC firmware. Output the GuC EIP where exception occurred to dmesg
for GuC debug information.

v2: correct typos, change debug message and error code returned for
GuC exception (Michal)

Signed-off-by: Robert M. Fosha <[email protected]>
Cc: Daniele Ceraolo Spurio <[email protected]>
Cc: Michal Wajdeczko <[email protected]>
Reviewed-by: Michal Wajdeczko <[email protected]>
Signed-off-by: Chris Wilson <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915/execlists: Convert recursive defer_request() into iterative
Chris Wilson [Tue, 25 Jun 2019 13:01:09 +0000 (14:01 +0100)]
drm/i915/execlists: Convert recursive defer_request() into iterative

As this engine owns the lock around rq->sched.link (for those waiters
submitted to this engine), we can use that link as an element in a local
list. We can thus replace the recursive algorithm with an iterative walk
over the ordered list of waiters.

Signed-off-by: Chris Wilson <[email protected]>
Reviewed-by: Matthew Auld <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/amd/powerplay: make athub pg bit configured by pg_flags
Huang Rui [Fri, 14 Jun 2019 08:19:36 +0000 (16:19 +0800)]
drm/amd/powerplay: make athub pg bit configured by pg_flags

The athub pg features enabling should be indicated by pg_flags.

Reported-by: Lijo Lazar <[email protected]>
Signed-off-by: Huang Rui <[email protected]>
Reviewed-by: Kenneth Feng <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/powerplay: make mmhub pg bit configured by pg_flags
Huang Rui [Fri, 14 Jun 2019 08:12:51 +0000 (16:12 +0800)]
drm/amd/powerplay: make mmhub pg bit configured by pg_flags

The mmhub pg features enabling should be indicated by pg_flags.

Reported-by: Lijo Lazar <[email protected]>
Signed-off-by: Huang Rui <[email protected]>
Reviewed-by: Kenneth Feng <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/powerplay: add feature check in unforce_dpm_levels function (v2)
Kevin Wang [Mon, 17 Jun 2019 05:05:00 +0000 (13:05 +0800)]
drm/amd/powerplay: add feature check in unforce_dpm_levels function (v2)

if not check dpm feature is enabled, it will cause show smc send message
failed log in dmesg log.
eg:
echo "auto" > power_dpm_force_performance_level

v2: whitespace fix (Alex)

Signed-off-by: Kevin Wang <[email protected]>
Reviewed-by: Evan Quan <[email protected]>
Reviewed-by: Rui Teng <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/i915/ehl: Add missing VECS engine
José Roberto de Souza [Fri, 14 Jun 2019 21:37:49 +0000 (14:37 -0700)]
drm/i915/ehl: Add missing VECS engine

EHL can have up to one VECS(video enhancement) engine, so add it to
the device_info.

BSpec: 29152
Cc: Rodrigo Vivi <[email protected]>
Cc: Bob Paauwe <[email protected]>
Cc: Matt Roper <[email protected]>
Cc: Clint Taylor <[email protected]>
Signed-off-by: José Roberto de Souza <[email protected]>
Reviewed-by: Matt Roper <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/amd/powerplay: check gfxclk dpm enablement before proceeding
Evan Quan [Fri, 14 Jun 2019 09:04:36 +0000 (17:04 +0800)]
drm/amd/powerplay: check gfxclk dpm enablement before proceeding

Support gfxclk dpm disablement.

Signed-off-by: Evan Quan <[email protected]>
Reviewed-by: Feifei Xu <[email protected]>
Reviewed-by: Kevin Wang <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/powerplay: print smu versions only if version mismatch
Kevin Wang [Tue, 11 Jun 2019 07:21:06 +0000 (15:21 +0800)]
drm/amd/powerplay: print smu versions only if version mismatch

only printf smu version when if version not matched.

Signed-off-by: Kevin Wang <[email protected]>
Reviewed-by: Xiaojie Yuan <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/powerplay: fix fan speed show error (for hwmon pwm)
Kevin Wang [Thu, 6 Jun 2019 09:12:34 +0000 (17:12 +0800)]
drm/amd/powerplay: fix fan speed show error (for hwmon pwm)

the navi asic can't get current rpm by MSG_GetCurrentRpm,
it will cause show fan rpm error, use Metrics_t to replace it.

Signed-off-by: Kevin Wang <[email protected]>
Reviewed-by: Alex Deucher <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/display: update infoframe after dig fe is turned on (v2)
Nicholas Kazlauskas [Mon, 24 Jun 2019 17:14:14 +0000 (13:14 -0400)]
drm/amd/display: update infoframe after dig fe is turned on (v2)

[Why]
The AVI infoframe is incorrectly programmed on DCN1/2 when enabling a
stream - causing the wrong pixel encoding to be used for display.

This is because the AVI infoframe is programmed before the DIG BE is
connected to the FE and turned on, so enabling the AFMT block doesn't
actually work and the registers subsequently can't be written to.

[How]
Program the infoframe *after* turning on the DIG FE. This was the
behavior previously used but it was incorrectly reverted
when adding the DCN2 HW sequencer code.

v2: Don't call update_info_frame twice

Fixes: 7ed4e6352c16fe01 ("drm/amd/display: Add DCN2 HW Sequencer and Resource")
Signed-off-by: Nicholas Kazlauskas <[email protected]>
Acked-by: Alex Deucher <[email protected]>
Reviewed-by: Bhawanpreet Lakha <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/powerplay:clean up the residual mutex for smu_hw_init
Prike Liang [Mon, 24 Jun 2019 09:25:26 +0000 (17:25 +0800)]
drm/amd/powerplay:clean up the residual mutex for smu_hw_init

The mutex for procting SMU during hw_init was removed as system
will be deadlock when smu_populate_umd_state_clk try get SMU mutex.
Therefore need remove the residual mutex from failed path.

Signed-off-by: Prike Liang <[email protected]>
Reviewed-by: Evan Quan <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/amdgpu: sdma_v4_0_start: initialize r
Ernst Sjöstrand [Mon, 24 Jun 2019 15:15:44 +0000 (17:15 +0200)]
drm/amd/amdgpu: sdma_v4_0_start: initialize r

Reported by smatch:
drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c:1167 sdma_v4_0_start() error: uninitialized symbol 'r'.

Signed-off-by: Ernst Sjöstrand <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/amdgpu: Fix style issues in dcn20_resource.c
Ernst Sjöstrand [Mon, 24 Jun 2019 15:15:43 +0000 (17:15 +0200)]
drm/amd/amdgpu: Fix style issues in dcn20_resource.c

Inconsistent indentation and mixed use of brackets.

Signed-off-by: Ernst Sjöstrand <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/amdgpu: Check stream in amdgpu_dm_commit_planes
Ernst Sjöstrand [Mon, 24 Jun 2019 15:15:42 +0000 (17:15 +0200)]
drm/amd/amdgpu: Check stream in amdgpu_dm_commit_planes

Reported by smatch:
amdgpu_dm.c:5637 amdgpu_dm_commit_planes() error: we previously assumed 'acrtc_state->stream' could be null
This seems to be checked for null pretty consistently elsewhere.

Signed-off-by: Ernst Sjöstrand <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/amdgpu: amdgpu_hwmon_show_temp: initialize temp
Ernst Sjöstrand [Mon, 24 Jun 2019 15:15:41 +0000 (17:15 +0200)]
drm/amd/amdgpu: amdgpu_hwmon_show_temp: initialize temp

Reported by smatch:
drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c:1496 amdgpu_hwmon_show_temp() error: uninitialized symbol 'temp'.

Signed-off-by: Ernst Sjöstrand <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/amdgpu: Fix amdgpu_set_pp_od_clk_voltage error check
Ernst Sjöstrand [Mon, 24 Jun 2019 15:15:40 +0000 (17:15 +0200)]
drm/amd/amdgpu: Fix amdgpu_set_pp_od_clk_voltage error check

Reported by smatch:
drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c:693 amdgpu_set_pp_od_clk_voltage() error: uninitialized symbol 'ret'.

Signed-off-by: Ernst Sjöstrand <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/amdgpu: Indent AMD_IS_APU properly
Ernst Sjöstrand [Mon, 24 Jun 2019 15:15:39 +0000 (17:15 +0200)]
drm/amd/amdgpu: Indent AMD_IS_APU properly

Reported by smatch:
drivers/gpu/drm/amd/amdgpu/soc15.c:715 soc15_get_pcie_usage() warn: inconsistent indenting
And a similar one in si.c.

Signed-off-by: Ernst Sjöstrand <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amdgpu/display: drop ifdefs around comments
Alex Deucher [Mon, 24 Jun 2019 15:13:56 +0000 (10:13 -0500)]
drm/amdgpu/display: drop ifdefs around comments

No need to protect the comments.  The DCN1_01 config
was dopped anyway.  Got accidently brought back with the
navi merge.

Reviewed-by: Nicholas Kazlauskas <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amdgpu/display: switch udelay to msleep
Alex Deucher [Tue, 25 Jun 2019 13:54:21 +0000 (08:54 -0500)]
drm/amdgpu/display: switch udelay to msleep

We may need to sleep for up to 80ms
(8ms per each of up to 10 loop iterations):

/* First DPCD read after VDD ON can fail if the particular board
 * does not have HPD pin wired correctly. So if DPCD read fails,
 * which it should never happen, retry a few times. Target worst
 * case scenario of 80 ms.
 */

Switch udelay to msleep to avoid limits on arm.

Reviewed-by: Nicholas Kazlauskas <[email protected]>
Reviewed-by: Hawking Zhang <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amdgpu/powerplay: FEATURE_MASK is 64 bit so use ULL
Alex Deucher [Tue, 25 Jun 2019 13:48:15 +0000 (08:48 -0500)]
drm/amdgpu/powerplay: FEATURE_MASK is 64 bit so use ULL

ULL is needed for 32 bit arches.

Reviewed-by: Nicholas Kazlauskas <[email protected]>
Reviewed-by: Hawking Zhang <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/i915/ehl: Add one additional PCH ID to MCC
Matt Roper [Fri, 21 Jun 2019 15:18:47 +0000 (08:18 -0700)]
drm/i915/ehl: Add one additional PCH ID to MCC

There's one additional ID that we should treat as Mule Creek Canyon.

Cc: José Roberto de Souza <[email protected]>
Signed-off-by: Matt Roper <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
Reviewed-by: José Roberto de Souza <[email protected]>
5 years agoMerge branch 'drm-next' into drm-next-5.3
Alex Deucher [Tue, 25 Jun 2019 13:42:25 +0000 (08:42 -0500)]
Merge branch 'drm-next' into drm-next-5.3

Backmerge drm-next and fix up conflicts due to drmP.h removal.

Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/msm: add dirty framebuffer helper
Brian Masney [Fri, 31 May 2019 09:46:14 +0000 (05:46 -0400)]
drm/msm: add dirty framebuffer helper

Use drm_atomic_helper_dirtyfb() as the dirty callback in the
msm_framebuffer_funcs struct. Call drm_plane_enable_fb_damage_clips()
when the planes are initialized in mdp4, mdp5, and dpu1.

Signed-off-by: Brian Masney <[email protected]>
Signed-off-by: Rob Clark <[email protected]>
5 years agodrm/i915/perf: fix ICL perf register offsets
Lionel Landwerlin [Mon, 10 Jun 2019 08:19:14 +0000 (11:19 +0300)]
drm/i915/perf: fix ICL perf register offsets

We got the wrong offsets (could they have changed?). New values were
computed off an error state by looking up the register offset in the
context image as written by the HW.

Signed-off-by: Lionel Landwerlin <[email protected]>
Fixes: 1de401c08fa805 ("drm/i915/perf: enable perf support on ICL")
Acked-by: Kenneth Graunke <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915: Disable SAMPLER_STATE prefetching on all Gen11 steppings.
Kenneth Graunke [Tue, 25 Jun 2019 09:06:55 +0000 (10:06 +0100)]
drm/i915: Disable SAMPLER_STATE prefetching on all Gen11 steppings.

The Demand Prefetch workaround (binding table prefetching) only applies
to Icelake A0/B0.  But the Sampler Prefetch workaround needs to be
applied to all Gen11 steppings, according to a programming note in the
SARCHKMD documentation.

Using the Intel Gallium driver, I have seen intermittent failures in
the dEQP-GLES31.functional.copy_image.non_compressed.* tests.  After
applying this workaround, the tests reliably pass.

v2: Remove the overlap with a pre-production w/a

BSpec: 9663
Signed-off-by: Kenneth Graunke <[email protected]>
Signed-off-by: Chris Wilson <[email protected]>
Cc: [email protected]
Reviewed-by: Mika Kuoppala <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/edid: use for_each_displayid_db where applicable
Andres Rodriguez [Wed, 19 Jun 2019 18:30:33 +0000 (14:30 -0400)]
drm/edid: use for_each_displayid_db where applicable

Replace the duplicated versions of the while loop with the new macro.

Signed-off-by: Andres Rodriguez <[email protected]>
Reviewed-by: Dave Airlie <[email protected]>
Signed-off-by: Dave Airlie <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/edid: parse CEA blocks embedded in DisplayID
Andres Rodriguez [Wed, 19 Jun 2019 18:09:01 +0000 (14:09 -0400)]
drm/edid: parse CEA blocks embedded in DisplayID

DisplayID blocks allow embedding of CEA blocks. The payloads are
identical to traditional top level CEA extension blocks, but the header
is slightly different.

This change allows the CEA parser to find a CEA block inside a DisplayID
block. Additionally, it adds support for parsing the embedded CTA
header. No further changes are necessary due to payload parity.

This change fixes audio support for the Valve Index HMD.

Signed-off-by: Andres Rodriguez <[email protected]>
Reviewed-by: Dave Airlie <[email protected]>
Cc: Jani Nikula <[email protected]>
Cc: <[email protected]> # v4.15
Signed-off-by: Dave Airlie <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agoMerge tag 'drm/tegra/for-5.3-rc1' of git://anongit.freedesktop.org/tegra/linux into...
Dave Airlie [Tue, 25 Jun 2019 02:59:35 +0000 (12:59 +1000)]
Merge tag 'drm/tegra/for-5.3-rc1' of git://anongit.freedesktop.org/tegra/linux into drm-next

drm/tegra: Changes for v5.3-rc1

This contains a couple of small improvements and cleanups for the Tegra
DRM driver.

Signed-off-by: Dave Airlie <[email protected]>
From: Thierry Reding <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agoMerge commit 'refs/for-upstream/mali-dp' of git://linux-arm.org/linux-ld into drm...
Dave Airlie [Tue, 25 Jun 2019 02:49:08 +0000 (12:49 +1000)]
Merge commit 'refs/for-upstream/mali-dp' of git://linux-arm.org/linux-ld into drm-next

Picking up pace on the upstreaming of Komeda driver, with quite a lot
of new features added this time. On top of that we have the small
cleanups and improved usage of the debugfs functions. Please pull!

Signed-off-by: Dave Airlie <[email protected]>
From: Liviu Dudau <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/i915/gem: Clear read/write domains for GPU clear
Chris Wilson [Mon, 24 Jun 2019 14:16:30 +0000 (15:16 +0100)]
drm/i915/gem: Clear read/write domains for GPU clear

Update the domains for the write via the GPU so that we do not
shortcircuit any set-domain clflush afterwards.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=110978
Fixes: b2dbf8d982a4 ("drm/i915/blt: Remove recursive vma->lock")
Signed-off-by: Chris Wilson <[email protected]>
Cc: Matthew Auld <[email protected]>
Reviewed-by: Matthew Auld <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/msm/a3xx: remove TPL1 regs from snapshot
Rob Clark [Mon, 24 Jun 2019 16:09:47 +0000 (09:09 -0700)]
drm/msm/a3xx: remove TPL1 regs from snapshot

These regs are write-only, and the hw throws a hissy-fit (ie. reboots)
when we try to read them for GPU state snapshot, in response to a GPU
hang.  It is rather impolite when GPU recovery triggers an insta-
reboot, so lets remove the TPL1 registers from the snapshot.

Fixes: 7198e6b03155 drm/msm: add a3xx gpu support
Signed-off-by: Rob Clark <[email protected]>
Reviewed-by: Jordan Crouse <[email protected]>
5 years agodrm/amdgpu: disable gfxoff on navi10
tiancyin [Thu, 20 Jun 2019 06:56:17 +0000 (14:56 +0800)]
drm/amdgpu: disable gfxoff on navi10

The gfxoff brings unstability, disable it by default

Reviewed-by: Hawking Zhang <[email protected]>
Signed-off-by: tiancyin <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amdgpu: fix modprobe failure for uvd_4/5/6
Hawking Zhang [Mon, 24 Jun 2019 11:26:00 +0000 (19:26 +0800)]
drm/amdgpu: fix modprobe failure for uvd_4/5/6

For uvd_4/5/6, amdgpu driver will only power on them when
there are jobs assigned to decode/enc rings.uvd_4/5/6 dpm was broken
since amdgpu_dpm_set_powergating_by_smu only covers gfx block.

The change would add more IP block support in amdgpu_dpm_set_powergating_by_smu
For GFX/UVD/VCN/VCE, if the new SMU driver is supported, invoke new
power gate helper function smu_dpm_set_power_gate, otherwise, fallback to
legacy powerplay helper function pp_set_powergating_by_smu. For other IP blocks
always invoke legacy powerplay helper function.

Signed-off-by: Hawking Zhang <[email protected]>
Reviewed-by: Tianci Yin <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/i915/execlists: Always clear ring_pause if we do not submit
Chris Wilson [Mon, 24 Jun 2019 09:20:09 +0000 (10:20 +0100)]
drm/i915/execlists: Always clear ring_pause if we do not submit

In the unlikely case (thank you CI!), we may find ourselves wanting to
issue a preemption but having no runnable requests left. In this case,
we set the semaphore before computing the preemption and so must unset
it before forgetting (or else we leave the machine busywaiting until the
next request comes along and so likely hang).

v2: Replace readback with only a wmb after asserting the semaphore

Signed-off-by: Chris Wilson <[email protected]>
Cc: Mika Kuoppala <[email protected]>
Reviewed-by: Mika Kuoppala <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
5 years agodrm/amdgpu: drop unused df init callback
Alex Deucher [Fri, 21 Jun 2019 21:32:25 +0000 (16:32 -0500)]
drm/amdgpu: drop unused df init callback

It was replaced with the sw_init callback so is no longer
needed.

Reviewed-by: Felix Kuehling <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amdgpu: add sw_init to df_v1_7
Jonathan Kim [Fri, 21 Jun 2019 02:23:35 +0000 (22:23 -0400)]
drm/amdgpu:  add sw_init to df_v1_7

change df_init to df_sw_init df 1.7 to prevent regression issues on pre-vega20
products when callback is called in sw_common_sw_init.

Reviewed-by: Felix Kuehling <[email protected]>
Signed-off-by: Jonathan Kim <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amdkfd: Set gws_mask to 64 bit 1s
Oak Zeng [Fri, 14 Jun 2019 15:55:50 +0000 (10:55 -0500)]
drm/amdkfd: Set gws_mask to 64 bit 1s

Previous kfd doesn't use gws so this mask was set to 0.
Set it to 64 bit 1s because now kfd can use all 64 gws
resources.

Signed-off-by: Oak Zeng <[email protected]>
Reviewed-by: Felix Kuehling <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/display/dc: set num-dwb = 1 as navi10 asic cap
hersen wu [Thu, 23 May 2019 22:49:39 +0000 (18:49 -0400)]
drm/amd/display/dc: set num-dwb = 1 as navi10 asic cap

during navi10 bring up, dwb causes system hang.
to continue debug major issue, disable dwb by
set num-dwb = 0. the hang issue is not reproduced now
by enable num-dwb =1. dc source is shared by all os.
win needs num-dwb = 1.

Signed-off-by: hersen wu <[email protected]>
Acked-by: Alex Deucher <[email protected]>
Reviewed-by: Roman Li <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/display: make clk_mgr call enable_pme_wa
Su Sung Chung [Thu, 30 May 2019 18:59:03 +0000 (14:59 -0400)]
drm/amd/display: make clk_mgr call enable_pme_wa

[why]
Before for raven and navi we are calling pp_smu functions for pme

[how]
refactor a code so we will call clk_mgr's enable_pme_wa function so we
can use pme_wa for future asics. This way we don't need to worry about
different ASIC since clk_mgr already have that information

Signed-off-by: Su Sung Chung <[email protected]>
Reviewed-by: Eric Yang <[email protected]>
Acked-by: Bhawanpreet Lakha <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/display: expose dentist_get_did_from_divider
Charlene Liu [Tue, 28 May 2019 23:44:32 +0000 (19:44 -0400)]
drm/amd/display: expose dentist_get_did_from_divider

for future use

Signed-off-by: Charlene Liu <[email protected]>
Reviewed-by: Dmytro Laktyushkin <[email protected]>
Acked-by: Bhawanpreet Lakha <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/display: add missing mod_vmid destructor
Dmytro Laktyushkin [Wed, 29 May 2019 15:24:35 +0000 (11:24 -0400)]
drm/amd/display: add missing mod_vmid destructor

mod_vmid is missing a destructor.

Signed-off-by: Dmytro Laktyushkin <[email protected]>
Reviewed-by: Charlene Liu <[email protected]>
Acked-by: Bhawanpreet Lakha <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/display: Add Underflow Asserts to dc
Thomas Lim [Mon, 29 Apr 2019 20:05:42 +0000 (16:05 -0400)]
drm/amd/display: Add Underflow Asserts to dc

[Why]
For debugging underflow issues it can be useful to have asserts when the
underflow initially occurs.

[How]
Read the underflow status registers after actions that have a high risk
of causing underflow and assert that no underflow occurred. If underflow
occurred, clear the bit.

Signed-off-by: Thomas Lim <[email protected]>
Reviewed-by: Eric Yang <[email protected]>
Acked-by: Bhawanpreet Lakha <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/display: move vmid determination logic to a module
Dmytro Laktyushkin [Wed, 22 May 2019 22:05:41 +0000 (18:05 -0400)]
drm/amd/display: move vmid determination logic to a module

Currently vmid is decided internally inside dc. With the introduction
of new asics we are required to coordinate vmid use with external
components.

This change converts vmid logic to a DAL module allowing vmid to be
passed in as a parameter to DC.

Signed-off-by: Dmytro Laktyushkin <[email protected]>
Reviewed-by: Charlene Liu <[email protected]>
Acked-by: Bhawanpreet Lakha <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/display: dcn2 use fixed clocks.
Charlene Liu [Tue, 28 May 2019 17:52:09 +0000 (13:52 -0400)]
drm/amd/display: dcn2 use fixed clocks.

[Description]
dcn2 use fixed clocks and not program DPP CLK or Disp_CLK.

Signed-off-by: Charlene Liu <[email protected]>
Reviewed-by: Dmytro Laktyushkin <[email protected]>
Acked-by: Bhawanpreet Lakha <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/display: add p010 and ayuv plane caps
Charlene Liu [Wed, 22 May 2019 22:25:33 +0000 (18:25 -0400)]
drm/amd/display: add p010 and ayuv plane caps

for future use

Signed-off-by: Charlene Liu <[email protected]>
Reviewed-by: Chris Park <[email protected]>
Acked-by: Bhawanpreet Lakha <[email protected]>
Acked-by: Krunoslav Kovac <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
5 years agodrm/amd/display: update DCN2 uclk switch time
Jun Lei [Mon, 27 May 2019 18:15:27 +0000 (14:15 -0400)]
drm/amd/display: update DCN2 uclk switch time

[why]
value commited to by HW team is going to be higher
than pre-silicon, and will cause underflow if driver not
updated

[how]
update hardcoded value, update pstate switching logic
to fix case where with long uclk time we won't allow switch
even when we should

Signed-off-by: Jun Lei <[email protected]>
Reviewed-by: Eric Yang <[email protected]>
Acked-by: Bhawanpreet Lakha <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
This page took 0.108683 seconds and 4 git commands to generate.