[PATCH 23/23] drm/ttm: remove bo->moving

2022-03-21 Thread Christian König
This is now handled by the DMA-buf framework in the dma_resv obj. Signed-off-by: Christian König --- .../gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c | 13 --- drivers/gpu/drm/amd/amdgpu/amdgpu_object.c| 7 ++-- drivers/gpu/drm/amd/amdgpu/amdgpu_vm_cpu.c| 11 +++---

[PATCH 16/23] dma-buf: add enum dma_resv_usage v3

2022-03-21 Thread Christian König
This change adds the dma_resv_usage enum and allows us to specify why a dma_resv object is queried for its containing fences. Additional to that a dma_resv_usage_rw() helper function is added to aid retrieving the fences for a read or write userspace submission. This is then deployed to the

[PATCH 19/23] dma-buf: add DMA_RESV_USAGE_KERNEL v2

2022-03-21 Thread Christian König
Add an usage for kernel submissions. Waiting for those are mandatory for dynamic DMA-bufs. v2: use "must" in documentation, fix whitespaces Signed-off-by: Christian König --- drivers/dma-buf/st-dma-resv.c| 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_object.c | 2 +-

[PATCH 20/23] dma-buf: add DMA_RESV_USAGE_BOOKKEEP v2

2022-03-21 Thread Christian König
Add an usage for submissions independent of implicit sync but still interesting for memory management. v2: cleanup the kerneldoc a bit Signed-off-by: Christian König --- drivers/dma-buf/dma-resv.c | 2 +- drivers/dma-buf/st-dma-resv.c| 2 +-

[PATCH 21/23] dma-buf: wait for map to complete for static attachments

2022-03-21 Thread Christian König
We have previously done that in the individual drivers but it is more defensive to move that into the common code. Dynamic attachments should wait for map operations to complete by themselves. Signed-off-by: Christian König --- drivers/dma-buf/dma-buf.c | 18

[PATCH 09/23] drm/amdgpu: use dma_resv_for_each_fence for CS workaround

2022-03-21 Thread Christian König
Get the write fence using dma_resv_for_each_fence instead of accessing it manually. Signed-off-by: Christian König Cc: amd-...@lists.freedesktop.org --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 9 ++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git

[PATCH 15/23] drm/amdgpu: use dma_resv_get_singleton in amdgpu_pasid_free_cb

2022-03-21 Thread Christian König
Makes the code a bit more simpler. Signed-off-by: Christian König Reviewed-by: Daniel Vetter Cc: amd-...@lists.freedesktop.org --- drivers/gpu/drm/amd/amdgpu/amdgpu_ids.c | 23 +++ 1 file changed, 3 insertions(+), 20 deletions(-) diff --git

[PATCH 08/23] drm/radeon: stop using dma_resv_excl_fence

2022-03-21 Thread Christian König
Instead use the new dma_resv_get_singleton function. Signed-off-by: Christian König Reviewed-by: Daniel Vetter Cc: amd-...@lists.freedesktop.org --- drivers/gpu/drm/radeon/radeon_display.c | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git

[PATCH 07/23] drm/vmwgfx: stop using dma_resv_excl_fence

2022-03-21 Thread Christian König
Instead use the new dma_resv_get_singleton function. Signed-off-by: Christian König Reviewed-by: Daniel Vetter Cc: VMware Graphics Cc: Zack Rusin --- drivers/gpu/drm/vmwgfx/vmwgfx_resource.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git

[PATCH 10/23] dma-buf: finally make dma_resv_excl_fence private v2

2022-03-21 Thread Christian König
Drivers should never touch this directly. v2: fix rebase clash Signed-off-by: Christian König --- drivers/dma-buf/dma-resv.c | 6 ++ include/linux/dma-resv.h | 17 - 2 files changed, 6 insertions(+), 17 deletions(-) diff --git a/drivers/dma-buf/dma-resv.c

[PATCH 14/23] drm/nouveau: support more than one write fence in fenv50_wndw_prepare_fb

