Re: [PATCH] amdgpu: add a filter condition when set brightness

2023-02-27 Thread wangyuanzhi
Hello, I have fixed compilation errors. The lenovo ThinkBook 14 G3 ACL notebook bios reports very small brightness value, 3 eg. On 2023/2/27 22:20, Mario Limonciello wrote: On 2/27/23 01:39, Yuanzhi Wang wrote: When the laptop is plugged into AC or DC power supply, the brightness obtained

[PATCH v2] amdgpu: add a filter condition when set brightness

2023-02-27 Thread Yuanzhi Wang
There is a lenovo ThinkBook 14 G3 ACL notebook, when the laptop is plugged into AC power supply, the brightness obtained ACPI may be smaller than current brightness.As a result the screen becomes dark,this is not what people want. So we should add So we should filter out very small brightness

[Bug 217099] New: amdgpu driver errors after disconnecting a Lenovo T14 (Gen1 AMD) from dock when the laptop is sleeping

2023-02-27 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=217099 Bug ID: 217099 Summary: amdgpu driver errors after disconnecting a Lenovo T14 (Gen1 AMD) from dock when the laptop is sleeping Product: Drivers Version: 2.5 Kernel Version:

Re: [PATCH] drm/virtio: Add option to disable KMS support

2023-02-27 Thread Gerd Hoffmann
On Mon, Feb 27, 2023 at 07:40:11AM -0800, Rob Clark wrote: > On Sun, Feb 26, 2023 at 10:38 PM Gerd Hoffmann wrote: > > > > On Fri, Feb 24, 2023 at 10:02:24AM -0800, Rob Clark wrote: > > > From: Rob Clark > > > > > > Add a build option to disable modesetting support. This is useful in > > >

[PATCH] drm/i915/hwmon: Accept writes of value 0 to power1_max_interval

2023-02-27 Thread Ashutosh Dixit
The value shown by power1_max_interval in millisec is essentially: ((1.x * power(2,y)) * 1000) >> 10 Where x and y are read from a HW register. On ATSM, x and y are 0 on power-up so the value shown is 0. Writes of 0 to power1_max_interval had previously been disallowed to avoid computing

[PATCH v6 4/8] drm/i915/pxp: Add GSC-CS backend to send GSC fw messages

2023-02-27 Thread Alan Previn
Add GSC engine based method for sending PXP firmware packets to the GSC firmware for MTL (and future) products. Use the newly added helpers to populate the GSC-CS memory header and send the message packet to the FW by dispatching the GSC_HECI_CMD_PKT instruction on the GSC engine. We use

[PATCH v6 7/8] drm/i915/pxp: On MTL, KCR enabling doesn't wait on tee component

2023-02-27 Thread Alan Previn
On legacy platforms, KCR HW enabling is done at the time the mei component interface is bound. It's also disabled during unbind. However, for MTL onwards, we don't depend on a tee component to start sending GSC-CS firmware messages. Thus, immediately enable (or disable) KCR HW on PXP's init, fini

[PATCH v6 8/8] drm/i915/pxp: Enable PXP with MTL-GSC-CS

2023-02-27 Thread Alan Previn
Enable PXP with MTL-GSC-CS: add the has_pxp into device info and increase the debugfs teardown timeouts to align with new GSC-CS + firmware specs. Signed-off-by: Alan Previn --- drivers/gpu/drm/i915/i915_pci.c | 1 + drivers/gpu/drm/i915/pxp/intel_pxp_debugfs.c | 9 -

[PATCH v6 3/8] drm/i915/pxp: Add MTL helpers to submit Heci-Cmd-Packet to GSC

2023-02-27 Thread Alan Previn
Add helper functions into a new file for heci-packet-submission. The helpers will handle generating the MTL GSC-CS Memory-Header and submission of the Heci-Cmd-Packet instructions to the engine. NOTE1: These common functions for heci-packet-submission will be used by different i915 callers:

[PATCH v6 2/8] drm/i915/pxp: Add MTL hw-plumbing enabling for KCR operation

2023-02-27 Thread Alan Previn
Add MTL hw-plumbing enabling for KCR operation under PXP which includes: 1. Updating 'pick-gt' to get the media tile for KCR interrupt handling 2. Adding MTL's KCR registers for PXP operation (init, status-checking, etc.). While doing #2, lets create a separate registers header file for

[PATCH v6 5/8] drm/i915/pxp: Add ARB session creation and cleanup

2023-02-27 Thread Alan Previn
Add MTL's function for ARB session creation using PXP firmware version 4.3 ABI structure format. Also add MTL's function for ARB session invalidation but this reuses PXP firmware version 4.2 ABI structure format. Before checking the return status, look at the GSC-CS-Mem-Header's pending-bit

[PATCH v6 6/8] drm/i915/pxp: MTL-KCR interrupt ctrl's are in GT-0

2023-02-27 Thread Alan Previn
Despite KCR subsystem being in the media-tile (close to the GSC-CS), the IRQ controls for it are on GT-0 with other global IRQ controls. Thus, add a helper for KCR hw interrupt enable/disable functions to get the correct gt structure (for uncore) for MTL. In the helper, we get GT-0's handle for

[PATCH v6 0/8] drm/i915/pxp: Add MTL PXP Support

2023-02-27 Thread Alan Previn
This series enables PXP on MTL. On ADL/TGL platforms, we rely on the mei driver via the i915-mei PXP component interface to establish a connection to the security firmware via the HECI device interface. That interface is used to create and teardown the PXP ARB session. PXP ARB session is created

[PATCH v6 1/8] drm/i915/pxp: Add GSC-CS back-end resource init and cleanup

2023-02-27 Thread Alan Previn
For MTL, the PXP back-end transport uses the GSC engine to submit HECI packets through the HW to the GSC firmware for PXP arb session management. This submission uses a non-priveleged batch buffer, a buffer for the command packet and of course a context targeting the GSC-CS. Thus for MTL, we need

