[PATCH] drm/vmwgfx: fix spinlock initialization in vmw_driver_load()

2021-03-21 Thread Tetsuo Handa
Since vmw_write() from vmw_detect_version() from vmw_driver_load() calls spin_lock(&dev_priv->hw_lock), spin_lock_init(&dev_priv->hw_lock) has to be called before vmw_detect_version() is called, or lockdep gets disabled. INFO: trying to register non-static key. the code is fine but needs lockd

[PATCH] drm/amdkfd: Fix cat debugfs hang_hws file causes system crash bug

2021-03-21 Thread Qu Huang
Here is the system crash log: [ 1272.884438] BUG: unable to handle kernel NULL pointer dereference at (null) [ 1272.88] IP: [< (null)>] (null) [ 1272.884447] PGD 825b09067 PUD 8267c8067 PMD 0 [ 1272.884452] Oops: 0010 [#1] SMP [ 1272.884509] CPU: 13 PID: 3485 Comm: cat Kdump:

[PATCH 1/2] dt-bindings: backlight: Add Kinetic KTD259 bindings

2021-03-21 Thread Linus Walleij
The KTD259 is just a newer version of the KTD253 and works all the same. Signed-off-by: Linus Walleij --- .../bindings/leds/backlight/kinetic,ktd253.yaml | 9 ++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/Documentation/devicetree/bindings/leds/backlight/kineti

[PATCH 2/2] backlight: ktd253: Support KTD259

2021-03-21 Thread Linus Walleij
The KTD259 works just like KTD253 so add this compatible to the driver. Signed-off-by: Linus Walleij --- drivers/video/backlight/ktd253-backlight.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/video/backlight/ktd253-backlight.c b/drivers/video/backlight/ktd253-backlight.c index d

Re: [PATCH v6 1/5] dt-bindings:drm/bridge:anx7625:add vendor define flags

2021-03-21 Thread Laurent Pinchart
Hi Xin, Thank you for the patch. On Fri, Mar 19, 2021 at 02:32:39PM +0800, Xin Ji wrote: > Add 'bus-type' and 'data-lanes' define for port0. Define DP tx lane0, > lane1 swing register array define, and audio enable flag. > > Signed-off-by: Xin Ji > --- > .../display/bridge/analogix,anx7625.yam

[PATCH v2 3/3] drm/tilcdc: fix pixel clock setting warning message

2021-03-21 Thread Dario Binacchi
The warning message did not printed the LCD pixel clock rate but the LCD clock divisor input rate. As a consequence, the required and real pixel clock rates are now passed to the tilcdc_pclk_diff(). Signed-off-by: Dario Binacchi --- Changes in v2: - The patch has been added in version 2. driv

[PATCH v2 2/3] drm/tilcdc: fix LCD pixel clock setting

2021-03-21 Thread Dario Binacchi
The tilcdc_pclk_diff() compares the requested pixel clock rate to the real one, so passing it clk_rate instead of clk_rate / clkdiv caused it to fail even if the clk_rate was properly set. Adding the real_pclk_rate variable makes the code more readable. Signed-off-by: Dario Binacchi --- Changes

[PATCH v2 0/3] drm/tilcdc: fix LCD pixel clock setting

2021-03-21 Thread Dario Binacchi
The series was born from a patch to fix the LCD pixel clock setting. Two additional patches have been added to this. One renames a misleading variable name that was probably the cause of the bug and the other fixes a warning message. Changes in v2: - The patch has been added in version 2. - Ren

[PATCH v2 1/3] drm/tilcdc: rename req_rate to pclk_rate

2021-03-21 Thread Dario Binacchi
The req_rate name is a little misleading, so let's rename to pclk_rate (pixel clock rate). Signed-off-by: Dario Binacchi --- Changes in v2: - The patch has been added in version 2. drivers/gpu/drm/tilcdc/tilcdc_crtc.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --

Re: [PATCH] drm/radeon: don't evict if not initialized

2021-03-21 Thread Christian König
Am 20.03.21 um 21:10 schrieb Tong Zhang: TTM_PL_VRAM may not initialized at all when calling radeon_bo_evict_vram(). We need to check before doing eviction. [2.160837] BUG: kernel NULL pointer dereference, address: 0020 [2.161212] #PF: supervisor read access in kernel mode

Re: [PATCH] drm/ttm: stop warning on TT shrinker failure

2021-03-21 Thread Christian König
Am 20.03.21 um 14:17 schrieb Daniel Vetter: On Sat, Mar 20, 2021 at 10:04 AM Christian König wrote: Am 19.03.21 um 20:06 schrieb Daniel Vetter: On Fri, Mar 19, 2021 at 07:53:48PM +0100, Christian König wrote: Am 19.03.21 um 18:52 schrieb Daniel Vetter: On Fri, Mar 19, 2021 at 03:08:57PM +010

[PATCH v2] drm/radeon: don't evict if not initialized

2021-03-21 Thread Tong Zhang
TTM_PL_VRAM may not initialized at all when calling radeon_bo_evict_vram(). We need to check before doing eviction. [2.160837] BUG: kernel NULL pointer dereference, address: 0020 [2.161212] #PF: supervisor read access in kernel mode [2.161490] #PF: error_code(0x) - not-

Re: [PATCH] drm/radeon: don't evict if not initialized

2021-03-21 Thread Tong Zhang
Thanks, Fixed as suggested and sent as v2. - Tong On Sun, Mar 21, 2021 at 9:26 AM Christian König wrote: > > > > Am 20.03.21 um 21:10 schrieb Tong Zhang: > > TTM_PL_VRAM may not initialized at all when calling > > radeon_bo_evict_vram(). We need to check before doing eviction. > > > > [2.1608

[Bug 212373] New: Dual monitors does not sleep when inactive

2021-03-21 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=212373 Bug ID: 212373 Summary: Dual monitors does not sleep when inactive Product: Drivers Version: 2.5 Kernel Version: 5.8.0-45 Hardware: All OS: Linux Tree: Mainli

[RFC PATCH 0/2] mm,drm/ttm: Always block GUP to TTM pages

2021-03-21 Thread Intel
get_user_pages() to TTM pages is uwanted since TTM assumes it owns the pages exclusively and / or sets up page-table mappings to io memory. The first patch make sures we stop fast gup to huge TTM pages using a trick with pmd_devmap() and pud_devmap() without a backing dev_pagemap. The second patc

[RFC PATCH 1/2] mm,drm/ttm: Block fast GUP to TTM huge pages

2021-03-21 Thread Intel
TTM sets up huge page-table-entries both to system- and device memory, and we don't want gup to assume there are always valid backing struct pages for these. For PTEs this is handled by setting the pte_special bit, but for the huge PUDs and PMDs, we have neither pmd_special nor pud_special. Normall

[RFC PATCH 2/2] mm,drm/ttm: Use VM_PFNMAP for TTM vmas

2021-03-21 Thread Intel
To block fast gup we need to make sure TTM ptes are always special. With MIXEDMAP we, on architectures that don't support pte_special, insert normal ptes, but OTOH on those architectures, fast is not supported. At the same time, the function documentation to vm_normal_page() suggests that ptes poin

Re: [PATCH] drm/rockchip: Cope with endpoints that haven't been registered yet

2021-03-21 Thread Heiko Stuebner
Hi Jonathan, Am Dienstag, 16. März 2021, 19:27:53 CET schrieb Jonathan McDowell: > The Rockchip RGB CRTC output driver attempts to avoid probing Rockchip > subdrivers to see if they're a connected panel or bridge. However part > of its checks assumes that if no OF platform device is found then it

Re: [PATCH v2 0/3] drm/tilcdc: fix LCD pixel clock setting

2021-03-21 Thread Jyri Sarha
On 2021-03-21 10:31, Dario Binacchi wrote: The series was born from a patch to fix the LCD pixel clock setting. Two additional patches have been added to this. One renames a misleading variable name that was probably the cause of the bug and the other fixes a warning message. Thanks you, I

Re: [PATCH] drm/tilcdc: panel: fix platform_no_drv_owner.cocci warnings

2021-03-21 Thread Jyri Sarha
On 2021-03-03 11:04, Yang Li wrote: ./drivers/gpu/drm/tilcdc/tilcdc_panel.c:402:3-8: No need to set .owner here. The core will do it. Remove .owner field if calls are used which set it automatically Reported-by: Abaci Robot Signed-off-by: Yang Li Reviewed-by: Jyri Sarha I'll merge this so

Re: [PATCH] drm/vmwgfx: fix spinlock initialization in vmw_driver_load()

2021-03-21 Thread Zack Rusin
> On Mar 21, 2021, at 10:56, Tetsuo Handa > wrote: > > Since vmw_write() from vmw_detect_version() from vmw_driver_load() calls > spin_lock(&dev_priv->hw_lock), spin_lock_init(&dev_priv->hw_lock) has to > be called before vmw_detect_version() is called, or lockdep gets disabled. > > INFO: tr

Re: [PATCH] drm/vmwgfx: Fix a typo

2021-03-21 Thread Zack Rusin
> On Mar 20, 2021, at 17:16, Bhaskar Chowdhury wrote: > > > s/particuar/particular/ > > Signed-off-by: Bhaskar Chowdhury > --- > drivers/gpu/drm/vmwgfx/vmwgfx_so.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_so.c > b/drivers/gpu/drm

Re: [PATCH] drm/amd/display: Set AMDGPU_DM_DEFAULT_MIN_BACKLIGHT to 0

2021-03-21 Thread Evan Benn
On Sat, Mar 20, 2021 at 8:36 AM Alex Deucher wrote: > > On Fri, Mar 19, 2021 at 5:31 PM Evan Benn wrote: > > > > On Sat, 20 Mar 2021 at 02:10, Harry Wentland wrote: > > > On 2021-03-19 10:22 a.m., Alex Deucher wrote: > > > > On Fri, Mar 19, 2021 at 3:23 AM Evan Benn wrote: > > > >> > > > >> AMD

Re: [PATCH V2] drm/bridge: lvds-codec: Add support for pixel data sampling edge select

2021-03-21 Thread Laurent Pinchart
Hi Marek, All my apologies for the awfully delayed review, and thank you for pinging me. On Thu, Dec 24, 2020 at 07:18:32AM +0100, Marek Vasut wrote: > The OnSemi FIN3385 Parallel-to-LVDS encoder has a dedicated input line to > select input pixel data sampling edge. Add DT property "pixelclk-acti

[PATCH] drm/sysfs: Convert sysfs sprintf/snprintf family to sysfs_emit

2021-03-21 Thread Tian Tao
Fix the following coccicheck warning: drivers/gpu/drm/drm_sysfs.c:172:8-16: WARNING: use scnprintf or sprintf drivers/gpu/drm/drm_sysfs.c:185:8-16: WARNING: use scnprintf or sprintf drivers/gpu/drm/drm_sysfs.c:159:8-16: WARNING: use scnprintf or sprintf Signed-off-by: Tian Tao --- drivers/gpu/dr

[PATCH] drm/amd/display: Remove unnecessary conversion to bool

2021-03-21 Thread Jiapeng Chong
Fix the following coccicheck warnings: ./drivers/gpu/drm/amd/display/dc/dcn30/dcn30_mpc.c:875:62-67: WARNING: conversion to bool not needed here. Reported-by: Abaci Robot Signed-off-by: Jiapeng Chong --- drivers/gpu/drm/amd/display/dc/dcn30/dcn30_mpc.c | 2 +- 1 file changed, 1 insertion(+), 1

[PATCH] dt-bindings: display: Fix a typo

2021-03-21 Thread Bhaskar Chowdhury
s/Subsytem/Subsystem/ Signed-off-by: Bhaskar Chowdhury --- Documentation/devicetree/bindings/display/msm/mdp5.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Documentation/devicetree/bindings/display/msm/mdp5.txt b/Documentation/devicetree/bindings/display/msm/mdp5.txt

Re: [PATCH] dt-bindings: display: Fix a typo

2021-03-21 Thread Randy Dunlap
On 3/21/21 7:29 PM, Bhaskar Chowdhury wrote: > > s/Subsytem/Subsystem/ > > Signed-off-by: Bhaskar Chowdhury > --- > Documentation/devicetree/bindings/display/msm/mdp5.txt | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/Documentation/devicetree/bindings/display/msm/mdp5

[RFC PATCH 00/11] drm/bridge: ti-sn65dsi86: Support DisplayPort mode

2021-03-21 Thread Laurent Pinchart
Hello, Despite the SN65DSI86 being a DSI to eDP bridge, it can also operate in DisplayPort mode. This patch series adds support for this feature to the ti-sn65dsi86 driver. The series starts with miscellaneous fixes and improvements in patch 01/11 to 04/11. Patch 05/11 then moves to the panel-bri

[RFC PATCH 01/11] dt-bindings: drm/bridge: ti-sn65dsi8: Make enable GPIO optional

2021-03-21 Thread Laurent Pinchart
The SN65DSI86 EN pin can be hardwired to a high level, or connected to a global reset signal, not controllable by the kernel. Make it optional in those cases. Signed-off-by: Laurent Pinchart --- .../devicetree/bindings/display/bridge/ti,sn65dsi86.yaml | 1 - 1 file changed, 1 deletion(-)

[RFC PATCH 02/11] drm/bridge: ti-sn65dsi86: Make enable GPIO optional

2021-03-21 Thread Laurent Pinchart
The enable signal may not be controllable by the kernel. Make it optional. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/bridge/ti-sn65dsi86.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/bridge/ti-sn65dsi86.c b/drivers/gpu/drm/bridge/ti-sn65dsi8

[RFC PATCH 04/11] drm/bridge: ti-sn65dsi86: Use bitmask to store valid rates

2021-03-21 Thread Laurent Pinchart
The valid rates are stored in an array of 8 booleans. Replace it with a bitmask to save space. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/bridge/ti-sn65dsi86.c | 24 +--- 1 file changed, 13 insertions(+), 11 deletions(-) diff --git a/drivers/gpu/drm/bridge/ti-sn65ds

[RFC PATCH 03/11] drm/bridge: ti-sn65dsi86: Unregister AUX adapter in remove()

2021-03-21 Thread Laurent Pinchart
The AUX adapter registered in probe() need to be unregistered in remove(). Do so. Fixes: b814ec6d4535 ("drm/bridge: ti-sn65dsi86: Implement AUX channel") Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/bridge/ti-sn65dsi86.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/gpu/d

[RFC PATCH 11/11] drm/bridge: ti-sn65dsi86: Support hotplug detection

2021-03-21 Thread Laurent Pinchart
When the SN65DSI86 is used in DisplayPort mode, its output is likely routed to a DisplayPort connector, which can benefit from hotplug detection. Support it in such cases, with polling mode only for now. The implementation is limited to the bridge operations, as the connector operations are legacy

[RFC PATCH 10/11] drm/bridge: ti-sn65dsi86: Support DisplayPort (non-eDP) mode

2021-03-21 Thread Laurent Pinchart
Despite the SN65DSI86 being an eDP bridge, on some systems its output is routed to a DisplayPort connector. Enable DisplayPort mode when the next component in the display pipeline is not a panel, and disable eDP features in that case. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/bridge/ti

[RFC PATCH 07/11] drm/bridge: ti-sn65dsi86: Split connector creation to a function

2021-03-21 Thread Laurent Pinchart
To prepare for making connector creation option, move connector creation out of ti_sn_bridge_attach to a separate function. No functional change intended. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/bridge/ti-sn65dsi86.c | 31 ++- 1 file changed, 21 insertions(+)

[RFC PATCH 06/11] drm/bridge: ti-sn65dsi86: Group code in sections

2021-03-21 Thread Laurent Pinchart
Reorganize the functions in sections, related to connector operations, bridge operations, AUX adapter, GPIO controller and probe & remove. This prepares for proper support of DRM_BRIDGE_ATTACH_NO_CONNECTOR that will add more functions, to ensure that the code will stay readable. No functional cha

[RFC PATCH 08/11] drm/bridge: ti-sn65dsi86: Implement bridge connector operations

2021-03-21 Thread Laurent Pinchart
Implement the bridge connector-related .get_edid() operation, and report the related bridge capabilities and type. The .get_edid() operation is implemented with the same backend as the EDID retrieval from the connector .get_modes() operation. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/b

[RFC PATCH 05/11] drm/bridge: ti-sn65dsi86: Wrap panel with panel-bridge

2021-03-21 Thread Laurent Pinchart
To simplify interfacing with the panel, wrap it in a panel-bridge and let the DRM bridge helpers handle chaining of operations. This also prepares for support of DRM_BRIDGE_ATTACH_NO_CONNECTOR, which requires all components in the display pipeline to be represented by bridges. Signed-off-by: Laur

[RFC PATCH 09/11] drm/bridge: ti-sn65dsi86: Make connector creation optional

2021-03-21 Thread Laurent Pinchart
Now that the driver supports the connector-related bridge operations, make the connector creation optional. This enables usage of the sn65dsi86 with the DRM bridge connector helper. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/bridge/ti-sn65dsi86.c | 11 --- 1 file changed, 4 inse

[PATCH] drm/imx: imx-ldb: Register LDB channel1 when it is the only channel to be used

2021-03-21 Thread Liu Ying
LDB channel1 should be registered if it is the only channel to be used. Without this patch, imx_ldb_bind() would skip registering LDB channel1 if LDB channel0 is not used, no matter LDB channel1 needs to be used or not. Fixes: 8767f4711b2b (drm/imx: imx-ldb: move initialization into probe) Signed-

[GIT PULL FOR v5.13] Conversion of misc display DT bindings to YAML

2021-03-21 Thread Laurent Pinchart
Hi Dave, Daniel, The following changes since commit 06debd6e1b28029e6e77c41e59a162868f377897: Merge tag 'drm-intel-next-2021-03-16' of git://anongit.freedesktop.org/drm/drm-intel into drm-next (2021-03-18 08:06:34 +1000) are available in the Git repository at: git://linuxtv.org/pinchartl/

Re: [PATCH v4 2/6] drm/sprd: add Unisoc's drm kms master

2021-03-21 Thread Kevin Tang
Hi Sam Ravnborg, Do you have more comments about my patch? Looking forward to your reply, thank you. Kevin Tang 于2021年2月22日周一 下午9:28写道: > Adds drm support for the Unisoc's display subsystem. > > This is drm kms driver, this driver provides support for the > application framework in Android, Yoc

[PATCH] drm/imx: ipuv3-plane: Remove two unnecessary export symbols

2021-03-21 Thread Liu Ying
The ipu_plane_disable_deferred() and ipu_plane_assign_pre() functions have not been used by any other modules but only imxdrm itself internally since imxdrm and imx-ipuv3-crtc were merged in one module. So, this patch removes export symbols for the two functions. Fixes: 3d1df96ad468 (drm/imx: merg

RE: [PATCH v3 3/3] drm/i915/display: Configure HDMI2.1 Pcon for FRL only if Src-Ctl mode is available

2021-03-21 Thread Shankar, Uma
> -Original Message- > From: Nautiyal, Ankit K > Sent: Tuesday, March 9, 2021 10:09 AM > To: intel-...@lists.freedesktop.org > Cc: dri-devel@lists.freedesktop.org; ville.syrj...@linux.intel.com; Shankar, > Uma > ; airl...@linux.ie; jani.nik...@linux.intel.com > Subject: [PATCH v3 3/3]

[PATCH] drm/msm/dpu: Fix a typo

2021-03-21 Thread Bhaskar Chowdhury
s/struture/structure/ Signed-off-by: Bhaskar Chowdhury --- drivers/gpu/drm/msm/disp/dpu1/dpu_hw_mdss.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_mdss.h b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_mdss.h index 09a3fb3e89f5..bb9ceadeb0bb