Commit graph

827745 commits

Author SHA1 Message Date
Dave Airlie 6ecac85ead drm/udl: move to embedding drm device inside udl device.
This should help with some of the lifetime issues, and move us away
from load/unload.

Acked-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20190405031715.5959-4-airlied@gmail.com
2019-04-24 13:48:45 +10:00
Dave Airlie fd96e0dba1 drm/udl: introduce a macro to convert dev to udl.
This just makes it easier to later embed drm into udl.

Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20190405031715.5959-3-airlied@gmail.com
2019-04-24 13:45:48 +10:00
Dave Airlie 331ca3a3d6 Log cleanups
- Correct the use of log macro in error case.
 - Drop unnecessary messages.
 - Replace DRM_ERROR/DEBUG with DRM_DEV_ERROR/DEBUG.
 - Print out debug messages with correct device name in vidi and ipp drivers.
 
 One trivial cleanup
 - Just fix checkpatch error, "foo* bar" to "foo *bar" in g2d driver.
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iQIcBAABAgAGBQJcv8lxAAoJEFc4NIkMQxK4c3AQAJ1BcnJgkSaWmt/4RPDxZ/TA
 CuZlqrvpteyj8lRQzO9Jlr822FianjFG1iS4y8EtoJT9fkqF6ca+jqp0Daw4DtgG
 bpc0twWKiJrPR7O8IZgitnNgZWCcoLQD99VrTs1VYoLmnXtQfPv/vlzA1cPamKML
 9T/jNaCN4gy8CZNsHnNkeHi9U9RmREloCRVmRimfzTRwYkiXF9gJ6cby/RTpaurE
 NRaML/PSD/Hz6Nkt6OkWVOxpcCPXlh6Q7lxt9wFI1Y6Nw5YR6GE6MVWapKFSx8z8
 +/2Nq46KvlHyo2pXVh2eqS86c/QCdi0DIM6w4OqjdfJNfXAE76R63OZI8sNkXxPy
 +zXOS2GSpPGs81TJUba8n44lLcjqhalZj5oE3fc7tj9axGhYi+f03oMSVF1WLrdH
 C2pEGoBnhjitGN9TgzT0Mylp05+oFs/17lU9BL69/rM5kzcovCiw+PvGx8ABH/7l
 XXwVnuUR9k5mMnZIFrdrptPCLEzYEns9an8qYwRnEllat+HCna1DH99cycXIEsHq
 LcSEA/+s+aal5rs5b1Feu+jQMmNARJVOVf9aNtAGaXy0TGT9DwsRCJtTyJPVuKUj
 QKxYx7e5AyAlCr1y1VfLgsp2CGWwQ5c4ai1VHKqbdJzs+r9NnzKWj3LGUV63SxdK
 sxNIY4zEp/e9vNPbtiop
 =vX5q
 -----END PGP SIGNATURE-----

Merge tag 'exynos-drm-next-for-v5.2' of git://git.kernel.org/pub/scm/linux/kernel/git/daeinki/drm-exynos into drm-next

Log cleanups
- Correct the use of log macro in error case.
- Drop unnecessary messages.
- Replace DRM_ERROR/DEBUG with DRM_DEV_ERROR/DEBUG.
- Print out debug messages with correct device name in vidi and ipp drivers.

One trivial cleanup
- Just fix checkpatch error, "foo* bar" to "foo *bar" in g2d driver.

Signed-off-by: Dave Airlie <airlied@redhat.com>

From: Inki Dae <inki.dae@samsung.com>
Link: https://patchwork.freedesktop.org/patch/msgid/1556073313-9923-1-git-send-email-inki.dae@samsung.com
2019-04-24 13:09:54 +10:00
Dave Airlie ee22f76306 drm/legacy: remove some legacy lock struct members
This removes these unless legacy is enabled.

The lock count init is unneeded anyways since it's kzalloc.

Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2019-04-24 12:36:32 +10:00
Dave Airlie 83c163f7eb drm/legacy: place all drm legacy members under DRM_LEGACY.
This places a bunch of the legacy members of drm_device into
only being there when legacy is enabled.

Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2019-04-24 12:33:30 +10:00
Dave Airlie 61ae227032 drm: allow removal of legacy codepaths (v4.1)
If you don't want the legacy drivers, then lets get rid of all the
legacy codepaths from the core module.