2022-03-21 Thread Christian König
Use dma_resv_get_singleton() here to eventually get more than one write fence as single fence. Signed-off-by: Christian König Reviewed-by: Daniel Vetter Cc: Thomas Zimmermann Cc: Laurent Pinchart Cc: Maxime Ripard Cc: Lyude Paul Cc: nouv...@lists.freedesktop.org ---

[PATCH 12/23] dma-buf/drivers: make reserving a shared slot mandatory v3

2022-03-21 Thread Christian König
Audit all the users of dma_resv_add_excl_fence() and make sure they reserve a shared slot also when only trying to add an exclusive fence. This is the next step towards handling the exclusive fence like a shared one. v2: fix missed case in amdgpu v3: and two more radeon, rename function

[PATCH 05/23] drm/etnaviv: stop using dma_resv_excl_fence

2022-03-21 Thread Christian König
We can get the excl fence together with the shared ones as well. Signed-off-by: Christian König Reviewed-by: Daniel Vetter Cc: Lucas Stach Cc: Russell King Cc: Christian Gmeiner Cc: etna...@lists.freedesktop.org --- drivers/gpu/drm/etnaviv/etnaviv_gem.h| 1 -

[PATCH 13/23] drm/atomic-helper: support more than one write fence in drm_gem_plane_helper_prepare_fb

2022-03-21 Thread Christian König
Use dma_resv_get_singleton() here to eventually get more than one write fence as single fence. Signed-off-by: Christian König Reviewed-by: Daniel Vetter --- drivers/gpu/drm/drm_gem_atomic_helper.c | 18 +++--- 1 file changed, 7 insertions(+), 11 deletions(-) diff --git

[PATCH 06/23] drm/nouveau: stop using dma_resv_excl_fence

2022-03-21 Thread Christian König
Instead use the new dma_resv_get_singleton function. Signed-off-by: Christian König Reviewed-by: Daniel Vetter Cc: Ben Skeggs Cc: Karol Herbst Cc: Lyude Paul Cc: nouv...@lists.freedesktop.org --- drivers/gpu/drm/nouveau/nouveau_bo.c | 9 - 1 file changed, 8 insertions(+), 1

[PATCH 11/23] dma-buf: drop the DAG approach for the dma_resv object v2

2022-03-21 Thread Christian König
So far we had the approach of using a directed acyclic graph with the dma_resv obj. This turned out to have many downsides, especially it means that every single driver and user of this interface needs to be aware of this restriction when adding fences. If the rules for the DAG are not followed

[PATCH 04/23] RDMA: use dma_resv_wait() instead of extracting the fence

2022-03-21 Thread Christian König
Use dma_resv_wait() instead of extracting the exclusive fence and waiting on it manually. Signed-off-by: Christian König Reviewed-by: Daniel Vetter Cc: Jason Gunthorpe Cc: Leon Romanovsky Cc: Maor Gottlieb Cc: Gal Pressman Cc: linux-me...@vger.kernel.org Cc: linaro-mm-...@lists.linaro.org

[PATCH 02/23] dma-buf: finally make the dma_resv_list private v2

2022-03-21 Thread Christian König
Drivers should never touch this directly. v2: drop kerneldoc for now internal handling Signed-off-by: Christian König Reviewed-by: Daniel Vetter --- drivers/dma-buf/dma-resv.c | 11 +++ include/linux/dma-resv.h | 26 +- 2 files changed, 12 insertions(+), 25

[PATCH 03/23] dma-buf: add dma_resv_get_singleton v2

2022-03-21 Thread Christian König
Add a function to simplify getting a single fence for all the fences in the dma_resv object. v2: fix ref leak in error handling Signed-off-by: Christian König --- drivers/dma-buf/dma-resv.c | 52 ++ include/linux/dma-resv.h | 2 ++ 2 files changed, 54

[PATCH 01/23] dma-buf: add dma_resv_replace_fences v2

2022-03-21 Thread Christian König
This function allows to replace fences from the shared fence list when we can gurantee that the operation represented by the original fence has finished or no accesses to the resources protected by the dma_resv object any more when the new fence finishes. Then use this function in the amdkfd code

[PATCH 5.10 11/30] drm/imx: parallel-display: Remove bus flags check in imx_pd_bridge_atomic_check()

