[PATCH v3 10/10] drm/msm/dsi: use new helpers for DSC setup

2023-03-28 Thread Dmitry Baryshkov
Use new DRM DSC helpers to setup DSI DSC configuration. The initial_scale_value needs to be adjusted according to the standard, but this is a separate change. Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/dsi/dsi_host.c | 61 -- 1 file changed, 8 insertions(

[PATCH v3 05/10] drm/display/dsc: use flat array for rc_parameters lookup

2023-03-28 Thread Dmitry Baryshkov
Next commits are going to add support for additional RC parameter lookup tables. These tables are going to use different bpp/bpc combinations, thus it makes little sense to keep the 2d array for RC parameters. Switch to using the flat array. Reviewed-by: Jani Nikula Signed-off-by: Dmitry Baryshko

[PATCH v3 06/10] drm/display/dsc: split DSC 1.2 and DSC 1.1 (pre-SCR) parameters

2023-03-28 Thread Dmitry Baryshkov
The array of rc_parameters contains a mixture of parameters from DSC 1.1 and DSC 1.2 standards. Split these tow configuration arrays in preparation to adding more configuration data. Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/display/drm_dsc_helper.c | 127 ++ drive

[PATCH v3 09/10] drm/display/dsc: add helper to set semi-const parameters

2023-03-28 Thread Dmitry Baryshkov
Add a helper setting config values which are typically constant across operating modes (table E-4 of the standard) and mux_word_size (which is a const according to 3.5.2). Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/display/drm_dsc_helper.c | 21 + include/drm/display

[PATCH v3 08/10] drm/display/dsc: add YCbCr 4:2:2 and 4:2:0 RC parameters

2023-03-28 Thread Dmitry Baryshkov
Include RC parameters for YCbCr 4:2:2 and 4:2:0 configurations. Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/display/drm_dsc_helper.c | 438 +++ include/drm/display/drm_dsc_helper.h | 2 + 2 files changed, 440 insertions(+) diff --git a/drivers/gpu/drm/display/d

Re: [PATCH 1/1] drm/i915: fix race condition UAF in i915_perf_add_config_ioctl

2023-03-28 Thread Umesh Nerlige Ramappa
On Tue, Mar 28, 2023 at 02:08:47PM +0100, Tvrtko Ursulin wrote: On 28/03/2023 10:36, Min Li wrote: Userspace can guess the id value and try to race oa_config object creation with config remove, resulting in a use-after-free if we dereference the object after unlocking the metrics_lock. For tha

[PATCH v3 0/2] drm/msm: rework msm_parse_deps() and msm_parse_post_deps()

2023-03-28 Thread Dmitry Baryshkov
As discusssed in the the review of [1], rework these two functions to separate single point parser and provide clean error path. Depenencies: [1], [2] [1] https://lore.kernel.org/all/20230215235048.1166484-1-robdcl...@gmail.com [2] https://patchwork.freedesktop.org/patch/524090/?series=114362&rev

[PATCH v3 1/2] drm/msm: drop unused ring variable in msm_ioctl_gem_submit()

2023-03-28 Thread Dmitry Baryshkov
The variable ring is not used by msm_parse_deps() and msm_ioctl_gem_submit() and thus can be dropped. Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/msm_gem_submit.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/msm/msm_gem_submit.c b/drivers/

[PATCH v3 2/2] drm/msm: simplify msm_parse_deps() and msm_parse_post_deps()

2023-03-28 Thread Dmitry Baryshkov
Simplify two functions msm_parse_deps() and msm_parse_post_deps(): extract single item parsing function and clean up error path. Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/msm_gem_submit.c | 186 +++ 1 file changed, 101 insertions(+), 85 deletions(-) diff --

Re: [PATCH v4 00/14] GMU-less A6xx support (A610, A619_holi)

2023-03-28 Thread Konrad Dybcio
On 14.03.2023 16:28, Konrad Dybcio wrote: > v3 -> v4: > - Drop the mistakengly-included and wrong A3xx-A5xx bindings changes > - Improve bindings commit messages to better explain what GMU Wrapper is > - Drop the A680 highest bank bit value adjustment patch > - Sort UBWC config variables in a re

[PATCH v5] drm/sysfs: Link DRM connectors to corresponding Type-C connectors

2023-03-28 Thread Won Chung
Create a symlink pointing to USB Type-C connector for DRM connectors when they are created. The link will be created only if the firmware is able to describe the connection beween the two connectors. Currently, even if a display uses a USB Type-C port, there is no way for the userspace to find whi

[PATCH] drm/sysfs: Expose DRM connector id in each connector sysfs

2023-03-28 Thread Won Chung
Expose DRM connector id in device sysfs so that we can map the connector id to the connector syspath. Currently, even if we can derive the connector id from modeset, we do not have a way to find the corresponding connector's syspath. This is helpful when determining the root connector of MST tree.

Re: [PATCH] drm/mediatek: Add ovl_adaptor get format function

2023-03-28 Thread 林欣螢

[PATCH v2] drm/mediatek: Add ovl_adaptor get format function

2023-03-28 Thread Nancy . Lin
Add ovl_adaptor get_format and get_num_formats component function. The two functions are need for getting the supported format in mtk_plane_init(). Signed-off-by: Nancy.Lin --- drivers/gpu/drm/mediatek/mtk_disp_drv.h | 2 ++ .../gpu/drm/mediatek/mtk_disp_ovl_adaptor.c | 24 +

[PATCH] linux/vt_buffer.h: allow either builtin or modular for macros

2023-03-28 Thread Randy Dunlap
Fix build errors on ARCH=alpha when CONFIG_MDA_CONSOLE=m. This allows the ARCH macros to be the only ones defined. In file included from ../drivers/video/console/mdacon.c:37: ../arch/alpha/include/asm/vga.h:17:40: error: expected identifier or '(' before 'volatile' 17 | static inline void scr_

Re: [PATCH v8 2/2] drm: add kms driver for loongson display controller

2023-03-28 Thread Sui Jingfeng
WARNING on linus/master v6.3-rc4 next-20230328] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in https://git-scm.com/docs/git-format-patch#_base_tree_information] url: https://github.com/int