This drop the size of drm.ko for me by about 10%.
 380515    7422    4192  392129   5fbc1 ../../drm-next-build/drivers/gpu/drm/drm.ko
 351736	   7298	   4192	 363226	  58ada	../../drm-next-build/drivers/gpu/drm/drm.ko

v2: drop drm_lock as well, fix some DMA->DRM typos
v3: avoid ifdefs in mainline code
v4: rework ioctl defs
v4.1: fix nouveau Kconfig

Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2019-04-24 12:33:15 +10:00
Dave Airlie 848ee53894 drm/legacy: don't include any of ati_pcigart in legacy. (v2)
This could probably be done with Kconfig somehow, but I failed in my
first 2 minute attempt.

v2: use Kconfig better.

Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2019-04-24 12:32:51 +10:00
Dave Airlie 1fa32cb612 drm/legacy: move legacy dev reinit into legacy misc
This moves the legacy dev reinit into the legacy misc file.

Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2019-04-24 12:32:33 +10:00
Dave Airlie 8437dd73b3 drm/legacy: move init/destroy of struct members into legacy file
This introduces drm_legacy_misc.c as a place for some misc legacy code,
eventually I want to give the option to remove this from the build.

Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2019-04-24 12:32:18 +10:00
Dave Airlie fabb0e2a25 drm/legacy: move map_hash create/destroy into inlines
This allows them to be removed later.

Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2019-04-24 12:32:16 +10:00
Dave Airlie 058ca50ce3 drm/legacy: move lock cleanup for master into lock file (v2)
This makes it easier to remove legacy code later.

v2: move check into lock file as well.

Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2019-04-24 12:32:15 +10:00
Dave Airlie 9b7a77435c drm/radeon: drop unused ati pcigart include.
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2019-04-24 12:32:14 +10:00
Dave Airlie 35a280219b drm/legacy: move map cleanups into drm_bufs.c
This makes it easier to clean this up later.

Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2019-04-24 12:32:13 +10:00
Dave Airlie 15e60851e1 drm/legacy: move drm_legacy_master_rmmaps to non-driver legacy header.
This isn't used by drivers, and won't be in the future.

Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2019-04-24 12:32:11 +10:00
Dave Airlie b30a43ac71 drm/nouveau: add kconfig option to turn off nouveau legacy contexts. (v3)
There was a nouveau DDX that relied on legacy context ioctls to work,
but we fixed it years ago, give distros that have a modern DDX the
option to break the uAPI and close the mess of holes that legacy
context support is.

Full context of the story:

commit 0e975980d4
Author: Peter Antoine <peter.antoine@intel.com>
Date:   Tue Jun 23 08:18:49 2015 +0100

    drm: Turn off Legacy Context Functions

    The context functions are not used by the i915 driver and should not
    be used by modeset drivers. These driver functions contain several bugs
    and security holes. This change makes these functions optional can be
    turned on by a setting, they are turned off by default for modeset
    driver with the exception of the nouvea driver that may require them with
    an old version of libdrm.

    The previous attempt was

    commit 7c510133d9
    Author: Daniel Vetter <daniel.vetter@ffwll.ch>
    Date:   Thu Aug 8 15:41:21 2013 +0200

        drm: mark context support as a legacy subsystem

    but this had to be reverted

    commit c21eb21cb5
    Author: Dave Airlie <airlied@redhat.com>
    Date:   Fri Sep 20 08:32:59 2013 +1000

        Revert "drm: mark context support as a legacy subsystem"

    v2: remove returns from void function, and formatting (Daniel Vetter)

    v3:
    - s/Nova/nouveau/ in the commit message, and add references to the
      previous attempts
    - drop the part touching the drm hw lock, that should be a separate
      patch.

    Signed-off-by: Peter Antoine <peter.antoine@intel.com> (v2)
    Cc: Peter Antoine <peter.antoine@intel.com> (v2)
    Reviewed-by: Peter Antoine <peter.antoine@intel.com>
    Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>

v2: move DRM_VM dependency into legacy config.
v3: fix missing dep (kbuild robot)

Cc: stable@vger.kernel.org
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2019-04-24 12:32:10 +10:00
Inki Dae 8b9550344d drm/ipp: clean up debug messages
Print out debug messages with correct device name.