2022-03-21 Thread Greg Kroah-Hartman
From: Christoph Niedermaier [ Upstream commit 6061806a863e8b65b109eb06a280041cc7525442 ] If display timings were read from the devicetree using of_get_display_timing() and pixelclk-active is defined there, the flag DISPLAY_FLAGS_SYNC_POSEDGE/NEGEDGE is automatically generated. Through the

Re: [Intel-gfx] [PATCH] drm/i915: avoid concurrent writes to aux_inv

2022-03-21 Thread Tvrtko Ursulin
On 18/03/2022 18:08, fei.y...@intel.com wrote: From: Fei Yang GPU hangs have been observed when multiple engines write to the same aux_inv register at the same time. To avoid this each engine should only invalidate its own auxiliary table. The function gen12_emit_flush_xcs() currently

Re: [PATCH 0/4] Drop wbinvd_on_all_cpus usage

2022-03-21 Thread Thomas Hellström
Hi, On Mon, 2022-03-21 at 13:12 +, Tvrtko Ursulin wrote: > > On 21/03/2022 12:33, Thomas Hellström wrote: > > On Mon, 2022-03-21 at 12:22 +, Tvrtko Ursulin wrote: > > > > > > On 21/03/2022 11:03, Thomas Hellström wrote: > > > > Hi, Tvrtko. > > > > > > > > On 3/21/22 11:27, Tvrtko

[PATCH v5 3/3] drm/panel : innolux-ej030na and abt-y030xx067a : add .enable and .disable

2022-03-21 Thread Christophe Branchereau
Following the introduction of bridge_atomic_enable in the ingenic drm driver, the crtc is enabled between .prepare and .enable, if it exists. Add it so the backlight is only enabled after the crtc is, to avoid graphical issues. Signed-off-by: Christophe Branchereau ---

[PATCH v5 2/3] drm/panel: Add panel driver for NewVision NV3052C based LCDs

2022-03-21 Thread Christophe Branchereau
This driver supports the NewVision NV3052C based LCDs. Right now, it only supports the LeadTek LTK035C5444T 2.4" 640x480 TFT LCD panel, which can be found in the Anbernic RG-350M handheld console. Signed-off-by: Christophe Branchereau --- drivers/gpu/drm/panel/Kconfig | 9 +

[PATCH v5 1/3] drm/ingenic : add ingenic_drm_bridge_atomic_enable and disable

2022-03-21 Thread Christophe Branchereau
ingenic_drm_bridge_atomic_enable allows the CRTC to be enabled after panels have slept out, and before their display is turned on, solving a graphical bug on the newvision nv3502c. Also add ingenic_drm_bridge_atomic_disable to balance it out. Signed-off-by: Christophe Branchereau ---

[PATCH v5 0/3] Ingenic DRM bridge_atomic_enable proposal

2022-03-21 Thread Christophe Branchereau
Hello, v5 : - this set doesn't include the nv3052c bindings doc anymore, as it's already applied - nv3052c panel driver : removed empty lines, proceed to turn it off even is sleeping in fails instead of stopping there - abt panel : switched to REGCACHE_FLAT so we can disable sleep mode

[PATCH 2/6] drm/ttm: add resource iterator v4

2022-03-21 Thread Christian König
Instead of duplicating that at different places add an iterator over all the resources in a resource manager. v2: add lockdep annotation and kerneldoc v3: fix various bugs pointed out by Felix v4: simplify the code a bit more Signed-off-by: Christian König Tested-by: Bas Nieuwenhuizen

[PATCH 6/6] drm/amdgpu: drop amdgpu_gtt_node

2022-03-21 Thread Christian König
We have the BO pointer in the base structure now as well. Signed-off-by: Christian König Reviewed-by: Daniel Vetter Tested-by: Bas Nieuwenhuizen --- drivers/gpu/drm/amd/amdgpu/amdgpu_gtt_mgr.c | 49 - include/drm/ttm/ttm_resource.h | 8 2 files changed,

[PATCH 5/6] drm/ttm: rework bulk move handling v4

