Re: [PATCH drm-misc-next] drm/test: drm_exec: fix memory leak on object prepare

2023-08-10 Thread Christian König
Am 10.08.23 um 00:50 schrieb Danilo Krummrich: drm_exec_prepare_obj() and drm_exec_prepare_array() both reserve dma-fence slots and hence a dma_resv_list without ever freeing it. Make sure to call drm_gem_private_object_fini() for each GEM object passed to drm_exec_prepare_obj()/drm_exec_prepare

Re: [PATCH -next] drm/ttm: Remove two unused function declarations

2023-08-10 Thread Christian König
Am 09.08.23 um 15:58 schrieb Yue Haibing: Commit cd3a8a596214 ("drm/ttm: remove ttm_bo_(un)lock_delayed_workqueue") removed the implementations but not the declarations. Signed-off-by: Yue Haibing Reviewed and pushed to drm-misc-next. Thanks, Christian. --- include/drm/ttm/ttm_bo.h | 2 -

Re: [RFC v6 0/3] Introduce KUnit tests for TTM subsystem

2023-08-10 Thread Christian König
Am 08.08.23 um 11:51 schrieb Karolina Stolarek: This series introduces KUnit[1] tests for TTM (Translation Table Manager) subsystem, a memory manager used by graphics drivers to create and manage memory buffers across different memory domains, such as system memory or VRAM. Unit tests implemente

Re: [PATCH v2 01/11] PCI/VGA: Use unsigned type for the io_state variable

2023-08-10 Thread Ilpo Järvinen
On Wed, 9 Aug 2023, Sui Jingfeng wrote: > From: Sui Jingfeng > > The io_state variable in the vga_arb_write() function is declared with > unsigned int type, while the vga_str_to_iostate() function takes 'int *' > type. To keep them consistent, this patch replaceis the third argument of > vga_str

Re: [PATCH v2 02/11] PCI: Add the pci_get_class_masked() helper

2023-08-10 Thread Ilpo Järvinen
On Wed, 9 Aug 2023, Sui Jingfeng wrote: > From: Sui Jingfeng > > Because there is no good way to get the mask member used to searching for > devices that conform to a specific PCI class code, an application needs to > process all PCI display devices can achieve its goal as follows: This is mixi

Re: [PATCH v2 04/11] PCI/VGA: Drop the inline in the vga_update_device_decodes() function.

2023-08-10 Thread Ilpo Järvinen
On Wed, 9 Aug 2023, Sui Jingfeng wrote: > From: Sui Jingfeng > > The vga_update_device_decodes() function is not performance-critical. > So drop the inline. This patch also makes the parameter consistent with > the argument, using the 'unsigned int' type instead of the 'signed' type > to store t

Re: [PATCH v2 10/11] PCI/VGA: Tidy up the code and comment format

2023-08-10 Thread Ilpo Järvinen
On Wed, 9 Aug 2023, Sui Jingfeng wrote: > From: Sui Jingfeng > > This patch replaces the leading space with a tab and removes the double > blank line and fix various typos, no functional change. > > Reviewed-by: Andi Shyti > Signed-off-by: Sui Jingfeng > --- > drivers/pci/vgaarb.c | 90 +++

Re: [PATCH v2 06/11] PCI/VGA: Fix two typos in the comments of pci_notify()