As for this, this patch adds device pointer to exynos_drm_ipp structure,
and in case of exynos_drm_ipp_task structure, replace drm_device pointer
with device one. This will make each ipp driver to print out debug
messages with correct device name.

Signed-off-by: Inki Dae <inki.dae@samsung.com>
2019-04-24 11:23:20 +09:00
Inki Dae df90a64eaf drm/vidi: replace platform_device pointer with device one
Add device pointer to vidi_context and remove platform_device pointer.

It doesn't need for vidi_context to contain platform_device object.
Instead, this patch makes this driver more simply by replacing platform_device
pointer with device one.

Signed-off-by: Inki Dae <inki.dae@samsung.com>
2019-04-24 11:23:20 +09:00
Inki Dae 6be900563a drm/exynos: use DRM_DEV_DEBUG* instead of DRM_DEBUG macro
Use DRM_DEV_DEBUG* instead of DRM_DEBUG macro to print out
debug messages.

This patch just cleans up the use of debug log macro, which changes
the log macro to DRM_DEV_DEBUG*.

Signed-off-by: Inki Dae <inki.dae@samsung.com>
2019-04-24 11:23:20 +09:00
Inki Dae 6f83d20838 drm/exynos: use DRM_DEV_ERROR to print out error message
This patch just cleans up the use of error log macro, which changes
the log macro to DRM_DEV_ERROR.

Signed-off-by: Inki Dae <inki.dae@samsung.com>
2019-04-24 11:23:20 +09:00
Inki Dae 62f28738f1 drm/exynos: remove unnecessary messages
This patch removes unnecessary messages from fimd_clear_channels
and decon_clear_channels functions which print out just function
name.

Signed-off-by: Inki Dae <inki.dae@samsung.com>
2019-04-24 11:23:20 +09:00
Inki Dae e59305305c drm/fimd: use DRM_ERROR instead of DRM_INFO in error case
This patch makes error messages to be printed out using DRM_ERROR
instead of DRM_INFO.

Signed-off-by: Inki Dae <inki.dae@samsung.com>
2019-04-24 11:23:20 +09:00
Seung-Woo Kim f9af3f846c drm/exynos: g2d: remove style error
Remove checkpatch error, "foo* bar" should be "foo *bar".

Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Signed-off-by: Inki Dae <inki.dae@samsung.com>
2019-04-24 11:23:20 +09:00
Dave Airlie 70b5f09e43 Merge tag 'drm-msm-next-2019-04-21' of https://gitlab.freedesktop.org/drm/msm into drm-next
This time around it is a bunch of cleanup and fixes, expanding gpu
"zap" shader support (so we can take the GPU out of secure mode on
boot) to a6xx, and small UABI extension to support robustness (see
mesa MR 673).

Signed-off-by: Dave Airlie <airlied@redhat.com>
From: Rob Clark <robdclark@gmail.com>
Link: https://patchwork.freedesktop.org/patch/msgid/CAF6AEGsHwsEfi4y2LYKSqeqDEYvffwVgKhiP8jHcHpxp13J5LQ@mail.gmail.com
2019-04-24 11:56:32 +10:00
Dave Airlie 42f1a01330 Merge branch 'drm-next-5.2' of git://people.freedesktop.org/~agd5f/linux into drm-next
- Add the amdgpu specific bits for timeline support
- Add internal interfaces for xgmi pstate support
- DC Z ordering fixes for planes
- Add support for NV12 planes in DC
- Add colorspace properties for planes in DC
- eDP optimizations if the GOP driver already initialized eDP
- DC bandwidth validation tracing support

