Re: [PATCH v3 1/2] drm/probe_helper: extract two helper functions

2023-01-26 Thread Neil Armstrong
Hi, On Tue, 24 Jan 2023 12:45:47 +0200, Dmitry Baryshkov wrote: > Extract drm_kms_helper_enable_hpd() and drm_kms_helper_disable_hpd(), > two helpers that enable and disable HPD handling on all device's > connectors. > > Thanks, Applied to https://anongit.freedesktop.org/git/drm/drm-misc.git (

Re: [PATCH] drm/bridge: Kconfig: fix a spelling mistake

2023-01-26 Thread Neil Armstrong
Hi, On Tue, 24 Jan 2023 15:34:42 -0800, Randy Dunlap wrote: > Correct a spelling mistake (reported by codespell). > > Thanks, Applied to https://anongit.freedesktop.org/git/drm/drm-misc.git (drm-misc-next) [1/1] drm/bridge: Kconfig: fix a spelling mistake https://cgit.freedesktop.org/d

[PULL] drm-misc-next

2023-01-26 Thread Thomas Zimmermann
Hi Dave and Daniel, after the PR earlier this week, here's drm-misc-next's final PR before -rc6. The committed TTM changes all seem to be reverted. Best regards Thomas drm-misc-next-2023-01-26: drm-misc-next for v6.3: UAPI Changes: Cross-subsystem Changes: Core Changes: * fbdev-helper: Stre

Re: UBSAN: shift-out-of-bounds in fbcon_set_font

2023-01-26 Thread Geert Uytterhoeven
Hi Sanan, On Thu, Jan 26, 2023 at 12:58 AM Sanan Hasanov wrote: > We found a bug using a modified kernel configuration file used by syzbot. > > We enhanced the coverage of the configuration file using our tool, klocalizer. > > Kernel Branch: 6.2.0-rc5-next-20230124 > Kernel config: > https://dri

Re: [PATCH] fbcon: Check font dimension limits

2023-01-26 Thread Jiri Slaby
On 26. 01. 23, 1:49, Samuel Thibault wrote: blit_x and blit_y are uint32_t, so fbcon currently cannot support fonts larger than 32x32. The 32x32 case also needs shifting an unsigned int, to properly set bit 31, otherwise we get "UBSAN: shift-out-of-bounds in fbcon_set_font", as reported on http

Re: [PATCH v5 2/8] drm/i915: Fix request locking during error capture & debugfs dump

2023-01-26 Thread Tvrtko Ursulin
On 26/01/2023 00:54, john.c.harri...@intel.com wrote: From: John Harrison When GuC support was added to error capture, the locking around the request object was broken. Fix it up. The context based search manages the spinlocking around the search internally. So it needs to grab the reference

Re: [PATCH] fbcon: Check font dimension limits

2023-01-26 Thread Jiri Slaby
On 26. 01. 23, 8:43, Greg KH wrote: --- linux-6.0.orig/drivers/video/fbdev/core/fbcon.c +++ linux-6.0/drivers/video/fbdev/core/fbcon.c @@ -2489,9 +2489,12 @@ static int fbcon_set_font(struct vc_data h > FBCON_SWAP(info->var.rotate, info->var.yres, info->var.xres)) retu

[PATCH] drm/simpledrm: Fix an NULL vs IS_ERR() bug

2023-01-26 Thread Dan Carpenter
The devm_memremap() function doesn't return NULL, it returns error pointers. Fixes: 9a10c7e6519b ("drm/simpledrm: Add support for system memory framebuffers") Signed-off-by: Dan Carpenter --- drivers/gpu/drm/tiny/simpledrm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git

Re: [PATCH 3/9] drm/vc4: hdmi: Add Broadcast RGB property to allow override of RGB range

2023-01-26 Thread Maxime Ripard
Hi, Thanks for your review On Wed, Jan 11, 2023 at 03:11:51PM +0100, Thomas Zimmermann wrote: > Am 07.12.22 um 17:07 schrieb Maxime Ripard: > > From: Dave Stevenson > > > > Copy Intel's "Broadcast RGB" property semantics to add manual override > > of the HDMI pixel range for monitors that don't

Re: [LSF/MM/BPF proposal]: Physr discussion

2023-01-26 Thread Mike Rapoport
On Mon, Jan 23, 2023 at 04:36:25AM +, Matthew Wilcox wrote: > On Sat, Jan 21, 2023 at 11:03:05AM -0400, Jason Gunthorpe wrote: > > I would like to have a session at LSF to talk about Matthew's > > physr discussion starter: > > > > https://lore.kernel.org/linux-mm/ydykweu0htv8m...@casper.infra

[PATCH] drm/panel: khadas-ts050: update timings to achieve 60Hz refresh rate

2023-01-26 Thread Neil Armstrong
This updates the panel timings to achieve a clean 60Hz refresh rate. Signed-off-by: Neil Armstrong --- drivers/gpu/drm/panel/panel-khadas-ts050.c | 18 +- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/drivers/gpu/drm/panel/panel-khadas-ts050.c b/drivers/gpu/drm/p

RE: Amdgpu module is references even after unbinding the vtcon

2023-01-26 Thread Slivka, Danijel
[AMD Official Use Only - General] Hi Thomas, I have checked what you mentioned. When loading amdgpu we call drm_client_init() during fbdev setup [1], the refcnt for drm_kms_helper increases from 3 -> 4. When we unbind vtcon, refcnt for drm_kms_helper drops 4 -> 3, but the drm_client_release()

Re: [PATCH v4 3/4] drm/amdgpu: Movie the amdgpu_gtt_mgr start and size from pages to bytes

