Laurent Pinchart
31aea15a84
drm: rcar-du: Fix typo in comment
...
Fix the misspelled 'belance' in a comment.
Reported-by: Ulrich Hecht <uli+renesas@fpond.eu >
Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com >
2018-11-23 13:51:22 +02:00
Thomas Zimmermann
c0ece6742d
drm/shmobile: Replace drm_dev_unref with drm_dev_put
...
This patch unifies the naming of DRM functions for reference counting
of struct drm_device. The resulting code is more aligned with the rest
of the Linux kernel interfaces.
Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de >
Reviewed-by: Simon Horman <horms+renesas@verge.net.au >
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com >
Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com >
2018-11-23 13:51:21 +02:00
Thomas Zimmermann
06fa0d46b1
drm/rcar-du: Replace drm_dev_unref with drm_dev_put
...
This patch unifies the naming of DRM functions for reference counting
of struct drm_device. The resulting code is more aligned with the rest
of the Linux kernel interfaces.
Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de >
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com >
Reviewed-by: Simon Horman <horms+renesas@verge.net.au >
Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com >
2018-11-23 13:51:21 +02:00
Jani Nikula
b4bf44d2dc
drm/i915: Update DRIVER_DATE to 20181122
...
Signed-off-by: Jani Nikula <jani.nikula@intel.com >
2018-11-22 16:49:47 +02:00
Noralf Trønnes
10fdb7d2ad
drm/prime: Fix drm_gem_prime_mmap() stack use
...
drivers/gpu/drm/drm_prime.c: In function 'drm_gem_prime_mmap':
>> drivers/gpu/drm/drm_prime.c:688:1: warning: the frame size of 1592 bytes is larger than 1024 bytes [-Wframe-larger-than=]
Fix by allocating on the heap.
Fixes: 7698799f95
("drm/prime: Add drm_gem_prime_mmap()")
Reported-by: kbuild test robot <lkp@intel.com >
Cc: Daniel Vetter <daniel.vetter@ffwll.ch >
Cc: Christian König <christian.koenig@amd.com >
Signed-off-by: Noralf Trønnes <noralf@tronnes.org >
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch >
Link: https://patchwork.freedesktop.org/patch/msgid/20181121180215.13881-1-noralf@tronnes.org
2018-11-22 15:44:05 +01:00
Jani Nikula
835cb5c500
drm/i915: Update DRIVER_DATE to 20181122
...
Signed-off-by: Jani Nikula <jani.nikula@intel.com >
2018-11-22 16:03:03 +02:00
Hans Holmberg
95fd94a645
drm/i915: avoid rebuilding i915_gpu_error.o on version string updates
...
There is no need to rebuild i915_gpu_error.o when the version string
changes as the version is available in init_utsname()->release.
Signed-off-by: Hans Holmberg <hans.holmberg@cnexlabs.com >
Reviewed-by: Jani Nikula <jani.nikula@intel.com >
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com >
Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181121095423.20760-1-hans.ml.holmberg@owltronix.com
2018-11-22 11:46:57 +02:00
Qiang Yu
7b24eec754
drm/sun4i: wait on implicit fence before display
...
Render like lima will attach a fence to the framebuffer
dma_buf, display like sun4i should wait it finish before
show the framebuffer. Otherwise tearing will be observed.
Signed-off-by: Qiang Yu <yuq825@gmail.com >
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch >
Link: https://patchwork.freedesktop.org/patch/msgid/20181122014417.23285-1-yuq825@gmail.com
2018-11-22 10:07:26 +01:00
Daniel Vetter
c6fdea6e1a
drm: Merge drm_info.c into drm_debugfs.c
...
Ever since
commit cb6458f97b
Author: Daniel Vetter <daniel.vetter@ffwll.ch >
Date: Thu Aug 8 15:41:34 2013 +0200
drm: remove procfs code, take 2
Having the code shared between procfs and debugfs in the separate
drm_info.c file stopped making sense. Merge them.
Noticed because Lyude asked some questions on irc about why we even
have drm_info_node and I remember this old story.
Cc: Lyude Paul <lyude@redhat.com >
Reviewed-by: Lyude Paul <lyude@redhat.com >
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181121213510.31260-1-daniel.vetter@ffwll.ch
2018-11-22 09:52:27 +01:00
Dave Airlie
b239499f92
Merge tag 'drm-misc-next-2018-11-21' of git://anongit.freedesktop.org/drm/drm-misc into drm-next
...
drm-misc-next for v4.21, part 2:
UAPI Changes:
- Remove syncobj timeline support from drm.
Cross-subsystem Changes:
- Document canvas provider node in the DT bindings.
- Improve documentation for TPO TPG110 DT bindings.
Core Changes:
- Use explicit state in drm atomic functions.
- Add panel quirk for new GPD Win2 firmware.
- Add DRM_FORMAT_XYUV8888.
- Set the default import/export function in prime to drm_gem_prime_import/export.
- Add a separate drm_gem_object_funcs, to stop relying on dev->driver->*gem* functions.
- Make sure that tinydrm sets the virtual address also on imported buffers.
Driver Changes:
- Support active-low data enable signal in sun4i.
- Fix scaling in vc4.
- Use canvas provider node in meson.
- Remove unused variables in sti and qxl and cirrus.
- Add overlay plane support and primary plane scaling to meson.
- i2c fixes in drm/bridge/sii902x
- Fix mailbox read size in rockchip.
- Spelling fix in panel/s6d16d0.
- Remove unnecessary null check from qxl_bo_unref.
- Remove unused arguments from qxl_bo_pin.
- Fix qxl cursor pinning.
Signed-off-by: Dave Airlie <airlied@redhat.com >
From: Maarten Lankhorst <maarten.lankhorst@linux.intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/9c0409e3-a85f-d2af-b4eb-baf1eb8bbae4@linux.intel.com
2018-11-22 12:54:38 +10:00
Chris Wilson
aa6a65daca
drm/i915: Show waiter's status on engine dump
...
When showing the list of waiters, include the task's status so that we
can tell if they have been woken up and are waiting for the CPU, or if
they are still waiting to be woken.
v2: task_state_to_char()
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk >
Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com >
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com >
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181121151653.24595-1-chris@chris-wilson.co.uk
2018-11-21 15:57:46 +00:00
Ville Syrjälä
f43348a3db
drm/i915: Add rotation readout for plane initial config
...
If we need to force a full plane update before userspace/fbdev
have given us a proper plane state we should try to maintain the
current plane state as much as possible (apart from the parts
of the state we're trying to fix up with the plane update).
To that end add basic readout for the plane rotation and
maintain it during the initial fb takeover.
Cc: Hans de Goede <hdegoede@redhat.com >
Fixes: 516a49cc19
("drm/i915: Fix assert_plane() warning on bootup with external display")
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181120135450.3634-2-ville.syrjala@linux.intel.com
Tested-by: Hans de Goede <hdegoede@redhat.com >
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com >
Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com >
2018-11-21 14:10:24 +02:00
Ville Syrjälä
fa6af5145b
drm/i915: Force a LUT update in intel_initial_commit()
...
If we force a plane update to fix up our half populated plane state
we'll also force on the pipe gamma for the plane (since we always
enable pipe gamma currently). If the BIOS hasn't programmed a sensible
LUT into the hardware this will cause the image to become corrupted.
Typical symptoms are a purple/yellow/etc. flash when the driver loads.
To avoid this let's program something sensible into the LUT when
we do the plane update. In the future I plan to add proper plane
gamma enable readout so this is just a temporary measure.
Cc: Hans de Goede <hdegoede@redhat.com >
Fixes: 516a49cc19
("drm/i915: Fix assert_plane() warning on bootup with external display")
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181120135450.3634-1-ville.syrjala@linux.intel.com
Tested-by: Hans de Goede <hdegoede@redhat.com >
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com >
2018-11-21 14:01:54 +02:00
Imre Deak
8f19b401a6
drm/i915: Make CHICKEN_TRANS reg not depend on enum value
...
Depending on the transcoder enum values to translate from transcoder to
the corresponding CHICKEN_TRANS register can easily break if we add a
new transcoder. Add an explicit mapping instead, by using helpers to
look up the register instance either by transcoder or port (since
unconveniently the registers have both port and transcoder specific
bits).
While at it also check for the correctness of GEN, port, transcoder. I
wasn't sure if psr2_enabled can only be set for GEN9+, but that seems to
be the case indeed (see setting of sink_psr2_support in
intel_psr_init_dpcd()).
v2 (Ville):
- Make gen9_chicken_trans_reg() internal to intel_psr.c.
- s/trans/cpu_transcoder/
Cc: Ville Syrjälä <ville.syrjala@linux.intel.com >
Cc: Lucas De Marchi <lucas.demarchi@intel.com >
Cc: Mika Kahola <mika.kahola@intel.com >
Signed-off-by: Imre Deak <imre.deak@intel.com >
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181119180021.370-1-imre.deak@intel.com
2018-11-21 13:45:33 +02:00
Imre Deak
8f78df90d8
drm/i915: Add code comment on assumption of pipe==transcoder
...
Add a comment to the pipe and transcoder enum definitions about our
assumption in the code about enum values for pipes and transcoders
with a 1:1 transcoder -> pipe mapping.
v2:
- Clarify more what are the assumptions about the enum values. (Ville)
v3: (Lucas)
- s/->/ -> / so it looks less like pointer dereferencing.
- Use pipe enums as initializers in the transcoder enum definition.
Cc: Ville Syrjälä <ville.syrjala@linux.intel.com >
Cc: Lucas De Marchi <lucas.demarchi@intel.com >
Cc: Mika Kahola <mika.kahola@intel.com >
Signed-off-by: Imre Deak <imre.deak@intel.com >
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com > (v2)
Link: https://patchwork.freedesktop.org/patch/msgid/20181120092325.21249-3-imre.deak@intel.com
2018-11-21 13:38:27 +02:00
Imre Deak
c0871805ce
drm/i915: Make EDP PSR flags not depend on enum values
...
Depending on the transcoder enum values to translate from transcoder
to EDP PSR flags can easily break if we add a new transcoder. So remove
the dependency by using an explicit mapping.
While at it also add a WARN for unexpected trancoders.
v2:
- Simplify things by defining flag shift values instead of indices.
- s/trans/cpu_transcoder/ (Ville)
v3:
- Define flags to look like separate bits instead of the values of
the same bitfield. (Ville)
Cc: Ville Syrjälä <ville.syrjala@linux.intel.com >
Cc: Lucas De Marchi <lucas.demarchi@intel.com >
Cc: Mika Kahola <mika.kahola@intel.com >
Signed-off-by: Imre Deak <imre.deak@intel.com >
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181120092325.21249-2-imre.deak@intel.com
2018-11-21 13:38:20 +02:00
Imre Deak
931f54920b
drm/i915: Make pipe/transcoder offsets not depend on enum values
...
Depending on the transcoder enum values to translate from transcoder
to pipe/transcoder register addresses can easily break if we add a new
transcoder. So remove the dependency by using named initializers.
Suggested-by: Ville Syrjälä <ville.syrjala@linux.intel.com >
Cc: Ville Syrjälä <ville.syrjala@linux.intel.com >
Signed-off-by: Imre Deak <imre.deak@intel.com >
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181120092325.21249-1-imre.deak@intel.com
2018-11-21 13:37:59 +02:00
Koen Kooi
42843dc2d5
drm/meson: Add implicit fencing support for primary and overlay planes
...
Suggested by Qiang Yu <yuq825@gmail.com > to fix tearing artefacts in the
Kodi GUI.
Suggested-by: Qiang Yu <yuq825@gmail.com >
Signed-off-by: Koen Kooi <koen@dominion.thruhere.net >
Acked-by: Neil Armstrong <narmstrong@baylibre.com >
[narmstrong: added Suggested-by tag]
Signed-off-by: Neil Armstrong <narmstrong@baylibre.com >
Link: https://patchwork.freedesktop.org/patch/msgid/1542621759-26413-1-git-send-email-koen@dominion.thruhere.net
2018-11-21 12:20:53 +01:00
Gerd Hoffmann
b4b01b4995
drm/virtio: add edid support
...
linux guest driver implementation of the VIRTIO_GPU_F_EDID feature.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com >
Acked-by: Daniel Vetter <daniel@ffwll.ch >
Link: http://patchwork.freedesktop.org/patch/msgid/20181030063206.19528-3-kraxel@redhat.com
2018-11-21 12:06:59 +01:00
Gerd Hoffmann
610c0c2b28
virtio-gpu: add VIRTIO_GPU_F_EDID feature
...
The feature allows the guest request an EDID blob (describing monitor
capabilities) for a given scanout (aka virtual monitor connector).
It brings a new command message, which has just a scanout field (beside
the standard virtio-gpu header) and a response message which carries the
EDID data.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com >
Reviewed-by: Dave Airlie <airlied@redhat.com >
Link: http://patchwork.freedesktop.org/patch/msgid/20181030063206.19528-2-kraxel@redhat.com
2018-11-21 12:06:59 +01:00
Alexandre Belloni
3c64ea8c98
drm/i915: fix spelling mistake "reserverd" -> "reserved"
...
Fix a spelling mistake in a comment.
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com >
Signed-off-by: Jani Nikula <jani.nikula@intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181120151415.32419-1-alexandre.belloni@bootlin.com
2018-11-21 11:11:44 +02:00
Christophe Fergeau
0081cdfe63
qxl: Make sure qxl_cursor memory is pinned
...
QEMU keeps a vram reference to the last QXLCursorCmd it received.
This QXLCursorCmd command points to a QXLCursor instance (stored in vram
too). However, while the QXLCursorCmd memory is pinned, the QXLCursor
memory is not.
When booting a recent Fedora to its login screen while monitoring the
QXLCursorCmd QEMU holds, it's possible to see the QXLCursor memory
becoming invalid shortly after boot. Pinning that memory ensures that
that QXLCursor memory is not going to be moved by the guest kernel.
Moving the pin/unpin to qxl_release_list_add()/qxl_release_free_list()
would be a more generic fix. However, doing this quickly exhausts QXL
video memory, so more fixing would be needed before this is workable.
Signed-off-by: Christophe Fergeau <cfergeau@redhat.com >
Link: http://patchwork.freedesktop.org/patch/msgid/20181120162004.22807-3-cfergeau@redhat.com
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com >
2018-11-21 09:12:46 +01:00
Christophe Fergeau
545592fb3d
qxl: Remove unused qxl_bo_pin arguments
...
The 'domain' argument to qxl_bo_pin is redundant with 'bo', and
'gpu_addr' is unused, so we can remove both.
Signed-off-by: Christophe Fergeau <cfergeau@redhat.com >
Link: http://patchwork.freedesktop.org/patch/msgid/20181120162004.22807-2-cfergeau@redhat.com
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com >
2018-11-21 09:12:45 +01:00
Christophe Fergeau
76a57db4a8
qxl: No need for NULL check before calling qxl_bo_unref()
...
qxl_bo_unref() is already performing a NULL check.
Signed-off-by: Christophe Fergeau <cfergeau@redhat.com >
Link: http://patchwork.freedesktop.org/patch/msgid/20181120162004.22807-1-cfergeau@redhat.com
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com >
2018-11-21 09:12:45 +01:00
YueHaibing
a071a8ff1f
drm/cirrus: Remove set but not used variable 'bo'
...
Fixes gcc '-Wunused-but-set-variable' warning:
drivers/gpu/drm/cirrus/cirrus_fbdev.c: In function 'cirrusfb_create':
drivers/gpu/drm/cirrus/cirrus_fbdev.c:172:20: warning:
variable 'bo' set but not used [-Wunused-but-set-variable]
It never used since introduction in commit
f9aa76a852
("drm/kms: driver for virtual cirrus under qemu")
Signed-off-by: YueHaibing <yuehaibing@huawei.com >
Link: http://patchwork.freedesktop.org/patch/msgid/1542283836-152176-1-git-send-email-yuehaibing@huawei.com
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com >
2018-11-21 09:12:44 +01:00
Lucas De Marchi
78abd9e2c8
drm/i915: Downgrade unknown CSR firmware warnings
...
Like it was done in commit 9e180d9991
("drm/i915: Downgrade unknown
firmware warnings") for huc and guc: downgrade CSR firmware warnings. If
we have released no firmware yet for a platform, stop scaring the
consumer and merely note its expected absence.
By simply removing the warning and early return we hit the condition
with the appropriate message.
Cc: Chris Wilson <chris@chris-wilson.co.uk >
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com >
Signed-off-by: Lucas De Marchi <lucas.demarchi@intel.com >
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk >
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com >
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181117004234.23437-2-lucas.demarchi@intel.com
2018-11-20 14:14:18 -08:00
Lucas De Marchi
02c07b76af
drm/i915: allow to load DMC firmware on next gen
...
Before commit d8a5b7d79f
("drm/i915/csr: keep max firmware size together
with firmare name and version") it was possible to load the firmware for
testing purposes via parameter. Let's use the size of the last known
platform to recover that behavior.
Cc: Jani Nikula <jani.nikula@intel.com >
Cc: Rodrigo Vivi <rodrigo.vivi@intel.com >
Signed-off-by: Lucas De Marchi <lucas.demarchi@intel.com >
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com >
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181117004234.23437-1-lucas.demarchi@intel.com
2018-11-20 14:14:17 -08:00
José Roberto de Souza
cab870b7fd
drm/i915/ilk: Fix warning when reading emon_status with no output
...
When there is no output no one will hold a runtime_pm reference
causing a warning when trying to read emom_status in debugfs.
[22.756480] ------------[ cut here ]------------
[22.756489] RPM wakelock ref not held during HW access
[22.756578] WARNING: CPU: 0 PID: 1058 at drivers/gpu/drm/i915/intel_drv.h:2104 gen5_read32+0x16b/0x1a0 [i915]
[22.756580] Modules linked in: snd_hda_codec_hdmi snd_hda_codec_realtek snd_hda_codec_generic i915 coretemp crct10dif_pclmul crc32_pclmul ghash_clmulni_intel snd_hda_intel snd_hda_codec snd_hwdep snd_hda_core e1000e snd_pcm mei_me prime_numbers mei lpc_ich
[22.756595] CPU: 0 PID: 1058 Comm: debugfs_test Not tainted 4.20.0-rc1-CI-Trybot_3219+ #1
[22.756597] Hardware name: Hewlett-Packard HP Compaq 8100 Elite SFF PC/304Ah, BIOS 786H1 v01.13 07/14/2011
[22.756634] RIP: 0010:gen5_read32+0x16b/0x1a0 [i915]
[22.756637] Code: a4 ea e0 0f 0b e9 d2 fe ff ff 80 3d a5 71 19 00 00 0f 85 d3 fe ff ff 48 c7 c7 48 d0 2d a0 c6 05 91 71 19 00 01 e8 35 a4 ea e0 <0f> 0b e9 b9 fe ff ff e8 69 c6 f2 e0 85 c0 75 92 48 c7 c2 78 d0 2d
[22.756639] RSP: 0018:ffffc90000f1fd38 EFLAGS: 00010282
[22.756642] RAX: 0000000000000000 RBX: ffff8801f7ab0000 RCX: 0000000000000006
[22.756643] RDX: 0000000000000006 RSI: ffffffff8212886a RDI: ffffffff820d6d57
[22.756645] RBP: 0000000000011020 R08: 0000000043e3d1a8 R09: 0000000000000000
[22.756647] R10: ffffc90000f1fd80 R11: 0000000000000000 R12: 0000000000000001
[22.756649] R13: ffff8801f7ab0068 R14: 0000000000000001 R15: ffff88020d53d188
[22.756651] FS: 00007f2878849980(0000) GS:ffff880213a00000(0000) knlGS:0000000000000000
[22.756653] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[22.756655] CR2: 00005638deedf028 CR3: 0000000203292001 CR4: 00000000000206f0
[22.756657] Call Trace:
[22.756689] i915_mch_val+0x1b/0x60 [i915]
[22.756721] i915_emon_status+0x45/0xd0 [i915]
[22.756730] seq_read+0xdb/0x3c0
[22.756736] ? lockdep_hardirqs_off+0x94/0xd0
[22.756740] ? __slab_free+0x24e/0x510
[22.756746] full_proxy_read+0x52/0x90
[22.756752] __vfs_read+0x31/0x170
[22.756759] ? do_sys_open+0x13b/0x240
[22.756763] ? rcu_read_lock_sched_held+0x6f/0x80
[22.756766] vfs_read+0x9e/0x140
[22.756770] ksys_read+0x50/0xc0
[22.756775] do_syscall_64+0x55/0x190
[22.756781] entry_SYSCALL_64_after_hwframe+0x49/0xbe
[22.756783] RIP: 0033:0x7f28781dc34e
[22.756786] Code: 00 00 00 00 48 8b 15 71 8c 20 00 f7 d8 64 89 02 48 c7 c0 ff ff ff ff c3 0f 1f 40 00 8b 05 ba d0 20 00 85 c0 75 16 31 c0 0f 05 <48> 3d 00 f0 ff ff 77 5a f3 c3 0f 1f 84 00 00 00 00 00 41 54 55 49
[22.756787] RSP: 002b:00007ffd33fa0d08 EFLAGS: 00000246 ORIG_RAX: 0000000000000000
[22.756790] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f28781dc34e
[22.756792] RDX: 0000000000000200 RSI: 00007ffd33fa0d50 RDI: 0000000000000008
[22.756794] RBP: 00007ffd33fa0f60 R08: 0000000000000000 R09: 0000000000000020
[22.756796] R10: 0000000000000000 R11: 0000000000000246 R12: 00005638de45c2c0
[22.756797] R13: 00007ffd33fa14b0 R14: 0000000000000000 R15: 0000000000000000
[22.756806] irq event stamp: 47950
[22.756811] hardirqs last enabled at (47949): [<ffffffff810fba74>] vprintk_emit+0x124/0x320
[22.756813] hardirqs last disabled at (47950): [<ffffffff810019b0>] trace_hardirqs_off_thunk+0x1a/0x1c
[22.756816] softirqs last enabled at (47518): [<ffffffff81c0033a>] __do_softirq+0x33a/0x4b9
[22.756820] softirqs last disabled at (47479): [<ffffffff8108df29>] irq_exit+0xa9/0xc0
[22.756858] WARNING: CPU: 0 PID: 1058 at drivers/gpu/drm/i915/intel_drv.h:2104 gen5_read32+0x16b/0x1a0 [i915]
[22.756860] ---[ end trace bf56fa7d6a3cbf7a ]
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181119230101.32460-1-jose.souza@intel.com
2018-11-20 14:04:04 -08:00
Chris Wilson
e32c8d3cae
drm/i915/selftests: Hold task reference to reset worker
...
As the worker may exit by itself, we need to hold a task reference to it
in the parent.
References: https://bugs.freedesktop.org/show_bug.cgi?id=108735
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk >
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181120120601.24083-1-chris@chris-wilson.co.uk
2018-11-20 14:32:16 +00:00
Stanislav Lisovskiy
61e49394a3
drm: Introduce new DRM_FORMAT_XYUV
...
v5: This is YUV444 packed format same as AYUV, but without alpha,
as supported by i915.
v6: Removed unneeded initializer for new XYUV format.
v7: Added is_yuv field initialization according to latest
drm_fourcc format structure initialization changes.
v8: Edited commit message to be more clear about skl+, renamed
PLANE_CTL_FORMAT_AYUV to PLANE_CTL_FORMAT_XYUV as this format
doesn't support per-pixel alpha. Fixed minor code issues.
v9: Moved DRM format check to proper place in intel_framebuffer_init.
v10: Changed DRM_FORMAT_XYUV to be DRM_FORMAT_XYUV8888
v11: Fixed rebase conflict, caused by added new formats to drm-tip
meanwhile.
Reviewed-by: Alexandru Gheorghe <alexandru-cosmin.gheorghe@arm.com >
Signed-off-by: Stanislav Lisovskiy <stanislav.lisovskiy@intel.com >
[vsyrjala: Removed stray tab and sorted the formats differently]
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181109093916.25858-2-stanislav.lisovskiy@intel.com
2018-11-20 16:20:13 +02:00
Noralf Trønnes
3db8d37dd8
drm/tinydrm: Use DRM_GEM_CMA_VMAP_DRIVER_OPS
...
The CMA helper now has the functionality to ensure a virtual address on
imported buffer so use that.
While touching all tinydrm drivers, remove the unnecessary inclusion of
drm_fb_helper.h in some drivers.
Cc: David Lechner <david@lechnology.com >
Cc: Eric Anholt <eric@anholt.net >
Signed-off-by: Noralf Trønnes <noralf@tronnes.org >
Acked-by: Christian König <christian.koenig@amd.com >
Reviewed-by: Eric Anholt <eric@anholt.net >
Link: https://patchwork.freedesktop.org/patch/msgid/20181110145647.17580-6-noralf@tronnes.org
2018-11-20 14:58:19 +01:00
Noralf Trønnes
b9068cde51
drm/cma-helper: Add DRM_GEM_CMA_VMAP_DRIVER_OPS
...
This adds functionality to the CMA helper which ensures that the kernel
virtual address is set on the CMA GEM object also for imported buffers.
The drivers have been audited to ensure that none set ->vaddr on imported
buffers, making the conditional dma_buf_vunmap() call in
drm_gem_cma_free_object() safe.
Signed-off-by: Noralf Trønnes <noralf@tronnes.org >
Acked-by: Christian König <christian.koenig@amd.com >
Reviewed-by: Eric Anholt <eric@anholt.net >
Link: https://patchwork.freedesktop.org/patch/msgid/20181110145647.17580-5-noralf@tronnes.org
2018-11-20 14:57:25 +01:00
Noralf Trønnes
b39b5394fa
drm/gem: Add drm_gem_object_funcs
...
This adds an optional function table on GEM objects.
The main benefit is for drivers that support more than one type of
memory (shmem,vram,cma) for their buffers depending on the hardware it
runs on. With the callbacks attached to the GEM object itself, it is
easier to have core helpers for the the various buffer types. The driver
only has to make the decision about buffer type on GEM object creation
and all other callbacks can be handled by the chosen helper.
drm_driver->gem_prime_res_obj has not been added since there's a todo to
put a reservation_object into drm_gem_object.
v3: Add todo entry
v2: Drop drm_gem_object_funcs->prime_mmap in favour of
drm_gem_prime_mmap() (Daniel Vetter)
v1:
- drm_gem_object_funcs.map -> .prime_map let it only do PRIME mmap like
the function it superseeds (Daniel Vetter)
- Flip around the if ladders and make obj->funcs the first choice
highlighting the fact that this the new default way of doing it
(Daniel Vetter)
Signed-off-by: Noralf Trønnes <noralf@tronnes.org >
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch >
Acked-by: Christian König <christian.koenig@amd.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181110145647.17580-4-noralf@tronnes.org
2018-11-20 14:56:18 +01:00
Noralf Trønnes
7698799f95
drm/prime: Add drm_gem_prime_mmap()
...
Add a generic PRIME GEM mmap function.
v2: Fix link in docs (Daniel Vetter)
Suggested-by: Daniel Vetter <daniel.vetter@ffwll.ch >
Signed-off-by: Noralf Trønnes <noralf@tronnes.org >
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch >
Acked-by: Christian König <christian.koenig@amd.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181110145647.17580-3-noralf@tronnes.org
2018-11-20 14:54:53 +01:00
Noralf Trønnes
f001488112
drm/driver: Add defaults for .gem_prime_export/import callbacks
...
The majority of drivers use drm_gem_prime_export() and
drm_gem_prime_import() for these callbacks so let's make them the
default.
Signed-off-by: Noralf Trønnes <noralf@tronnes.org >
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch >
Acked-by: Christian König <christian.koenig@amd.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181110145647.17580-2-noralf@tronnes.org
2018-11-20 14:54:15 +01:00
Colin Ian King
f577f7eac5
drm/panel: s6d16d0: fix spelling mistake "enble" -> "enable"
...
Trivial fix to spelling mistake in DRM_DEV_ERROR error message
Signed-off-by: Colin Ian King <colin.king@canonical.com >
Signed-off-by: Linus Walleij <linus.walleij@linaro.org >
Link: https://patchwork.freedesktop.org/patch/msgid/20181106154022.9209-1-colin.king@canonical.com
2018-11-20 13:50:00 +01:00
Jani Nikula
2ac5e38ea4
Merge drm/drm-next into drm-intel-next-queued
...
Pull in v4.20-rc3 via drm-next.
Signed-off-by: Jani Nikula <jani.nikula@intel.com >
2018-11-20 13:14:08 +02:00
Jani Nikula
f48cc647f3
drm/i915/fixed: cosmetic cleanup
...
Clean up fixed point temp variable initialization, use the more
conventional tmp name for temp variables, add empty lines before
return. No functional changes.
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com >
Signed-off-by: Jani Nikula <jani.nikula@intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181116120729.7580-5-jani.nikula@intel.com
2018-11-20 12:49:24 +02:00
Jani Nikula
f1eea8910b
drm/i915/fixed: simplify is_fixed16_zero()
...
Simply return the condition. No functional changes.
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com >
Signed-off-by: Jani Nikula <jani.nikula@intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181116120729.7580-4-jani.nikula@intel.com
2018-11-20 12:49:24 +02:00
Jani Nikula
e7a2381691
drm/i915/fixed: simplify FP_16_16_MAX definition
...
No need to use a compound statement enclosed in parenthesis where a C99
compound literal will do. No functional changes.
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com >
Signed-off-by: Jani Nikula <jani.nikula@intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181116120729.7580-3-jani.nikula@intel.com
2018-11-20 12:49:24 +02:00
Jani Nikula
3122b9c527
drm/i915/fixed: prefer kernel types over stdint types
...
While at it, conform to kernel spacing (i.e. no space) after cast. No
functional changes.
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com >
Signed-off-by: Jani Nikula <jani.nikula@intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181116120729.7580-2-jani.nikula@intel.com
2018-11-20 12:42:33 +02:00
Jani Nikula
2d332ee123
drm/i915: extract fixed point math to i915_fixed.h
...
Reduce bloat in one of the bigger header files. Fix some indentation
while at it. No functional changes.
v2: Add include guards (Joonas)
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com >
Signed-off-by: Jani Nikula <jani.nikula@intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181116120729.7580-1-jani.nikula@intel.com
2018-11-20 12:42:26 +02:00
Chris Wilson
7fa28e1469
drm/i915: Write GPU relocs harder with gen3
...
Under moderate amounts of GPU stress, we can observe on Bearlake and
Pineview (later gen3 models) that we execute the following batch buffer
before the write into the batch is coherent. Adding extra (tested with
upto 32x) MI_FLUSH to either the invalidation, flush or both phases does
not solve the incoherency issue with the relocations, but emitting the
MI_STORE_DWORD_IMM twice does. So be it.
Fixes: 7dd4f6729f
("drm/i915: Async GPU relocation processing")
Testcase: igt/gem_tiled_fence_blits # blb/pnv
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk >
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com >
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181119154153.15327-1-chris@chris-wilson.co.uk
2018-11-20 09:50:21 +00:00
Fabrizio Castro
ea6b13e9fe
drm/bridge/sii902x: Add missing dependency on I2C_MUX
...
kbuild test robot reports:
>> ERROR: "i2c_mux_add_adapter" [drivers/gpu/drm/bridge/sii902x.ko] undefined!
>> ERROR: "i2c_mux_alloc" [drivers/gpu/drm/bridge/sii902x.ko] undefined!
>> ERROR: "i2c_mux_del_adapters" [drivers/gpu/drm/bridge/sii902x.ko] undefined!
Quite obviously the driver depends on I2C_MUX, but adding a "depends on"
introduces a recursive dependency, therefore this patch selects I2C_MUX
instead.
Fixes: 21d808405f
("drm/bridge/sii902x: Fix EDID readback")
Signed-off-by: Fabrizio Castro <fabrizio.castro@bp.renesas.com >
Link: https://lists.01.org/pipermail/kbuild-all/2018-November/054924.html
Acked-by: Peter Rosin <peda@axentia.se >
Signed-off-by: Boris Brezillon <boris.brezillon@bootlin.com >
Link: https://patchwork.freedesktop.org/patch/msgid/1542633978-22064-1-git-send-email-fabrizio.castro@bp.renesas.com
2018-11-20 10:24:30 +01:00
Chris Wilson
fb6f0b64e4
drm/i915: Prevent machine hang from Broxton's vtd w/a and error capture
...
Since capturing the error state requires fiddling around with the GGTT
to read arbitrary buffers and is itself run under stop_machine(), it
deadlocks the machine (effectively a hard hang) when run in conjunction
with Broxton's VTd workaround to serialize GGTT access.
v2: Store the ERR_PTR in first_error so that the error can be reported
to the user via sysfs.
v3: Mention the quirk in dmesg (using info as per usual)
Fixes: 0ef34ad622
("drm/i915: Serialize GTT/Aperture accesses on BXT")
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk >
Cc: Jon Bloomfield <jon.bloomfield@intel.com >
Cc: John Harrison <john.C.Harrison@intel.com >
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com >
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com >
Cc: Daniel Vetter <daniel.vetter@ffwll.ch >
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181102161232.17742-5-chris@chris-wilson.co.uk
2018-11-19 17:16:44 +00:00
Damian Kos
fa68d4f847
drm/rockchip: fix for mailbox read size
...
Some of the functions (like cdn_dp_dpcd_read, cdn_dp_get_edid_block)
allow to read 64KiB, but the cdn_dp_mailbox_read_receive, that is
used by them, can read only up to 255 bytes at once. Normally, it's
not a big issue as DPCD or EDID reads won't (hopefully) exceed that
value.
The real issue here is the revocation list read during the HDCP
authentication process. (problematic use case:
https://chromium.googlesource.com/chromiumos/third_party/kernel/+/chromeos-4.4/drivers/gpu/drm/rockchip/cdn-dp-reg.c#1152 )
The list can reach 127*5+4 bytes (num devs * 5 bytes per ID/Bksv +
4 bytes of an additional info).
In other words - CTSes with HDCP Repeater won't pass without this
fix. Oh, and the driver will most likely stop working (best case
scenario).
Signed-off-by: Damian Kos <dkos@cadence.com >
Signed-off-by: Heiko Stuebner <heiko@sntech.de >
Link: https://patchwork.freedesktop.org/patch/msgid/1541518625-25984-1-git-send-email-dkos@cadence.com
2018-11-19 14:59:50 +01:00
Joonas Lahtinen
31579ba22c
drm/i915: Hide enable_gvt modparam when not compiled in
...
Hide the enable_gvt modparam in the default scenario where
support has not been compiled in.
Cc: Zhenyu Wang <zhenyuw@linux.intel.com >
Cc: Zhi Wang <zhi.a.wang@intel.com >
Cc: Chris Wilson <chris@chris-wilson.co.uk >
Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com >
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk >
Acked-by: Zhenyu Wang <zhenyuw@linux.intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181116144447.7836-1-joonas.lahtinen@linux.intel.com
2018-11-19 13:19:04 +02:00
Joonas Lahtinen
6b671c27ff
Revert "drm/i915/perf: Fix warning in documentation"
...
Userspace portion is still missing.
This reverts commit 9fa6e2f760
.
Cc: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Cc: Matthew Auld <matthew.auld@intel.com >
Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com >
Acked-by: Matthew Auld <matthew.auld@intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181116135510.13807-2-joonas.lahtinen@linux.intel.com
2018-11-19 13:08:48 +02:00
Joonas Lahtinen
fe84168647
Revert "drm/i915/perf: add a parameter to control the size of OA buffer"
...
Userspace portion is still missing.
This reverts commit cd956bfcd0
.
Cc: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Cc: Matthew Auld <matthew.auld@intel.com >
Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com >
Acked-by: Matthew Auld <matthew.auld@intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181116135510.13807-1-joonas.lahtinen@linux.intel.com
2018-11-19 13:07:29 +02:00
Dave Airlie
9235dd441a
Merge branch 'drm-next-4.21' of git://people.freedesktop.org/~agd5f/linux into drm-next
...
New features for 4.21:
amdgpu:
- Support for SDMA paging queue on vega
- Put compute EOP buffers into vram for better performance
- Share more code with amdkfd
- Support for scanout with DCC on gfx9
- Initial kerneldoc for DC
- Updated SMU firmware support for gfx8 chips
- Rework CSA handling for eventual support for preemption
- XGMI PSP support
- Clean up RLC handling
- Enable GPU reset by default on VI, SOC15 dGPUs
- Ring and IB test cleanups
amdkfd:
- Share more code with amdgpu
ttm:
- Move global init out of the drivers
scheduler:
- Track if schedulers are ready for work
- Timeout/fault handling changes to facilitate GPU recovery
Signed-off-by: Dave Airlie <airlied@redhat.com >
From: Alex Deucher <alexdeucher@gmail.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20181114165113.3751-1-alexander.deucher@amd.com
2018-11-19 11:07:52 +10:00