Signed-off-by: Dave Airlie <airlied@redhat.com>
From: Alex Deucher <alexdeucher@gmail.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20190419150034.3473-1-alexander.deucher@amd.com
2019-04-24 11:46:19 +10:00
Dave Airlie 6e865c7230 drm/tegra: Changes for v5.2-rc1
This contains a fix for the usage of shared resets that previously
 generated a WARN on boot. In addition, there's a fix for CPU cache
 maintenance of GEM buffers allocated using get_pages().
 -----BEGIN PGP SIGNATURE-----
 
 iQJHBAABCAAxFiEEiOrDCAFJzPfAjcif3SOs138+s6EFAly4k7gTHHRyZWRpbmdA
 bnZpZGlhLmNvbQAKCRDdI6zXfz6zoUqkD/oC21pwikg0nYh1LoiH7GbmA3NPm56o
 Ei0cx9p8KyHUT0ongxmr0wfvyfCjwCqlFPWJOZrFOXjUmIupUooTbsqnAiHwEQE8
 6m2FaZXRpYc8VYk7+uW4u1MhmWr7fStuxVs/GKVZBK7jaxn3MXouL6fP3cOc8QK1
 GZdek2hxMDkvK1PnDc0MRx+COxsi3pMRL8hwBj++1EWPh3SGuOBsaj8S9dxXwSXH
 TrNCIpGV6BOL6y9g9uDGmqDM6lef90Dx0mRneuWK3pQoCbQJDMUsdVuNEKYI+wqZ
 hrfG9TZWeamK42OSX5GDM/DJwtb2K1z58Z410dlmc1IK9Inw7LcpYDHdoZQSmBgv
 5KwYgeqjQSYV9Ok1D0SY3grdroufg6PSHuE+VgD4SpQ4pbBrBvPUqxpi4icY0re9
 Td3FBzHzEMB14QWXIKWXfG7fd9pAKSesxaRaI3G9mtJrI1kIeRa3/0z8MQtSwbOg
 fxAZYXkCS2aeo9h6Owmhqm/lgYuv/SJ/1NOwLVJ6tgoI1rN0ukMe2OCPCOFmY7AJ
 ehiVBfXY7bjVYW3yhCUdm4w5ju/lmO5g2N4nqdpmcpvOz4QZE0aviPqcA5hiMfMQ
 5WKakqrJ1NGVMTQtKJxGgUq3BXEFqnMpKUkUMT+KVQinMjZOEu1klxlg4ScyZVdd
 Ly0z3PjsUbv+6g==
 =nA5m
 -----END PGP SIGNATURE-----

Merge tag 'drm/tegra/for-5.2-rc1' of git://anongit.freedesktop.org/tegra/linux into drm-next

drm/tegra: Changes for v5.2-rc1

This contains a fix for the usage of shared resets that previously
generated a WARN on boot. In addition, there's a fix for CPU cache
maintenance of GEM buffers allocated using get_pages().

(airlied: contains a merge from a shared tegra tree)

Signed-off-by: Dave Airlie <airlied@redhat.com>

From: Thierry Reding <thierry.reding@gmail.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20190418151447.9430-1-thierry.reding@gmail.com
2019-04-24 10:30:45 +10:00
Dave Airlie 8d8f6f7044 drm-misc-next for v5.2:
UAPI Changes:
 - Document which feature flags belong to which command in virtio_gpu.h
 - Make the FB_DAMAGE_CLIPS available for atomic userspace only, it's useless for legacy.
 
 Cross-subsystem Changes:
 - Add device tree bindings for lg,acx467akm-7 panel and ST-Ericsson Multi Channel Display Engine MCDE
 - Add parameters to the device tree bindings for tfp410
 - iommu/io-pgtable: Add ARM Mali midgard MMU page table format
 - dma-buf: Only do a 64-bits seqno compare when driver explicitly asks for it, else wraparound.
 - Use the 64-bits compare for dma-fence-chains
 
 Core Changes:
 - Make the fb conversion functions use __iomem dst.
 - Rename drm_client_add to drm_client_register
 - Move intel_fb_initial_config to core.
 - Add a drm_gem_objects_lookup helper
 - Add drm_gem_fence_array helpers, and use it in lima.
 - Add drm_format_helper.c to kerneldoc.
 
 Driver Changes:
 - Add panfrost driver for mali midgard/bitfrost.
 - Converts bochs to use the simple display type.
 - Small fixes to sun4i, tinydrm, ti-fp410.
 - Fid aspeed's Kconfig options.
 - Make some symbols/functions static in lima, sun4i and meson.
 - Add a driver for the lg,acx467akm-7 panel.
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEuXvWqAysSYEJGuVH/lWMcqZwE8MFAly4N1oACgkQ/lWMcqZw
 E8OJNQ//fk8+8TkupJTiBYjsAIbo4pRrWa29zQFhiqEhG2kpDESr1YjkeN3uQ+wg
 R6laOUt1jMNiV/BRBUlsv95cbZ0eda3mDPyFOqni8qBoUf0o4NMgLhuLK6qPeMyN
 76u/VZCwYl1AZGiyi33xMABWZ0WmRkwaGxG8gDW/pGU2klRX6T7XgZPDnXrX/jJC
 xq9QUWsOKoBVXX6OtYQPiL6WslbHh97sPzzs5dljJuLOWIug6xFWarUYK6vPnzU1
 HVNcu2/oS6VMCRAW+Ocf4dlcfIN7PvKL984AOcZH3SLB5qabhbjB14e10RivJGZx
 O2yhqNsdF42HcvA08EnwzNvtNS9Rj/GNuw95KHEU+pKZGZ6dQo/fFivm2DoeOqub
 piQlTjVqrHhpNhKg+h8Bd5jUQjx97TPy+PjFtjvCZznZpp8SK8T12yrN+MK4W1ml
 vzMYSaMWiUYNbdixSQH0L90i555uMQgOXh53mKNEovPkh1SKlcsMbONuJIEphpne
 jOT89O9AhtwGu4179cTHRPWpsDcWw/Uoji5wcWZkjeBWdwjwXDGXiIHePN1KAcw9
 qBERJs+yVujgmAvjnJwbe78QlYB1+wgtPdvWAGR0gmu31J1WVL1ADMLFe0YQ5RIz
 huXetCYJzYzv8PxWAPUkky/vUFq4EZQkEQFzGQPtrZje5sH2mko=
 =7Hyr
 -----END PGP SIGNATURE-----