2023-01-26 Thread Christian König
Am 25.01.23 um 16:20 schrieb Somalapuram Amaranath: To support GTT manager amdgpu_res_first, amdgpu_res_next from pages to bytes and clean up PAGE_SHIFT operation. Change the GTT manager init and allocate from pages to bytes v1 -> v2: reorder patch sequence v3 -> v4: reorder patch sequence That

[PATCH 1/2] drm/client: fix circular reference counting issue

2023-01-26 Thread Christian König
We reference dump buffers both by their handle as well as their object. The problem is now that when anybody iterates over the DRM framebuffers and exports the underlying GEM objects through DMA-buf we run into a circular reference count situation. The result is that the fbdev handling holds the G

[PATCH 2/2] drm: remove dumb_destroy callback

2023-01-26 Thread Christian König
Not used by any driver any more. Signed-off-by: Christian König --- drivers/gpu/drm/drm_dumb_buffers.c | 5 + drivers/gpu/drm/drm_gem.c | 7 --- drivers/gpu/drm/drm_internal.h | 3 --- include/drm/drm_drv.h | 19 --- 4 files changed, 1 inserti

[PULL] drm-misc-fixes

2023-01-26 Thread Maxime Ripard
Hi Dave, Daniel, Here's this week drm-misc-fixes PR Maxime drm-misc-fixes-2023-01-26: A fix and a preliminary patch to fix a memory leak in i915, and a use after free fix for fbdev deferred io The following changes since commit 2293a73ad4f3b6c37c06713ff1b67659d92ef43d: drm/i915: Remove unused

Re: [CI v8 0/4] drm/i915: switch to drm_edid and enable HF-EEODB support

2023-01-26 Thread Jani Nikula
On Wed, 25 Jan 2023, Jani Nikula wrote: > Here are the drm/i915 patches from [1], re-submitted to CI now that the > drm/edid dependencies from that series have been merged to > drm-misc-next, merged to drm-next, and backmerged to drm-misc-next. > > Fingers crossed. This has been a long journey. A

Re: [Intel-gfx] [PATCH v4] drm/i915/uncore: Use GT message helpers in uncore

2023-01-26 Thread Tvrtko Ursulin
On 25/01/2023 19:04, Matt Roper wrote: On Wed, Jan 25, 2023 at 10:51:53AM +, Tvrtko Ursulin wrote: On 24/01/2023 20:54, john.c.harri...@intel.com wrote: From: John Harrison Uncore is really part of the GT. So use the GT specific debug/error That's not really true; uncore should be ou

Re: [PATCH 1/6] dt-bindings: phy: qcom,hdmi-phy-other: use pxo clock

2023-01-26 Thread Krzysztof Kozlowski
On 19/01/2023 14:22, Dmitry Baryshkov wrote: > Add pxo clock to the 8960 bindings (used by the HDMI PLL) > > Signed-off-by: Dmitry Baryshkov > --- > .../bindings/phy/qcom,hdmi-phy-other.yaml | 23 --- > 1 file changed, 20 insertions(+), 3 deletions(-) > Reviewed-by: Krzysz

Re: (subset) [PATCH] drm/vc4: hdmi: make CEC adapter name unique

2023-01-26 Thread Maxime Ripard
On Thu, 19 Jan 2023 10:02:19 +0100, Hans Verkuil wrote: > The bcm2711 has two HDMI outputs, each with their own CEC adapter. > The CEC adapter name has to be unique, but it is currently > hardcoded to "vc4" for both outputs. Change this to use the card_name > from the variant information in order t

Re: [REGRESSION] [Bug 216859] New: PCI bridge to bus boot hang at enumeration

2023-01-26 Thread Bjorn Helgaas
[+cc folks from 145eed48de27 and framebuffer folks, regression list] On Thu, Jan 12, 2023 at 02:08:19PM -0600, Bjorn Helgaas wrote: > On Wed, Dec 28, 2022 at 06:02:48AM -0600, Bjorn Helgaas wrote: > > On Wed, Dec 28, 2022 at 08:37:52AM +, bugzilla-dae...@kernel.org wrote: > > > https://bugzill

Re: [RESEND PATCH v11 02/18] drm: bridge: panel: Add devm_drm_of_dsi_get_bridge helper

2023-01-26 Thread Maxime Ripard
Hi, On Mon, Jan 23, 2023 at 08:41:56PM +0530, Jagan Teki wrote: > Add devm OF helper to return the next DSI bridge in the chain. > > Unlike general bridge return helper devm_drm_of_get_bridge, this > helper uses the dsi specific panel_or_bridge helper to find the > next DSI device in the pipeline

Re: [PATCH v10 05/11] drm/shmem: Switch to use drm_* debug helpers

2023-01-26 Thread Gerd Hoffmann
On Mon, Jan 09, 2023 at 12:04:39AM +0300, Dmitry Osipenko wrote: > f a multi-GPU system by using drm_WARN_*() and > drm_dbg_kms() helpers that print out DRM device name corresponding > to shmem GEM. That commit message looks truncated ... take care, Gerd

Re: [PATCH v10 06/11] drm/shmem-helper: Don't use vmap_use_count for dma-bufs

2023-01-26 Thread Gerd Hoffmann
On Mon, Jan 09, 2023 at 12:04:40AM +0300, Dmitry Osipenko wrote: > its own refcounting of vmaps, use it instead of drm-shmem > counting. This change prepares drm-shmem for addition of memory shrinker > support where drm-shmem will use a single dma-buf reservation lock for > all operations performe

Re: Amdgpu module is references even after unbinding the vtcon

2023-01-26 Thread Christian König
Am 26.01.23 um 10:49 schrieb Slivka, Danijel: [AMD Official Use Only - General] Hi Thomas, I have checked what you mentioned. When loading amdgpu we call drm_client_init() during fbdev setup [1], the refcnt for drm_kms_helper increases from 3 -> 4. When we unbind vtcon, refcnt for drm_kms_hel