Re: [PATCH drm-next v2 05/16] drm: manager to keep track of GPUs VA mappings

2023-02-27 Thread Danilo Krummrich
On Tue, Feb 21, 2023 at 01:20:50PM -0500, Liam R. Howlett wrote: > * Danilo Krummrich [230217 08:45]: > > Add infrastructure to keep track of GPU virtual address (VA) mappings > > with a decicated VA space manager implementation. > > > > New UAPIs, motivated by Vulkan sparse memory bindings

[PATCH v3 2/2] drm/i915/gt: Make sure that errors are propagated through request chains

2023-02-27 Thread Andi Shyti
Currently, when we perform operations such as clearing or copying large blocks of memory, we generate multiple requests that are executed in a chain. However, if one of these requests fails, we may not realize it unless it happens to be the last request in the chain. This is because errors are

[PATCH v3 0/2] Fix error propagation amongst request

2023-02-27 Thread Andi Shyti
Hi, This series of two patches fixes the issue introduced in cf586021642d80 ("drm/i915/gt: Pipelined page migration") where, as reported by Matt, in a chain of requests an error is reported only if happens in the last request. However Chris noticed that without ensuring exclusivity in the

[PATCH v3 1/2] drm/i915: Throttle for ringspace prior to taking the timeline mutex

2023-02-27 Thread Andi Shyti
From: Chris Wilson Before taking exclusive ownership of the ring for emitting the request, wait for space in the ring to become available. This allows others to take the timeline->mutex to make forward progresses while userspace is blocked. In particular, this allows regular clients to issue

Re: [RFT PATCH v2 3/3] drm/msm/dsi: More properly handle errors in regards to dsi_mgr_bridge_power_on()

2023-02-27 Thread Dmitry Baryshkov
On 01/02/2023 00:18, Douglas Anderson wrote: In commit 7d8e9a90509f ("drm/msm/dsi: move DSI host powerup to modeset time") the error handling with regards to dsi_mgr_bridge_power_on() got a bit worse. Specifically if we failed to power the bridge on then nothing would really notice. The modeset

Re: [RFT PATCH v2 2/3] drm/msm/dsi: Stop unconditionally powering up DSI hosts at modeset

2023-02-27 Thread Dmitry Baryshkov
On 01/02/2023 00:18, Douglas Anderson wrote: In commit 7d8e9a90509f ("drm/msm/dsi: move DSI host powerup to modeset time"), we moved powering up DSI hosts to modeset time. This wasn't because it was an elegant design, but there were no better options. That commit actually ended up breaking

Re: [RFT PATCH v2 1/3] drm/bridge: tc358762: Set pre_enable_prev_first