Merge tag 'drm-misc-next-2019-04-18' of git://anongit.freedesktop.org/drm/drm-misc into drm-next

drm-misc-next for v5.2:

UAPI Changes:
- Document which feature flags belong to which command in virtio_gpu.h
- Make the FB_DAMAGE_CLIPS available for atomic userspace only, it's useless for legacy.

Cross-subsystem Changes:
- Add device tree bindings for lg,acx467akm-7 panel and ST-Ericsson Multi Channel Display Engine MCDE
- Add parameters to the device tree bindings for tfp410
- iommu/io-pgtable: Add ARM Mali midgard MMU page table format
- dma-buf: Only do a 64-bits seqno compare when driver explicitly asks for it, else wraparound.
- Use the 64-bits compare for dma-fence-chains

Core Changes:
- Make the fb conversion functions use __iomem dst.
- Rename drm_client_add to drm_client_register
- Move intel_fb_initial_config to core.
- Add a drm_gem_objects_lookup helper
- Add drm_gem_fence_array helpers, and use it in lima.
- Add drm_format_helper.c to kerneldoc.

Driver Changes:
- Add panfrost driver for mali midgard/bitfrost.
- Converts bochs to use the simple display type.
- Small fixes to sun4i, tinydrm, ti-fp410.
- Fid aspeed's Kconfig options.
- Make some symbols/functions static in lima, sun4i and meson.
- Add a driver for the lg,acx467akm-7 panel.

Signed-off-by: Dave Airlie <airlied@redhat.com>

From: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/737ad994-213d-45b5-207a-b99d795acd21@linux.intel.com
2019-04-24 10:12:50 +10:00
Dave Airlie b1c4f7fead Merge tag 'drm-intel-next-2019-04-17' of git://anongit.freedesktop.org/drm/drm-intel into drm-next
UAPI Changes:

- uAPI "Fixes:" patch for the upcoming kernel 5.1, included here too

  We have an Ack from the media folks (only current user) for this
  late tweak

Cross-subsystem Changes:

- ALSA: hda: Fix racy display power access (Takashi, Chris)

Driver Changes:

- DDI and MIPI-DSI clocks fixes for Icelake (Vandita)
- Fix Icelake frequency change/locking (RPS) (Mika)
- Temporarily disable ppGTT read-only bit on Icelake (Mika)
- Add missing Icelake W/As (Mika)
- Enable 12 deep CSB status FIFO on Icelake (Mika)
- Inherit more Icelake code for Elkhartlake (Bob, Jani)