Re: [PATCH v10 06/11] drm/shmem-helper: Don't use vmap_use_count for dma-bufs

2023-01-26 Thread Dmitry Osipenko
On 1/26/23 15:17, Gerd Hoffmann wrote: > On Mon, Jan 09, 2023 at 12:04:40AM +0300, Dmitry Osipenko wrote: >> its own refcounting of vmaps, use it instead of drm-shmem >> counting. This change prepares drm-shmem for addition of memory shrinker >> support where drm-shmem will use a single dma-buf re

Re: [PATCH v1] drm/shmem-helper: Remove another errant put in error path

2023-01-26 Thread Dmitry Osipenko
On 1/9/23 00:13, Dmitry Osipenko wrote: > drm_gem_shmem_mmap() doesn't own reference in error code path, resulting > in the dma-buf shmem GEM object getting prematurely freed leading to a > later use-after-free. > > Fixes: f49a51bfdc8e ("drm/shme-helpers: Fix dma_buf_mmap forwarding bug") > Cc: st

Re: Amdgpu module is references even after unbinding the vtcon

2023-01-26 Thread Thomas Zimmermann
Hi Am 26.01.23 um 10:49 schrieb Slivka, Danijel: [AMD Official Use Only - General] Hi Thomas, I have checked what you mentioned. When loading amdgpu we call drm_client_init() during fbdev setup [1], the refcnt for drm_kms_helper increases from 3 -> 4. When we unbind vtcon, refcnt for drm_kms

Re: Amdgpu module is references even after unbinding the vtcon

2023-01-26 Thread Christian König
Am 26.01.23 um 13:40 schrieb Thomas Zimmermann: Hi Am 26.01.23 um 10:49 schrieb Slivka, Danijel: [AMD Official Use Only - General] Hi Thomas, I have checked what you mentioned. When loading amdgpu we call  drm_client_init() during fbdev setup [1], the refcnt for drm_kms_helper increases from

Re: [PATCH] drm/simpledrm: Fix an NULL vs IS_ERR() bug

2023-01-26 Thread Thomas Zimmermann
Am 26.01.23 um 10:28 schrieb Dan Carpenter: The devm_memremap() function doesn't return NULL, it returns error pointers. Fixes: 9a10c7e6519b ("drm/simpledrm: Add support for system memory framebuffers") Signed-off-by: Dan Carpenter Reviewed-by: Thomas Zimmermann --- drivers/gpu/drm/ti

Re: Amdgpu module is references even after unbinding the vtcon

2023-01-26 Thread Thomas Zimmermann
Hi Am 26.01.23 um 13:45 schrieb Christian König: Am 26.01.23 um 13:40 schrieb Thomas Zimmermann: Hi Am 26.01.23 um 10:49 schrieb Slivka, Danijel: [AMD Official Use Only - General] Hi Thomas, I have checked what you mentioned. When loading amdgpu we call  drm_client_init() during fbdev setup

Re: [RFC v3 00/12] DRM scheduling cgroup controller

2023-01-26 Thread Michal Koutný
On Wed, Jan 25, 2023 at 06:11:35PM +, Tvrtko Ursulin wrote: > I don't immediately see how you envisage the half-userspace implementation > would look like in terms of what functionality/new APIs would be provided by > the kernel? Output: drm.stat (with consumed time(s)) Input:

Re: [PATCH v2 1/2] drm/simpledrm: Allow physical width and height configuration via DT

2023-01-26 Thread Thomas Zimmermann
Hi, I just want to comment that the code in this patch is fine, but I'm not going to merge it until the other discussion about using the panel's DT nodes has been resolved. IMHO, the panel-based solution seems preferable to the new properties. Best regards Thomas Am 21.01.23 um 16:35 schrie

Re: [PATCH v2 1/3] drm/i915/xehp: GAM registers don't need to be re-applied on engine resets

2023-01-26 Thread Gustavo Sousa
On Wed, Jan 25, 2023 at 03:41:57PM -0800, Matt Roper wrote: > Register reset characteristics (i.e., whether the register maintains or > loses its value on engine reset) is an important factor that determines > which wa_list we want to add workarounds to. We recently found out that > the bspec docu

Re: [PATCH v2 2/3] drm/i915/mtl: Correct implementation of Wa_18018781329

2023-01-26 Thread Gustavo Sousa
On Wed, Jan 25, 2023 at 03:43:26PM -0800, Matt Roper wrote: > On Wed, Jan 25, 2023 at 03:41:58PM -0800, Matt Roper wrote: > > Workaround Wa_18018781329 has applied to several recent Xe_HP-based > > platforms. However there are some extra gotchas to implementing this > > properly for MTL that we ne

Re: [PATCH 5/9] drm/vc4: hdmi: Rework the CSC matrices organization

2023-01-26 Thread Maxime Ripard
Hi, On Wed, Jan 11, 2023 at 05:00:41PM +, Dave Stevenson wrote: > Hi Thomas > > Thanks for the review > > On Wed, 11 Jan 2023 at 15:03, Thomas Zimmermann wrote: > > > > Hi > > > > Am 07.12.22 um 17:07 schrieb Maxime Ripard: > > > From: Dave Stevenson > > > > > > The CSC matrices were store

Re: Assertion failure in i915 intel_display.c#assert_plane() after resume from hibernation

2023-01-26 Thread Jani Nikula
On Tue, 24 Jan 2023, наб wrote: > Booted with both, hibernated, resumed; full dmesg below. Unfortunately, this is probably hitting a regression with drm debug logging, and we don't get proper debug logging for i915. :( Please use DRM_USE_DYNAMIC_DEBUG=n with v6.1. I don't know if the proper fixe