2022-03-21 Thread Christian König
Instead of providing the bulk move structure for each LRU update set this as property of the BO. This should avoid costly bulk move rebuilds with some games under RADV. v2: some name polishing, add a few more kerneldoc words. v3: add some lockdep v4: fix bugs, handle pin/unpin as well

[PATCH 4/6] drm/ttm: de-inline ttm_bo_pin/unpin

2022-03-21 Thread Christian König
Those functions are going to become more complex, don't inline them any more. Signed-off-by: Christian König --- drivers/gpu/drm/ttm/ttm_bo.c | 31 +++ include/drm/ttm/ttm_bo_api.h | 30 ++ 2 files changed, 33 insertions(+), 28

[PATCH 3/6] drm/ttm: allow bulk moves for all domains

2022-03-21 Thread Christian König
Not just TT and VRAM. Signed-off-by: Christian König Reviewed-by: Daniel Vetter Tested-by: Bas Nieuwenhuizen --- drivers/gpu/drm/ttm/ttm_resource.c | 52 +- include/drm/ttm/ttm_device.h | 2 -- include/drm/ttm/ttm_resource.h | 4 +-- 3 files changed, 17

[PATCH 1/6] drm/ttm: move the LRU into resource handling v4

2022-03-21 Thread Christian König
This way we finally fix the problem that new resource are not immediately evict-able after allocation. That has caused numerous problems including OOM on GDS handling and not being able to use TTM as general resource manager. v2: stop assuming in ttm_resource_fini that res->bo is still valid.

Re: [Intel-gfx] [PATCH v5 16/19] uapi/drm/dg2: Introduce format modifier for DG2 clear color

2022-03-21 Thread Imre Deak
Hi Nanley, JP, On Tue, Feb 15, 2022 at 09:34:22PM +0200, Juha-Pekka Heikkila wrote: > [...] > > > > > > > > > diff --git a/include/uapi/drm/drm_fourcc.h > > > > > > > > > b/include/uapi/drm/drm_fourcc.h index > > > > > > > > > b8fb7b44c03c..697614ea4b84 100644 > > > > > > > > > ---

Re: [PATCH 0/4] Drop wbinvd_on_all_cpus usage

2022-03-21 Thread Tvrtko Ursulin
On 21/03/2022 12:33, Thomas Hellström wrote: On Mon, 2022-03-21 at 12:22 +, Tvrtko Ursulin wrote: On 21/03/2022 11:03, Thomas Hellström wrote: Hi, Tvrtko. On 3/21/22 11:27, Tvrtko Ursulin wrote: On 19/03/2022 19:42, Michael Cheng wrote: To align with the discussion in [1][2], this

Re: [PATCH v4 2/4] drm/panel: Add panel driver for NewVision NV3052C based LCDs

2022-03-21 Thread Christophe Branchereau
Hi Paul On Mon, Mar 14, 2022 at 8:54 PM Paul Cercueil wrote: > > Hi Christophe, > > Le ven., mars 11 2022 at 18:02:38 +0100, Christophe Branchereau > a écrit : > > This driver supports the NewVision NV3052C based LCDs. Right now, it > > only supports the LeadTek LTK035C5444T 2.4" 640x480 TFT

Re: [PATCH v1 3/3] drm/panel : innolux-ej030na and abt-y030xx067a : add .enable and .disable

2022-03-21 Thread Christophe Branchereau
Hi Paul, yes that works fine, thanks for checking it out On Mon, Mar 14, 2022 at 9:54 PM Paul Cercueil wrote: > > Hi Christophe, > > Le lun., mars 7 2022 at 19:12:49 +0100, Christophe Branchereau > a écrit : > > Hi Paul, it should in theory, but doesn't work in practice, the > > display doesn't

Re: [PATCH] drm: drm_bufs: Error out if 'dev->agp' is a null pointer

2022-03-21 Thread Zheyu Ma
On Thu, Mar 17, 2022 at 6:49 PM Daniel Vetter wrote: > > On Fri, Mar 11, 2022 at 07:23:02AM +, Zheyu Ma wrote: > > The user program can control the 'drm_buf_desc::flags' via ioctl system > > call and enter the function drm_legacy_addbufs_agp(). If the driver > > doesn't initialize the agp