- Handle catastrophic error on engine reset (Mika)
- Shortcut readiness to reset check (Mika)
- Regression fix for GEM_BUSY causing us to report a mixed uabi-class request as not busy (Chris)
- Revert back to max link rate and lane count on eDP (Jani)
- Fix pipe BPP readout for BXT/GLK DSI (Ville)
- Set DP min_bpp to 8*3 for non-RGB output formats (Ville)
- Enable coarse preemption boundaries for Gen8 (Chris)
- Do not enable FEC without DSC (Ville)
- Restore correct BXT DDI latency optim setting calculation (Ville)
- Always reset context's RING registers to avoid running workload twice during reset (Chris)
- Set GPU wedged on driver unload (Janusz)
- Consolidate two similar barries from timeline into one (Chris)
- Only reset the pinned kernel contexts on resume (Chris)
- Wakeref tracking improvements (Chris, Imre)
- Lockdep fixes for shrinker interactions (Chris)
- Bump ready tasks ahead of busywaits in prep of semaphore use (Chris)

- Huge step in splitting display code into fine grained files (Jani)
- Refactor the IRQ init/reset macros for code saving (Paulo)
- Convert IRQ initialization code to uncore MMIO access (Paulo)
- Convert workarounds code to use uncore MMIO access (Chris)
- Nuke drm_crtc_state and use intel_atomic_state instead (Manasi)
- Update SKL clock-gating WA (Radhakrishna, Ville)
- Isolate GuC reset code flow (Chris)
- Expose force_dsc_enable through debugfs (Manasi)
- Header standalone compile testing framework (Jani)
- Code cleanups to reduce driver footprint (Chris)
- PSR code fixes and cleanups (Jose)
- Sparse and kerneldoc updates (Chris)
- Suppress spurious combo PHY B warning (Vile)

Signed-off-by: Dave Airlie <airlied@redhat.com>
From: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20190418080426.GA6409@jlahtine-desk.ger.corp.intel.com
2019-04-24 10:02:20 +10:00
Jun Lei a9a3c0da14 drm/amd/display: add explicit handshake between x86 and DMCU
[why]
When DMCU interrupts x86, it leads to undefined phy programming

[how]
expand dmcu interface to support new PHY lock and unlock commands
if DMCU FW doesn't support these commands, they fail silently so its okay

Signed-off-by: Jun Lei <Jun.Lei@amd.com>
Reviewed-by: Anthony Koo <Anthony.Koo@amd.com>
Acked-by: Leo Li <sunpeng.li@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2019-04-23 17:28:19 -05:00
Eric Bernstein cc602e2b0d drm/amd/display: Allow cursor position when plane_res.ipp is NULL
[Why]
Starting with DCN1, the input_pixel_processor (ipp) struct has been
replaced by dpp struct (part of DAL3.1 SW architecture change).
Need to update logic to handle cases where ipp is never allocated.

[How]
Only skip cursor position programming if both ipp and dpp resources
are NULL.

Signed-off-by: Eric Bernstein <eric.bernstein@amd.com>
Reviewed-by: Dmytro Laktyushkin <Dmytro.Laktyushkin@amd.com>
Acked-by: Leo Li <sunpeng.li@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2019-04-23 17:28:11 -05:00
Aric Cyr 00ae0af700 drm/amd/display: 3.2.27
Signed-off-by: Aric Cyr <aric.cyr@amd.com>
Reviewed-by: Aric Cyr <Aric.Cyr@amd.com>
Acked-by: Leo Li <sunpeng.li@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2019-04-23 17:28:05 -05:00
Anthony Koo 5b7c0d8d2b drm/amd/display: Fix eDP Black screen after S4 resume
[Why]
Power down of PHY on eDP requires us to call eDP power
control to power on again

[How]
1. In the case link rates don't match, disable PHY
requires calling of eDP power control ON after

2. Link disable case limit to eDP path since
this is not really applicable to DP since we do
power down PHY as part of verify link cap

3. Move detection of eDP link settings to be
done even for S4 resume cases where other
dpcd cap read and edid read can be skipped

Signed-off-by: Anthony Koo <Anthony.Koo@amd.com>
Reviewed-by: Jun Lei <Jun.Lei@amd.com>
Acked-by: Aric Cyr <Aric.Cyr@amd.com>
Acked-by: Leo Li <sunpeng.li@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2019-04-23 17:27:58 -05:00
Anthony Koo abdef75583 drm/amd/display: Send DMCU messages only if FW loaded
[Why]
Some DMCU messages were being sent in cases where
there was no DMCU FW at all, which resulted in some wait
timeouts

[How]
Delay sending some of the DMCU messages after FW
init is called and DMCU is running.