RE: Amdgpu module is references even after unbinding the vtcon

2023-01-26 Thread Slivka, Danijel
[AMD Official Use Only - General] Hi Christian, I have tested the proposed patch, the issue is not reproducible and everything else seems to work fine. BR, Danijel >-Original Message- >From: Christian König >Sent: Thursday, January 26, 2023 1:20 PM >To: Slivka, Danijel ; Thomas Zimmer

[PATCH v2 0/9] drm/vc4: hdmi: Broadcast RGB, BT601, BT2020

2023-01-26 Thread Maxime Ripard
Hi, Here's a collection of patches that have been in the downstream tree for a while to add a bunch of new features to the HDMI controller. Let me know what you think, Maxime To: Emma Anholt To: Maxime Ripard To: David Airlie To: Daniel Vetter Cc: dri-devel@lists.freedesktop.org Cc: linux-ke

[PATCH v2 3/9] drm/vc4: hdmi: Add Broadcast RGB property to allow override of RGB range

2023-01-26 Thread Maxime Ripard
From: Dave Stevenson Copy Intel's "Broadcast RGB" property semantics to add manual override of the HDMI pixel range for monitors that don't abide by the content of the AVI Infoframe. Signed-off-by: Dave Stevenson Signed-off-by: Maxime Ripard --- drivers/gpu/drm/vc4/vc4_hdmi.c | 97 +++

[PATCH v2 1/9] drm/vc4: Switch to container_of_const

2023-01-26 Thread Maxime Ripard
container_of_const() allows to preserve the pointer constness and is thus more flexible than inline functions. Let's switch all our instances of container_of() to container_of_const(). Signed-off-by: Maxime Ripard --- drivers/gpu/drm/vc4/tests/vc4_mock.h| 3 ++ drivers/gpu/drm/vc4/test

[PATCH v2 4/9] drm/vc4: hdmi: Rename full range helper

2023-01-26 Thread Maxime Ripard
From: Dave Stevenson The VC4 HDMI driver has a helper function to figure out whether full range or limited range RGB is being used called vc4_hdmi_is_full_range_rgb(). We'll need it to support other colorspaces, so let's rename it to vc4_hdmi_is_full_range(). Signed-off-by: Dave Stevenson Revi

[PATCH v2 2/9] drm/vc4: hdmi: Update all the planes if the TV margins are changed

2023-01-26 Thread Maxime Ripard
On VC4, the TV margins on the HDMI connector are implemented by scaling the planes. However, if only the TV margins or the connector are changed by a new state, the planes ending up on that connector won't be. Thus, they won't be updated properly and we'll effectively ignore that change until the

[PATCH v2 9/9] drm/vc4: hdmi: Add BT.2020 Support

2023-01-26 Thread Maxime Ripard
From: Dave Stevenson Even though we report that we support the BT.2020 Colorspace, we were always using the BT.709 conversion matrices. Let's add the BT.2020 ones. Signed-off-by: Dave Stevenson Reviewed-by: Thomas Zimmermann Signed-off-by: Maxime Ripard --- drivers/gpu/drm/vc4/vc4_hdmi.c | 3

[PATCH v2 6/9] drm/vc4: hdmi: Rework the CSC matrices organization

2023-01-26 Thread Maxime Ripard
From: Dave Stevenson The CSC matrices were stored as separate matrix for each colorspace, and if we wanted a limited or full RGB output. This created some gaps in our support and we would not always pick the relevant matrix. Let's rework our data structure to store one per colorspace, and then

[PATCH v2 7/9] drm/vc4: hdmi: Add a function to retrieve the CSC matrix

2023-01-26 Thread Maxime Ripard
From: Dave Stevenson The CSC matrix to use depends on the output format, its range and the colorspace. Since we're going to add more colorspaces, let's move the CSC matrix retrieval to a function. Signed-off-by: Dave Stevenson Reviewed-by: Thomas Zimmermann Signed-off-by: Maxime Ripard ---

[PATCH v2 5/9] drm/vc4: hdmi: Swap CSC matrix channels for YUV444

2023-01-26 Thread Maxime Ripard
From: Dave Stevenson YUV444 and YUV422 actually require the same matrix, but programmed differently. We've dealt with it in the past by having two matrices, with the one for YUV444 reordered to accomodate the hardware. This gets in the way of subsequent reworks so let's define a function that w

[PATCH v2 8/9] drm/vc4: hdmi: Add BT.601 Support

2023-01-26 Thread Maxime Ripard
From: Dave Stevenson Even though we report that we support the BT601 Colorspace, we were always using the BT.709 conversion matrices. Let's add the BT601 ones. Signed-off-by: Dave Stevenson Reviewed-by: Thomas Zimmermann Signed-off-by: Maxime Ripard --- drivers/gpu/drm/vc4/vc4_hdmi.c | 38 ++

Re: Amdgpu module is references even after unbinding the vtcon

2023-01-26 Thread Christian König
Hi Danijel, can you also double check that GDM/X is still capable of acquiring a DMA-buf file descriptor for the buffer (e.g. that we have a DMA-buf handle for it while they are started). And that handover from fbdev to GDM/X is flicker free? Thanks, Christian. Am 26.01.23 um 14:44 schrieb

RE: Amdgpu module is references even after unbinding the vtcon

2023-01-26 Thread Sharma, Shashank
[AMD Official Use Only - General] I would also highly recommend this to be tested with another compositor (Like Weston/Sway etc) Regards Shashank -Original Message- From: Christian König Sent: 26 January 2023 15:12 To: Slivka, Danijel ; Thomas Zimmermann Cc: Deucher, Alexander ; dri-

