[PATCH 07/10] drm: Store new plane state in a variable for atomic_update and disable

2021-01-16 Thread Maxime Ripard
In order to store the new plane state in a subsequent helper, let's move the plane->state dereferences into a variable. This was done using the following coccinelle script, plus some hand changes for vmwgfx: @ plane_atomic_func @ identifier helpers; identifier func; @@ ( static const struct drm

[PATCH 05/10] drm: Use the state pointer directly in planes atomic_check

2021-01-16 Thread Maxime Ripard
Now that atomic_check takes the global atomic state as a parameter, we don't need to go through the pointer in the plane state. This was done using the following coccinelle script: @ plane_atomic_func @ identifier helpers; identifier func; @@ static struct drm_plane_helper_funcs helpers = {

[PATCH v2 1/3] drm/bridge/lontium-lt9611uxc: fix waiting for EDID to become available

2021-01-16 Thread Dmitry Baryshkov
- Call wake_up() when EDID ready event is received to wake wait_event_interruptible_timeout() - Increase waiting timeout, reading EDID can take longer than 100ms, so let's be on a safe side. Signed-off-by: Dmitry Baryshkov Fixes: 0cbbd5b1a012 ("drm: bridge: add support for lontium LT9611UXC

[PATCH 01/10] drm/atomic: Pass the full state to planes async atomic check and update

2021-01-16 Thread Maxime Ripard
The current atomic helpers have either their object state being passed as an argument or the full atomic state. The former is the pattern that was done at first, before switching to the latter for new hooks or when it was needed. Let's start convert all the remaining helpers to provide a consiste

Re: [PATCH][next] drm/amdgpu: Add missing BOOTUP_DEFAULT to profile_name[]

2021-01-16 Thread Christophe JAILLET
Le 15/01/2021 à 11:10, Colin Ian King a écrit : On 15/01/2021 10:07, Christophe JAILLET wrote: Le 15/01/2021 à 10:37, Colin Ian King a écrit : On 12/01/2021 10:07, Dan Carpenter wrote: On Mon, Jan 11, 2021 at 11:46:38AM +, Colin King wrote: From: Colin Ian King A recent change added a n

[PATCH] drm/vc4: Unify PCM card's driver_name

2021-01-16 Thread Nicolas Saenz Julienne
User-space ALSA matches a card's driver name against an internal list of aliases in order to select the correct configuration for the system. When the driver name isn't defined, the match is performed against the card's name. With the introduction of RPi4 we now have two HDMI ports with two distin

[PATCH 09/10] drm/atomic: Pass the full state to planes atomic disable and update

2021-01-16 Thread Maxime Ripard
The current atomic helpers have either their object state being passed as an argument or the full atomic state. The former is the pattern that was done at first, before switching to the latter for new hooks or when it was needed. Let's start convert all the remaining helpers to provide a consiste

[PATCH v2 3/3] drm/bridge/lontium-lt9611uxc: move HPD notification out of IRQ handler

2021-01-16 Thread Dmitry Baryshkov
drm hotplug handling code (drm_client_dev_hotplug()) can wait on mutex, thus delaying further lt9611uxc IRQ events processing. It was observed occasionally during bootups, when drm_client_modeset_probe() was waiting for EDID ready event, which was delayed because IRQ handler was stuck trying to de

Re: [PATCH][next] drm/amdgpu: Add missing BOOTUP_DEFAULT to profile_name[]

2021-01-16 Thread Christophe JAILLET
Le 15/01/2021 à 10:37, Colin Ian King a écrit : On 12/01/2021 10:07, Dan Carpenter wrote: On Mon, Jan 11, 2021 at 11:46:38AM +, Colin King wrote: From: Colin Ian King A recent change added a new BOOTUP_DEFAULT power profile mode to the PP_SMC_POWER_PROFILE enum but omitted updating the co

[PATCH v2 2/3] drm/bridge/lontium-lt9611uxc: fix get_edid return code