2023-08-10 Thread Ilpo Järvinen
On Wed, 9 Aug 2023, Sui Jingfeng wrote: > From: Sui Jingfeng > > 1) s/intereted/interested > 2) s/hotplugable/hot-pluggable > > While at it, convert the comments to the conventional multi-line style, > and rewrap to fill 78 columns. > > Fixes: deb2d2ecd43d ("PCI/GPU: implement VGA arbitration

Re: [PATCH v2] dma-contiguous: define proper name for global cma region

2023-08-10 Thread Pintu Agarwal
Hi, On Thu, 3 Aug 2023 at 23:04, Pintu Agarwal wrote: > > Hi, > > On Wed, 2 Aug 2023 at 15:17, Christoph Hellwig wrote: > > > > On Tue, Aug 01, 2023 at 10:39:04PM -0700, John Stultz wrote: > > > So, forgive me, I've not had a chance to look into this, but my > > > recollection was "reserved" is

Re: [PATCH v2 05/11] PCI/VGA: Move the new_state assignment out of the loop

2023-08-10 Thread Ilpo Järvinen
On Wed, 9 Aug 2023, Sui Jingfeng wrote: > From: Sui Jingfeng > > In the vga_arbiter_notify_clients() function, the value of the 'new_state' > variable will be 'false' on systems that have more than one VGA device. > The value will be 'true' if there is only one VGA device or no VGA device > at a

Re: [PATCH v2 07/11] PCI/VGA: vga_client_register() return -ENODEV on failure, not -1

2023-08-10 Thread Ilpo Järvinen
On Wed, 9 Aug 2023, Sui Jingfeng wrote: > From: Sui Jingfeng > Changelog body is missing. > Fixes: 934f992c763a ("drm/i915: Recognise non-VGA display devices") > Signed-off-by: Sui Jingfeng > --- > drivers/pci/vgaarb.c | 15 ++- > 1 file changed, 6 insertions(+), 9 deletions(-) >

Re: [PATCH v2 08/11] PCI/VGA: Fix a typo to the comment of vga_default

2023-08-10 Thread Ilpo Järvinen
On Wed, 9 Aug 2023, Sui Jingfeng wrote: > From: Sui Jingfeng > Please add changelog text. > Fixes: deb2d2ecd43d ("PCI/GPU: implement VGA arbitration on Linux") > Signed-off-by: Sui Jingfeng > --- > drivers/pci/vgaarb.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a

Re: [PATCH v5 1/1] drm/doc: Document DRM device reset expectations

2023-08-10 Thread Michel Dänzer
On 8/9/23 21:15, Marek Olšák wrote: > On Wed, Aug 9, 2023 at 3:35 AM Michel Dänzer > wrote: >> On 8/8/23 19:03, Marek Olšák wrote: >>> It's the same situation as SIGSEGV. A process can catch the signal, >>> but if it doesn't, it gets killed. GL and Vulkan APIs give you a way >>> to catch the GPU

[PATCH V8 0/9] Enable Wifi RFI interference mitigation feature support

2023-08-10 Thread Evan Quan
Due to electrical and mechanical constraints in certain platform designs there may be likely interference of relatively high-powered harmonics of the (G-)DDR memory clocks with local radio module frequency bands used by Wifi 6/6e/7. To mitigate possible RFI interference producers can advertise the

[PATCH V8 1/9] drivers core: Add support for Wifi band RF mitigations

2023-08-10 Thread Evan Quan
Due to electrical and mechanical constraints in certain platform designs there may be likely interference of relatively high-powered harmonics of the (G-)DDR memory clocks with local radio module frequency bands used by Wifi 6/6e/7. To mitigate this, AMD has introduced a mechanism that devices can

[PATCH V8 2/9] drivers core: add ACPI based WBRF mechanism introduced by AMD

2023-08-10 Thread Evan Quan
AMD has introduced an ACPI based mechanism to support WBRF for some platforms with AMD dGPU + WLAN. This needs support from BIOS equipped with necessary AML implementations and dGPU firmwares. For those systems without the ACPI mechanism and developing solutions, user can use/fall-back the generic

[PATCH V8 3/9] cfg80211: expose nl80211_chan_width_to_mhz for wide sharing

2023-08-10 Thread Evan Quan
The newly added WBRF feature needs this interface for channel width calculation. Signed-off-by: Evan Quan --- include/net/cfg80211.h | 8 net/wireless/chan.c| 3 ++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h index

[PATCH V8 4/9] wifi: mac80211: Add support for WBRF features

2023-08-10 Thread Evan Quan
To support the WBRF mechanism, Wifi adapters utilized in the system must register the frequencies in use(or unregister those frequencies no longer used) via the dedicated calls. So that, other drivers responding to the frequencies can take proper actions to mitigate possible interference. Co-devel

[PATCH V8 5/9] drm/amd/pm: update driver_if and ppsmc headers for coming wbrf feature

2023-08-10 Thread Evan Quan
Add those data structures to support Wifi RFI mitigation feature. Signed-off-by: Evan Quan Reviewed-by: Mario Limonciello --- .../pm/swsmu/inc/pmfw_if/smu13_driver_if_v13_0_0.h | 14 +- .../pm/swsmu/inc/pmfw_if/smu13_driver_if_v13_0_7.h | 14 +- .../amd/pm/swsmu/inc/pmfw

[PATCH V8 6/9] drm/amd/pm: setup the framework to support Wifi RFI mitigation feature

2023-08-10 Thread Evan Quan
With WBRF feature supported, as a driver responding to the frequencies, amdgpu driver is able to do shadow pstate switching to mitigate possible interference(between its (G-)DDR memory clocks and local radio module frequency bands used by Wifi 6/6e/7). Signed-off-by: Evan Quan Reviewed-by: Mario

[PATCH V8 7/9] drm/amd/pm: add flood detection for wbrf events

2023-08-10 Thread Evan Quan
To protect PMFW from being overloaded. Signed-off-by: Evan Quan Reviewed-by: Mario Limonciello --- drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c | 31 +++ drivers/gpu/drm/amd/pm/swsmu/inc/amdgpu_smu.h | 7 + 2 files changed, 32 insertions(+), 6 deletions(-) diff --git a/dr

[PATCH V8 8/9] drm/amd/pm: enable Wifi RFI mitigation feature support for SMU13.0.0

2023-08-10 Thread Evan Quan
Fulfill the SMU13.0.0 support for Wifi RFI mitigation feature. Signed-off-by: Evan Quan Reviewed-by: Mario Limonciello --- drivers/gpu/drm/amd/pm/swsmu/inc/amdgpu_smu.h | 3 + drivers/gpu/drm/amd/pm/swsmu/inc/smu_types.h | 3 +- drivers/gpu/drm/amd/pm/swsmu/inc/smu_v13_0.h | 3 + .../gpu/d

[PATCH V8 9/9] drm/amd/pm: enable Wifi RFI mitigation feature support for SMU13.0.7

2023-08-10 Thread Evan Quan
Fulfill the SMU13.0.7 support for Wifi RFI mitigation feature. Signed-off-by: Evan Quan Reviewed-by: Mario Limonciello --- .../drm/amd/pm/swsmu/smu13/smu_v13_0_7_ppt.c | 59 +++ 1 file changed, 59 insertions(+) diff --git a/drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_7_ppt.c

Re: [PATCH 1/1] drm/fourcc: Add documentation about software color conversion.

2023-08-10 Thread Maxime Ripard
Hi On Mon, Aug 07, 2023 at 03:45:15PM +0200, Jocelyn Falempe wrote: > After discussions on IRC, the consensus is that the DRM drivers should > not do software color conversion, and only advertise the supported formats. > Update the doc accordingly so that the rule and exceptions are clear for > ev

[PATCH] accel/ivpu: Document DRM_IVPU_PARAM_CAPABILITIES

2023-08-10 Thread Stanislaw Gruszka
Add comments regarding new DRM_IVPU_PARAM_CAPABILITIES param. Signed-off-by: Stanislaw Gruszka --- include/uapi/drm/ivpu_accel.h | 19 +-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/include/uapi/drm/ivpu_accel.h b/include/uapi/drm/ivpu_accel.h index a58a14c9f2

Re: [PATCH] video/hdmi: convert *_infoframe_init() functions to void

2023-08-10 Thread Maxime Ripard
Hi, On Tue, Aug 08, 2023 at 11:02:45AM -0700, Nikita Zhandarovich wrote: > Four hdmi_*_infoframe_init() functions that initialize different > types of hdmi infoframes only return the default 0 value, contrary to > their descriptions. Yet these functions are still unnecessarily checked > against po

Re: [RFC PATCH 00/10] drm/panel: Remove most store/double-check of prepared/enabled state

2023-08-10 Thread Linus Walleij
On Fri, Aug 4, 2023 at 11:07 PM Douglas Anderson wrote: > As talked about in commit d2aacaf07395 ("drm/panel: Check for already > prepared/enabled in drm_panel"), we want to remove needless code from > panel drivers that was storing and double-checking the > prepared/enabled state. Even if someon

Re: [PATCH 1/2] drm/exec: use unique instead of local label

2023-08-10 Thread Rasmus Villemoes
On 01/08/2023 22.35, Nick Desaulniers wrote: > I suspect it's possible to change the indirect goto into a direct goto > with some further refactoring (macros can take block statements; Well, with some somewhat subtle restrictions. C99, 6.10.3.11. "The sequence of preprocessing tokens bounded by

[PULL] drm-misc-next

2023-08-10 Thread Thomas Zimmermann
Hi Dave and Daniel, this is the PR for drm-misc-next; presumably the final one before -rc6. Half of the patches update fbdev drivers to make them use the provided helpers and macros. The big feature is nouveau's support for tracking virtual memory on the GPU, which enables Vulkan sparse binding an

Re: [PATCH 1/1] drm/fourcc: Add documentation about software color conversion.

2023-08-10 Thread Jocelyn Falempe
On 09/08/2023 18:29, Simon Ser wrote: Looks good to me. Thanks for reviewing it. Maybe the IN_FORMATS prop docs is a better place for this? you mean to move it here ?: https://elixir.bootlin.com/linux/latest/source/drivers/gpu/drm/drm_plane.c#L132 I don't have a preference since it's my f

next-20230726 and later - crash in radeon module during init

2023-08-10 Thread Valdis Klētnieks
I am seeing the following consistent crash at boot: [ 61.211213][ T819] [drm] radeon kernel modesetting enabled. [ 61.584870][ T819] vga_switcheroo: detected switching method \_SB_.PCI0.GFX0.ATPX handle [ 61.667507][ T819] ATPX version 1, functions 0x0033 [ 61.748228][ T819] gener

Re: next-20230726 and later - crash in radeon module during init

2023-08-10 Thread Valdis Klētnieks
On Thu, 10 Aug 2023 05:35:02 -0400, "Valdis Klētnieks" said: > I am seeing the following consistent crash at boot: > Some quick digging indicates the most likely culprit is: > > commit cbd0606e6a776bf2ba10d4a6957bb7628c0da947 > Author: Srinivasan Shanmugam > Date: Thu Jul 20 15:39:24 2023 +05

Re: [Intel-gfx] [PATCH] drm/i915/guc: Fix potential null pointer deref in GuC 'steal id' test

2023-08-10 Thread Andi Shyti
On Mon, Aug 07, 2023 at 12:46:46PM -0700, John Harrison wrote: > On 8/3/2023 06:28, Andi Shyti wrote: > > Hi John, > > > > On Wed, Aug 02, 2023 at 11:49:40AM -0700, john.c.harri...@intel.com wrote: > > > From: John Harrison > > > > > > It was noticed that if the very first 'stealing' request fai

Re: [RFC v6 0/3] Introduce KUnit tests for TTM subsystem

2023-08-10 Thread Karolina Stolarek
On 10.08.2023 09:19, Christian König wrote: Am 08.08.23 um 11:51 schrieb Karolina Stolarek: This series introduces KUnit[1] tests for TTM (Translation Table Manager) subsystem, a memory manager used by graphics drivers to create and manage memory buffers across different memory domains, such as

[PATCH 2/2] drm/lima: fix Wvoid-pointer-to-enum-cast warning

2023-08-10 Thread Krzysztof Kozlowski
'id' is an enum, thus cast of pointer on 64-bit compile test with W=1 causes: lima_drv.c:387:13: error: cast to smaller integer type 'enum lima_gpu_id' from 'const void *' [-Werror,-Wvoid-pointer-to-enum-cast] Signed-off-by: Krzysztof Kozlowski --- drivers/gpu/drm/lima/lima_drv.c | 2 +- 1 f

[PATCH 1/2] drm/bridge: adv7511: fix Wvoid-pointer-to-enum-cast warning

2023-08-10 Thread Krzysztof Kozlowski
'type' is an enum, thus cast of pointer on 64-bit compile test with W=1 causes: adv7511_drv.c:1214:19: error: cast to smaller integer type 'enum adv7511_type' from 'const void *' [-Werror,-Wvoid-pointer-to-enum-cast] Signed-off-by: Krzysztof Kozlowski --- drivers/gpu/drm/bridge/adv7511/adv75

Re: [PATCH 1/2] drm/bridge: adv7511: fix Wvoid-pointer-to-enum-cast warning

2023-08-10 Thread Laurent Pinchart
Hi Krzysztof, Thank you for the patch. On Thu, Aug 10, 2023 at 11:59:22AM +0200, Krzysztof Kozlowski wrote: > 'type' is an enum, thus cast of pointer on 64-bit compile test with W=1 > causes: > > adv7511_drv.c:1214:19: error: cast to smaller integer type 'enum > adv7511_type' from 'const void

Re: [PATCH 1/1] drm/fourcc: Add documentation about software color conversion.

2023-08-10 Thread Jocelyn Falempe
On 10/08/2023 09:45, Maxime Ripard wrote: Hi On Mon, Aug 07, 2023 at 03:45:15PM +0200, Jocelyn Falempe wrote: After discussions on IRC, the consensus is that the DRM drivers should not do software color conversion, and only advertise the supported formats. Update the doc accordingly so that the

Re: [RFC PATCH v2 00/11] Device Memory TCP

2023-08-10 Thread Christian König
Am 10.08.23 um 03:57 schrieb Mina Almasry: Changes in RFC v2: -- The sticking point in RFC v1[1] was the dma-buf pages approach we used to deliver the device memory to the TCP stack. RFC v2 is a proof-of-concept that attempts to resolve this by implementing scatterlist support in

Re: [PATCH v5 9/9] drm: Introduce documentation for hotspot properties

2023-08-10 Thread Albert Esteve
On Mon, Jul 24, 2023 at 1:04 PM Albert Esteve wrote: > > > On Thu, Jul 20, 2023 at 9:32 PM Simon Ser wrote: > >> On Thursday, July 20th, 2023 at 21:28, Zack Rusin >> wrote: >> >> > On Thu, 2023-07-20 at 09:07 +, Simon Ser wrote: >> > >> > > !! External Email >> > > >> > > On Thursday, July

Re: [PATCH] video/hdmi: convert *_infoframe_init() functions to void

2023-08-10 Thread Nikita Zhandarovich
Hello, On 8/10/23 01:13, Maxime Ripard wrote: > Hi, > > On Tue, Aug 08, 2023 at 11:02:45AM -0700, Nikita Zhandarovich wrote: >> Four hdmi_*_infoframe_init() functions that initialize different >> types of hdmi infoframes only return the default 0 value, contrary to >> their descriptions. Yet thes

Re: [PATCH v2 07/11] PCI/VGA: vga_client_register() return -ENODEV on failure, not -1

2023-08-10 Thread suijingfeng
Hi, On 2023/8/9 21:52, Ilpo Järvinen wrote: On Wed, 9 Aug 2023, Sui Jingfeng wrote: From: Sui Jingfeng Changelog body is missing. I thought that probably the Fixes tag could be taken as the body of this commit, since there are no warnings when I check the whole series with checkpatch.pl

Re: [PATCH 2/2] drm/lima: fix Wvoid-pointer-to-enum-cast warning

2023-08-10 Thread Qiang Yu
Reviewed-by: Qiang Yu On Thu, Aug 10, 2023 at 5:59 PM Krzysztof Kozlowski wrote: > > 'id' is an enum, thus cast of pointer on 64-bit compile test with W=1 > causes: > > lima_drv.c:387:13: error: cast to smaller integer type 'enum lima_gpu_id' > from 'const void *' [-Werror,-Wvoid-pointer-to-e

Re: [PATCH v2 06/11] PCI/VGA: Fix two typos in the comments of pci_notify()

2023-08-10 Thread suijingfeng
Hi, On 2023/8/9 22:12, Ilpo Järvinen wrote: On Wed, 9 Aug 2023, Sui Jingfeng wrote: From: Sui Jingfeng 1) s/intereted/interested 2) s/hotplugable/hot-pluggable While at it, convert the comments to the conventional multi-line style, and rewrap to fill 78 columns. Fixes: deb2d2ecd43d ("PCI/

[PATCH -next] drm/msm/adreno: adreno_gpu: Switch to memdup_user_nul() helper

2023-08-10 Thread Ruan Jinjie
Use memdup_user_nul() helper instead of open-coding to simplify the code. Signed-off-by: Ruan Jinjie --- drivers/gpu/drm/msm/adreno/adreno_gpu.c | 14 +++--- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/drivers/gpu/drm/msm/adreno/adreno_gpu.c b/drivers/gpu/drm/msm/adre

Re: [PATCH v2 07/11] PCI/VGA: vga_client_register() return -ENODEV on failure, not -1

2023-08-10 Thread Sui Jingfeng
Hi, On 2023/8/10 20:13, Ilpo Järvinen wrote: On Thu, 10 Aug 2023, suijingfeng wrote: On 2023/8/9 21:52, Ilpo Järvinen wrote: On Wed, 9 Aug 2023, Sui Jingfeng wrote: From: Sui Jingfeng Changelog body is missing. I thought that probably the Fixes tag could be taken as the body of this co

[PATCH] accel/qaic: Clean up integer overflow checking in map_user_pages()

2023-08-10 Thread Dan Carpenter
The encode_dma() function has some validation on in_trans->size but it would be more clear to move those checks to find_and_map_user_pages(). The encode_dma() had two checks: if (in_trans->addr + in_trans->size < in_trans->addr || !in_trans->size) return -EINVAL; The in_t

[PATCH 2/2] drm/i915: Handle legacy cursor update as normal update

2023-08-10 Thread Maarten Lankhorst
Abuse the vblank worker to make the changes as small as possible. We need a way to sync flip_done, but if we wait on flip_done, all async tests start failing. Signed-off-by: Maarten Lankhorst --- drivers/gpu/drm/i915/display/intel_crtc.c| 21 ++-- drivers/gpu/drm/i915/display

[PATCH 1/2] drm/i915: Swap ggtt_vma during legacy cursor update

2023-08-10 Thread Maarten Lankhorst
Signed-off-by: Maarten Lankhorst --- drivers/gpu/drm/i915/display/intel_cursor.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/i915/display/intel_cursor.c b/drivers/gpu/drm/i915/display/intel_cursor.c index b342fad180ca..ab25f019eda1 100644 --- a/driver

Re: [PATCH v2 02/11] PCI: Add the pci_get_class_masked() helper

2023-08-10 Thread suijingfeng
Hi, On 2023/8/9 22:01, Ilpo Järvinen wrote: On Wed, 9 Aug 2023, Sui Jingfeng wrote: From: Sui Jingfeng Because there is no good way to get the mask member used to searching for devices that conform to a specific PCI class code, an application needs to process all PCI display devices can ach

[PATCH 00/20] DSC misc fixes

2023-08-10 Thread Ankit Nautiyal
This series is an attempt to address multiple issues with DSC, scattered in separate existing series. Patches 1-4 are DSC fixes from series to Handle BPC for HDMI2.1 PCON https://patchwork.freedesktop.org/series/107550/ Patches 5-6 are from series DSC fixes for Bigjoiner: https://patchwork.freede

[PATCH 01/20] drm/i915/dp: Consider output_format while computing dsc bpp

2023-08-10 Thread Ankit Nautiyal
While using DSC the compressed bpp is computed assuming RGB output format. Consider the output_format and compute the compressed bpp during mode valid and compute config steps. For DP-MST we currently use RGB output format only, so continue using RGB while computing compressed bpp for MST case. v

[PATCH 02/20] drm/i915/dp: Move compressed bpp check with 420 format inside the helper

2023-08-10 Thread Ankit Nautiyal
Move the check for limiting compressed bite_per_pixel for 420,422 formats in the helper to compute bits_per_pixel. Signed-off-by: Ankit Nautiyal Reviewed-by: Arun R Murthy --- drivers/gpu/drm/i915/display/intel_dp.c | 18 +- 1 file changed, 9 insertions(+), 9 deletions(-) diff

[PATCH 07/20] drm/i915/dp: Remove extra logs for printing DSC info

2023-08-10 Thread Ankit Nautiyal
DSC compressed bpp and slice counts are already getting printed at the end of dsc compute config. Remove extra logs. Signed-off-by: Ankit Nautiyal Reviewed-by: Arun R Murthy --- drivers/gpu/drm/i915/display/intel_dp.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/gpu/drm/i915/di

[PATCH 10/20] drm/i915/dp: Add functions to get min/max src input bpc with DSC

2023-08-10 Thread Ankit Nautiyal
Separate out functions for getting maximum and minimum input BPC based on platforms, when DSC is used. v2: Use HAS_DSC macro instead of platform check while getting min input bpc. (Stan) Signed-off-by: Ankit Nautiyal --- drivers/gpu/drm/i915/display/intel_dp.c | 35 +++-- 1

[PATCH 11/20] drm/i915/dp: Check min bpc DSC limits for dsc_force_bpc also

2023-08-10 Thread Ankit Nautiyal
For DSC the min BPC is 8 for ICL+ and so the min pipe_bpp is 24. Check this condition for cases where bpc is forced by debugfs flag dsc_force_bpc. If the check fails, then WARN and ignore the debugfs flag. For MST case the pipe_bpp is already computed (hardcoded to be 24), and this check is not re

[PATCH 05/20] drm/i915/dp: Update Bigjoiner interface bits for computing compressed bpp

2023-08-10 Thread Ankit Nautiyal
In Bigjoiner check for DSC, bigjoiner interface bits for DP for DISPLAY > 13 is 36 (Bspec: 49259). v2: Corrected Display ver to 13. v3: Follow convention for conditional statement. (Ville) v4: Fix check for display ver. (Ville) v5: Added note for 2 PPC. (Stan) Signed-off-by: Ankit Nautiyal Re

[PATCH 17/20] drm/i915/dp: Get optimal link config to have best compressed bpp

2023-08-10 Thread Ankit Nautiyal
Currently, we take the max lane, rate and pipe bpp, to get the maximum compressed bpp possible. We then set the output bpp to this value. This patch provides support to have max bpp, min rate and min lanes, that can support the min compressed bpp. v2: -Avoid ending up with compressed bpp, same as

[PATCH 06/20] drm/i915/intel_cdclk: Add vdsc with bigjoiner constraints on min_cdlck

2023-08-10 Thread Ankit Nautiyal
As per Bsepc:49259, Bigjoiner BW check puts restriction on the compressed bpp for a given CDCLK, pixelclock in cases where Bigjoiner + DSC are used. Currently compressed bpp is computed first, and it is ensured that the bpp will work at least with the max CDCLK freq. Since the CDCLK is computed l

[PATCH 04/20] drm/i915/dp: Use consistent name for link bpp and compressed bpp

2023-08-10 Thread Ankit Nautiyal
Currently there are many places where we use output_bpp for link bpp and compressed bpp. Lets use consistent naming: output_bpp : The intermediate value taking into account the output_format chroma subsampling. compressed_bpp : target bpp for the DSC encoder. link_bpp : final bpp used in the link.

[PATCH 13/20] drm/i915/dp: Rename helper to get DSC max pipe_bpp

2023-08-10 Thread Ankit Nautiyal
The helper intel_dp_dsc_compute_bpp gives the maximum pipe bpp that is allowed with DSC. Rename the this to reflect that it returns max pipe bpp supported with DSC. Signed-off-by: Ankit Nautiyal Reviewed-by: Stanislav Lisovskiy --- drivers/gpu/drm/i915/display/intel_dp.c | 8 driv

[PATCH 08/20] drm/display/dp: Fix the DP DSC Receiver cap size

2023-08-10 Thread Ankit Nautiyal
DP DSC Receiver Capabilities are exposed via DPCD 60h-6Fh. Fix the DSC RECEIVER CAP SIZE accordingly. Fixes: ffddc4363c28 ("drm/dp: Add DP DSC DPCD receiver capability size define and missing SHIFT") Cc: Anusha Srivatsa Cc: Manasi Navare Cc: # v5.0+ Signed-off-by: Ankit Nautiyal Reviewed-by:

[PATCH 09/20] drm/i915/dp: Avoid forcing DSC BPC for MST case

2023-08-10 Thread Ankit Nautiyal
For MST the bpc is hardcoded to 8, and pipe bpp to 24. So avoid forcing DSC bpc for MST case. v2: Warn and ignore the debug flag than to bail out. (Jani) v3: Fix dbg message to mention forced bpc instead of bpp. v4: Fix checkpatch longline warning. Signed-off-by: Ankit Nautiyal Reviewed-by: St

[PATCH 03/20] drm/i915/dp_mst: Use output_format to get the final link bpp

2023-08-10 Thread Ankit Nautiyal
The final link bpp used to calculate the m_n values depend on the output_format. Though the output_format is set to RGB for MST case and the link bpp will be same as the pipe bpp, for the sake of semantics, lets calculate the m_n values with the link bpp, instead of pipe_bpp. Signed-off-by: Ankit

[PATCH 18/20] drm/i915/dp: Check src/sink compressed bpp limit for edp

2023-08-10 Thread Ankit Nautiyal
Use checks for src and sink limits before computing compressed bpp for eDP. Signed-off-by: Ankit Nautiyal Reviewed-by: Stanislav Lisovskiy --- drivers/gpu/drm/i915/display/intel_dp.c | 18 +++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/i915/dis

[PATCH 12/20] drm/i915/dp: Avoid left shift of DSC output bpp by 4

2023-08-10 Thread Ankit Nautiyal
To make way for fractional bpp support, avoid left shifting the output_bpp by 4 in helper intel_dp_dsc_get_output_bpp. Signed-off-by: Ankit Nautiyal Reviewed-by: Stanislav Lisovskiy --- drivers/gpu/drm/i915/display/intel_dp.c | 10 +++--- drivers/gpu/drm/i915/display/intel_dp_mst.c | 2

[PATCH 20/20] drm/i915: Query compressed bpp properly using correct DPCD and DP Spec info

2023-08-10 Thread Ankit Nautiyal
From: Stanislav Lisovskiy Currently we seem to be using wrong DPCD register for reading compressed bpps, reading min/max input bpc instead of compressed bpp. Fix that, so that we now apply min/max compressed bpp limitations we get from DP Spec Table 2-157 DP v2.0 and/or correspondent DPCD registe

[PATCH 19/20] drm/i915/dp: Check if force_dsc_output_format is possible

2023-08-10 Thread Ankit Nautiyal
Currently for testing an output format with DSC, we just force the output format, without checking if it can be supported. This also creates an issue where there is a PCON which might need to convert from forced output format to the format to sink format. Signed-off-by: Ankit Nautiyal Reviewed-by

[PATCH 16/20] drm/i915/dp: Separate out function to get compressed bpp with joiner

2023-08-10 Thread Ankit Nautiyal
Pull the code to get joiner constraints on maximum compressed bpp into separate function. Signed-off-by: Ankit Nautiyal Reviewed-by: Stanislav Lisovskiy --- drivers/gpu/drm/i915/display/intel_dp.c | 54 ++--- 1 file changed, 30 insertions(+), 24 deletions(-) diff --git a/dr

[PATCH 15/20] drm/i915/dp: Add DSC BPC/BPP constraints while selecting pipe bpp with DSC

2023-08-10 Thread Ankit Nautiyal
Currently we check if the pipe_bpp selected is >= the min DSC bpc/bpp requirement. We do not check if it is <= the max DSC bpc/bpp requirement. Add checks for max DSC BPC/BPP constraints while computing the pipe_bpp when DSC is in use. v2: Fix the commit message. Signed-off-by: Ankit Nautiyal R

[PATCH 14/20] drm/i915/dp: Separate out functions for edp/DP for computing DSC bpp

2023-08-10 Thread Ankit Nautiyal
Refactor code to separate functions for eDP and DP for computing pipe_bpp/compressed bpp when DSC is involved. This will help to optimize the link configuration for DP later. v2: Fix checkpatch warning. Signed-off-by: Ankit Nautiyal Reviewed-by: Stanislav Lisovskiy --- drivers/gpu/drm/i915/di

Re: [PATCH 0/3] pll-video0 notifier for v6.5+

2023-08-10 Thread Chen-Yu Tsai
On Mon, Aug 7, 2023 at 5:36 PM Frank Oltmanns wrote: > > Hi Icenowy, > > it is my understanding that you are the original author of the following > patches are in Ondřej's 6.4 branch [1] [2] [3] but not in his 6.5 > branch. I assume it is because of merge conflicts as the part about > setting the

Re: [PATCH next] drm/loongson: Fix error handling in lsdc_pixel_pll_setup()

2023-08-10 Thread suijingfeng
Hi, On 2023/7/20 20:39, Harshit Mogalapalli wrote: There are two problems in lsdc_pixel_pll_setup() 1. If kzalloc() fails then call iounmap() to release the resources. 2. Both kzalloc and ioremap doesnot return error pointers on failure, so using IS_ERR_OR_NULL() checks is a bit confusing a

Re: [PATCH V8 3/9] cfg80211: expose nl80211_chan_width_to_mhz for wide sharing

2023-08-10 Thread Jeff Johnson
On 8/10/2023 12:37 AM, Evan Quan wrote: The newly added WBRF feature needs this interface for channel width calculation. Signed-off-by: Evan Quan --- include/net/cfg80211.h | 8 net/wireless/chan.c| 3 ++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/include/n

Re: [PATCH] drm/i915/gmch: fix build error var set but not used

2023-08-10 Thread Jani Nikula
On Thu, 10 Aug 2023, Wang Jinchao wrote: > When CONFIG_PNP is not defined, i915 will fail to compile with error bellow: > drivers/gpu/drm/i915/soc/intel_gmch.c:43:13: error: variable > ‘mchbar_addr’ set but not used > Fix it by surrounding variable declaration and assignment with ifdef > >

Re: [PATCH] accel/ivpu: Document DRM_IVPU_PARAM_CAPABILITIES

2023-08-10 Thread Jeffrey Hugo
On 8/10/2023 2:07 AM, Stanislaw Gruszka wrote: Add comments regarding new DRM_IVPU_PARAM_CAPABILITIES param. Signed-off-by: Stanislaw Gruszka --- include/uapi/drm/ivpu_accel.h | 19 +-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/include/uapi/drm/ivpu_accel

Re: [PATCH] accel/ivpu: Document DRM_IVPU_PARAM_CAPABILITIES

2023-08-10 Thread Stanislaw Gruszka
On Thu, Aug 10, 2023 at 08:27:08AM -0600, Jeffrey Hugo wrote: > On 8/10/2023 2:07 AM, Stanislaw Gruszka wrote: > > Add comments regarding new DRM_IVPU_PARAM_CAPABILITIES param. > > > > Signed-off-by: Stanislaw Gruszka > > --- > > include/uapi/drm/ivpu_accel.h | 19 +-- > > 1 fi

Re: [PATCH 1/2] drm/exec: use unique instead of local label

2023-08-10 Thread Nathan Chancellor
On Thu, Aug 10, 2023 at 08:48:05AM +0200, Christian König wrote: > Am 10.08.23 um 08:40 schrieb Boris Brezillon: > > On Wed, 9 Aug 2023 08:37:55 -0700 > > Nathan Chancellor wrote: > > > > > Hi Christian, > > > > > > Can this be applied to drm-misc? Other drivers are starting to make use > > > of

[PATCH v2 1/3] dt-bindings: vendor-prefixes: add ShenZhen New Display Co.

2023-08-10 Thread Luca Ceresoli
ShenZhen New Display Co., Limited is the manufacturer of the NDS040480800-V3 LCD panel according the datasheet. Signed-off-by: Luca Ceresoli --- Changes in v2: none --- Documentation/devicetree/bindings/vendor-prefixes.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Documentation/de

[PATCH v2 3/3] DRM: panel: add Ilitek ILI9806E driver

2023-08-10 Thread Luca Ceresoli
Add a driver for the ILITEK ILI9806E 480x864 RGB LCD controller connected over SPI, and implement the ShenZhen New Display Co NDS040480800-V3 480x800 panel. Signed-off-by: Luca Ceresoli --- Changes in v2: - add ILI9806E_P1_DISCTRL1 bit description --- MAINTAINERS

[PATCH v2 2/3] dt-bindings: display: panel: Add panels based on ILITEK ILI9806E

2023-08-10 Thread Luca Ceresoli
Add bindings for LCD panels based on the ILITEK ILI9806E RGB controller connected over SPI and the "ShenZhen New Display Co NDS040480800-V3" 480x800 panel based on it. Signed-off-by: Luca Ceresoli --- Changes in v2: - remove T: line form MAINTAINERS entry - reference spi-peripheral-props.yaml

[PATCH 0/6] imx6q related DT binding fixes

2023-08-10 Thread Alexander Stein
Hi everyone, while working on i.MX6Q based board (arch/arm/boot/dts/nxp/imx/imx6q-mba6a.dts) I noticed several warnings on dtbs_check. The first 5 patches should be pretty much straight forward. I'm not 100% sure on the sixth patch, as it might be affected by incorrect compatible lists. Please ref

[PATCH 2/6] dt-bindings: imx-thermal: Add #thermal-sensor-cells property

2023-08-10 Thread Alexander Stein
This property is defined in thermal-sensor.yaml. Reference this file and constraint '#thermal-sensor-cells' to 0 for imx-thermal. Fixes the warning: arch/arm/boot/dts/nxp/imx/imx6q-mba6a.dtb: tempmon: '#thermal-sensor-cells' does not match any of the regexes: 'pinctrl-[0-9]+' From schema: Documen

[PATCH 1/6] dt-bindings: trivial-devices: Remove national,lm75

2023-08-10 Thread Alexander Stein
Starting with commit 3e37c9d48f7a ("dt-bindings: hwmon: Convert lm75 bindings to yaml") 'national,lm75' has it's own dedicated (YAML) binding. If kept in this file device specific properties as 'vs-supply' are considered excessive. Remove compatible here so it can be checked with more specific bind

[PATCH 3/6] dt-bindings: display: imx: hdmi: Allow 'reg' and 'interrupts'

2023-08-10 Thread Alexander Stein
Although defined in synopsys,dw-hdmi.yaml, they need to explicitly allowed in fsl,imx6-hdmi.yaml. Fixes the warning: arch/arm/boot/dts/nxp/imx/imx6q-mba6a.dtb: hdmi@12: 'interrupts', 'reg' do not match any of the regexes: 'pinctrl-[0-9]+' From schema: Documentation/devicetree/bindings/display

[PATCH 6/6] dt-bindings: timer: fsl, imxgpt: Add optional osc_per clock

2023-08-10 Thread Alexander Stein
Since commit bad3db104f89 ("ARM: imx: source gpt per clk from OSC for system timer") osc_per can be used for clocking the GPT which is not scaled when entering low bus mode. This clock source is available only on i.MX6Q (incl. i.MX6QP) and i.MX6DL. Signed-off-by: Alexander Stein --- Notes: o

[PATCH 5/6] dt-bindings: timer: add imx7d compatible

2023-08-10 Thread Alexander Stein
Currently the dtbs_check for imx6ul generates warnings like this: ['fsl,imx7d-gpt', 'fsl,imx6sx-gpt'] is too long The driver has no special handling for fsl,imx7d-gpt, so fsl,imx6sx-gpt is used. Therefore make imx7d GPT compatible to the imx6sx one to fix the warning. Signed-off-by: Alexander St

[PATCH 4/6] dt-bindings: net: microchip: Allow nvmem-cell usage

2023-08-10 Thread Alexander Stein
MAC address can be provided by a nvmem-cell, thus allow referencing a source for the address. Fixes the warning: arch/arm/boot/dts/nxp/imx/imx6q-mba6a.dtb: ethernet@1: 'nvmem-cell-names', 'nvmem-cells' do not match any of the regexes: 'pinctrl-[0-9]+' From schema: Documentation/devicetree/binding

Re: [PATCH] accel/ivpu: Document DRM_IVPU_PARAM_CAPABILITIES

2023-08-10 Thread Jeffrey Hugo
On 8/10/2023 8:32 AM, Stanislaw Gruszka wrote: On Thu, Aug 10, 2023 at 08:27:08AM -0600, Jeffrey Hugo wrote: On 8/10/2023 2:07 AM, Stanislaw Gruszka wrote: Add comments regarding new DRM_IVPU_PARAM_CAPABILITIES param. Signed-off-by: Stanislaw Gruszka --- include/uapi/drm/ivpu_accel.h | 19

Re: [PATCH drm-misc-next] drm/sched: support multiple rings per gpu_scheduler

2023-08-10 Thread Danilo Krummrich
On 8/10/23 06:31, Matthew Brost wrote: On Thu, Aug 10, 2023 at 12:17:23AM +0200, Danilo Krummrich wrote: With the current mental model every GPU scheduler instance represents a single HW ring, while every entity represents a software queue feeding into one or multiple GPU scheduler instances and

Re: [PATCH -next] drm/msm/adreno: adreno_gpu: Switch to memdup_user_nul() helper

2023-08-10 Thread Bjorn Andersson
On Thu, Aug 10, 2023 at 08:04:24PM +0800, Ruan Jinjie wrote: > Use memdup_user_nul() helper instead of open-coding to simplify the code. > > Signed-off-by: Ruan Jinjie Reviewed-by: Bjorn Andersson Regards, Bjorn

Re: [PATCH drm-misc-next] drm/sched: support multiple rings per gpu_scheduler

2023-08-10 Thread Danilo Krummrich
On 8/10/23 08:34, Christian König wrote: Am 10.08.23 um 00:17 schrieb Danilo Krummrich: With the current mental model every GPU scheduler instance represents a single HW ring, while every entity represents a software queue feeding into one or multiple GPU scheduler instances and hence into one o

Re: [PATCH V8 1/9] drivers core: Add support for Wifi band RF mitigations

2023-08-10 Thread Randy Dunlap
On 8/10/23 00:37, Evan Quan wrote: > diff --git a/Documentation/admin-guide/kernel-parameters.txt > b/Documentation/admin-guide/kernel-parameters.txt > index a1457995fd41..21f73a0bbd0b 100644 > --- a/Documentation/admin-guide/kernel-parameters.txt > +++ b/Documentation/admin-guide/kernel-parame

Re: [PATCH v2 00/15] drm: Add a driver for FW-based Mali GPUs

2023-08-10 Thread Boris Brezillon
Hello Rob, On Wed, 9 Aug 2023 14:22:59 -0600 Rob Herring wrote: > On Wed, Aug 9, 2023 at 10:53 AM Boris Brezillon > wrote: > > > > I tried to Cc anyone that was involved in any development of the code > > I picked from panfrost, so they can acknowledge the GPL2 -> MIT+GPL2 > > change. If I miss

[PATCH v2 01/34] drm/amd/display: fix segment distribution for linear LUTs

2023-08-10 Thread Melissa Wen
From: Harry Wentland The region and segment calculation was incapable of dealing with regions of more than 16 segments. We first fix this. Now that we can support regions up to 256 elements we can define a better segment distribution for near-linear LUTs for our maximum of 256 HW-supported point

[PATCH v2 00/34] drm/amd/display: add AMD driver-specific properties for color mgmt

2023-08-10 Thread Melissa Wen
Hi all, Here is the next version of our work to enable AMD driver-specific color management properties [1][2]. This series is a collection of contributions from Joshua, Harry, and me to enhance the AMD KMS color pipeline for Steam Deck/SteamOS by exposing additional pre-blending and post-blending

[PATCH v2 02/34] drm/drm_mode_object: increase max objects to accommodate new color props

2023-08-10 Thread Melissa Wen
DRM_OBJECT_MAX_PROPERTY limits the number of properties to be attached and we are increasing that value all time we add a new property (generic or driver-specific). In this series, we are adding 13 new KMS driver-specific properties for AMD color manage: - CRTC Gamma enumerated Transfer Function -

[PATCH v2 03/34] drm/drm_property: make replace_property_blob_from_id a DRM helper

2023-08-10 Thread Melissa Wen
Place it in drm_property where drm_property_replace_blob and drm_property_lookup_blob live. Then we can use the DRM helper for driver-specific KMS properties too. Reviewed-by: Harry Wentland Reviewed-by: Liviu Dudau Signed-off-by: Melissa Wen --- drivers/gpu/drm/arm/malidp_crtc.c | 2 +- driv

[PATCH v2 04/34] drm/drm_plane: track color mgmt changes per plane

2023-08-10 Thread Melissa Wen
We will add color mgmt properties to DRM planes in the next patches and we want to track when one of this properties change to define atomic commit behaviors. Using a similar approach from CRTC color props, we set a color_mgmt_changed boolean whenever a plane color prop changes. Reviewed-by: Harry

[PATCH v2 05/34] drm/amd/display: add driver-specific property for plane degamma LUT

2023-08-10 Thread Melissa Wen
Hook up driver-specific atomic operations for managing AMD color properties. Create AMD driver-specific color management properties and attach them according to HW capabilities defined by `struct dc_color_caps`. First add plane degamma LUT properties that means user-blob and its size. We will add

  1   2   >