Re: Amdgpu module is references even after unbinding the vtcon

2023-01-26 Thread Christian König
Oh, yeah. Very good point as well. Christian. Am 26.01.23 um 15:13 schrieb Sharma, Shashank: [AMD Official Use Only - General] I would also highly recommend this to be tested with another compositor (Like Weston/Sway etc) Regards Shashank -Original Message- From: Christian König Sen

Re: [PATCH 15/15] backlight: backlight: Drop the deprecated fb_blank property

2023-01-26 Thread Lee Jones
On Sat, 07 Jan 2023, Sam Ravnborg via B4 Submission Endpoint wrote: > From: Sam Ravnborg > > With all users gone remove the deprecated fb_blank member in > backlight_properties. > > Signed-off-by: Sam Ravnborg > Cc: Lee Jones > Cc: Daniel Thompson > Cc: Jingoo Han > --- > drivers/video/bac

Re: [PATCH 1/2] drm/client: fix circular reference counting issue

2023-01-26 Thread Thomas Zimmermann
Hi Am 26.01.23 um 11:28 schrieb Christian König: We reference dump buffers both by their handle as well as their object. The problem is now that when anybody iterates over the DRM framebuffers and exports the underlying GEM objects through DMA-buf we run into a circular reference count situation

Re: [PATCH 2/2] drm: remove dumb_destroy callback

2023-01-26 Thread Thomas Zimmermann
Am 26.01.23 um 11:28 schrieb Christian König: Not used by any driver any more. Signed-off-by: Christian König Same comments as for patch 1. Reviewed-by: Thomas Zimmermann Tested-by: Thomas Zimmermann --- drivers/gpu/drm/drm_dumb_buffers.c | 5 + drivers/gpu/drm/drm_gem.c

Re: [PATCH v9 1/2] dt-bindings: leds: backlight: Add Kinetic KTZ8866 backlight

2023-01-26 Thread Lee Jones
On Fri, 20 Jan 2023, Jianhua Lu wrote: > Add Kinetic KTZ8866 backlight binding documentation. > > Signed-off-by: Jianhua Lu > Reviewed-by: Krzysztof Kozlowski > --- > Changes in v2: > - Remove "items" between "compatible" and "const: kinetic,ktz8866". > - Change "additionalProperties" to "u

Re: [PATCH v9 2/2] backlight: ktz8866: Add support for Kinetic KTZ8866 backlight

2023-01-26 Thread Lee Jones
On Fri, 20 Jan 2023, Jianhua Lu wrote: > Add support for Kinetic KTZ8866 backlight, which is used in > Xiaomi tablet, Mi Pad 5 series. This driver lightly based on > downstream implementation [1]. > [1] > https://github.com/MiCode/Xiaomi_Kernel_OpenSource/blob/elish-r-oss/drivers/video/backlight/

Re: [PATCH 1/4] arm64: tegra: Mark host1x as dma-coherent on Tegra194/234

2023-01-26 Thread Thierry Reding
From: Thierry Reding On Thu, 19 Jan 2023 15:38:58 +0200, Mikko Perttunen wrote: > From: Mikko Perttunen > > Ensure appropriate configuration is done to make the host1x device > and context devices DMA coherent by adding the dma-coherent flag. > > Applied, thanks! [1/4] arm64: tegra: Mark ho

Re: [PATCH 1/4] gpu: host1x: Implement syncpoint wait using DMA fences

2023-01-26 Thread Thierry Reding
From: Thierry Reding On Thu, 19 Jan 2023 15:09:18 +0200, Mikko Perttunen wrote: > From: Mikko Perttunen > > In anticipation of removal of the intr API, move host1x_syncpt_wait > to use DMA fences instead. As of this patch, this means that waits > have a 30 second maximum timeout because of the

[PATCH v12 00/18] drm: Add Samsung MIPI DSIM bridge

2023-01-26 Thread Jagan Teki
This series supports common bridge support for Samsung MIPI DSIM which is used in Exynos and i.MX8MM SoC's. The final bridge supports both the Exynos and i.MX8M Mini/Nano/Plus. Patch 0001 - 0004: adding devm_drm_of_dsi_get_bridge Patch 0005 - 0006: optional PHY, PMS_P offset Patch 0007 :

[PATCH v12 01/18] drm: of: Lookup if child node has DSI panel or bridge

2023-01-26 Thread Jagan Teki
Devices can also be child nodes when we also control that device through the upstream device (ie, MIPI-DCS for a MIPI-DSI device). Unlike the drm_of_find_panel_or_bridge helper it requires a special case to lookup a child node of the given parent that isn't either port or ports. Lookup for a chil

[PATCH v12 02/18] drm: bridge: panel: Add devm_drm_of_dsi_get_bridge helper

2023-01-26 Thread Jagan Teki
Add devm OF helper to return the next DSI bridge in the chain. Unlike general bridge return helper devm_drm_of_get_bridge, this helper uses the dsi specific panel_or_bridge helper to find the next DSI device in the pipeline. Helper lookup a given child DSI node or a DT node's port and endpoint nu

[PATCH v12 03/18] drm: exynos: dsi: Drop explicit call to bridge detach

2023-01-26 Thread Jagan Teki
Exynos DSI already converted into a bridge driver, so bridge detach will suppose happened during bridge chain removal done by the bridge core. Drop the explicit call chain to detach the bridge. Signed-off-by: Jagan Teki --- Changes for v12, v11: - none Changes for v10: - new patch drivers/gpu/

[PATCH v12 04/18] drm: exynos: dsi: Switch to devm_drm_of_dsi_get_bridge

