Daniel Vetter
1c305e13ec
drm/vkms: No _irqsave within spin_lock_irq needed
...
irqs are already off.
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com >
Reviewed-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Tested-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Signed-off-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190606222751.32567-9-daniel.vetter@ffwll.ch
2019-06-26 23:14:24 -03:00
Daniel Vetter
64cfaa5092
drm/vkms: Dont flush crc worker when we change crc status
...
The crc core code can cope with some late crc, the race is kinda
unavoidable. So no need to flush pending workers, they'll complete in
time.
Cc: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Cc: Haneen Mohammed <hamohammed.sa@gmail.com >
Cc: Daniel Vetter <daniel@ffwll.ch >
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com >
Reviewed-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Tested-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Signed-off-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190606222751.32567-8-daniel.vetter@ffwll.ch
2019-06-26 23:13:10 -03:00
Daniel Vetter
5ef8100a39
drm/vkms: flush crc workers earlier in commit flow
...
Currently, we flush pending CRC workers very late in the commit flow,
when we destroy all the old crtc states. Unfortunately, at that point,
the framebuffers are already unpinned (and our vaddr possible gone), so
this isn't good. Also, the plane_states we need might also already be
cleaned up, since cleanup order of state structures isn't well defined.
Fix this by waiting for all CRC workers of the old state to complete
before we start any of the cleanup work. For correct ordering and
avoiding races, we can only flush_work after
drm_atomic_helper_wait_for_vblanks() since we know that all subsequent
queue_work will be for the new state. Only once that's done is
flush_work() useful, before that we might flush the work, and then right
after the hrtimer that simulates vblank queues it again. Every time you
have a flush_work before cleaning up the work structure, the following
sequence must be obeyed, or it can go wrong:
1. Make sure no one else can re-queue the work anymore (in our case
that's done by a combination of first updating output->crc_state and
then waiting for the vblank to pass to make sure the hrtimer has noticed
that change).
2. flush_work()
3. Actually clean up stuff (which isn't done here).
Doing the flush_work before we even completed the output->state update,
much less waited for the vblank to make sure that's happened, missed the
point.
Note that this is not yet race-free because of the hrtimer and crc
worker look at the wrong state pointers, but that will be fixed in
subsequent patches.
Cc: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Cc: Haneen Mohammed <hamohammed.sa@gmail.com >
Cc: Daniel Vetter <daniel@ffwll.ch >
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com >
Reviewed-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Tested-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Signed-off-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190606222751.32567-7-daniel.vetter@ffwll.ch
2019-06-26 23:10:35 -03:00
Daniel Vetter
3d08eb7ddb
drm/vkms: Add our own commit_tail
...
Just prep work, more will be done here in following patches.
Cc: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Cc: Haneen Mohammed <hamohammed.sa@gmail.com >
Cc: Daniel Vetter <daniel@ffwll.ch >
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com >
Reviewed-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Tested-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Signed-off-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190606222751.32567-6-daniel.vetter@ffwll.ch
2019-06-26 23:01:37 -03:00
Daniel Vetter
fb4155fa4c
drm/vkms: Rename vkms_output.state_lock to crc_lock
...
Plus add a comment about what it actually protects. It's very little.
Cc: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Cc: Haneen Mohammed <hamohammed.sa@gmail.com >
Cc: Daniel Vetter <daniel@ffwll.ch >
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com >
Reviewed-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Tested-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Signed-off-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190606222751.32567-4-daniel.vetter@ffwll.ch
2019-06-26 23:00:55 -03:00
Daniel Vetter
a0e4e5754c
drm/vkms: Use spin_lock_irq in process context
...
The worker is always in process context, no need for the _irqsafe
version. Same for the set_source callback, that's only called from the
debugfs handler in a syscall.
Cc: Shayenne Moura <shayenneluzmoura@gmail.com >
Cc: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Cc: Haneen Mohammed <hamohammed.sa@gmail.com >
Cc: Daniel Vetter <daniel@ffwll.ch >
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com >
Reviewed-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Tested-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Signed-off-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190606222751.32567-3-daniel.vetter@ffwll.ch
2019-06-26 22:56:40 -03:00
Daniel Vetter
18d0952a83
drm/vkms: Fix crc worker races
...
The issue we have is that the crc worker might fall behind. We've
tried to handle this by tracking both the earliest frame for which it
still needs to compute a crc, and the last one. Plus when the
crtc_state changes, we have a new work item, which are all run in
order due to the ordered workqueue we allocate for each vkms crtc.
Trouble is there's been a few small issues in the current code:
- we need to capture frame_end in the vblank hrtimer, not in the
worker. The worker might run much later, and then we generate a lot
of crc for which there's already a different worker queued up.
- frame number might be 0, so create a new crc_pending boolean to
track this without confusion.
- we need to atomically grab frame_start/end and clear it, so do that
all in one go. This is not going to create a new race, because if we
race with the hrtimer then our work will be re-run.
- only race that can happen is the following:
1. worker starts
2. hrtimer runs and updates frame_end
3. worker grabs frame_start/end, already reading the new frame_end,
and clears crc_pending
4. hrtimer calls queue_work()
5. worker completes
6. worker gets re-run, crc_pending is false
Explain this case a bit better by rewording the comment.
v2: Demote warning level output to debug when we fail to requeue, this
is expected under high load when the crc worker can't quite keep up.
Cc: Shayenne Moura <shayenneluzmoura@gmail.com >
Cc: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Cc: Haneen Mohammed <hamohammed.sa@gmail.com >
Cc: Daniel Vetter <daniel@ffwll.ch >
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com >
Reviewed-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Tested-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Signed-off-by: Rodrigo Siqueira <rodrigosiqueiramelo@gmail.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190606222751.32567-2-daniel.vetter@ffwll.ch
2019-06-26 22:52:47 -03:00
Dave Airlie
b22342ea07
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 <airlied@redhat.com >
From: Russell King <rmk@armlinux.org.uk >
Link: https://patchwork.freedesktop.org/patch/msgid/20190625125005.GA31503@rmk-PC.armlinux.org.uk
2019-06-27 11:48:10 +10:00
Dave Airlie
665d6d4e32
Merge tag 'drm-misc-fixes-2019-06-26' of git://anongit.freedesktop.org/drm/drm-misc into drm-fixes
...
virtio- Don't call drm_connector_update_edid_property() while holding spinlock
Cc: Gerd Hoffmann <kraxel@redhat.com >
Signed-off-by: Dave Airlie <airlied@redhat.com >
From: Sean Paul <sean@poorly.run >
Link: https://patchwork.freedesktop.org/patch/msgid/20190626205615.GA123489@art_vandelay
2019-06-27 11:34:52 +10:00
Michal Wajdeczko
5ed7a0cf33
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 <michal.wajdeczko@intel.com >
Cc: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Cc: Chris Wilson <chris@chris-wilson.co.uk >
Cc: Jani Nikula <jani.nikula@intel.com >
Acked-by: Chris Wilson <chris@chris-wilson.co.uk >
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Acked-by: Jani Nikula <jani.nikula@intel.com >
Reviewed-by: Umesh Nerlige Ramappa <umesh.nerlige.ramappa@intel.com >
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk >
Link: https://patchwork.freedesktop.org/patch/msgid/20190626123826.39760-1-michal.wajdeczko@intel.com
2019-06-26 23:23:59 +01:00
Chris Wilson
c1a495a558
drm: Allow range of 0 for drm_mm_insert_node_in_range()
...
We gracefully handle the caller specifying a zero range, so don't force
them to special case that condition if it naturally falls out of their
setup. What we don't check is if the end < start, so keep that as an
assert for an illegal call.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk >
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com >
Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com >
Cc: Daniel Vetter <daniel.vetter@ffwll.ch >
Reviewed-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190626094330.3556-1-chris@chris-wilson.co.uk
2019-06-26 21:13:12 +01:00
José Roberto de Souza
63c9dae71d
drm/i915/ehl: Add voltage level requirement table
...
EHL has it own voltage level requirement depending on cd clock.
BSpec: 21809
Cc: Clint Taylor <Clinton.A.Taylor@intel.com >
Cc: Matt Roper <matthew.d.roper@intel.com >
Cc: Ville Syrjälä <ville.syrjala@linux.intel.com >
Reviewed-by: Matt Roper <matthew.d.roper@intel.com >
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190626014053.30541-3-jose.souza@intel.com
2019-06-26 12:01:54 -07:00
José Roberto de Souza
6e63790efd
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 <Clinton.A.Taylor@intel.com >
Cc: Matt Roper <matthew.d.roper@intel.com >
Cc: Ville Syrjälä <ville.syrjala@linux.intel.com >
Cc: Jani Nikula <jani.nikula@intel.com >
Reviewed-by: Matt Roper <matthew.d.roper@intel.com >
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190626014053.30541-2-jose.souza@intel.com
2019-06-26 12:01:53 -07:00
José Roberto de Souza
9c811fce8a
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 <Clinton.A.Taylor@intel.com >
Cc: Ville Syrjälä <ville.syrjala@linux.intel.com >
Reviewed-by: Matt Roper <matthew.d.roper@intel.com >
Signed-off-by: José Roberto de Souza <jose.souza@intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190626014053.30541-1-jose.souza@intel.com
2019-06-26 12:01:52 -07:00
Chris Wilson
092be382a2
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: 79ffac8599 ("drm/i915: Invert the GEM wakeref hierarchy")
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk >
Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com >
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com >
Cc: Imre Deak <imre.deak@intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190626154549.10066-3-chris@chris-wilson.co.uk
2019-06-26 18:01:01 +01:00
Chris Wilson
18398904ca
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: 79ffac8599 ("drm/i915: Invert the GEM wakeref hierarchy")
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk >
Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com >
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com >
Cc: Imre Deak <imre.deak@intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190626154549.10066-2-chris@chris-wilson.co.uk
2019-06-26 18:01:01 +01:00
Chris Wilson
de5147b8ce
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 <chris@chris-wilson.co.uk >
Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190626154549.10066-1-chris@chris-wilson.co.uk
2019-06-26 18:01:01 +01:00
Ville Syrjälä
7d23e59376
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ä <ville.syrjala@linux.intel.com >
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk >
Link: https://patchwork.freedesktop.org/patch/msgid/20190619170842.20579-5-ville.syrjala@linux.intel.com
2019-06-26 19:23:28 +03:00
Ville Syrjälä
b318b82455
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ä <ville.syrjala@linux.intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190620103334.15651-1-ville.syrjala@linux.intel.com
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk >
2019-06-26 19:23:28 +03:00
Ville Syrjälä
08fa8fd0fa
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ä <ville.syrjala@linux.intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190619170842.20579-3-ville.syrjala@linux.intel.com
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk >
2019-06-26 19:23:28 +03:00
Ville Syrjälä
4c888e7bd2
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 <shawn.guo@linaro.org >
Cc: Daniel Vetter <daniel.vetter@ffwll.ch >
Fixes: 967dd48417 ("drm: remove drm_vblank_no_hw_counter assignment from driver code")
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com >
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk >
Link: https://patchwork.freedesktop.org/patch/msgid/20190619170842.20579-2-ville.syrjala@linux.intel.com
2019-06-26 19:23:28 +03:00
Chris Wilson
faaa2902b5
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 <chris@chris-wilson.co.uk >
Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190626134433.6318-3-chris@chris-wilson.co.uk
2019-06-26 16:03:13 +01:00
Chris Wilson
1e5deb2632
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: 79ffac8599 ("drm/i915: Invert the GEM wakeref hierarchy")
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk >
Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190626134433.6318-2-chris@chris-wilson.co.uk
2019-06-26 16:03:13 +01:00
Chris Wilson
d847479566
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 <chris@chris-wilson.co.uk >
Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190626134433.6318-1-chris@chris-wilson.co.uk
2019-06-26 16:03:13 +01:00
Lee Shawn C
5ccf2027bb
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ä <ville.syrjala@linux.intel.com >
Cc: Jani Nikula <jani.nikula@intel.com >
Cc: Jose Roberto de Souza <jose.souza@intel.com >
Cc: Cooper Chiou <cooper.chiou@intel.com >
Signed-off-by: Lee Shawn C <shawn.c.lee@intel.com >
Signed-off-by: Jani Nikula <jani.nikula@intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/1561045456-12171-1-git-send-email-shawn.c.lee@intel.com
2019-06-26 17:48:12 +03:00
Emil Velikov
848ed7d542
drm/virtio: drop DRM_AUTH usage from the driver
...
The authentication can be circumvented, by design, by using the render
node.
From the driver POV there is no distinction between primary and render
nodes, thus we can drop the token.
Cc: Gerd Hoffmann <kraxel@redhat.com >
Cc: virtualization@lists.linux-foundation.org
Cc: David Airlie <airlied@linux.ie >
Cc: Daniel Vetter <daniel@ffwll.ch >
Signed-off-by: Emil Velikov <emil.velikov@collabora.com >
Acked-by: Gerd Hoffmann <kraxel@redhat.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190527081741.14235-12-emil.l.velikov@gmail.com
2019-06-26 15:00:41 +01:00
Emil Velikov
e4eee93d25
drm/vgem: drop DRM_AUTH usage from the driver
...
The authentication can be circumvented, by design, by using the render
node.
From the driver POV there is no distinction between primary and render
nodes, thus we can drop the token.
Cc: David Airlie <airlied@linux.ie >
Cc: Daniel Vetter <daniel@ffwll.ch >
Signed-off-by: Emil Velikov <emil.velikov@collabora.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190527081741.14235-11-emil.l.velikov@gmail.com
2019-06-26 15:00:40 +01:00
Emil Velikov
7042a33deb
drm/omap: drop DRM_AUTH from DRM_RENDER_ALLOW ioctls
...
The authentication can be circumvented, by design, by using the render
node.
From the driver POV there is no distinction between primary and render
nodes, thus we can drop the token.
Note: the outstanding DRM_AUTH instance is:
- (badly coped) legacy DRI1 ioctl, which is a noop
Cc: Tomi Valkeinen <tomi.valkeinen@ti.com >
Cc: David Airlie <airlied@linux.ie >
Cc: Daniel Vetter <daniel@ffwll.ch >
Signed-off-by: Emil Velikov <emil.velikov@collabora.com >
Acked-by: Tomi Valkeinen <tomi.valkeinen@ti.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190527081741.14235-9-emil.l.velikov@gmail.com
2019-06-26 15:00:40 +01:00
Emil Velikov
a305f6c5c8
drm/nouveau: drop DRM_AUTH from DRM_RENDER_ALLOW ioctls
...
The authentication can be circumvented, by design, by using the render
node.
From the driver POV there is no distinction between primary and render
nodes, thus we can drop the token.
Note: the outstanding DRM_AUTH instance is:
- legacy DRI1 ioctl, which is already neutered
Cc: Ben Skeggs <bskeggs@redhat.com >
Cc: nouveau@lists.freedesktop.org
Cc: David Airlie <airlied@linux.ie >
Cc: Daniel Vetter <daniel@ffwll.ch >
Signed-off-by: Emil Velikov <emil.velikov@collabora.com >
Reviewed-by: Ben Skeggs <bskeggs@redhat.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190527081741.14235-8-emil.l.velikov@gmail.com
2019-06-26 15:00:40 +01:00
Emil Velikov
88209d2c50
drm/msm: drop DRM_AUTH usage from the driver
...
The authentication can be circumvented, by design, by using the render
node.
From the driver POV there is no distinction between primary and render
nodes, thus we can drop the token.
Cc: Rob Clark <robdclark@gmail.com >
Cc: Sean Paul <sean@poorly.run >
Cc: freedreno@lists.freedesktop.org
Cc: David Airlie <airlied@linux.ie >
Cc: Daniel Vetter <daniel@ffwll.ch >
Signed-off-by: Emil Velikov <emil.velikov@collabora.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190527081741.14235-7-emil.l.velikov@gmail.com
2019-06-26 15:00:39 +01:00
Emil Velikov
921d573236
drm/lima: drop DRM_AUTH usage from the driver
...
The authentication can be circumvented, by design, by using the render
node.
From the driver POV there is no distinction between primary and render
nodes, thus we can drop the token.
Cc: Qiang Yu <yuq825@gmail.com >
Cc: lima@lists.freedesktop.org
Cc: David Airlie <airlied@linux.ie >
Cc: Daniel Vetter <daniel@ffwll.ch >
Signed-off-by: Emil Velikov <emil.velikov@collabora.com >
Reviewed-by: Qiang Yu <yuq825@gmail.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190527081741.14235-6-emil.l.velikov@gmail.com
2019-06-26 15:00:39 +01:00
Emil Velikov
951ecc022c
drm/exynos: drop DRM_AUTH from DRM_RENDER_ALLOW ioctls
...
The authentication can be circumvented, by design, by using the render
node.
From the driver POV there is no distinction between primary and render
nodes, thus we can drop the token.
Cc: Inki Dae <inki.dae@samsung.com >
Cc: Joonyoung Shim <jy0922.shim@samsung.com >
Cc: Seung-Woo Kim <sw0312.kim@samsung.com >
Cc: Kyungmin Park <kyungmin.park@samsung.com >
Cc: Tobias Jakobi <tjakobi@math.uni-bielefeld.de >
Signed-off-by: Emil Velikov <emil.velikov@collabora.com >
Acked-by: Inki Dae <inki.dae@samsung.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190527081741.14235-4-emil.l.velikov@gmail.com
2019-06-26 15:00:39 +01:00
Emil Velikov
b8602f9a65
drm/etnaviv: drop DRM_AUTH usage from the driver
...
The authentication can be circumvented, by design, by using the render
node.
From the driver POV there is no distinction between primary and render
nodes, thus we can drop the token.
Cc: Lucas Stach <l.stach@pengutronix.de >
Cc: Christian Gmeiner <christian.gmeiner@gmail.com >
Cc: etnaviv@lists.freedesktop.org
Cc: David Airlie <airlied@linux.ie >
Cc: Daniel Vetter <daniel@ffwll.ch >
Signed-off-by: Emil Velikov <emil.velikov@collabora.com >
Reviewed-by: Christian Gmeiner <christian.gmeiner@gmail.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190527081741.14235-3-emil.l.velikov@gmail.com
2019-06-26 15:00:39 +01:00
Emil Velikov
cbfbe47fc5
drm/vmwgfx: use core drm to extend/check vmw_execbuf_ioctl
...
Currently vmw_execbuf_ioctl() open-codes the permission checking, size
extending and copying that is already done in core drm.
Kill all the duplication, adding a few comments for clarity.
Cc: VMware Graphics <linux-graphics-maintainer@vmware.com >
Cc: Thomas Hellstrom <thellstrom@vmware.com >
Cc: Daniel Vetter <daniel@ffwll.ch >
Signed-off-by: Emil Velikov <emil.velikov@collabora.com >
Tested-by: Thomas Hellstrom <thellstrom@vmware.com >
Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190522164119.24139-3-emil.l.velikov@gmail.com
2019-06-26 15:00:38 +01:00
Emil Velikov
bcde7d345c
drm/vmgfx: kill off unused init_mutex
...
According to the docs - prevents firstopen/lastclose races. Yet never
used in practise.
Cc: VMware Graphics <linux-graphics-maintainer@vmware.com >
Cc: Thomas Hellstrom <thellstrom@vmware.com >
Cc: Daniel Vetter <daniel@ffwll.ch >
Signed-off-by: Emil Velikov <emil.velikov@collabora.com >
Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190522164119.24139-2-emil.l.velikov@gmail.com
2019-06-26 15:00:38 +01:00
Emil Velikov
3cd74023ea
vmwgfx: drop empty lastclose stub
...
Core DRM is safe when the callback is NULL.
Cc: VMware Graphics <linux-graphics-maintainer@vmware.com >
Cc: Thomas Hellstrom <thellstrom@vmware.com >
Cc: Daniel Vetter <daniel@ffwll.ch >
Signed-off-by: Emil Velikov <emil.velikov@collabora.com >
Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190522164119.24139-1-emil.l.velikov@gmail.com
2019-06-26 15:00:38 +01:00
Emil Velikov
ccdae42575
drm/nouveau: remove open-coded drm_invalid_op()
...
Cc: Ben Skeggs <bskeggs@redhat.com >
Cc: nouveau@lists.freedesktop.org
Signed-off-by: Emil Velikov <emil.velikov@collabora.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190522150219.13913-2-emil.l.velikov@gmail.com
2019-06-26 15:00:38 +01:00
Emil Velikov
b402375699
drm/i915: remove irrelevant DRM_UNLOCKED flag
...
DRM_UNLOCKED doesn't do anything for non-legacy drivers. Remove it.
Cc: intel-gfx@lists.freedesktop.org
Cc: Daniel Vetter <daniel@ffwll.ch >
Signed-off-by: Emil Velikov <emil.velikov@collabora.com >
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch >
Link: https://patchwork.freedesktop.org/patch/msgid/20190522154702.16269-3-emil.l.velikov@gmail.com
2019-06-26 15:00:37 +01:00
Emil Velikov
d6891db2ad
drm/tegra: remove irrelevant DRM_UNLOCKED flag
...
DRM_UNLOCKED doesn't do anything for non-legacy drivers. Remove it.
Cc: Thierry Reding <treding@nvidia.com >
Cc: linux-tegra@vger.kernel.org
Cc: Daniel Vetter <daniel@ffwll.ch >
Signed-off-by: Emil Velikov <emil.velikov@collabora.com >
Acked-by: Thierry Reding <treding@nvidia.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190522154702.16269-1-emil.l.velikov@gmail.com
2019-06-26 15:00:37 +01:00
Guido Günther
1a14e0c256
drm/panel: jh057n00900: Add regulator support
...
Allow to specify regulators for vcc and iovcc. According to the data
sheet the panel wants vcc (2.8V) and iovcc (1.8V) and there's no startup
dependency between the two.
Signed-off-by: Guido Günther <agx@sigxcpu.org >
Reviewed-by: Sam Ravnborg <sam@ravnborg.org >
Signed-off-by: Sam Ravnborg <sam@ravnborg.org >
Link: https://patchwork.freedesktop.org/patch/msgid/f78611fb26329e50ec1533810fbb76562f2f4e48.1561542477.git.agx@sigxcpu.org
2019-06-26 14:39:25 +02:00
Guido Günther
428733c72d
drm/panel: jh057n00900: Don't use magic constant
...
0xBF isn't in any ST7703 data sheet so mark it as unknown. This avoids
confusion on whether there is a missing command in that
dsi_generic_write_seq() call.
Signed-off-by: Guido Günther <agx@sigxcpu.org >
Reviewed-by: Sam Ravnborg <sam@ravnborg.org >
Signed-off-by: Sam Ravnborg <sam@ravnborg.org >
Link: https://patchwork.freedesktop.org/patch/msgid/7f50fa6de2ae029111f158f8ea7fd69a0903eb97.1561542477.git.agx@sigxcpu.org
2019-06-26 14:37:23 +02:00
Robert Chiras
f63df31d2d
drm/panel: Add support for Raydium RM67191 panel driver
...
This patch adds Raydium RM67191 TFT LCD panel driver (MIPI-DSI
protocol).
Signed-off-by: Robert Chiras <robert.chiras@nxp.com >
Reviewed-by: Sam Ravnborg <sam@ravnborg.org >
Reviewed-by: Fabio Estevam <festevam@gmail.com >
Signed-off-by: Sam Ravnborg <sam@ravnborg.org >
Link: https://patchwork.freedesktop.org/patch/msgid/1561550907-9733-3-git-send-email-robert.chiras@nxp.com
2019-06-26 14:34:54 +02:00
Mark Brown
53c8b29abe
Merge tag 'v5.2-rc6' into asoc-5.3
...
Linux 5.2-rc6
2019-06-26 12:39:34 +01:00
Paul Cercueil
f1bd37f300
drm/panel: simple: Add Sharp LS020B1DD01D panel support
...
The Sharp LS020B1DD01D is a simple 2.0" 240x160 16-bit TFT panel.
Signed-off-by: Paul Cercueil <paul@crapouillou.net >
Tested-by: Artur Rojek <contact@artur-rojek.eu >
Reviewed-by: Sam Ravnborg <sam@ravnborg.org >
Signed-off-by: Sam Ravnborg <sam@ravnborg.org >
Link: https://patchwork.freedesktop.org/patch/msgid/20190603153120.23947-3-paul@crapouillou.net
2019-06-26 13:38:16 +02:00
Paul Cercueil
ecdcbbb7ce
drm/panel: Add Novatek NT39016 panel support
...
Add support for display panels built around the Novatek NT39016 display
controller, as found on e.g. the King Display KD035G6-54NT 24-bit
320x240 3.5" LCD panel which equips the GCW Zero open-source handheld
gaming console.
Signed-off-by: Paul Cercueil <paul@crapouillou.net >
Signed-off-by: Maarten ter Huurne <maarten@treewalker.org >
Reviewed-by: Sam Ravnborg <sam@ravnborg.org >
Signed-off-by: Sam Ravnborg <sam@ravnborg.org >
Link: https://patchwork.freedesktop.org/patch/msgid/20190603152555.23527-2-paul@crapouillou.net
2019-06-26 13:36:02 +02:00
Maarten Lankhorst
daed277e4d
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 <maarten.lankhorst@linux.intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/7dd06ccb-7f8d-943b-bbc0-f4e58e041a23@linux.intel.com
2019-06-26 12:26:34 +02:00
Maarten Lankhorst
355a47ae7e
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 <maarten.lankhorst@linux.intel.com >
2019-06-26 12:22:54 +02:00
Gerd Hoffmann
41de4be6f6
drm/virtio: move drm_connector_update_edid_property() call
...
drm_connector_update_edid_property can sleep, we must not
call it while holding a spinlock. Move the callsite.
Fixes: b4b01b4995 ("drm/virtio: add edid support")
Reported-by: Max Filippov <jcmvbkbc@gmail.com >
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com >
Tested-by: Max Filippov <jcmvbkbc@gmail.com >
Tested-by: Cornelia Huck <cohuck@redhat.com >
Acked-by: Cornelia Huck <cohuck@redhat.com >
Link: http://patchwork.freedesktop.org/patch/msgid/20190405044602.2334-1-kraxel@redhat.com
2019-06-26 11:05:05 +02:00
Daniel Vetter
6116b892bd
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 <sfr@canb.auug.org.au >
Reported-by: kbuild test robot <lkp@intel.com >
Fixes: 1cd51b5d20 ("vgaswitcheroo: call fbcon_remap_all directly")
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com >
Cc: Stephen Rothwell <sfr@canb.auug.org.au >
Cc: Lukas Wunner <lukas@wunner.de >
Cc: Daniel Vetter <daniel.vetter@intel.com >
Cc: Sam Ravnborg <sam@ravnborg.org >
Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com >
Cc: David Airlie <airlied@linux.ie >
Cc: Daniel Vetter <daniel@ffwll.ch >
Cc: Maxime Ripard <maxime.ripard@bootlin.com >
Cc: Sean Paul <sean@poorly.run >
Cc: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com >
Cc: Hans de Goede <hdegoede@redhat.com >
Cc: Yisheng Xie <ysxie@foxmail.com >
Cc: linux-fbdev@vger.kernel.org
Cc: Daniel Thompson <daniel.thompson@linaro.org >
Cc: Lee Jones <lee.jones@linaro.org >
Cc: dri-devel@lists.freedesktop.org
Cc: linux-fbdev@vger.kernel.org
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190624092153.23375-1-daniel.vetter@ffwll.ch
2019-06-26 10:36:49 +02:00
Chris Wilson
cba17e5d64
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 <chris@chris-wilson.co.uk >
Reviewed-by: Matthew Auld <matthew.auld@intel.com >
Link: https://patchwork.freedesktop.org/patch/msgid/20190625194859.28005-1-chris@chris-wilson.co.uk
2019-06-26 07:44:43 +01:00