Signed-off-by: Anthony Koo <Anthony.Koo@amd.com>
Reviewed-by: Aric Cyr <Aric.Cyr@amd.com>
Acked-by: Leo Li <sunpeng.li@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2019-04-23 17:27:51 -05:00
Wenjing Liu 43e3ac8389 drm/amd/display: Add function to copy DC streams
We'll need the ability to copy a dc_stream_state for some features.
Implement it here.

Signed-off-by: Wenjing Liu <Wenjing.Liu@amd.com>
Reviewed-by: Jun Lei <Jun.Lei@amd.com>
Acked-by: Leo Li <sunpeng.li@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2019-04-23 17:27:45 -05:00
Anthony Koo 41629f02c6 drm/amd/display: Allow system to enter stutter on init
[Why]
Workaround was missing in one HW disable path,
meaning when all pipes are power gated, stutter was
not working

[How]
Add workaround for init_hw path for stutter
workaround

Signed-off-by: Anthony Koo <Anthony.Koo@amd.com>
Reviewed-by: Aric Cyr <Aric.Cyr@amd.com>
Acked-by: Leo Li <sunpeng.li@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2019-04-23 17:27:32 -05:00
Leo Li bb20be7510 drm/amdgpu: Check if SW SMU is supported before accessing funcs
smu.ppt_funcs is only initialized for ASICs supporting SW SMU.

On a Hawaii ASIC, attempting to access the udev attribute
ATTRS{power_dpm_state} will cause a null pointer deref in
amdgpu_get_dpm_state() because of this.

Fix by checking if SW SMU is supported first.

Signed-off-by: Leo Li <sunpeng.li@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Reviewed-by: Huang Rui <ray.huang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2019-04-23 17:27:25 -05:00
Leo Li 3b8cea6f64 drm/amd/include: Add HUBPREQ_DEBUG register offsets
They will be used by DC when runing ASIC-specific HUBP initialization.

Signed-off-by: Leo Li <sunpeng.li@amd.com>
Acked-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2019-04-23 17:27:08 -05:00
Dave Airlie b3edf499dd Merge branch 'vmwgfx-next' of https://gitlab.freedesktop.org/drawat/linux into drm-next
Resource dirtying improvement by Thomas,
user-space error logging improvement and
some other minor fixes.

Signed-off-by: Dave Airlie <airlied@redhat.com>
From: Deepak Rawat <drawat@vmware.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20190423211630.61874-1-drawat@vmware.com
2019-04-24 07:21:39 +10:00
Andrey Grodzovsky f83088981a drm/amd/display: Use a reasonable timeout for framebuffer fence waits
Patch '5edb0c9b Fix deadlock with display during hanged ring recovery'
was accidentaly removed during one of DALs code merges.

Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky@amd.com>
Reviewed-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2019-04-23 12:09:26 -05:00
Christian König 2fac0f53fe drm/amd/display: wait for fence without holding reservation lock
Don't block others while waiting for the fences to finish, concurrent
submission is perfectly valid in this case and holding the lock can
prevent killed applications from terminating.

Signed-off-by: Christian König <ckoenig.leichtzumerken@gmail.com>
Reviewed-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2019-04-23 12:09:26 -05:00
Andrey Grodzovsky 77e7f82985 drm/amdgpu: Change VRAM lost print from ERR to INF
It's normal for VRAM to lost during GPU reset and so change
the log level to INFO to avoid confusing users.

Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2019-04-23 12:09:26 -05:00
Chengming Gui 8d01071d26 drm/amd/powerplay: enable UMDPSTATE support on raven2 (v2)
enable UMDPSTATE support to force performance level for raven2.

v2: squash in warning fix (Alex)

Signed-off-by: Chengming Gui <Jack.Gui@amd.com>
Reviewed-by: Huang Rui <ray.huang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2019-04-23 12:09:14 -05:00
Chengming Gui 45516e91c2 drm/amd/powerplay: add set/get_power_profile_mode for Raven (v2)
The power profile allows the user to adjust the power state
heuristics for clock level transitions.

v2: squash in warning fix (Alex)

Reviewed-by: Evan Quan <evan.quan@amd.com>
Reviewed-by: Huang Rui <ray.huang@amd.com>
Signed-off-by: Chengming Gui <Jack.Gui@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2019-04-23 12:08:48 -05:00
Marco Felsch 9158e3c311 drm/panel: simple: Add Evervision VGG804821 panel support
Add support the Evervision VGG804821 800x480 5.0" WVGA TFT panel.