2023-01-26 Thread Jagan Teki
devm_drm_of_dsi_get_bridge is capable of looking up the downstream DSI bridge and panel and trying to add a panel bridge if the panel is found. Replace explicit finding calls with devm_drm_of_dsi_get_bridge. Signed-off-by: Jagan Teki --- Changes for v12, v11: - none Changes for v10: - new patch

[PATCH v12 05/18] drm: exynos: dsi: Mark PHY as optional

2023-01-26 Thread Jagan Teki
The same Samsung MIPI DSIM master can also be used in NXP's i.MX8M Mini/Nano/Plus SoC. In i.MX8M Mini/Nano/Plus SoC the DSI Phy requires a MIPI DPHY bit to reset in order to activate the PHY and that can be done via upstream i.MX8M blk-ctrl driver. So, mark the phy get as optional. Reviewed-by:

[PATCH v12 06/18] drm: exynos: dsi: Add platform PLL_P (PMS_P) offset

2023-01-26 Thread Jagan Teki
Look like PLL PMS_P offset value varies between platforms that have Samsung DSIM IP. However, there is no clear evidence for it as both Exynos and i.MX 8M Mini Application Processor Reference Manual is still referring the PMS_P offset as 13. The offset 13 is not working for i.MX8M Mini SoCs but t

[PATCH v12 07/18] drm: exynos: dsi: Introduce hw_type platform data

2023-01-26 Thread Jagan Teki
Samsung MIPI DSIM controller is common DSI IP that can be used in various SoCs like Exynos, i.MX8M Mini/Nano/Plus. Add hw_type enum via platform_data so that accessing the different controller data between various platforms becomes easy and meaningful. Reviewed-by: Marek Vasut Reviewed-by: Fried

[PATCH v12 08/18] drm: exynos: dsi: Handle proper host initialization

2023-01-26 Thread Jagan Teki
From: Marek Szyprowski Host transfer() in the DSI master will invoke only when the DSI commands are sent from DSI devices like DSI Panel or DSI bridges and this host the transfer wouldn't invoke for I2C-based-DSI bridge drivers. Handling DSI host initialization in transfer calls misses the contr

[PATCH v12 09/18] drm: exynos: dsi: Add atomic check

2023-01-26 Thread Jagan Teki
Look like an explicit fixing up of mode_flags is required for DSIM IP present in i.MX8M Mini/Nano SoCs. At least the LCDIF + DSIM needs active low sync polarities in order to correlate the correct sync flags of the surrounding components in the chain to make sure the whole pipeline can work proper

[PATCH v12 10/18] drm: exynos: dsi: Add input_bus_flags

2023-01-26 Thread Jagan Teki
LCDIF-DSIM glue logic inverts the HS/VS/DE signals and expecting the i.MX8M Mini/Nano DSI host to add additional Data Enable signal active low (DE_LOW). This makes the valid data transfer on each horizontal line. So, add additional bus flags DE_LOW setting via input_bus_flags for i.MX8M Mini/Nano

[PATCH v12 11/18] drm: exynos: dsi: Add atomic_get_input_bus_fmts

2023-01-26 Thread Jagan Teki
Finding the right input bus format throughout the pipeline is hard so add atomic_get_input_bus_fmts callback and initialize with the proper input format from list of supported output formats. This format can be used in pipeline for negotiating bus format between the DSI-end of this bridge and the

[PATCH v12 12/18] drm: exynos: dsi: Consolidate component and bridge

2023-01-26 Thread Jagan Teki
DSI host registration, attach and detach operations are quite different for the component and bridge-based DRM drivers.  Supporting generic bridge driver to use both component and bridge based DRM drivers can be tricky and would require additional host related operation hooks. Add host operation

[PATCH v12 13/18] drm: exynos: dsi: Add host helper for te_irq_handler

2023-01-26 Thread Jagan Teki
IRQ handler for te-gpio seems to be common across DSIM host. However, Exynos is handling this via CRTC drivers but there is no clear evidence on how the same has been handled in i.MX8MM. Keeping the handler as-it-is can be a viable option but adding DSIM bridge core in upcoming patches is not poss

Re: [PATCH v12 02/18] drm: bridge: panel: Add devm_drm_of_dsi_get_bridge helper

2023-01-26 Thread Maxime Ripard
On Thu, Jan 26, 2023 at 08:14:11PM +0530, Jagan Teki wrote: > Add devm OF helper to return the next DSI bridge in the chain. > > Unlike general bridge return helper devm_drm_of_get_bridge, this > helper uses the dsi specific panel_or_bridge helper to find the > next DSI device in the pipeline. >

[PATCH v12 14/18] drm: bridge: Generalize Exynos-DSI driver into a Samsung DSIM bridge

2023-01-26 Thread Jagan Teki
Samsung MIPI DSIM controller is common DSI IP that can be used in various SoCs like Exynos, i.MX8M Mini/Nano. In order to access this DSI controller between various platform SoCs, the ideal way to incorporate this in the drm stack is via the drm bridge driver. We already have a consolidated code

[PATCH v12 15/18] dt-bindings: display: exynos: dsim: Add NXP i.MX8M Mini/Nano support

2023-01-26 Thread Jagan Teki
Samsung MIPI DSIM bridge can also be found in i.MX8M Mini/Nano SoC. Add dt-bingings for it. Reviewed-by: Marek Vasut Acked-by: Rob Herring Signed-off-by: Jagan Teki --- Changes for v12: - collect RB from Marek Changes for v11, v10, v9: - none Changes for v8: - add comment to include i.MX8M Nan

[PATCH v12 16/18] drm: bridge: samsung-dsim: Add i.MX8M Mini/Nano support

