Re: [PATCH v2 23/59] dyndbg: move .mod_name from/to structs ddebug_table/_ddebug_info

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : struct _ddebug_info already has almost all dyndbg's info for a module, so finish the encapsulation. This puts the datum closer to where its needed, improving the chance that we can obsolete the _ddebug.modame field with a desc_modname(dp) accessor f

Re: [PATCH v2 26/59] dyndbg: split multi-query strings with %

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : Since commit 85f7f6c0edb8 ("dynamic_debug: process multiple debug-queries on a line") Multi-query commands have been allowed: modprobe drm dyndbg="class DRM_UT_CORE +p; class DRM_UT_KMS +p" modprobe drm dyndbg=< [ 203.902703] dyndbg: query p

Re: [PATCH v2 24/59] dyndbg: treat comma as a token separator

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : Treat comma as a token terminator, just like a space. This allows a user to avoid quoting hassles when spaces are otherwise needed: :#> modprobe drm dyndbg=class,DRM_UT_CORE,+p\;class,DRM_UT_KMS,+p or as a boot arg: drm.dyndbg=class,DRM_UT_CO

Re: [PATCH v2 25/59] selftests-dyndbg: add comma_terminator_tests

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : New fn validates parsing and effect of queries using combinations of commas and spaces to delimit the tokens. It manipulates pr-debugs in builtin module/params, so might have deps I havent foreseen on odd configurations. Signed-off-by: Jim Cromie

Re: [PATCH v2 27/59] selftests-dyndbg: test_percent_splitting

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : This does basic testing of classmaps using '%' separated multi-queries. It modprobes test_dynamic_debug with several classes enabled, and counts to verify that the expected sites show the enablement in the control file. Signed-off-by: Jim Cromie

Re: [PATCH v2 29/59] dyndbg: change __dynamic_func_call_cls* macros into expressions

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : The Xe driver's XE_IOCTL_DBG macro calls drm_dbg() from inside an if (expression). This breaks when CONFIG_DRM_USE_DYNAMIC_DEBUG=y because the invoked macro has a do-while-0 wrapper. if (cond && (drm_dbg("expr-form"),1)) { ... do some mo

Re: [PATCH v2 28/59] selftests-dyndbg: add test_mod_submod

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : This new test-fn runs 3 module/submodule modprobe scenarios, variously using both the generic dyndbg= modprobe arg, and the test-module's classmap-params to manipulate the test-mod*'s pr_debugs. In all cases, the current flag-settings are counted and

Re: [PATCH v2 30/59] dyndbg: drop "protection" of class'd pr_debugs from legacy queries

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : Current classmap code protects class'd pr_debugs from unintended changes by "legacy" unclassed queries: # this doesn't disable all of DRM_UT_* categories echo "-p" > /proc/dynamic_debug/control # name the class to change it - protective bu

[PATCH 0/2] Add a Rust GPUVM abstraction

2025-03-24 Thread Daniel Almeida
Changes from v0: This version changes how `LockedGpuVm` operates. The previous code assumed that the interval tree would be protected if all the associated GEM's resvs were locked, but this is completely unrelated. In fact, this initial version only aims to support the core VA range management fe

[PATCH RESEND RFC v4 4/6] drm/display: dp-cec: use new DCPD access helpers

2025-03-24 Thread Dmitry Baryshkov
From: Dmitry Baryshkov Switch drm_dp_cec.c to use new set of DPCD read / write helpers. Reviewed-by: Lyude Paul Acked-by: Jani Nikula Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/display/drm_dp_cec.c | 37 ++-- 1 file changed, 18 insertions(+), 19 delet

[RFC PATCH 1/5] drm/sched: Fix teardown leaks with waitqueue

2025-03-24 Thread Philipp Stanner
From: Philipp Stanner The GPU scheduler currently does not ensure that its pending_list is empty before performing various other teardown tasks in drm_sched_fini(). If there are still jobs in the pending_list, this is problematic because after scheduler teardown, no one will call backend_ops.fre

[PATCH v5 0/6] drm/panfrost: Add support for AARCH64_4K page table format

2025-03-24 Thread Ariel D'Alessandro
Hi all, This is a new iteration on Panfrost support for AARCH64_4K page table format. The main reason behind this patchset is that MediaTek MT8188 SoC (ARM Mali-G57 MC3 GPU) constantly faults due to the actual Panfrost cache configuration. Currently, Panfrost only supports MMU configuration in "L

[RFC PATCH 3/5] drm/sched: Warn if pending list is not empty

2025-03-24 Thread Philipp Stanner
drm_sched_fini() can leak jobs under certain circumstances. Warn if that happens. Signed-off-by: Philipp Stanner --- drivers/gpu/drm/scheduler/sched_main.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/gpu/drm/scheduler/sched_main.c b/drivers/gpu/drm/scheduler/sched_main.c in

[RFC PATCH 2/5] drm/sched: Prevent teardown waitque from blocking too long

2025-03-24 Thread Philipp Stanner
The waitqueue that ensures that drm_sched_fini() blocks until the pending_list has become empty could theoretically cause that function to block for a very long time. That, ultimately, could block userspace procesess and prevent them from being killable through SIGKILL. When a driver calls drm_sch

[RFC PATCH 5/5] drm/nouveau: Remove waitque for sched teardown