Re: [PATCH 0/4] Drop wbinvd_on_all_cpus usage

2022-03-21 Thread Thomas Hellström
On Mon, 2022-03-21 at 12:22 +, Tvrtko Ursulin wrote: > > On 21/03/2022 11:03, Thomas Hellström wrote: > > Hi, Tvrtko. > > > > On 3/21/22 11:27, Tvrtko Ursulin wrote: > > > > > > On 19/03/2022 19:42, Michael Cheng wrote: > > > > To align with the discussion in [1][2], this patch series drops

[PATCH RESEND] drm/i915/debugfs: Do not return '0' if there is nothing to return

2022-03-21 Thread Andi Shyti
Change functions that always return '0' to be void type. Signed-off-by: Andi Shyti Reviewed-by: Maciej Patelczyk --- Hi, just resending it once more time. Matt, can you please commit this refactoring if you are OK with it? Andi drivers/gpu/drm/i915/gt/intel_gt_debugfs.c| 7 ---

Re: [PATCH 0/4] Drop wbinvd_on_all_cpus usage

2022-03-21 Thread Tvrtko Ursulin
On 21/03/2022 11:03, Thomas Hellström wrote: Hi, Tvrtko. On 3/21/22 11:27, Tvrtko Ursulin wrote: On 19/03/2022 19:42, Michael Cheng wrote: To align with the discussion in [1][2], this patch series drops all usage of wbvind_on_all_cpus within i915 by either replacing the call with certain

Re: [PATCH v2] drm/amdgpu: Add support for drm_privacy_screen

2022-03-21 Thread Hans de Goede
Hi, On 3/20/22 21:11, Rajat Jain wrote: > () Hello Hans, Sean, > > > > On Fri, Mar 11, 2022 at 4:12 AM Hans de Goede wrote: >> >> Hi All, >> >> On 3/9/22 18:53, Rajat Jain wrote: >>> On Wed, Mar 9, 2022 at 7:06 AM Sean Paul wrote: From: Sean Paul This patch adds the

Re: [PATCH v12 3/4] drm/bridge: anx7625: add MIPI DPI input feature

2022-03-21 Thread Xin Ji
On Tue, Mar 08, 2022 at 11:00:20AM +0100, Robert Foss wrote: > On Mon, 7 Mar 2022 at 16:49, Robert Foss wrote: > > > > On Mon, 7 Mar 2022 at 07:12, Chen-Yu Tsai wrote: > > > > > > On Sun, Mar 06, 2022 at 07:13:30PM +0200, Laurent Pinchart wrote: > > > > Hello Xin, > > > > > > > > (Question for

[PATCH] drm/privacy-screen: Use connector name in lookup

2022-03-21 Thread Hans de Goede
ATM the drm privacy-screen code is not using connector names to lookup drm privacy-screen providers, drm_privacy_screen_get() does support this, but before this change the con_id is set to NULL everywhere which is treated as a wildcard. There are some worries that we may see devices with 2

Re: [PATCH v4 2/4] drm/panel: Add panel driver for NewVision NV3052C based LCDs

2022-03-21 Thread Sam Ravnborg
Hi Christophe, > > > + { 0x0d, 0x58 }, > > > + { 0x0e, 0x48 }, > > > + { 0x0f, 0x38 }, > > > + { 0x10, 0x2b }, > > > + > > > + { 0xff, 0x30 }, > > > + { 0xff, 0x52 }, > > > + { 0xff, 0x00 }, > > > + { 0x36, 0x0a }, > > > +}; > > There are some random (?) empty

Re: [PATCH 1/4] i915/gem: drop wbinvd_on_all_cpus usage

2022-03-21 Thread Thomas Hellström
On 3/21/22 11:30, Tvrtko Ursulin wrote: On 19/03/2022 19:42, Michael Cheng wrote: Previous concern with using drm_clflush_sg was that we don't know what the sg_table is pointing to, thus the usage of wbinvd_on_all_cpus to flush everything at once to avoid paranoia. And now we know, or we