2023-01-26 Thread Jagan Teki
Samsung MIPI DSIM master can also be found in i.MX8M Mini/Nano SoC. Add compatible and associated driver_data for it. Reviewed-by: Marek Vasut Reviewed-by: Frieder Schrempf Acked-by: Robert Foss Reviewed-by: Laurent Pinchart Signed-off-by: Marek Szyprowski Signed-off-by: Jagan Teki --- Chan

[PATCH v12 17/18] dt-bindings: display: exynos: dsim: Add NXP i.MX8M Plus support

2023-01-26 Thread Jagan Teki
Samsung MIPI DSIM bridge can also be found in i.MX8M Plus SoC. Add dt-bingings for it. Reviewed-by: Marek Vasut Acked-by: Rob Herring Signed-off-by: Jagan Teki --- Changes for v12: - collect RB from Marek Changes for v11: - collect ACK from Rob Changes for v10, v9: - none Documentation/devic

[PATCH v12 18/18] drm: bridge: samsung-dsim: Add i.MX8M Plus support

2023-01-26 Thread Jagan Teki
From: Marek Vasut Add extras to support i.MX8M Plus. The main change is the removal of HS/VS/DE signal inversion in the LCDIFv3-DSIM glue logic, otherwise the implementation of this IP in i.MX8M Plus is very much compatible with the i.MX8M Mini/Nano one. Reviewed-by: Marek Vasut Reviewed-by: Fr

Re: [PATCH v12 02/18] drm: bridge: panel: Add devm_drm_of_dsi_get_bridge helper

2023-01-26 Thread Jagan Teki
On Thu, Jan 26, 2023 at 8:17 PM Maxime Ripard wrote: > > On Thu, Jan 26, 2023 at 08:14:11PM +0530, Jagan Teki wrote: > > Add devm OF helper to return the next DSI bridge in the chain. > > > > Unlike general bridge return helper devm_drm_of_get_bridge, this > > helper uses the dsi specific panel_or

Re: [RESEND PATCHv2 2/2] i915/display/dp: SDP CRC16 for 128b132b link layer

2023-01-26 Thread Jani Nikula
On Fri, 20 Jan 2023, Arun R Murthy wrote: > Enable SDP error detection configuration, this will set CRC16 in > 128b/132b link layer. > For Display version 13 a hardware bit31 in register VIDEO_DIP_CTL is > added to enable/disable SDP CRC applicable for DP2.0 only, but the > default value of this b

[PATCH 01/14] drm/msm/a6xx: De-staticize sptprac en/disable functions

2023-01-26 Thread Konrad Dybcio
These two will be reused by at least A619_holi in the non-gmu paths. De-staticize them to make it possible. Signed-off-by: Konrad Dybcio --- drivers/gpu/drm/msm/adreno/a6xx_gmu.c | 4 ++-- drivers/gpu/drm/msm/adreno/a6xx_gmu.h | 2 ++ 2 files changed, 4 insertions(+), 2 deletions(-) diff --git

[PATCH 02/14] drm/msm/a6xx: Extend UBWC config

2023-01-26 Thread Konrad Dybcio
Port setting min_access_length, ubwc_mode and upper_bit from downstream. Values were validated using downstream device trees for SM8[123]50 and left default (as per downstream) elsewhere. Signed-off-by: Konrad Dybcio --- drivers/gpu/drm/msm/adreno/a6xx_gpu.c | 26 ++ 1 fi

[PATCH 03/14] drm/msm/a6xx: Introduce GMU wrapper support

2023-01-26 Thread Konrad Dybcio
Some (particularly SMD_RPM, a.k.a non-RPMh) SoCs implement A6XX GPUs but don't implement the associated GMUs. This is due to the fact that the GMU directly pokes at RPMh. Sadly, this means we have to take care of enabling & scaling power rails, clocks and bandwidth ourselves. Reuse existing Adreno

[PATCH 05/14] drm/msm/adreno: Disable has_cached_coherent for A610/A619_holi

2023-01-26 Thread Konrad Dybcio
These SKUs don't support the feature. Disable it to make the GPU stop crashing after almost each and every submission - the received data on the GPU end was simply incomplete in garbled, resulting in almost nothing being executed properly. Signed-off-by: Konrad Dybcio --- drivers/gpu/drm/msm/adr

[PATCH 04/14] drm/msm/a6xx: Remove both GBIF and RBBM GBIF halt on hw init

2023-01-26 Thread Konrad Dybcio
Currently we're only deasserting REG_A6XX_RBBM_GBIF_HALT, but we also need REG_A6XX_GBIF_HALT to be set to 0. For GMU-equipped GPUs this is done in a6xx_bus_clear_pending_transactions(), but for the GMU-less ones we have to do it *somewhere*. Unhalting both side by side sounds like a good plan and

[PATCH 09/14] drm/msm/a6xx: Fix some A619 tunables

2023-01-26 Thread Konrad Dybcio
Adreno 619 expects some tunables to be set differently. Make up for it. Fixes: b7616b5c69e6 ("drm/msm/adreno: Add A619 support") Signed-off-by: Konrad Dybcio --- drivers/gpu/drm/msm/adreno/a6xx_gpu.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/msm/adr

[PATCH 08/14] drm/msm/a6xx: Add A610 support

2023-01-26 Thread Konrad Dybcio
A610 is one of (if not the) lowest-tier SKUs in the A6XX family. It features no GMU, as it's implemented solely on SoCs with SMD_RPM. What's more interesting is that it does not feature a VDDGX line either, being powered solely by VDDCX and has an unfortunate hardware quirk that makes its reset lin

[PATCH 07/14] drm/msm/a6xx: Add support for A619_holi

2023-01-26 Thread Konrad Dybcio
A619_holi is a GMU-less variant of the already-supported A619 GPU. It's present on at least SM4350 (holi) and SM6375 (blair). No mesa changes are required. Add the required kernel-side support for it. Signed-off-by: Konrad Dybcio --- drivers/gpu/drm/msm/adreno/a6xx_gpu.c | 37 ++