Signed-off-by: Marco Felsch <m.felsch@pengutronix.de>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20190416100645.21689-4-m.felsch@pengutronix.de
2019-04-23 14:25:32 +02:00
Marco Felsch 81c2d54ad9 dt-bindings: Add Evervision VGG804821 panel
Add device tree bindings for the Evervision VG804821 800x480 5.0" LCD
TFT parallel panel.

Signed-off-by: Marco Felsch <m.felsch@pengutronix.de>
Reviewed-by: Rob Herring <robh@kernel.org>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20190416100645.21689-3-m.felsch@pengutronix.de
2019-04-23 14:24:22 +02:00
Marco Felsch fbd8b69ab6 dt-bindings: Add vendor prefix for Evervision Electronics
Evervision Electronics is a panel manufacturer from Taipei.
http://www.evervisionlcd.com/index.php?lang=en

Signed-off-by: Marco Felsch <m.felsch@pengutronix.de>
Reviewed-by: Rob Herring <robh@kernel.org>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20190416100645.21689-2-m.felsch@pengutronix.de
2019-04-23 14:23:47 +02:00
Andreas Pretzsch c2d24af620 drm/panel: simple: Add support for EDT ET035012DM6
Add support for the EDT ET035012DM6 3.5" 320x240 QVGA 24-bit RGB TFT.

The datasheet with all specs can be retrieved online:
https://www.glynshop.com/erp/owweb/Daten/DSS/EDT/Products/ \
Specifications/Active%20Displays/ET035012DM6.pdf

Signed-off-by: Andreas Pretzsch <apr@cn-eng.de>
[m.felsch@pengutronix.de: adapt commit message]
[m.felsch@pengutronix.de: rm unecessary comments]
[m.felsch@pengutronix.de: correct data_enable polarity]
Signed-off-by: Marco Felsch <m.felsch@pengutronix.de>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20190416101630.3482-2-m.felsch@pengutronix.de
2019-04-23 14:22:27 +02:00
Marco Felsch c9219ae4bd dt-bindings: display: add EDT ET035012DM6 display description
Add support for the ET035012DM6 3.5" QVGA TFT LCD panel. The datasheet
can be retrieved online:

https://www.glynshop.com/erp/owweb/Daten/DSS/EDT/Products/ \
Specifications/Active%20Displays/ET035012DM6.pdf

Signed-off-by: Marco Felsch <m.felsch@pengutronix.de>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20190416101630.3482-1-m.felsch@pengutronix.de
2019-04-23 14:20:53 +02:00
Souptick Joarder 0a4330f359 drm/panel: Remove duplicate header
Remove duplicate header which is included twice.

Signed-off-by: Souptick Joarder <jrdr.linux@gmail.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Link: https://patchwork.freedesktop.org/patch/msgid/1555183750-11028-1-git-send-email-jrdr.linux@gmail.com
2019-04-23 14:18:59 +02:00
Jyri Sarha 4216153182 drm/panel: simple: Add TFC S9700RTWV43TR-01B 800x480 panel support
Add support for Three Five displays TFC S9700RTWV43TR-01B 800x480
panel with resistive touch found on TI's AM335X-EVM.

Signed-off-by: Jyri Sarha <jsarha@ti.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Link: https://patchwork.freedesktop.org/patch/msgid/ba4b2c26beec014b7b3c84a27b9413cec7ef2902.1553243203.git.jsarha@ti.com
2019-04-23 14:15:23 +02:00
Jyri Sarha b1b0d36bdb dt-bindings: drm/panel: simple: Add binding for TFC S9700RTWV43TR-01B
Add bindign for TFC S9700RTWV43TR-01B 7" Three Five Corp 800x480 LCD
panel with resistive touch.

The panel is found on TI AM335x-evm.

Signed-off-by: Jyri Sarha <jsarha@ti.com>
Reviewed-by: Rob Herring <robh@kernel.org>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Link: https://patchwork.freedesktop.org/patch/msgid/24fea39438decd1e17a9c9afa320d49aca03f60d.1553243203.git.jsarha@ti.com
2019-04-23 14:15:06 +02:00