2021-01-16 Thread Dmitry Baryshkov
Return NULL pointer from get_edid() callback rather than ERR_PTR() pointer, as DRM code does NULL checks rather than IS_ERR(). Also while we are at it, return NULL if getting EDID timed out. Signed-off-by: Dmitry Baryshkov Fixes: 0cbbd5b1a012 ("drm: bridge: add support for lontium LT9611UXC bridg

[PATCH v2 0/3] drm/bridge/lontium-lt9611uxc: fix handling of EDID/HPD

2021-01-16 Thread Dmitry Baryshkov
These three patches provide fixes for HPD handling and EDID readout for Lontium lt9611uxc DSI-to-HDMI bridge driver. Dmitry Baryshkov (3): drm/bridge/lontium-lt9611uxc: fix waiting for EDID to become available drm/bridge/lontium-lt9611uxc: fix get_edid return code drm/bridge/lont

[PATCH 06/10] drm: Use state helper instead of plane state pointer in atomic_check

2021-01-16 Thread Maxime Ripard
Many drivers reference the plane->state pointer in order to get the current plane state in their atomic_check hook, which would be the old plane state in the global atomic state since _swap_state hasn't happened when atomic_check is run. Use the drm_atomic_get_old_plane_state helper to get that st

Re: [PATCH] drm/i915/userptr: detect un-GUP-able pages early

2021-01-16 Thread Jinoh Kang
On 1/15/21 4:56 PM, Chris Wilson wrote: > Quoting Jinoh Kang (2021-01-15 16:23:31) >> If GUP-ineligible pages are passed to a GEM userptr object, -EFAULT is >> returned only when the object is actually bound. >> >> The xf86-video-intel userspace driver cannot differentiate this >> condition, and ma

Re: [PATCH v2 1/3] drm/bridge/lontium-lt9611uxc: fix waiting for EDID to become available

2021-01-16 Thread Bjorn Andersson
On Fri 15 Jan 05:02 CST 2021, Dmitry Baryshkov wrote: > - Call wake_up() when EDID ready event is received to wake > wait_event_interruptible_timeout() > > - Increase waiting timeout, reading EDID can take longer than 100ms, so > let's be on a safe side. > Reviewed-by: Bjorn Andersson Reg

Re: [PATCH 02/10] drm: Rename plane atomic_check state names

2021-01-16 Thread Maxime Ripard
Hi, On Fri, Jan 15, 2021 at 02:46:36PM +0100, Thomas Zimmermann wrote: > Hi > > Am 15.01.21 um 13:56 schrieb Maxime Ripard: > > diff --git a/drivers/gpu/drm/imx/ipuv3-plane.c > > b/drivers/gpu/drm/imx/ipuv3-plane.c > > index 8a4235d9d9f1..2cb09e9d9306 100644 > > --- a/drivers/gpu/drm/imx/ipuv3-p

Re: [PATCH RFC] drm/vc4: hdmi: Avoid ASoC error messages on startup

2021-01-16 Thread Nicolas Saenz Julienne
On Tue, 2020-12-29 at 16:36 +0100, Stefan Wahren wrote: > During startup of Raspberry Pi 4 there seems to be a race between > VC4 probing and Pulseaudio trying to open its PCM device: > > ASoC: error at snd_soc_dai_startup on fef05700.hdmi: -19 > > Avoid these errors by returning EPROBE_DEFER

[PATCH] drm/i915/userptr: detect un-GUP-able pages early

2021-01-16 Thread Jinoh Kang
If GUP-ineligible pages are passed to a GEM userptr object, -EFAULT is returned only when the object is actually bound. The xf86-video-intel userspace driver cannot differentiate this condition, and marks the GPU as wedged. This not only disables graphics acceleration but may also cripple other f

Re: [PATCH v2 1/7] dt-bindings: display: mxsfb: Convert binding to YAML

2021-01-16 Thread Martin Kepplinger
Am 15. Jänner 2021 23:25:14 MEZ schrieb Laurent Pinchart : >Hi Martin, > >On Fri, Jan 15, 2021 at 08:59:18AM +0100, Martin Kepplinger wrote: >> hi Laurent, >> >> Do you mind me adding a DT property in the old format now? If so, I'd >> appreciated an ack in this thread: >> >https://lore.kernel.o

Re: [PATCH] drm/i915/userptr: detect un-GUP-able pages early

2021-01-16 Thread Jinoh Kang
On 1/15/21 5:07 PM, Chris Wilson wrote: > Quoting Chris Wilson (2021-01-15 16:56:42) >> Quoting Jinoh Kang (2021-01-15 16:23:31) >>> If GUP-ineligible pages are passed to a GEM userptr object, -EFAULT is >>> returned only when the object is actually bound. >>> >>> The xf86-video-intel userspace dri

[PATCH v4 2/2] drm/drm_vblank: set the dma-fence timestamp during send_vblank_event

2021-01-16 Thread Veera Sundaram Sankaran
The explicit out-fences in crtc are signaled as part of vblank event, indicating all framebuffers present on the Atomic Commit request are scanned out on the screen. Though the fence signal and the vblank event notification happens at the same time, triggered by the same hardware vsync event, the t

[PATCH 08/10] drm: Rename plane->state variables in atomic update and disable

2021-01-16 Thread Maxime Ripard
Some drivers are storing the plane->state pointer in atomic_update and atomic_disable in a variable simply called state, while the state passed as an argument is called old_state. In order to ease subsequent reworks and to avoid confusing or inconsistent names, let's rename those variables to new_

Re: [PATCH v3 2/2] drm/drm_vblank: set the dma-fence timestamp during send_vblank_event

2021-01-16 Thread veeras
On 2021-01-15 14:29, John Stultz wrote: On Thu, Jan 14, 2021 at 12:54 PM wrote: On 2021-01-13 18:28, John Stultz wrote: > On Wed, Jan 13, 2021 at 11:52 AM Veera Sundaram Sankaran > wrote: >> >> The explicit out-fences in crtc are signaled as part of vblank event, >> indicating all framebuffer

[PATCH] drm/dp_helper: tweak kerneldoc to address warning

2021-01-16 Thread Lukas Bulwahn
Commit 07c9b8634fb6 ("drm/dp_helper: Add helpers to configure PCONs RGB-YCbCr Conversion") introduces a warning with make htmldocs in ./drivers/gpu/drm/drm_dp_helper.c:965 for drm_dp_downstream_rgb_to_ycbcr_conversion(): warning: Excess function parameter 'colorspc' description warning: Functi

[PATCH 10/10] drm: Use state helper instead of the plane state pointer

2021-01-16 Thread Maxime Ripard
Many drivers reference the plane->state pointer in order to get the current plane state in their atomic_update or atomic_disable hooks, which would be the new plane state in the global atomic state since _swap_state happened when those hooks are run. Use the drm_atomic_get_new_plane_state helper t

Re: [PATCH] drm/hisilicon/hibmc: Remove hibmc_ttm.c

2021-01-16 Thread tiantao (H)
在 2021/1/15 16:42, Thomas Zimmermann 写道: ping for review Am 13.01.21 um 12:31 schrieb Thomas Zimmermann: The file is not in use. It got re-added by a rebased patch. Removing it. Reviewed-by Tian Tao Signed-off-by: Thomas Zimmermann Fixes: 4d4dad21cc7b ("drm/hibmc: Remove references to str

Re: [PATCH v2 1/5] drm/panel-simple: Undo enable if HPD never asserts

2021-01-16 Thread Stephen Boyd
Quoting Douglas Anderson (2021-01-15 14:44:16) > If the HPD signal never asserts in panel_simple_prepare() and we > return an error, we should unset the enable GPIO and disable the > regulator to make it consistent for the caller. > > At the moment I have some hardware where HPD sometimes doesn't

[PATCH 04/10] drm/atomic: Pass the full state to planes atomic_check

2021-01-16 Thread Maxime Ripard
The current atomic helpers have either their object state being passed as an argument or the full atomic state. The former is the pattern that was done at first, before switching to the latter for new hooks or when it was needed. Let's start convert all the remaining helpers to provide a consiste

[PATCH 02/10] drm: Rename plane atomic_check state names

2021-01-16 Thread Maxime Ripard
Most drivers call the argument to the plane atomic_check hook simply state, which is going to conflict with the global atomic state in a later rework. Let's rename it to new_plane_state (or new_state depending on the convention used in the driver). This was done using the coccinelle script below,

Re: [PATCH v2 2/3] drm/bridge/lontium-lt9611uxc: fix get_edid return code

2021-01-16 Thread Bjorn Andersson
On Fri 15 Jan 05:02 CST 2021, Dmitry Baryshkov wrote: > Return NULL pointer from get_edid() callback rather than ERR_PTR() > pointer, as DRM code does NULL checks rather than IS_ERR(). Also while > we are at it, return NULL if getting EDID timed out. > Reviewed-by: Bjorn Andersson > Signed-off

Re: [PATCH V4] dt-bindings: gpu: Convert v3d to json-schema

2021-01-16 Thread Nicolas Saenz Julienne
On Wed, 2021-01-13 at 20:08 +0100, Stefan Wahren wrote: > This converts the v3d bindings to yaml format. > > Signed-off-by: Stefan Wahren > --- Reviewed-by: Nicolas Saenz Julienne Regards, Nicolas > > Changes in V4: > - define order for required reg-names > - adapt example > > Changes in V3

[PATCH] drm/msm/dpu1: add support for qseed3lite used on sm8250

2021-01-16 Thread Dmitry Baryshkov
SM8250 has quite unique qseed lut type: qseed3lite, which is a lightweight version of qseed3 scaler. Signed-off-by: Dmitry Baryshkov --- .../gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c| 38 +- .../gpu/drm/msm/disp/dpu1/dpu_hw_catalog.h| 2 + drivers/gpu/drm/msm/disp/dpu1/dpu_hw_sspp.

[PATCH 03/10] drm/atmel-hlcdc: Rename custom plane state variable

2021-01-16 Thread Maxime Ripard
Subsequent reworks will pass the global atomic state in the function prototype, and atomic_check and atomic_update already have such a variable already. Let's change them to ease the rework. Signed-off-by: Maxime Ripard --- .../gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c | 118 +-

[PATCH v4 1/2] dma-fence: allow signaling drivers to set fence timestamp

2021-01-16 Thread Veera Sundaram Sankaran
Some drivers have hardware capability to get the precise HW timestamp of certain events based on which the fences are triggered. The delta between the event HW timestamp & current HW reference timestamp can be used to calculate the timestamp in kernel's CLOCK_MONOTONIC time domain. This allows it t

Re: [PATCH RFC] drm/vc4: hdmi: Avoid ASoC error messages on startup

2021-01-16 Thread Maxime Ripard
Hi, On Wed, Jan 13, 2021 at 11:42:23AM +, Mark Brown wrote: > On Wed, Jan 13, 2021 at 10:19:57AM +0100, Maxime Ripard wrote: > > > I'd like to get Mark's opinion before merging though > > I'm not sure what the question is here? I get CCed on a bunch of not > obviously relevant DRM patches s

Re: [PATCH v2 3/3] drm/bridge/lontium-lt9611uxc: move HPD notification out of IRQ handler

2021-01-16 Thread kernel test robot
ng-of-EDID-HPD/20210116-184620 base: git://anongit.freedesktop.org/drm-intel for-linux-next config: x86_64-randconfig-a004-20210116 (attached as .config) compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project d7bc3b7ce23b664d6620cdc32370a8614523ca2f) reproduce (this is a

Re: [PATCH v2 3/3] drm/bridge/lontium-lt9611uxc: move HPD notification out of IRQ handler

2021-01-16 Thread kernel test robot
ng-of-EDID-HPD/20210116-184620 base: git://anongit.freedesktop.org/drm-intel for-linux-next config: nds32-randconfig-r033-20210116 (attached as .config) compiler: nds32le-linux-gcc (GCC) 9.3.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/m

Re: [PATCH v1] drm/panel: simple: add SGD GKTW70SDAD1SD

2021-01-16 Thread Fabio Estevam
On Sat, Jan 16, 2021 at 9:49 AM Oliver Graute wrote: > > power-supply = <®_touch_3v3> is not correct, as the reg_touch_3v3 > > does not power the LCD. > > yes, but how is the LCD correctly powered then? J4 is powered by VCC_5V and VCC_3V#. > [7.795980] pwm-backlight backlight: supply power

[Bug 211189] vgaarb overrides boot device unexpectedly with Intel and discrete AMDGPU

2021-01-16 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=211189 --- Comment #3 from Dominik Mierzejewski (domi...@greysector.net) --- Created attachment 294673 --> https://bugzilla.kernel.org/attachment.cgi?id=294673&action=edit dmesg from kernel 5.10.7 Thanks for your analysis. Full dmesg attached. -- Yo

Re: [PATCH] drm/vc4: Unify PCM card's driver_name

2021-01-16 Thread Takashi Iwai
On Fri, 15 Jan 2021 20:12:09 +0100, Nicolas Saenz Julienne wrote: > > User-space ALSA matches a card's driver name against an internal list of > aliases in order to select the correct configuration for the system. > When the driver name isn't defined, the match is performed against the > card's na