[PATCH 10/14] drm/msm/a6xx: Fix up A6XX protected registers

2023-01-26 Thread Konrad Dybcio
One of the protected ranges was too small (compared to the data we have downstream). Fix it. Fixes: 408434036958 ("drm/msm/a6xx: update/fix CP_PROTECT initialization") Signed-off-by: Konrad Dybcio --- drivers/gpu/drm/msm/adreno/a6xx_gpu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) di

[PATCH 06/14] drm/msm/gpu: Use dev_pm_opp_set_rate for non-GMU GPUs

2023-01-26 Thread Konrad Dybcio
Currently we only utilize the OPP table connected to the GPU for getting (available) frequencies. We do however need to scale the voltage rail(s) accordingly to ensure that we aren't trying to run the GPU at 1GHz with a VDD_LOW vote, as that would result in an otherwise inexplainable hang. Tell th

[PATCH 11/14] drm/msm/a6xx: Enable optional icc voting from OPP tables

2023-01-26 Thread Konrad Dybcio
On GMU-equipped GPUs, the GMU requests appropriate bandwidth votes for us. This is however not the case for the other GPUs. Add the dev_pm_opp_of_find_icc_paths() call to let the OPP framework handle bus voting as part of power level setting. Signed-off-by: Konrad Dybcio --- drivers/gpu/drm/msm/

[PATCH 12/14] drm/msm/a6xx: Use "else if" in GPU speedbin rev matching

2023-01-26 Thread Konrad Dybcio
The GPU can only be one at a time. Turn a series of ifs into if + elseifs to save some CPU cycles. Signed-off-by: Konrad Dybcio --- drivers/gpu/drm/msm/adreno/a6xx_gpu.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/msm/adreno/a6xx_gpu.c b/drivers/g

[PATCH 13/14] drm/msm/a6xx: Add A619_holi speedbin support

2023-01-26 Thread Konrad Dybcio
A619_holi is implemented on at least two SoCs: SM4350 (holi) and SM6375 (blair). This is what seems to be a first occurrence of this happening, but it's easy to overcome by guarding the SoC-specific fuse values with of_machine_is_compatible(). Do just that to enable frequency limiting on these SoCs

[PATCH 14/14] drm/msm/a6xx: Add A610 speedbin support

2023-01-26 Thread Konrad Dybcio
A610 is implemented on at least three SoCs: SM6115 (bengal), SM6125 (trinket) and SM6225 (khaje). Trinket does not support speed binning (only a single SKU exists) and we don't yet support khaje upstream. Hence, add a fuse mapping table for bengal to allow for per-chip frequency limiting. Signed-o

Re: [RESEND PATCH v11 02/18] drm: bridge: panel: Add devm_drm_of_dsi_get_bridge helper

2023-01-26 Thread Jagan Teki
On Thu, Jan 26, 2023 at 5:42 PM Maxime Ripard wrote: > > Hi, > > On Mon, Jan 23, 2023 at 08:41:56PM +0530, Jagan Teki wrote: > > Add devm OF helper to return the next DSI bridge in the chain. > > > > Unlike general bridge return helper devm_drm_of_get_bridge, this > > helper uses the dsi specific

Re: [PATCH 1/4] dt-bindings: display: bridge: tfp410: Add tfp410 i2c example

2023-01-26 Thread Krzysztof Kozlowski
On 25/01/2023 22:09, Jonathan Cormier wrote: > Add a i2c example with HDMI connector Why? It's the same - but more on this below. > > Signed-off-by: Jonathan Cormier You need to test the bindings before sending and fix the errors. > --- > .../bindings/display/bridge/ti,tfp410.yaml |

Re: [PATCH 2/4] DRM: BRIDGE: TFP410: Support basic I2C interface

2023-01-26 Thread Krzysztof Kozlowski
On 25/01/2023 22:09, Jonathan Cormier wrote: > From: Michael Williamson > > The TFP410 driver does not support I2C. As such, the device remains in > Power Down if the I2C is enabled by the bootstrap pins. > > Add basic support for the I2C interface, and provide support to take > the device out

Re: [Intel-gfx] [PATCH v4] drm/i915/uncore: Use GT message helpers in uncore

2023-01-26 Thread Matt Roper
On Thu, Jan 26, 2023 at 10:46:01AM +, Tvrtko Ursulin wrote: > > On 25/01/2023 19:04, Matt Roper wrote: > > On Wed, Jan 25, 2023 at 10:51:53AM +, Tvrtko Ursulin wrote: > > > > > > On 24/01/2023 20:54, john.c.harri...@intel.com wrote: > > > > From: John Harrison > > > > > > > > Uncore is

Re: [PATCH v12 11/18] drm: exynos: dsi: Add atomic_get_input_bus_fmts

2023-01-26 Thread Marek Vasut
On 1/26/23 15:44, Jagan Teki wrote: Finding the right input bus format throughout the pipeline is hard so add atomic_get_input_bus_fmts callback and initialize with the proper input format from list of supported output formats. This format can be used in pipeline for negotiating bus format betwe

Re: [PATCH 15/15] backlight: backlight: Drop the deprecated fb_blank property

2023-01-26 Thread Sam Ravnborg
Hi Lee, On Thu, Jan 26, 2023 at 02:27:26PM +, Lee Jones wrote: > On Sat, 07 Jan 2023, Sam Ravnborg via B4 Submission Endpoint wrote: > > > From: Sam Ravnborg > > > > With all users gone remove the deprecated fb_blank member in > > backlight_properties. > > > > Signed-off-by: Sam Ravnborg >

  1   2   3   >