2025-03-24 Thread Philipp Stanner
struct nouveau_sched contains a waitque needed to prevent drm_sched_fini() from being called while there are still jobs pending. Doing so so far would have caused memory leaks. With the new memleak-free mode of operation switched on in drm_sched_fini() by providing the callback nouveau_sched_fence

[PATCH v2] drm/panel/sharp-ls043t1le01: Use _multi variants

2025-03-24 Thread Anusha Srivatsa
Move away from using deprecated API and use _multi variants if available. Use mipi_dsi_msleep() and mipi_dsi_usleep_range() instead of msleep() and usleep_range() respectively. Used Coccinelle to find the _multi variant APIs, replacing mpi_dsi_msleep() where necessary and for returning dsi_ctx.acc

[PATCH v4 11/15] drm/i915/gt: Store active CCS mask

2025-03-24 Thread Andi Shyti
To support upcoming patches, we need to store the current mask for active CCS engines. Active engines refer to those exposed to userspace via the UABI engine list. Signed-off-by: Andi Shyti --- drivers/gpu/drm/i915/gt/intel_gt_ccs_mode.c | 41 +++-- drivers/gpu/drm/i915/gt/intel

[PATCH v4 06/15] drm/i915/gt: Introduce for_each_enabled_engine() and apply it in selftests

2025-03-24 Thread Andi Shyti
Selftests should run only on enabled engines, as disabled engines are not intended for use. A practical example is when, on DG2 machines, the user chooses to utilize only one CCS stream instead of all four. To address this, introduce the for_each_enabled_engine() loop, which will skip engines when

[PATCH v4 07/15] drm/i915/gt: Manage CCS engine creation within UABI exposure

2025-03-24 Thread Andi Shyti
In commit ea315f98e5d6 ("drm/i915/gt: Do not generate the command streamer for all the CCS"), we restricted the creation of physical CCS engines to only one stream. This allowed the user to submit a single compute workload, with all CCS slices sharing the workload from that stream. This patch remo

[PATCH v4 02/15] drm/i915/gt: Move the CCS mode variable to a global position

2025-03-24 Thread Andi Shyti
Store the CCS mode value in the intel_gt->ccs structure to make it available for future instances that may need to change its value. Name it mode_reg_val because it holds the value that will be written into the CCS_MODE register, determining the CCS balancing and, consequently, the number of engin

[PATCH v4 04/15] drm/i915/gt: Refactor uabi engine class/instance list creation

2025-03-24 Thread Andi Shyti
For the upcoming changes we need a cleaner way to build the list of uabi engines. Suggested-by: Tvrtko Ursulin Signed-off-by: Andi Shyti --- drivers/gpu/drm/i915/gt/intel_engine_user.c | 29 - 1 file changed, 17 insertions(+), 12 deletions(-) diff --git a/drivers/gpu/drm/i9

[PATCH v4 01/15] drm/i915/gt: Avoid using masked workaround for CCS_MODE setting

2025-03-24 Thread Andi Shyti
When setting the CCS mode, we mistakenly used wa_masked_en() to apply the workaround, which reads from the register and masks the existing value with the new one. Our intention was to write the value directly, without masking it. So far, this hasn't caused issues because we've been using a regist

[PATCH v4 08/15] drm/i915/gt: Remove cslices mask value from the CCS structure

2025-03-24 Thread Andi Shyti
Following the decision to manage CCS engine creation within UABI engines, the "cslices" variable in the "ccs" structure in the "gt" is no longer needed. Remove it is now redundant. Signed-off-by: Andi Shyti --- drivers/gpu/drm/i915/gt/intel_gt_ccs_mode.c | 2 +- drivers/gpu/drm/i915/gt/intel_gt_

[PATCH v4 03/15] drm/i915/gt: Allow the creation of multi-mode CCS masks

2025-03-24 Thread Andi Shyti
Until now, we have only set CCS mode balancing to 1, which means that only one compute engine is exposed to the user. The stream of compute commands submitted to that engine is then shared among all the dedicated execution units. This is done by calling the 'intel_gt_apply_ccs_mode(); function. W

[PATCH v4 10/15] drm/i915/gt: Store engine-related sysfs kobjects

2025-03-24 Thread Andi Shyti
Upcoming commits will need to access engine-related kobjects to enable the creation and destruction of sysfs interfaces at runtime. For this, store the "engine" directory (i915->sysfs_engine), the engine files (gt->kobj), and the default data (gt->kobj_defaults). Signed-off-by: Andi Shyti --- d

[PATCH v4 12/15] drm/i915: Protect access to the UABI engines list with a mutex

2025-03-24 Thread Andi Shyti
Until now, the UABI engines list has been accessed in read-only mode, as it was created once during boot and destroyed upon module unload. In upcoming commits, we will be modifying this list by changing the CCS mode, allowing compute engines to be dynamically added and removed at runtime based on

[PATCH v4 14/15] drm/i915/gt: Implement creation and removal routines for CCS engines

2025-03-24 Thread Andi Shyti
In preparation for upcoming patches, we need routines to dynamically create and destroy CCS engines based on the CCS mode that the user wants to set. The process begins by calculating the engine mask for the engines that need to be added or removed. We then update the UABI list of exposed engines

[PATCH v4 09/15] drm/i915/gt: Expose the number of total CCS slices