2023-02-27 Thread Dmitry Baryshkov
On 01/02/2023 00:18, Douglas Anderson wrote: Set the "pre_enable_prev_first" as provided by commit 4fb912e5e190 ("drm/bridge: Introduce pre_enable_prev_first to alter bridge init order"). This should allow us to revert commit ec7981e6c614 ("drm/msm/dsi: don't powerup at modeset time for

Re: [RFT PATCH v2 1/3] drm/bridge: tc358762: Set pre_enable_prev_first

2023-02-27 Thread Dmitry Baryshkov
On 28/02/2023 02:26, Doug Anderson wrote: Hi, On Wed, Feb 1, 2023 at 1:51 AM Dave Stevenson wrote: On Tue, 31 Jan 2023 at 22:22, Douglas Anderson wrote: Set the "pre_enable_prev_first" as provided by commit 4fb912e5e190 ("drm/bridge: Introduce pre_enable_prev_first to alter bridge init

[PATCH v2] drm/vram-helper: fix function names in vram helper doc

2023-02-27 Thread Luc Ma
Refer to drmm_vram_helper_init() instead of the non-existent drmm_vram_helper_alloc_mm(). Fixes: a5f23a72355d ("drm/vram-helper: Managed vram helpers") Signed-off-by: Luc Ma --- v1 -> v2: improved commit message and add changelog drivers/gpu/drm/drm_gem_vram_helper.c | 6 +++--- 1 file

Re: [RFT PATCH v2 1/3] drm/bridge: tc358762: Set pre_enable_prev_first

2023-02-27 Thread Doug Anderson
Hi, On Wed, Feb 1, 2023 at 1:51 AM Dave Stevenson wrote: > > On Tue, 31 Jan 2023 at 22:22, Douglas Anderson wrote: > > > > Set the "pre_enable_prev_first" as provided by commit 4fb912e5e190 > > ("drm/bridge: Introduce pre_enable_prev_first to alter bridge init > > order"). This should allow us

Re: [PATCH v4 06/14] dma-buf/sync_file: Support (E)POLLPRI

2023-02-27 Thread Rob Clark
On Mon, Feb 27, 2023 at 2:44 PM Sebastian Wick wrote: > > On Mon, Feb 27, 2023 at 11:20 PM Rob Clark wrote: > > > > On Mon, Feb 27, 2023 at 1:36 PM Rodrigo Vivi wrote: > > > > > > On Fri, Feb 24, 2023 at 09:59:57AM -0800, Rob Clark wrote: > > > > On Fri, Feb 24, 2023 at 7:27 AM Luben Tuikov >

Re: [RFC PATCH 2/2] drm/msm/dp: enable pm_runtime support for dp driver

2023-02-27 Thread Bjorn Andersson
On Thu, Feb 23, 2023 at 07:26:35PM +0530, Sankeerth Billakanti wrote: > diff --git a/drivers/gpu/drm/msm/dp/dp_aux.c b/drivers/gpu/drm/msm/dp/dp_aux.c [..] > +static int dp_runtime_resume(struct device *dev) > +{ > + struct platform_device *pdev = to_platform_device(dev); > + struct msm_dp

Re: [PATCH v4 06/14] dma-buf/sync_file: Support (E)POLLPRI

2023-02-27 Thread Sebastian Wick
On Mon, Feb 27, 2023 at 11:20 PM Rob Clark wrote: > > On Mon, Feb 27, 2023 at 1:36 PM Rodrigo Vivi wrote: > > > > On Fri, Feb 24, 2023 at 09:59:57AM -0800, Rob Clark wrote: > > > On Fri, Feb 24, 2023 at 7:27 AM Luben Tuikov wrote: > > > > > > > > On 2023-02-24 06:37, Tvrtko Ursulin wrote: > > >

Re: [PATCH v4 06/14] dma-buf/sync_file: Support (E)POLLPRI

2023-02-27 Thread Rob Clark
On Mon, Feb 27, 2023 at 1:36 PM Rodrigo Vivi wrote: > > On Fri, Feb 24, 2023 at 09:59:57AM -0800, Rob Clark wrote: > > On Fri, Feb 24, 2023 at 7:27 AM Luben Tuikov wrote: > > > > > > On 2023-02-24 06:37, Tvrtko Ursulin wrote: > > > > > > > > On 24/02/2023 11:00, Pekka Paalanen wrote: > > > >> On

[PATCH v2] drm/msm/disp/dpu: fix sc7280_pp base offset

2023-02-27 Thread Kuogee Hsieh
At sc7280, pingpong block is used to management the dither effects to reduce distortion at panel. Currently pingpong-0 base offset is wrongly set at 0x59000. This mistake will not cause system to crash. However it will make dither not work. This patch correct sc7280 ping pong-0 block base offset.

Re: [PATCH v4 06/14] dma-buf/sync_file: Support (E)POLLPRI

2023-02-27 Thread Rodrigo Vivi
On Fri, Feb 24, 2023 at 09:59:57AM -0800, Rob Clark wrote: > On Fri, Feb 24, 2023 at 7:27 AM Luben Tuikov wrote: > > > > On 2023-02-24 06:37, Tvrtko Ursulin wrote: > > > > > > On 24/02/2023 11:00, Pekka Paalanen wrote: > > >> On Fri, 24 Feb 2023 10:50:51 + > > >> Tvrtko Ursulin wrote: > > >>

Re: [RFC PATCH 1/2] drm/msm/dpu: add dsc helper functions

2023-02-27 Thread Abhinav Kumar
On 2/27/2023 11:25 AM, Dmitry Baryshkov wrote: 27 февраля 2023 г. 19:59:35 GMT+02:00, Abhinav Kumar пишет: On 2/27/2023 4:45 AM, Dmitry Baryshkov wrote: On Mon, 27 Feb 2023 at 01:49, Abhinav Kumar wrote: On 2/26/2023 5:09 AM, Dmitry Baryshkov wrote: On 26/02/2023 02:47, Abhinav

[PATCH v2 1/2] drm/i915: Throttle for ringspace prior to taking the timeline mutex

2023-02-27 Thread Andi Shyti
From: Chris Wilson Before taking exclusive ownership of the ring for emitting the request, wait for space in the ring to become available. This allows others to take the timeline->mutex to make forward progresses while userspace is blocked. In particular, this allows regular clients to issue

[PATCH v2 2/2] drm/i915/gt: Make sure that errors are propagated through request chains

2023-02-27 Thread Andi Shyti
Currently, when we perform operations such as clearing or copying large blocks of memory, we generate multiple requests that are executed in a chain. However, if one of these requests fails, we may not realize it unless it happens to be the last request in the chain. This is because errors are

[PATCH v2 0/2] Fix error propagation amongst requests

2023-02-27 Thread Andi Shyti
Hi, This series of two patches fixes the issue introduced in cf586021642d80 ("drm/i915/gt: Pipelined page migration") where, as reported by Matt, in a chain of requests an error is reported only if happens in the last request. However Chris noticed that without ensuring exclusivity in the

[PATCH v2] drm/msm/dp: check core_initialized flag at both host_init() and host_deinit()

2023-02-27 Thread Kuogee Hsieh
There is a reboot/suspend test case where system suspend is forced during system booting up. Since dp_display_host_init() of external DP is executed at hpd thread context, this test case may created a scenario that dp_display_host_deinit() from pm_suspend() run before dp_display_host_init() if hpd

Re: [RESEND v2 PATCH] init/do_mounts.c: add virtiofs root fs support

2023-02-27 Thread David Heidelberg
Thank you all! We'll drop this patch in next MesaCI kernel uprev without this patch! David On 27/02/2023 19:06, Vivek Goyal wrote: On Mon, Feb 27, 2023 at 10:53:45AM -0500, Stefan Hajnoczi wrote: On Fri, Feb 24, 2023 at 03:37:51PM +0100, David Heidelberg wrote: From: Stefan Hajnoczi Make

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

2023-02-27 Thread André Almeida
Create a section that specifies how to deal with DRM device resets for kernel and userspace drivers. Signed-off-by: André Almeida --- Documentation/gpu/drm-uapi.rst | 51 ++ 1 file changed, 51 insertions(+) diff --git a/Documentation/gpu/drm-uapi.rst

[PATCH v2 0/1] drm: Add doc about GPU reset

2023-02-27 Thread André Almeida
Hi, Thanks everyone that gave feedback. v2 Changes: - This new version is a section of drm-uapi instead of a new file - Drop requirement for KMD to kill applications - Drop role of init systems on compositors recover - Drop assumption that robust apps creates new contexts Original cover letter

Re: [PATCH v13 04/18] drm: exynos: dsi: Switch to DSI panel or bridge find helper

2023-02-27 Thread Jagan Teki
On Tue, Feb 28, 2023 at 1:40 AM Marek Vasut wrote: > > On 2/27/23 20:49, Jagan Teki wrote: > > On Tue, Feb 28, 2023 at 1:11 AM Marek Vasut wrote: > >> > >> On 2/27/23 20:34, Jagan Teki wrote: > >>> On Tue, Feb 28, 2023 at 12:54 AM Marek Vasut wrote: > > On 2/27/23 20:15, Jagan Teki

Re: [PATCH v13 04/18] drm: exynos: dsi: Switch to DSI panel or bridge find helper

2023-02-27 Thread Marek Vasut
On 2/27/23 20:49, Jagan Teki wrote: On Tue, Feb 28, 2023 at 1:11 AM Marek Vasut wrote: On 2/27/23 20:34, Jagan Teki wrote: On Tue, Feb 28, 2023 at 12:54 AM Marek Vasut wrote: On 2/27/23 20:15, Jagan Teki wrote: On Tue, Feb 28, 2023 at 12:38 AM Marek Vasut wrote: On 2/27/23 20:01,

Re: [PATCH] drm/msm/dp: check core_initialized flag at both host_init() and host_deinit()

2023-02-27 Thread Abhinav Kumar
Hi Stephen On 2/27/2023 11:53 AM, Stephen Boyd wrote: Quoting Kuogee Hsieh (2023-02-24 10:29:58) There is a reboot/suspend test case where system suspend is forced during system booting up. Since host_init() of external DP is executed at hpd dp_display_host_init()? thread context, this

Re: [PATCH 0/2] char/agp: consolidate asm/agp.h

2023-02-27 Thread Arnd Bergmann
On Sun, Feb 12, 2023, at 09:46, Mike Rapoport wrote: > From: "Mike Rapoport (IBM)" > > asm/agp.h is duplicated in several architectures, with x86 being the > only instance that differs from the rest. > > Introduce asm-generic/agp.h and use it instead of per-architecture > headers for the most

Re: [PATCH] drm/msm/dp: check core_initialized flag at both host_init() and host_deinit()

2023-02-27 Thread Stephen Boyd
Quoting Kuogee Hsieh (2023-02-24 10:29:58) > There is a reboot/suspend test case where system suspend is forced during > system booting up. Since host_init() of external DP is executed at hpd dp_display_host_init()? > thread context, this test case may created a scenario that host_deinit()

Re: [PATCH v13 04/18] drm: exynos: dsi: Switch to DSI panel or bridge find helper

2023-02-27 Thread Jagan Teki
On Tue, Feb 28, 2023 at 1:19 AM Jagan Teki wrote: > > On Tue, Feb 28, 2023 at 1:11 AM Marek Vasut wrote: > > > > On 2/27/23 20:34, Jagan Teki wrote: > > > On Tue, Feb 28, 2023 at 12:54 AM Marek Vasut wrote: > > >> > > >> On 2/27/23 20:15, Jagan Teki wrote: > > >>> On Tue, Feb 28, 2023 at 12:38

Re: [PATCH v13 04/18] drm: exynos: dsi: Switch to DSI panel or bridge find helper

2023-02-27 Thread Jagan Teki
On Tue, Feb 28, 2023 at 1:11 AM Marek Vasut wrote: > > On 2/27/23 20:34, Jagan Teki wrote: > > On Tue, Feb 28, 2023 at 12:54 AM Marek Vasut wrote: > >> > >> On 2/27/23 20:15, Jagan Teki wrote: > >>> On Tue, Feb 28, 2023 at 12:38 AM Marek Vasut wrote: > > On 2/27/23 20:01, Jagan Teki

Re: [PATCH v13 04/18] drm: exynos: dsi: Switch to DSI panel or bridge find helper

2023-02-27 Thread Marek Vasut
On 2/27/23 20:34, Jagan Teki wrote: On Tue, Feb 28, 2023 at 12:54 AM Marek Vasut wrote: On 2/27/23 20:15, Jagan Teki wrote: On Tue, Feb 28, 2023 at 12:38 AM Marek Vasut wrote: On 2/27/23 20:01, Jagan Teki wrote: On Tue, Feb 28, 2023 at 12:25 AM Marek Vasut wrote: On 2/27/23 12:39,

[PATCH v7 14/15] drm/msm/atomic: Switch to vblank_start helper

2023-02-27 Thread Rob Clark
From: Rob Clark Drop our custom thing and switch to drm_crtc_next_vblank_start() for calculating the time of the start of the next vblank period. Signed-off-by: Rob Clark --- drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 15 --- drivers/gpu/drm/msm/msm_atomic.c| 8 +---

[PATCH v7 15/15] drm/i915: Add deadline based boost support

2023-02-27 Thread Rob Clark
From: Rob Clark v2: rebase Signed-off-by: Rob Clark --- drivers/gpu/drm/i915/i915_request.c | 20 1 file changed, 20 insertions(+) diff --git a/drivers/gpu/drm/i915/i915_request.c b/drivers/gpu/drm/i915/i915_request.c index 7503dcb9043b..44491e7e214c 100644 ---

[PATCH v7 13/15] drm/msm: Add wait-boost support

2023-02-27 Thread Rob Clark
From: Rob Clark Add a way for various userspace waits to signal urgency. Signed-off-by: Rob Clark --- drivers/gpu/drm/msm/msm_drv.c | 12 drivers/gpu/drm/msm/msm_gem.c | 5 + include/uapi/drm/msm_drm.h| 14 -- 3 files changed, 25 insertions(+), 6 deletions(-)

[PATCH v7 12/15] drm/msm: Add deadline based boost support

2023-02-27 Thread Rob Clark
From: Rob Clark Track the nearest deadline on a fence timeline and set a timer to expire shortly before to trigger boost if the fence has not yet been signaled. v2: rebase Signed-off-by: Rob Clark --- drivers/gpu/drm/msm/msm_fence.c | 74 +

[PATCH v7 10/15] drm/vblank: Add helper to get next vblank time

2023-02-27 Thread Rob Clark
From: Rob Clark Will be used in the next commit to set a deadline on fences that an atomic update is waiting on. v2: Calculate time at *start* of vblank period, not end v3: Fix kbuild complaints Signed-off-by: Rob Clark --- drivers/gpu/drm/drm_vblank.c | 53

[PATCH v7 11/15] drm/atomic-helper: Set fence deadline for vblank

2023-02-27 Thread Rob Clark
From: Rob Clark For an atomic commit updating a single CRTC (ie. a pageflip) calculate the next vblank time, and inform the fence(s) of that deadline. v2: Comment typo fix (danvet) Signed-off-by: Rob Clark Reviewed-by: Daniel Vetter Signed-off-by: Rob Clark ---

[PATCH v7 09/15] drm/syncobj: Add deadline support for syncobj waits

2023-02-27 Thread Rob Clark
From: Rob Clark Add a new flag to let userspace provide a deadline as a hint for syncobj and timeline waits. This gives a hint to the driver signaling the backing fences about how soon userspace needs it to compete work, so it can addjust GPU frequency accordingly. An immediate deadline can be

[PATCH v7 05/15] dma-buf/sync_file: Add SET_DEADLINE ioctl

2023-02-27 Thread Rob Clark
From: Rob Clark The initial purpose is for igt tests, but this would also be useful for compositors that wait until close to vblank deadline to make decisions about which frame to show. The igt tests can be found at:

[PATCH v7 08/15] drm/scheduler: Add fence deadline support

2023-02-27 Thread Rob Clark
As the finished fence is the one that is exposed to userspace, and therefore the one that other operations, like atomic update, would block on, we need to propagate the deadline from from the finished fence to the actual hw fence. v2: Split into drm_sched_fence_set_parent() (ckoenig) v3: Ensure a

[PATCH v7 06/15] dma-buf/sync_file: Support (E)POLLPRI

2023-02-27 Thread Rob Clark
From: Rob Clark Allow userspace to use the EPOLLPRI/POLLPRI flag to indicate an urgent wait (as opposed to a "housekeeping" wait to know when to cleanup after some work has completed). Usermode components of GPU driver stacks often poll() on fence fd's to know when it is safe to do things like

[PATCH v7 07/15] dma-buf/sw_sync: Add fence deadline support

2023-02-27 Thread Rob Clark
From: Rob Clark This consists of simply storing the most recent deadline, and adding an ioctl to retrieve the deadline. This can be used in conjunction with the SET_DEADLINE ioctl on a fence fd for testing. Ie. create various sw_sync fences, merge them into a fence-array, set deadline on the

[PATCH v7 04/15] dma-buf/dma-resv: Add a way to set fence deadline

2023-02-27 Thread Rob Clark
From: Rob Clark Add a way to set a deadline on remaining resv fences according to the requested usage. Signed-off-by: Rob Clark Reviewed-by: Christian König --- drivers/dma-buf/dma-resv.c | 22 ++ include/linux/dma-resv.h | 2 ++ 2 files changed, 24 insertions(+) diff

[PATCH v7 03/15] dma-buf/fence-chain: Add fence deadline support

2023-02-27 Thread Rob Clark
From: Rob Clark Propagate the deadline to all the fences in the chain. v2: Use dma_fence_chain_contained [Tvrtko] Signed-off-by: Rob Clark Reviewed-by: Christian König for this one. --- drivers/dma-buf/dma-fence-chain.c | 12 1 file changed, 12 insertions(+) diff --git

[PATCH v7 01/15] dma-buf/dma-fence: Add deadline awareness

2023-02-27 Thread Rob Clark
From: Rob Clark Add a way to hint to the fence signaler of an upcoming deadline, such as vblank, which the fence waiter would prefer not to miss. This is to aid the fence signaler in making power management decisions, like boosting frequency as the deadline approaches and awareness of missing

[PATCH v7 02/15] dma-buf/fence-array: Add fence deadline support

2023-02-27 Thread Rob Clark
From: Rob Clark Propagate the deadline to all the fences in the array. Signed-off-by: Rob Clark Reviewed-by: Christian König --- drivers/dma-buf/dma-fence-array.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/drivers/dma-buf/dma-fence-array.c

[PATCH v7 00/15] dma-fence: Deadline awareness

2023-02-27 Thread Rob Clark
From: Rob Clark This series adds a deadline hint to fences, so realtime deadlines such as vblank can be communicated to the fence signaller for power/ frequency management decisions. This is partially inspired by a trick i915 does, but implemented via dma-fence for a couple of reasons: 1) To

Re: [PATCH v13 04/18] drm: exynos: dsi: Switch to DSI panel or bridge find helper

2023-02-27 Thread Jagan Teki
On Tue, Feb 28, 2023 at 12:54 AM Marek Vasut wrote: > > On 2/27/23 20:15, Jagan Teki wrote: > > On Tue, Feb 28, 2023 at 12:38 AM Marek Vasut wrote: > >> > >> On 2/27/23 20:01, Jagan Teki wrote: > >>> On Tue, Feb 28, 2023 at 12:25 AM Marek Vasut wrote: > > On 2/27/23 12:39, Jagan Teki

Re: [RFC PATCH 1/2] drm/msm/dpu: add dsc helper functions

2023-02-27 Thread Dmitry Baryshkov
27 февраля 2023 г. 19:59:35 GMT+02:00, Abhinav Kumar пишет: > > >On 2/27/2023 4:45 AM, Dmitry Baryshkov wrote: >> On Mon, 27 Feb 2023 at 01:49, Abhinav Kumar >> wrote: >>> >>> >>> >>> On 2/26/2023 5:09 AM, Dmitry Baryshkov wrote: On 26/02/2023 02:47, Abhinav Kumar wrote: > Hi

Re: [PATCH v13 04/18] drm: exynos: dsi: Switch to DSI panel or bridge find helper

2023-02-27 Thread Marek Vasut
On 2/27/23 20:15, Jagan Teki wrote: On Tue, Feb 28, 2023 at 12:38 AM Marek Vasut wrote: On 2/27/23 20:01, Jagan Teki wrote: On Tue, Feb 28, 2023 at 12:25 AM Marek Vasut wrote: On 2/27/23 12:39, Jagan Teki wrote: drm_of_dsi_find_panel_or_bridge is capable of looking up the downstream DSI

Re: [PATCH v3 1/2] drm/edid: parse DRM VESA dsc bpp target

2023-02-27 Thread Jani Nikula
On Mon, 27 Feb 2023, Harry Wentland wrote: > On 2/27/23 12:12, Jani Nikula wrote: >> On Mon, 27 Feb 2023, Harry Wentland wrote: >>> On 2/26/23 09:10, Yaroslav Bolyukin wrote: As per DisplayID v2.0 Errata E9 spec "DSC pass-through timing support" VESA vendor-specific data block may

Re: [PATCH v13 04/18] drm: exynos: dsi: Switch to DSI panel or bridge find helper

2023-02-27 Thread Jagan Teki
On Tue, Feb 28, 2023 at 12:38 AM Marek Vasut wrote: > > On 2/27/23 20:01, Jagan Teki wrote: > > On Tue, Feb 28, 2023 at 12:25 AM Marek Vasut wrote: > >> > >> On 2/27/23 12:39, Jagan Teki wrote: > >>> drm_of_dsi_find_panel_or_bridge is capable of looking up the > >>> downstream DSI bridge and

Re: [PATCH v13 04/18] drm: exynos: dsi: Switch to DSI panel or bridge find helper

2023-02-27 Thread Marek Vasut
On 2/27/23 20:01, Jagan Teki wrote: On Tue, Feb 28, 2023 at 12:25 AM Marek Vasut wrote: On 2/27/23 12:39, Jagan Teki wrote: drm_of_dsi_find_panel_or_bridge is capable of looking up the downstream DSI bridge and panel and trying to add a panel bridge if the panel is found. Replace explicit

Re: [PATCH v13 04/18] drm: exynos: dsi: Switch to DSI panel or bridge find helper

2023-02-27 Thread Jagan Teki
On Tue, Feb 28, 2023 at 12:25 AM Marek Vasut wrote: > > On 2/27/23 12:39, Jagan Teki wrote: > > drm_of_dsi_find_panel_or_bridge is capable of looking up the > > downstream DSI bridge and panel and trying to add a panel bridge > > if the panel is found. > > > > Replace explicit finding calls with

Re: [PATCH drm-next v2 04/16] maple_tree: add flag MT_FLAGS_LOCK_NONE

2023-02-27 Thread Danilo Krummrich
On 2/27/23 19:36, Matthew Wilcox wrote: On Mon, Feb 27, 2023 at 06:39:33PM +0100, Danilo Krummrich wrote: On 2/21/23 19:31, Matthew Wilcox wrote: Lockdep will shout at you if you get it wrong ;-) But you can safely take the spinlock before calling mas_store_gfp(GFP_KERNEL) because mas_nomem()

Re: [PATCH v1] drm/msm/disp/dpu: fix sc7280_pp base address

2023-02-27 Thread Stephen Boyd
Quoting Kuogee Hsieh (2023-02-27 09:04:31) > Correct sc7280 pp block base address. What goes wrong if this is left unchanged? How important is it to fix this? Does the display fail to work? Does it fix something for a new feature that isn't yet enabled upstream? This information is useful to put

Re: [PATCH v13 04/18] drm: exynos: dsi: Switch to DSI panel or bridge find helper

2023-02-27 Thread Marek Vasut
On 2/27/23 12:39, Jagan Teki wrote: drm_of_dsi_find_panel_or_bridge is capable of looking up the downstream DSI bridge and panel and trying to add a panel bridge if the panel is found. Replace explicit finding calls with drm_of_dsi_find_panel_or_bridge followed with drmm_panel_bridge_add.

Re: [PATCH v3] drm/virtio: Add option to disable KMS support

2023-02-27 Thread Dmitry Osipenko
On 2/27/23 20:38, Rob Clark wrote: > static const struct drm_driver driver = { > - .driver_features = DRIVER_MODESET | DRIVER_GEM | DRIVER_RENDER | > DRIVER_ATOMIC, > + .driver_features = > +#if defined(CONFIG_DRM_VIRTIO_GPU_KMS) I'd also replace the `#if defined()` with `#if

Re: [PATCH v4 06/14] dma-buf/sync_file: Support (E)POLLPRI

2023-02-27 Thread Rob Clark
On Mon, Feb 27, 2023 at 1:34 AM Pekka Paalanen wrote: > > On Fri, 24 Feb 2023 11:44:53 -0800 > Rob Clark wrote: > > > On Fri, Feb 24, 2023 at 2:24 AM Pekka Paalanen wrote: > > > > > > On Fri, 24 Feb 2023 09:41:46 + > > > Tvrtko Ursulin wrote: > > > > > > > On 24/02/2023 09:26, Pekka

Re: [PATCH drm-next v2 04/16] maple_tree: add flag MT_FLAGS_LOCK_NONE

2023-02-27 Thread Matthew Wilcox
On Mon, Feb 27, 2023 at 06:39:33PM +0100, Danilo Krummrich wrote: > On 2/21/23 19:31, Matthew Wilcox wrote: > > Lockdep will shout at you if you get it wrong ;-) But you can safely > > take the spinlock before calling mas_store_gfp(GFP_KERNEL) because > > mas_nomem() knows to drop the lock before

Re: [PATCH v3 1/2] drm/edid: parse DRM VESA dsc bpp target

2023-02-27 Thread Harry Wentland
On 2/27/23 12:12, Jani Nikula wrote: > On Mon, 27 Feb 2023, Harry Wentland wrote: >> On 2/26/23 09:10, Yaroslav Bolyukin wrote: >>> As per DisplayID v2.0 Errata E9 spec "DSC pass-through timing support" >>> VESA vendor-specific data block may contain target DSC bits per pixel >>> fields >>> >>

Re: [PATCH v3 2/2] drm/amd: use fixed dsc bits-per-pixel from edid

2023-02-27 Thread Harry Wentland
On 2/26/23 09:10, Yaroslav Bolyukin wrote: > VESA vendor header from DisplayID spec may contain fixed bit per pixel > rate, it should be respected by drm driver > This will apply the fixed bpp for all modes. I don't think that's right. It should apply only to VII timings. Harry >

Re: [PATCH v3] drm/virtio: Add option to disable KMS support

2023-02-27 Thread Rob Clark
On Mon, Feb 27, 2023 at 9:57 AM Dmitry Osipenko wrote: > > On 2/27/23 20:38, Rob Clark wrote: > ... > > + if (IS_ENABLED(CONFIG_DRM_VIRTIO_GPU_KMS)) { > > + /* get display info */ > > + virtio_cread_le(vgdev->vdev, struct virtio_gpu_config, > > +

Re: [PATCH v14 2/3] drm: bridge: panel: Add drmm_panel_bridge_add_nodrm

2023-02-27 Thread Jagan Teki
On Mon, Feb 27, 2023 at 11:17 PM Maxime Ripard wrote: > > On Mon, Feb 27, 2023 at 11:02:30PM +0530, Jagan Teki wrote: > > drmm_panel_bridge_add_nodrm is an another type of DRM-managed action > > helper with nodrm pointer. > > > > DRM pointer is required to perform DRM-managed action, > > - The

Re: [RESEND v2 PATCH] init/do_mounts.c: add virtiofs root fs support

2023-02-27 Thread Vivek Goyal
On Mon, Feb 27, 2023 at 10:53:45AM -0500, Stefan Hajnoczi wrote: > On Fri, Feb 24, 2023 at 03:37:51PM +0100, David Heidelberg wrote: > > From: Stefan Hajnoczi > > > > Make it possible to boot directly from a virtiofs file system with tag > > 'myfs' using the following kernel parameters: > > > >

Re: [RFC PATCH 1/2] drm/msm/dpu: add dsc helper functions

2023-02-27 Thread Abhinav Kumar
On 2/27/2023 4:45 AM, Dmitry Baryshkov wrote: On Mon, 27 Feb 2023 at 01:49, Abhinav Kumar wrote: On 2/26/2023 5:09 AM, Dmitry Baryshkov wrote: On 26/02/2023 02:47, Abhinav Kumar wrote: Hi Dmitry On 2/25/2023 7:23 AM, Dmitry Baryshkov wrote: On 25/02/2023 02:36, Abhinav Kumar wrote:

Re: [PATCH v3] drm/virtio: Add option to disable KMS support

2023-02-27 Thread Dmitry Osipenko
On 2/27/23 20:38, Rob Clark wrote: ... > + if (IS_ENABLED(CONFIG_DRM_VIRTIO_GPU_KMS)) { > + /* get display info */ > + virtio_cread_le(vgdev->vdev, struct virtio_gpu_config, > + num_scanouts, _scanouts); > + vgdev->num_scanouts =

Re: [PATCH v14 2/3] drm: bridge: panel: Add drmm_panel_bridge_add_nodrm

2023-02-27 Thread Maxime Ripard
On Mon, Feb 27, 2023 at 11:02:30PM +0530, Jagan Teki wrote: > drmm_panel_bridge_add_nodrm is an another type of DRM-managed action > helper with nodrm pointer. > > DRM pointer is required to perform DRM-managed action, > - The conventional component-based drm bridges, the DRM pointer can >

Re: [PATCH drm-next v2 04/16] maple_tree: add flag MT_FLAGS_LOCK_NONE

2023-02-27 Thread Danilo Krummrich
On 2/21/23 19:31, Matthew Wilcox wrote: On Tue, Feb 21, 2023 at 03:37:49PM +0100, Danilo Krummrich wrote: On Mon, Feb 20, 2023 at 08:33:35PM +, Matthew Wilcox wrote: On Mon, Feb 20, 2023 at 06:06:03PM +0100, Danilo Krummrich wrote: On 2/20/23 16:10, Matthew Wilcox wrote: This is why we

[PATCH v3] drm/virtio: Add option to disable KMS support

2023-02-27 Thread Rob Clark
From: Rob Clark Add a build option to disable modesetting support. This is useful in cases where the guest only needs to use the GPU in a headless mode, or (such as in the CrOS usage) window surfaces are proxied to a host compositor. v2: Use more if (IS_ENABLED(...)) v3: Also permit the host

[PATCH v14 3/3] drm: bridge: panel: Add drmm_of_dsi_get_bridge helper

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

[PATCH v14 2/3] drm: bridge: panel: Add drmm_panel_bridge_add_nodrm

2023-02-27 Thread Jagan Teki
drmm_panel_bridge_add_nodrm is an another type of DRM-managed action helper with nodrm pointer. DRM pointer is required to perform DRM-managed action, - The conventional component-based drm bridges, the DRM pointer can access in component ops bind API. - The non-component-based bridges (like

[PATCH v14 1/3] drm: of: Lookup if child node has DSI panel or bridge

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

Re: [PATCH v2 5/8] accel/qaic: Add datapath

2023-02-27 Thread Stanislaw Gruszka
On Fri, Feb 24, 2023 at 12:36:51PM -0700, Jeffrey Hugo wrote: > > > +static int reserve_pages(unsigned long start_pfn, unsigned long nr_pages, > > > + bool reserve) > > > +{ > > > + unsigned long pfn; > > > + unsigned long end_pfn = start_pfn + nr_pages; > > > + struct page *page;

Re: [PATCH v3 1/2] drm/edid: parse DRM VESA dsc bpp target

2023-02-27 Thread Jani Nikula
On Mon, 27 Feb 2023, Harry Wentland wrote: > On 2/26/23 09:10, Yaroslav Bolyukin wrote: >> As per DisplayID v2.0 Errata E9 spec "DSC pass-through timing support" >> VESA vendor-specific data block may contain target DSC bits per pixel >> fields >> > > According to the errata this should only

Re: [PATCH v13 02/18] drm: bridge: panel: Support nodrm case for drmm_panel_bridge_add

2023-02-27 Thread Maxime Ripard
On Mon, Feb 27, 2023 at 05:58:03PM +0530, Jagan Teki wrote: > On Mon, Feb 27, 2023 at 5:41 PM Maxime Ripard wrote: > > > > On Mon, Feb 27, 2023 at 05:09:09PM +0530, Jagan Teki wrote: > > > drmm_panel_bridge_add DRM-managed action helper is useful for the bridge > > > which automatically removes

[PATCH v1] drm/msm/disp/dpu: fix sc7280_pp base address

2023-02-27 Thread Kuogee Hsieh
Correct sc7280 pp block base address. Fixes: 591e34a091d1 ("drm/msm/disp/dpu1: add support for display for SC7280 target") Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/disp/dpu1/dpu_hw_catalog.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

Re: [PATCH v3 1/2] drm/edid: parse DRM VESA dsc bpp target

2023-02-27 Thread Harry Wentland
On 2/26/23 09:10, Yaroslav Bolyukin wrote: > As per DisplayID v2.0 Errata E9 spec "DSC pass-through timing support" > VESA vendor-specific data block may contain target DSC bits per pixel > fields > According to the errata this should only apply to VII timings. The way it is currently

Re: [PATCH v2] drm/virtio: Add option to disable KMS support

2023-02-27 Thread Rob Clark
On Mon, Feb 27, 2023 at 8:16 AM Daniel Vetter wrote: > > On Mon, Feb 27, 2023 at 08:01:13AM -0800, Rob Clark wrote: > > From: Rob Clark > > > > Add a build option to disable modesetting support. This is useful in > > cases where the guest only needs to use the GPU in a headless mode, or > >

Re: [PATCH] fbdev: chipsfb: Fix error codes in chipsfb_pci_init()

2023-02-27 Thread Dan Carpenter
On Mon, Feb 27, 2023 at 11:13:19AM +0100, Thomas Zimmermann wrote: > Hi > > Am 27.02.23 um 11:07 schrieb Dan Carpenter: > > The error codes are not set on these error paths. > > > > Fixes: 145eed48de27 ("fbdev: Remove conflicting devices on PCI bus") > > Signed-off-by: Dan Carpenter > >

Re: [PATCH] MAINTAINERS: Add myself as co-maintainer for DRM Panels drivers

2023-02-27 Thread Neil Armstrong
Hi Thierry, On 27/02/2023 16:37, Thierry Reding wrote: On Mon, Feb 27, 2023 at 09:22:02AM +0100, Neil Armstrong wrote: Hi Sam ! On 17/02/2023 11:45, Sam Ravnborg wrote: On Fri, Feb 17, 2023 at 10:58:15AM +0100, Neil Armstrong wrote: Add myself as co-maintainer for DRM Panel Drivers in order

Re: [PATCH v2] drm/virtio: Add option to disable KMS support

2023-02-27 Thread Daniel Vetter
On Mon, Feb 27, 2023 at 08:01:13AM -0800, Rob Clark wrote: > From: Rob Clark > > Add a build option to disable modesetting support. This is useful in > cases where the guest only needs to use the GPU in a headless mode, or > (such as in the CrOS usage) window surfaces are proxied to a host >

Re: [PATCH] MAINTAINERS: Add myself as co-maintainer for DRM Panels drivers

2023-02-27 Thread Jagan Teki
On Fri, Feb 17, 2023 at 3:28 PM Neil Armstrong wrote: > > Add myself as co-maintainer for DRM Panel Drivers in order to help > reviewing and getting new panels drivers merged. > > Signed-off-by: Neil Armstrong > --- Thanks for doing this, I'm acking since I have potential involvement in Panels.

Re: [PATCH] drm/virtio: Add option to disable KMS support

2023-02-27 Thread Ville Syrjälä
On Mon, Feb 27, 2023 at 07:40:11AM -0800, Rob Clark wrote: > On Sun, Feb 26, 2023 at 10:38 PM Gerd Hoffmann wrote: > > > > On Fri, Feb 24, 2023 at 10:02:24AM -0800, Rob Clark wrote: > > > From: Rob Clark > > > > > > Add a build option to disable modesetting support. This is useful in > > >

Re: [PATCH v7 1/7] drm/print: Fix and add support for NULL as first argument in drm_* macros

2023-02-27 Thread Jani Nikula
On Mon, 27 Feb 2023, Siddh Raman Pant wrote: > On Mon, 27 Feb 2023 15:13:21 +0530, Jani Nikula wrote: >> First of all, that's two distinct changes in one patch. The subject says >> one thing, but it's really two. > > Sorry, my bad. > >> But the main question is, do we *really* want to let callers

  1   2   3   >