Re: [PATCH] drm/i915/reg: Fix spelling mistake "Unsupport" -> "Unsupported"

2022-03-21 Thread Wang, Zhi A
Thanks for the contribution, Colin. Queued. On 3/15/22 8:24 PM, Colin Ian King wrote: > There is a spelling mistake in a gvt_vgpu_err error message. Fix it. > > Signed-off-by: Colin Ian King > --- > drivers/gpu/drm/i915/gvt/handlers.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) >

Re: [PATCH 0/4] Drop wbinvd_on_all_cpus usage

2022-03-21 Thread Thomas Hellström
Hi, Tvrtko. On 3/21/22 11:27, Tvrtko Ursulin wrote: On 19/03/2022 19:42, Michael Cheng wrote: To align with the discussion in [1][2], this patch series drops all usage of wbvind_on_all_cpus within i915 by either replacing the call with certain drm clflush helpers, or reverting to a previous

[PATCH] drm/bridge: adv7511: clean up CEC adapter when probe fails

2022-03-21 Thread Lucas Stach
When the probe routine fails we also need to clean up the CEC adapter registered in adv7511_cec_init(). Fixes: 3b1b975003e4 ("drm: adv7511/33: add HDMI CEC support") Signed-off-by: Lucas Stach --- The "fixed" commit is not the one introducing the issue, it had been there as long as the driver

Re: [PATCH v4 4/8] drm/i915/selftest_migrate: Check CCS meta data clear

2022-03-21 Thread Hellstrom, Thomas
On Sun, 2022-03-20 at 02:12 +0530, Ramalingam C wrote: > While clearing the Flat-CCS capable lmem object, we need to clear the > CCS > meta data corresponding to the memory. > > As part of live_migrate_clear add check for the ccs meta data clear > for > the Flat-CCS capable lmem object. > >

Re: [PATCH 1/2] dma-buf: add dma_fence_unwrap

2022-03-21 Thread Christian König
[Adding Daniel] Just once more a ping for this. It's an important bug fix and the end user already reported that it works. Regards, Christian. Am 14.03.22 um 12:14 schrieb Christian König: Just a gentle ping. This series is an important fix for drm-misc-next-fixes. Regards, Christian. Am

Re: [PATCH 1/4] i915/gem: drop wbinvd_on_all_cpus usage

2022-03-21 Thread Tvrtko Ursulin
On 19/03/2022 19:42, Michael Cheng wrote: Previous concern with using drm_clflush_sg was that we don't know what the sg_table is pointing to, thus the usage of wbinvd_on_all_cpus to flush everything at once to avoid paranoia. And now we know, or we know it is not a concern? To make i915

Re: [PATCH 0/4] Drop wbinvd_on_all_cpus usage

2022-03-21 Thread Tvrtko Ursulin
On 19/03/2022 19:42, Michael Cheng wrote: To align with the discussion in [1][2], this patch series drops all usage of wbvind_on_all_cpus within i915 by either replacing the call with certain drm clflush helpers, or reverting to a previous logic. AFAIU, complaint from [1] was that it is

Re: [Intel-gfx] [PATCH v4 6/8] drm/ttm: Add a parameter to add extra pages into ttm_tt

2022-03-21 Thread Das, Nirmoy
In the previous version I replied only to the mailing list email so probably my email slipped through. Reviewed-by: Nirmoy Das for patch 6-7 On 3/19/2022 9:42 PM, Ramalingam C wrote: Add a parameter called "extra_pages" for ttm_tt_init, to indicate that driver needs extra pages in ttm_tt.

Re: (subset) [PATCH] drm/selftest: plane_helper: Put test structures in static storage

2022-03-21 Thread Maxime Ripard
On Wed, 2 Mar 2022 16:59:09 -0700, Nathan Chancellor wrote: > Clang warns on certain 32-bit architectures: > > drivers/gpu/drm/selftests/test-drm_plane_helper.c:76:5: warning: stack > frame size (1064) exceeds limit (1024) in 'igt_check_plane_state' > [-Wframe-larger-than] > int

Re: [Intel-gfx] [PATCH v2 0/7] drm/i915: Use the memcpy_from_wc function from drm