2025-03-24 Thread Andi Shyti
Implement a sysfs interface to show the number of available CCS slices. The displayed number does not take into account the CCS balancing mode. Signed-off-by: Andi Shyti --- drivers/gpu/drm/i915/gt/intel_gt_ccs_mode.c | 21 + drivers/gpu/drm/i915/gt/intel_gt_ccs_mode.h | 1 +

[PATCH v4 13/15] drm/i915/gt: Isolate single sysfs engine file creation

2025-03-24 Thread Andi Shyti
In preparation for upcoming patches, we need the ability to create and remove individual sysfs files. To facilitate this, extract from the intel_engines_add_sysfs() function the creation of individual files. Signed-off-by: Andi Shyti --- drivers/gpu/drm/i915/gt/sysfs_engines.c | 75 +

[PATCH v4 15/15] drm/i915/gt: Allow the user to change the CCS mode through sysfs

2025-03-24 Thread Andi Shyti
Create the 'ccs_mode' file under /sys/class/drm/cardX/gt/gt0/ccs_mode This file allows the user to read and set the current CCS mode. - Reading: The user can read the current CCS mode, which can be 1, 2, or 4. This value is derived from the current engine mask. - Writing: The user can s

Re: [PATCH v7 drm-dp 5/9] drm/hisilicon/hibmc: Getting connector info and EDID by using AUX channel

2025-03-24 Thread Jani Nikula
On Mon, 24 Mar 2025, Yongbang Shi wrote: >> On Wed, 19 Mar 2025, Yongbang Shi wrote: >>> From: Baihan Li >>> >>> Add registering drm_aux and use it to get connector edid with drm >>> functions. Add ddc channel in connector initialization to put drm_aux >>> in drm_connector. >>> >>> Signed-off-by

[PATCH v11 2/5] drm/xe/xe_gt_pagefault: Move pagefault struct to header

2025-03-24 Thread Jonathan Cavitt
Move the pagefault struct from xe_gt_pagefault.c to the xe_gt_pagefault_types.h header file, and move the associated enum values into the regs folder under xe_pagefault_desc.h Since xe_pagefault_desc.h is being initialized here, also move the xe_guc_pagefault_desc hardware formats to the new file.

[PATCH v11 0/5] drm/xe/xe_vm: Implement xe_vm_get_property_ioctl

2025-03-24 Thread Jonathan Cavitt
Add additional information to each VM so they can report up to the first 50 seen faults. Only pagefaults are saved this way currently, though in the future, all faults should be tracked by the VM for future reporting. Additionally, of the pagefaults reported, only failed pagefaults are saved this

[PATCH v11 4/5] drm/xe/xe_vm: Add per VM fault info

2025-03-24 Thread Jonathan Cavitt
Add additional information to each VM so they can report up to the first 50 seen faults. Only pagefaults are saved this way currently, though in the future, all faults should be tracked by the VM for future reporting. Additionally, of the pagefaults reported, only failed pagefaults are saved this

[PATCH v11 5/5] drm/xe/xe_vm: Implement xe_vm_get_property_ioctl