[PING PATCH] drm/bochs: replace ioremap with devm_ioremap to avoid immo leak

2023-03-28 Thread Gencen Gan
From: Gan Gecen Smatch reports: drivers/gpu/drm/tiny/bochs.c:290 bochs_hw_init() warn: 'bochs->mmio' from ioremap() not released on lines: 246,250,254. In the function bochs_load() that calls bochs_hw_init() only, if bochs_hw_init(dev) returns -ENODEV(-19), it will jumps

RE: [GIT PULL] exynos-drm-next

2023-03-28 Thread 대인기
> -Original Message- > From: Daniel Vetter > Sent: Wednesday, March 29, 2023 2:31 AM > To: Inki Dae > Cc: airl...@linux.ie; dan...@ffwll.ch; dri-devel@lists.freedesktop.org; > linux-samsung-...@vger.kernel.org > Subject: Re: [GIT PULL] exynos-drm-next > > On Tue, Mar 28, 2023 at 01:05

[PATCH] drm/mediatek: dp: change the aux retries times when receiving AUX_DEFER

2023-03-28 Thread xinlei.lee
From: Xinlei Lee DP 1.4a Section 2.8.7.1.5.6.1: A DP Source device shall retry at least seven times upon receiving AUX_DEFER before giving up the AUX transaction. The drm_dp_i2c_do_msg() function in the drm_dp_helper.c file will judge the status of the msg->reply parameter passed to aux_transfer

[PATCH 1/2] drm: buddy_allocator: Fix buddy allocator init on 32-bit systems

2023-03-28 Thread David Gow
The drm buddy allocator tests were broken on 32-bit systems, as rounddown_pow_of_two() takes a long, and the buddy allocator handles 64-bit sizes even on 32-bit systems. This can be reproduced with the drm_buddy_allocator KUnit tests on i386: ./tools/testing/kunit/kunit.py run --arch i386

[PATCH 2/2] drm: test: Fix 32-bit issue in drm_buddy_test

2023-03-28 Thread David Gow
The drm_buddy_test KUnit tests verify that returned blocks have sizes which are powers of two using is_power_of_2(). However, is_power_of_2() operations on a 'long', but the block size is a u64. So on systems where long is 32-bit, this can sometimes fail even on correctly sized blocks. This only r

<    1   2