2022-03-21 Thread Das, Nirmoy
looks good to me overall but I would get others r-b. Patches 1-3 Reviewed-by: Nirmoy Das Patches 4-7 Acked-by: Nirmoy Das On 03/03/2022 19:00, Balasubramani Vivekanandan wrote: drm_memcpy_from_wc() performs fast copy from WC memory type using non-temporal instructions. Now there are two

Re: [PATCH] ttm: remove check of list iterator against head outside the loop

2022-03-21 Thread Christian König
Am 19.03.22 um 08:31 schrieb Xiaomeng Tong: When list_for_each_entry() completes the iteration over the whole list without breaking the loop, the iterator value will be a bogus pointer computed based on the head element. While it is safe to use the pointer to determine if it was computed based

Re: [PATCH] drm/ttm: fix potential null ptr deref in when mem space alloc fails

2022-03-21 Thread Christian König
Am 18.03.22 um 20:50 schrieb Robert Beckett: when allocating a resource in place it is common to free the buffer's resource, then allocate a new resource in a different placement. e.g. amdgpu_bo_create_kernel_at calls ttm_resource_free, then calls ttm_bo_mem_space. Well yes I'm working the

Re: [PATCH 5/5] drm/ttm: Fix a kernel oops due to an invalid read

2022-03-21 Thread Christian König
Am 18.03.22 um 18:43 schrieb Zack Rusin: From: Zack Rusin The res is initialized here only if there's no errors so passing it to ttm_resource_fini in the error paths results in a kernel oops. In the error paths, instead of the unitialized res, we have to use to use node->base on which

Re: [PATCH v4 2/4] drm/panel: Add panel driver for NewVision NV3052C based LCDs

2022-03-21 Thread Christophe Branchereau
Hello Sam On Tue, Mar 15, 2022 at 9:23 PM Sam Ravnborg wrote: > > Hi Christophe, > On Fri, Mar 11, 2022 at 06:02:38PM +0100, Christophe Branchereau wrote: > > This driver supports the NewVision NV3052C based LCDs. Right now, it > > only supports the LeadTek LTK035C5444T 2.4" 640x480 TFT LCD

Re: [PATCH v2 1/2] drm: Add GPU reset sysfs event