2025-03-24 Thread Jonathan Cavitt
Add support for userspace to request a list of observed faults from a specified VM. v2: - Only allow querying of failed pagefaults (Matt Brost) v3: - Remove unnecessary size parameter from helper function, as it is a property of the arguments. (jcavitt) - Remove unnecessary copy_from_user (Jain

[PATCH v11 3/5] drm/xe/uapi: Define drm_xe_vm_get_property

2025-03-24 Thread Jonathan Cavitt
Add initial declarations for the drm_xe_vm_get_property ioctl. v2: - Expand kernel docs for drm_xe_vm_get_property (Jianxun) v3: - Remove address type external definitions (Jianxun) - Add fault type to xe_drm_fault struct (Jianxun) Signed-off-by: Jonathan Cavitt Cc: Zhang Jianxun --- include/

Re: [PATCH 1/2] rust: helpers: Add bindings/wrappers for dma_resv

2025-03-24 Thread Miguel Ojeda
On Mon, Mar 24, 2025 at 4:14 PM Daniel Almeida wrote: > > -const blk_features_t RUST_CONST_HELPER_BLK_FEAT_ROTATIONAL = > BLK_FEAT_ROTATIONAL; > +const blk_features_t RUST_CONST_HELPER_BLK_FEAT_ROTATIONAL = > + BLK_FEAT_ROTATIONAL; Spurious change? Ah, this is probably the result of apply

Re: [PATCH v2 4/9] drm/panthor: Implement optional reset

2025-03-24 Thread Marek Vasut
On 3/24/25 9:43 AM, Boris Brezillon wrote: [...] @@ -563,6 +585,7 @@ int panthor_device_suspend(struct device *dev) panthor_devfreq_suspend(ptdev); + reset_control_assert(ptdev->resets); Hm, that might be the cause of the fast reset issue (which is a fast resume more than a fast rese

[PATCH] drm/amdgpu: Replace deprecated function strcpy() with strscpy()

2025-03-24 Thread Andres Urian Florez
Instead of using the strcpy() deprecated function to populate the fw_name, use the strscpy() function Link: https://www.kernel.org/doc/html/latest/process/deprecated.html#strcpy Signed-off-by: Andres Urian Florez --- drivers/gpu/drm/amd/amdgpu/amdgpu_cgs.c | 68 - 1 file

Re: [PATCH v7 drm-dp 5/9] drm/hisilicon/hibmc: Getting connector info and EDID by using AUX channel

2025-03-24 Thread Yongbang Shi
On Mon, 24 Mar 2025, Yongbang Shi wrote: On Wed, 19 Mar 2025, Yongbang Shi wrote: From: Baihan Li Add registering drm_aux and use it to get connector edid with drm functions. Add ddc channel in connector initialization to put drm_aux in drm_connector. Signed-off-by: Baihan Li Signed-off

Re: [PATCH v4 4/6] drm/panfrost: Add support for AARCH64_4K page table format

2025-03-24 Thread Ariel D'Alessandro
Adrian, On 3/22/25 3:48 PM, Adrian Larumbe wrote: On 17.03.2025 11:52, Ariel D'Alessandro wrote: Currently, Panfrost only supports MMU configuration in "LEGACY" (as Bifrost calls it) mode, a (modified) version of LPAE "Large Physical Address Extension", which in Linux we've called "mali_lpae".

Re: [PATCH 2/2] rust: drm: Add GPUVM abstraction

2025-03-24 Thread Daniel Almeida
Hi Miguel, thanks for having a look at this: > On 24 Mar 2025, at 14:36, Miguel Ojeda > wrote: > > Hi Daniel, > > A few quick notes for future versions on style/docs to try to keep > things consistent upstream -- not an actual review. > > On Mon, Mar 24, 2025 at 4:14 PM Daniel Almeida > wrot

Re: [RFC PATCH RESEND v4 0/6] drm/display: dp: add new DPCD access functions

2025-03-24 Thread Lyude Paul
This looks all good to me, do you need someone to push this to drm-misc? On Mon, 2025-03-24 at 13:51 +0200, Dmitry Baryshkov wrote: > Existing DPCD access functions return an error code or the number of > bytes being read / write in case of partial access. However a lot of > drivers either (incorr

Re: [PATCH 2/2] rust: drm: Add GPUVM abstraction

2025-03-24 Thread Benno Lossin
On Mon Mar 24, 2025 at 8:25 PM CET, Daniel Almeida wrote: >> On 24 Mar 2025, at 14:36, Miguel Ojeda >> wrote: >> >> Hi Daniel, >> >> A few quick notes for future versions on style/docs to try to keep >> things consistent upstream -- not an actual review. >> >> On Mon, Mar 24, 2025 at 4:14 PM D

Re: [PATCH] drm/i915/gvt: Add __nonstring annotations for unterminated strings

2025-03-24 Thread Nicolas Chauvet
Le lun. 24 mars 2025 à 13:54, Jani Nikula a écrit : > > On Sun, 23 Mar 2025, Damian Tometzki wrote: > > On Mon, 10. Mar 15:23, Kees Cook wrote: > >> When a character array without a terminating NUL character has a static > >> initializer, GCC 15's -Wunterminated-string-initialization will only >

Re: [PATCH v2 06/15] soc: mediatek: add mmsys support for MT8196

2025-03-24 Thread AngeloGioacchino Del Regno
Il 21/03/25 10:33, paul-pl.chen ha scritto: From: Nancy Lin 1. Defining driver data and adding compatible string for different subsystems (DISPSYS0, DISPSYS1, OVLSYS0, OVLSYS1, VDISP_AO) 2. Adding functions to control top clocks and ddp clocks. 3. Updating the probe function to initialize clock

Re: [PATCH v2 09/15] drm/mediatek: Refine OVL format convert API and export to public

2025-03-24 Thread 胡俊光

Re: [PATCH v2 14/15] drm/mediatek: Add support for multiple mmsys in the one mediatek-drm driver

2025-03-24 Thread 胡俊光

Re: [PATCH v2 47/59] drm-dyndbg: add DRM_CLASSMAP_USE to bochs

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : tiny/bochs has 5 DRM_UT_* debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module has class'd debugs. Signed-off-by: Jim Cromie Reviewed-by: Louis Chauvet --- drivers/gpu/drm/tiny/bochs.c | 2 ++

Re: [PATCH v2 10/59] dyndbg: replace classmap list with a vector

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:51, Jim Cromie a écrit : Classmaps are stored in an elf section/array, but currently are individually list-linked onto dyndbg's per-module ddebug_table for operation. This is unnecessary. Just like dyndbg's descriptors, classes are packed in compile order; so even with many

Re: [PATCH v2 16/59] dyndbg-API: remove DD_CLASS_TYPE_(DISJOINT|LEVEL)_NAMES and code

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:51, Jim Cromie a écrit : Remove the DD_CLASS_TYPE_*_NAMES classmap types and code. These 2 classmap types accept class names at the PARAM interface, for example: echo +DRM_UT_CORE,-DRM_UT_KMS > /sys/module/drm/parameters/debug_names The code works, but its only used by

Re: [PATCH v2 17/59] dyndbg-API: replace DECLARE_DYNDBG_CLASSMAP

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:51, Jim Cromie a écrit : DECLARE_DYNDBG_CLASSMAP() has a design error; its usage fails a basic K&R rule: "define once, refer many times". When DRM_USE_DYNAMIC_DEBUG=y, it is used across DRM core & drivers; each invocation allocates/inits the classmap understood by that modu

Re: [PATCH v2 12/59] dyndbg, module: make proper substructs in _ddebug_info

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:51, Jim Cromie a écrit : recompose struct _ddebug_info, inserting proper sub-structs. The struct currently has 2 pairs of fields: descs, num_descs and classes, num_classes. Several for-loops operate on these field pairs, soon many more will be added. Looping over these bl

Re: [PATCH v2 7/9] dt-bindings: gpu: mali-valhall-csf: Document i.MX95 support

2025-03-24 Thread Rob Herring (Arm)
On Fri, 21 Mar 2025 21:05:57 +0100, Marek Vasut wrote: > The instance of the GPU populated in Freescale i.MX95 is the > Mali G310, document support for this variant. > > Reviewed-by: Alexander Stein > Reviewed-by: Frank Li > Signed-off-by: Marek Vasut > --- > Cc: Boris Brezillon > Cc: Conor

Re: [PATCH v4] drm/panel/synaptics-r63353: Use _multi variants

2025-03-24 Thread Doug Anderson
Hi, On Tue, Mar 18, 2025 at 7:37 AM Anusha Srivatsa wrote: > > Move away from using deprecated API and use _multi > variants if available. Use mipi_dsi_msleep() > and mipi_dsi_usleep_range() instead of msleep() > and usleep_range() respectively. > > Used Coccinelle to find the _multi variant APIs

Re: [PATCH v3] drm/bridge: ti-sn65dsi86: Check bridge connection failure

2025-03-24 Thread Doug Anderson
Hi, On Tue, Mar 18, 2025 at 10:56 AM Doug Anderson wrote: > > Hi, > > On Tue, Mar 18, 2025 at 8:56 AM Wolfram Sang > wrote: > > > > Read out and check the ID registers, so we can bail out if I2C > > communication does not work or if the device is unknown. Tested on a > > Renesas GrayHawk board (

Re: [PATCH v2] drm/bridge: ti-sn65dsi86: make use of debugfs_init callback

2025-03-24 Thread Doug Anderson
Hi, On Mon, Mar 17, 2025 at 7:33 AM Doug Anderson wrote: > > Hi, > > On Sat, Mar 15, 2025 at 1:17 PM Wolfram Sang > wrote: > > > > Do not create a custom directory in debugfs-root, but use the > > debugfs_init callback to create a custom directory at the given place > > for the bridge. The new d

Re: [PATCH v4] drm/panel: novatek-nt36523: transition to mipi_dsi wrapped functions

2025-03-24 Thread Doug Anderson
Hi, On Sat, Mar 15, 2025 at 11:25 AM Tejas Vipin wrote: > > Changes the novatek-nt36523 panel to use multi style functions for > improved error handling. > > Reviewed-by: Douglas Anderson > Signed-off-by: Tejas Vipin > --- > Changes in v4: > - Cleanup nt36523_prepare > > Link to v3: > http

Re: [PATCH v7 0/5] bits: Fixed-type GENMASK_U*() and BIT_U*()

2025-03-24 Thread Vincent Mailhol
On 24/03/2025 at 23:28, Yury Norov wrote: > On Sat, Mar 22, 2025 at 06:23:11PM +0900, Vincent Mailhol via B4 Relay wrote: >> Introduce some fixed width variant of the GENMASK() and the BIT() >> macros in bits.h. Note that the main goal is not to get the correct >> type, but rather to enforce more c

Re: [PATCH 0/3] bits: Split asm and non-asm GENMASK*() and unify definitions

2025-03-24 Thread Vincent Mailhol
On 25/03/2025 at 01:11, Yury Norov wrote: > + Anshuman Khandual, Catalin Marinas, linux-arm-ker...@lists.infradead.org > > This series moves GENMASK_U128 out of uapi. ARM is the only proposed > user. Add ARM people for visibility. Actually, not yet. Here, I am decoupling GENMASK_U128() from __GEN

Re: [PATCH v3] drm/bridge: ti-sn65dsi86: Check bridge connection failure

2025-03-24 Thread Laurent Pinchart
On Tue, Mar 18, 2025 at 10:00:31PM +0100, Wolfram Sang wrote: > Hi Laurent, > > > > Read out and check the ID registers, so we can bail out if I2C > > > communication does not work or if the device is unknown. > > > > What's the advantage of that, what are you trying to guard against ? > > That

Re: [PATCH v2 39/59] drm-dyndbg: DRM_CLASSMAP_USE in amdgpu driver

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : Following the dyndbg-api-fix, replace DECLARE_DYNDBG_CLASSMAP with DRM_CLASSMAP_USE. This refs the defined & exported classmap, rather than re-declaring it redundantly, and error-prone-ly. This resolves the appearance of "class:_UNKNOWN_" in the co

Re: [PATCH v2] drm/panel: samsung-s6d7aa0: transition to mipi_dsi wrapped functions

2025-03-24 Thread Doug Anderson
Hi, On Wed, Mar 19, 2025 at 1:05 PM Doug Anderson wrote: > > Hi, > > On Wed, Mar 19, 2025 at 11:31 AM Tejas Vipin wrote: > > > > Changes the samsung-s6d7aa0 panel to use multi style functions for > > improved error handling. > > > > Signed-off-by: Tejas Vipin > > --- > > Changes in v2: > >

Re: [PATCH v2 2/3] misc: fastrpc: add support for gpdsp remoteproc

2025-03-24 Thread Srinivas Kandagatla
On 21/03/2025 14:07, Dmitry Baryshkov wrote: On Thu, Mar 20, 2025 at 05:11:20PM +, Srinivas Kandagatla wrote: On 20/03/2025 09:14, Ling Xu wrote: The fastrpc driver has support for 5 types of remoteprocs. There are some products which support GPDSP remoteprocs. Add changes to support G

Re: [PATCH v7 2/5] bits: introduce fixed-type BIT_U*()

2025-03-24 Thread Vincent Mailhol
On 24/03/2025 at 22:41, Andy Shevchenko wrote: > On Sat, Mar 22, 2025 at 06:23:13PM +0900, Vincent Mailhol via B4 Relay wrote: >> From: Lucas De Marchi >> >> Implement fixed-type BIT_U*() to help drivers add stricter checks, >> like it was done for GENMASK_U*(). > > ... > >> +/* >> + * Fixed-typ

Re: [PATCH v7 2/5] bits: introduce fixed-type BIT_U*()

2025-03-24 Thread Andy Shevchenko
On Mon, Mar 24, 2025 at 11:16:30PM +0900, Vincent Mailhol wrote: > On 24/03/2025 at 22:41, Andy Shevchenko wrote: > > On Sat, Mar 22, 2025 at 06:23:13PM +0900, Vincent Mailhol via B4 Relay > > wrote: ... > >> +/* > >> + * Fixed-type variants of BIT(), with additional checks like > >> GENMASK_T

Re: [PATCH v2 31/59] docs/dyndbg: explain new delimiters: comma, percent

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : Add mention of comma and percent delimiters into the respective paragraphs describing their equivalents: space and newline. cc: linux-...@vger.kernel.org Signed-off-by: Jim Cromie I think this should go with the previous patches introducing the

Re: [PATCH v2 32/59] docs/dyndbg: explain flags parse 1st

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : When writing queries to >control, flags are parsed 1st, since they are the only required field, and they require specific compositions. So if the flags draw an error (on those specifics), then keyword errors aren't reported. This can be mildly conf

Re: [PATCH v2 34/59] checkpatch: dont warn about unused macro arg on empty body

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : we currently get: WARNING: Argument 'name' is not used in function-like macro on: #define DRM_CLASSMAP_USE(name) /* nothing here */ Following this advice is wrong here, and shouldn't be fixed by ignoring args altogether; the macro should prop

Re: [PATCH v2 42/59] drm-dyndbg: DRM_CLASSMAP_USE in drm_dp_helper

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : Following the dyndbg-api-fix, replace DECLARE_DYNDBG_CLASSMAP with DRM_CLASSMAP_USE. This refs the defined & exported classmap, rather than re-declaring it redundantly, and error-prone-ly. This resolves the appearance of "class:_UNKNOWN_" in the co

Re: [PATCH v2 44/59] drm-dyndbg: add DRM_CLASSMAP_USE to Xe driver

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : Invoke DRM_CLASSMAP_USE from xe_drm_client.c. When built with CONFIG_DRM_USE_DYNAMIC_DEBUG=y, this tells dydnbg that Xe uses has drm.debug calls. Signed-off-by: Jim Cromie --- drivers/gpu/drm/xe/xe_drm_client.c | 2 ++ 1 file changed, 2 inserti

Re: [PATCH v2 37/59] drm-dyndbg: adapt DRM to invoke DYNAMIC_DEBUG_CLASSMAP_PARAM

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : Invoke DYNAMIC_DEBUG_CLASSMAP_PARAM to hook drm.debug (__drm_debug) to the DRM_UT_* classmap, replacing the ad-hoc wiring previously doing it. Add DRM_CLASSMAP_* adapter macros to selectively use DYNAMIC_DEBUG_CLASSMAP_* when DRM_USE_DYNAMIC_DEBUG=y

Re: [PATCH v2 41/59] drm-dyndbg: DRM_CLASSMAP_USE in drm_crtc_helper

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : Following the dyndbg-api-fix, replace DECLARE_DYNDBG_CLASSMAP with DRM_CLASSMAP_USE. This refs the defined & exported classmap, rather than re-declaring it redundantly, and error-prone-ly. This resolves the appearance of "class:_UNKNOWN_" in the co

Re: [PATCH v2 36/59] drm-dyndbg: adapt drm core to use dyndbg classmaps-v2

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : dyndbg's CLASSMAP-v1 api was broken; DECLARE_DYNDBG_CLASSMAP tried to do too much. Its replaced by DRM_CLASSMAP_DEFINE, which creates & EXPORTs a classmap (in DRM core), and DRM_CLASSMAP_USE which refers to the classmap defined elsewhere. The drive

Re: [PATCH v2 38/59] drm-print: fix config-dependent unused variable

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : With CONFIG_DRM_USE_DYNAMIC_DEBUG=y, __drm_printfn_dbg() gets an unused variable warning/error on 'category', even though the usage follows immediately, in drm_debug_enabled(category). For static-key optimized dyndbg, the macro doesn't actually chec

Re: [PATCH v2 08/10] drm/bridge: anx7625: enable HPD interrupts

2025-03-24 Thread Ayushi Makhija
On 3/11/2025 9:09 PM, Dmitry Baryshkov wrote: > On Tue, Mar 11, 2025 at 05:54:43PM +0530, Ayushi Makhija wrote: >> When device enters the suspend state, it prevents >> HPD interrupts from occurring. To address this, >> add an additional PM runtime vote in hpd_enable(). >> This vote is removed in hp

Re: [PATCH v2 40/59] drm-dyndbg: DRM_CLASSMAP_USE in i915 driver

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : Following the dyndbg-api-fix, replace DECLARE_DYNDBG_CLASSMAP with DRM_CLASSMAP_USE. This refs the defined & exported classmap, rather than re-declaring it redundantly, and error-prone-ly. This resolves the appearance of "class:_UNKNOWN_" in the co

Re: [PATCH v2 33/59] docs/dyndbg: add classmap info to howto (TBD)

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : Describe the 3 API macros providing dynamic_debug's classmaps DYNDBG_CLASSMAP_DEFINE - create & export a classmap DYNDBG_CLASSMAP_USE- refer to exported map DYNDBG_CLASSMAP_PARAM - bind control param to the classmap DYNDBG_CLASSMAP_PARAM_REF +

Re: [PATCH v2 14/59] dyndbg: split _emit_lookup() out of dynamic_emit_prefix()

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:51, Jim Cromie a écrit : Split dynamic_emit_prefix() to separate out _INCL_LOOKUPs: 1. keep dynamic_emit_prefix() static inline check _INCL_ANY flags before calling 2 2. __dynamic_emit_prefix() prints [TID] or and trailing space if +t flag check _INCL_LOOKUP f

Re: [PATCH 16/63] dyndbg-API: replace DECLARE_DYNDBG_CLASSMAP

2025-03-24 Thread Louis Chauvet
Le 16/03/2025 à 20:46, jim.cro...@gmail.com a écrit : hi Louis, On Tue, Feb 25, 2025 at 7:16 AM Louis Chauvet wrote: Le 25/01/2025 à 07:45, Jim Cromie a écrit : DECLARE_DYNDBG_CLASSMAP() has a design error; its usage fails a basic K&R rule: "define once, refer many times". It is used a

Re: [PATCH v2 5/7] accel/rocket: Add IOCTL for BO creation

2025-03-24 Thread Jeffrey Hugo
On 2/25/2025 12:55 AM, Tomeu Vizoso wrote: +/** + * rocket_gem_create_object - Implementation of driver->gem_create_object. + * @dev: DRM device + * @size: Size in bytes of the memory the object will reference + * + * This lets the GEM helpers allocate object structs for us, and keep + * our BO s

[PATCH 2/2] rust: drm: Add GPUVM abstraction

2025-03-24 Thread Daniel Almeida
From: Asahi Lina Add a GPUVM abstraction to be used by Rust GPU drivers. GPUVM keeps track of a GPU's virtual address (VA) space and manages the corresponding virtual mappings represented by "GPU VA" objects. It also keeps track of the mapping's backing GEM buffers. This initial version only su

Re: [PATCH v2 05/15] dt-bindings: display: mediatek: add OUTPROC yaml for MT8196

2025-03-24 Thread Rob Herring
On Fri, Mar 21, 2025 at 05:33:34PM +0800, paul-pl.chen wrote: > From: Paul-pl Chen > > Add mediate,outproc.yaml to support OUTPROC for MT8196. > MediaTek display overlap output processor, namely OVL_OUTPROC > or OUTPROC,handles the post-stage of pixel processing in the > overlapping procedure. >

Re: [PATCH v2 15/59] dyndbg: hoist classmap-filter-by-modname up to ddebug_add_module

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:51, Jim Cromie a écrit : The body of ddebug_attach_module_classes() is dominated by a code-block that finds the contiguous subrange of classmaps matching on modname, and saves it into the ddebug_table's info record. Implement this block in a macro to accommodate different c

Re: [PATCH v2 20/59] dyndbg: check DYNDBG_CLASSMAP_DEFINE args at compile-time

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:51, Jim Cromie a écrit : Add __DYNDBG_CLASSMAP_CHECK to implement these arg-checks at compile: 0 <= _base < 63 class_names is not empty class_names[0] is a string (class_names.length + _base) < 63 These compile-time checks will prevent severa

[PATCH 1/2] rust: helpers: Add bindings/wrappers for dma_resv

2025-03-24 Thread Daniel Almeida
From: Asahi Lina This is just for basic usage in the DRM shmem abstractions for implied locking, not intended as a full DMA Reservation abstraction yet. Signed-off-by: Asahi Lina --- rust/bindings/bindings_helper.h | 4 +++- rust/helpers/dma-resv.c | 13 + rust/helpers/hel

Re: [PATCH v2 22/59] dyndbg-API: promote DYNAMIC_DEBUG_CLASSMAP_PARAM to API

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : move the DYNAMIC_DEBUG_CLASSMAP_PARAM macro from test-dynamic-debug.c into the header, and refine it, by distinguishing the 2 use cases: 1.DYNAMIC_DEBUG_CLASSMAP_PARAM_REF for DRM, to pass in extern __drm_debug by name. dyndbg keeps bits i

Re: [PATCH v3 00/16] Introduce and use generic parity16/32/64 helper

2025-03-24 Thread Yury Norov
On Sun, Mar 23, 2025 at 03:40:20PM -0700, H. Peter Anvin wrote: > On March 23, 2025 8:16:24 AM PDT, Kuan-Wei Chiu wrote: > >On Thu, Mar 13, 2025 at 03:41:49PM +0800, Kuan-Wei Chiu wrote: > >> On Thu, Mar 13, 2025 at 12:29:13AM +0800, Kuan-Wei Chiu wrote: > >> > On Wed, Mar 12, 2025 at 11:51:12AM -

Re: [PATCH 1/2] drm/sched: add drm_sched_prealloc_dependency_slots v2

2025-03-24 Thread Christian König
Am 21.03.25 um 19:05 schrieb Philipp Stanner: > On Fri, 2025-03-21 at 16:58 +0100, Christian König wrote: >> Sometimes drivers need to be able to submit multiple jobs which >> depend on >> each other to different schedulers at the same time, but using >> drm_sched_job_add_dependency() can't fail an

Re: [PATCH v20 01/10] drm/gem: Change locked/unlocked postfix of drm_gem_v/unmap() function names

2025-03-24 Thread Christian König
Am 22.03.25 um 22:25 schrieb Dmitry Osipenko: > Make drm/gem API function names consistent by having locked function > use the _locked postfix in the name, while the unlocked variants don't > use the _unlocked postfix. Rename drm_gem_v/unmap() function names to > make them consistent with the rest

Re: [PATCH 1/2] drm/sched: add drm_sched_prealloc_dependency_slots v2

2025-03-24 Thread Christian König
Am 24.03.25 um 09:35 schrieb Tvrtko Ursulin: > > On 21/03/2025 15:58, Christian König wrote: >> Sometimes drivers need to be able to submit multiple jobs which depend on >> each other to different schedulers at the same time, but using >> drm_sched_job_add_dependency() can't fail any more after the

[PATCH v4 00/15] CCS static load balance

2025-03-24 Thread Andi Shyti
Hi, Back in v3, this patch series was turned down due to community policies regarding i915 GEM development. Since then, I have received several requests from userspace developers, which I initially declined in order to respect those policies. However, with the latest request from UMD users, I dec

[git pull] drm fixes for 6.14-rc8/final

2025-03-24 Thread Dave Airlie
Hi Linus, It appears that the fd.o infrastructure is back enough to facilitate sending this week's fixes, hopefully you can grab it without issue. Just the usual spread of a bunch for amdgpu, and small changes to others. Regards, Dave. drm-fixes-2025-03-21: drm fixes for 6.14-rc8 scheduler: - f

Re: [PATCH RFC v3 6/7] gpu: nova-core: add basic timer device

2025-03-24 Thread Daniel Brooks
"Alexandre Courbot" writes: > Hi Boqun, > > On Fri Mar 21, 2025 at 3:17 AM JST, Boqun Feng wrote: >> Also an Instant type has been proposed and reviewed for a while: >> >> >> https://lore.kernel.org/rust-for-linux/20250220070611.214262-5-fujita.tomon...@gmail.com/ >> >> we should use that t

Re: [PATCH v7 2/5] bits: introduce fixed-type BIT_U*()

2025-03-24 Thread Andy Shevchenko
On Sat, Mar 22, 2025 at 06:23:13PM +0900, Vincent Mailhol via B4 Relay wrote: > From: Lucas De Marchi > > Implement fixed-type BIT_U*() to help drivers add stricter checks, > like it was done for GENMASK_U*(). ... > +/* > + * Fixed-type variants of BIT(), with additional checks like GENMASK_TYP

Re: [PATCH v2 59/59] drm: RFC - make drm_dyndbg_user.o for drm-*_helpers, drivers

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : Add new drm_dyndbg_user.c with a single call to DYNDBG_CLASSMAP_USE(drm_debug_classes). This creates a _class_user record (and a linkage dependency). I agree, this could be a very nice thing to automagically have the _USE call included. But if th

Re: [PATCH v2 52/59] drm-dyndbg: add DRM_CLASSMAP_USE to vkms driver

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:52, Jim Cromie a écrit : The vkms driver has a number of DRM_UT_* debugs, make them controllable when CONFIG_DRM_USE_DYNAMIC_DEBUG=y by telling dyndbg that the module uses them. Signed-off-by: Jim Cromie Reviewed-by: Louis Chauvet --- drivers/gpu/drm/vkms/vkms_drv.c

Re: [PATCH v2 11/59] dyndbg: macrofy a 2-index for-loop pattern

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:51, Jim Cromie a écrit : dynamic-debug has several __sections, each with , num_, and it iterates over these with a 2-index for-loop. These loops are fiddly with the 2 names. We have only 2 such loops now, but are getting more soon; lets embed/abstract the fiddlyness in the

Re: [PATCH v2 13/59] dyndbg: add 2 new _DPRINTK_FLAGS_: INCL_LOOKUP, PREFIX_CACHED

2025-03-24 Thread Louis Chauvet
Le 20/03/2025 à 19:51, Jim Cromie a écrit : Add _INCL_LOOKUP condition to separate +mfsl flags from +t, allowing (after refactoring) to avoid a needless call-return. Add a PREFIX_CACHED bit to remember that a pr-debug callsite is: - enabled, with +p - wants a dynamic-prefix, with _INCL_LOOKU

RE: [PATCH v10 5/5] drm/xe/xe_vm: Implement xe_vm_get_property_ioctl

2025-03-24 Thread Cavitt, Jonathan
-Original Message- From: Jadav, Raag Sent: Friday, March 21, 2025 4:37 PM To: Cavitt, Jonathan Cc: intel...@lists.freedesktop.org; Gupta, saurabhg ; Zuo, Alex ; joonas.lahti...@linux.intel.com; Brost, Matthew ; Zhang, Jianxun ; Lin, Shuicheng ; dri-devel@lists.freedesktop.org; Wajdec

  1   2   >