2022-03-21 Thread Christian König
Am 18.03.22 um 16:12 schrieb Rob Clark: On Fri, Mar 18, 2022 at 12:42 AM Christian König wrote: Am 17.03.22 um 18:31 schrieb Rob Clark: On Thu, Mar 17, 2022 at 10:27 AM Daniel Vetter wrote: [SNIP] (At some point, I'd like to use scheduler for the replay, and actually use

Re: [PATCH v2] drm: of: Properly try all possible cases for bridge/panel detection

2022-03-21 Thread Maxime Ripard
On Fri, Mar 18, 2022 at 05:22:46PM +0100, Paul Kocialkowski wrote: > On Fri 18 Mar 22, 17:18, Maxime Ripard wrote: > > On Fri, Mar 18, 2022 at 05:02:49PM +0100, Paul Kocialkowski wrote: > > > While bridge/panel detection was initially relying on the usual > > > port/ports-based of graph detection,

[PATCH 1/2] drm: Add missing DP DSC extended capability definitions.

2022-03-21 Thread Stanislav Lisovskiy
Adding DP DSC register definitions, we might need for further DSC implementation, supporting MST and DP branch pass-through mode. v2: - Fixed checkpatch comment warning Signed-off-by: Stanislav Lisovskiy --- drivers/gpu/drm/dp/drm_dp.c| 25 +

[PATCH 2/2] drm/i915: Add DSC support to MST path

2022-03-21 Thread Stanislav Lisovskiy
Whenever we are not able to get enough timeslots for required PBN, let's try to allocate those using DSC, just same way as we do for SST. v2: Add DSC checks to intel_dp_mst_mode_valid_ctx, similar to ones we have in intel_dp_mode_valid(Manasi Navare) v3: Removed redundant edp condition logic

[PATCH 0/2] Add DP MST DSC support to i915

2022-03-21 Thread Stanislav Lisovskiy
Currently we have only DSC support for DP SST. Stanislav Lisovskiy (2): drm: Add missing DP DSC extended capability definitions. drm/i915: Add DSC support to MST path drivers/gpu/drm/dp/drm_dp.c | 25 drivers/gpu/drm/i915/display/intel_dp.c | 75 +-

Re: Regression from 3c196f056666 ("drm/amdgpu: always reset the asic in suspend (v2)") on suspend?

2022-03-21 Thread Thorsten Leemhuis
Hi, this is your Linux kernel regression tracker. Top-posting for once, to make this easily accessible to everyone. Dominique/Salvatore/Eric, what's the status of this regression? According to the debian bug tracker the problem is solved with 5.16 and 5.17, but was 5.15 ever fixed? Ciao,

Re: [PATCH v4 1/8] drm/i915/gt: Use XY_FASR_COLOR_BLT to clear obj on graphics ver 12+

2022-03-21 Thread Hellstrom, Thomas
On Sun, 2022-03-20 at 02:12 +0530, Ramalingam C wrote: > XY_FAST_COLOR_BLT cmd is faster than the older XY_COLOR_BLT. Hence > for > clearing (Zero out) the pages of the newly allocated object, faster > cmd > is used. NIT: Imperative wording > > Signed-off-by: Ramalingam C > Signed-off-by:

Re: [PATCH v8 02/16] clk: Provide new devm_clk helpers for prepared and enabled clocks

2022-03-21 Thread Uwe Kleine-König
On Sat, Mar 19, 2022 at 06:29:36PM +, Jonathan Cameron wrote: > On Mon, 14 Mar 2022 15:16:29 +0100 > Uwe Kleine-König wrote: > > > When a driver keeps a clock prepared (or enabled) during the whole > > lifetime of the driver, these helpers allow to simplify the drivers. > > > >

Re: [Intel-gfx] Small bar recovery vs compressed content on DG2

2022-03-21 Thread Thomas Hellström
On 3/18/22 19:12, Daniel Vetter wrote: Maybe also good to add dri-devel to these discussions. I'm not sure where exactly we landed with dgpu error capture (maybe I should check the code but it's really w/e here), but I think we can also toss in "you need a non-recoverable context for error

Re: [PATCH] drm: add a check to verify the size alignment

2022-03-21 Thread Paul Menzel
Dear Arunpravin, Am 21.03.22 um 06:59 schrieb Arunpravin Paneer Selvam: add a simple check to reject any size not aligned to the min_page_size. Nit: I’d start sentences with a capital letter. Could you please add a summary of the discussion to the commit message, so the question “Why?” is

Re: [PATCH v2] drm: Fix a infinite loop condition when order becomes 0

2022-03-21 Thread Arunpravin Paneer Selvam
On 16/03/22 6:02 pm, Christian König wrote: > Am 16.03.22 um 12:31 schrieb Matthew Auld: >> On 16/03/2022 06:34, Arunpravin Paneer Selvam wrote: >>> handle a situation in the condition order-- == min_order, >>> when order = 0 and min_order = 0, leading to order = -1, >>> it now won't exit the

Re: [PATCH] drm: Fix a infinite loop condition when order becomes 0

2022-03-21 Thread Arunpravin Paneer Selvam
On 16/03/22 12:28 pm, Paul Menzel wrote: > Dear Arunprivin, > > > Am 16.03.22 um 07:49 schrieb Arunpravin Paneer Selvam: > >> On 15/03/22 9:14 pm, Paul Menzel wrote: > >>> Am 15.03.22 um 16:42 schrieb Arunpravin: >>> On 15/03/22 2:35 pm, Paul Menzel wrote: >>> > Am 15.03.22 um

[PATCH] drm: add a check to verify the size alignment

2022-03-21 Thread Arunpravin Paneer Selvam
add a simple check to reject any size not aligned to the min_page_size. Signed-off-by: Arunpravin Paneer Selvam --- drivers/gpu/drm/drm_buddy.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/gpu/drm/drm_buddy.c b/drivers/gpu/drm/drm_buddy.c index 72f52f293249..b503c88786b0

<    1   2