Re: [PATCH linux-next v2] backlight: use sysfs_emit() to instead of scnprintf()

2022-09-28 Thread 葉星辰
Thanks for your reply. This patch about lp8788 fixes have already applied in: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=61e86018aebffd172c9da967f284469924d5e947 So this patch just fixed the rest. Best Regards, YE XINGCHEN

Re: [Intel-gfx] [PATCH 05/16] drm/i915/vm_bind: Implement bind and unbind of object

2022-09-28 Thread Niranjana Vishwanathapura
On Wed, Sep 28, 2022 at 01:06:18PM -0700, Welty, Brian wrote: On 9/27/2022 11:19 PM, Niranjana Vishwanathapura wrote: Add uapi and implement support for bind and unbind of an object at the specified GPU virtual addresses. The vm_bind mode is not supported in legacy execbuf2 ioctl. It will be

Re: [PATCH 05/16] drm/i915/vm_bind: Implement bind and unbind of object

2022-09-28 Thread Niranjana Vishwanathapura
On Wed, Sep 28, 2022 at 06:52:21PM +0100, Matthew Auld wrote: On 28/09/2022 07:19, Niranjana Vishwanathapura wrote: Add uapi and implement support for bind and unbind of an object at the specified GPU virtual addresses. The vm_bind mode is not supported in legacy execbuf2 ioctl. It will be

Re: [PATCH 03/16] drm/i915/vm_bind: Expose i915_gem_object_max_page_size()

2022-09-28 Thread Niranjana Vishwanathapura
On Wed, Sep 28, 2022 at 06:40:01PM +0100, Matthew Auld wrote: On 28/09/2022 07:19, Niranjana Vishwanathapura wrote: Expose i915_gem_object_max_page_size() function non-static which will be used by the vm_bind feature. Signed-off-by: Niranjana Vishwanathapura Signed-off-by: Andi Shyti ---

Re: [PATCH 02/16] drm/i915/vm_bind: Add __i915_sw_fence_await_reservation()

2022-09-28 Thread Niranjana Vishwanathapura
On Wed, Sep 28, 2022 at 06:39:05PM +0100, Matthew Auld wrote: On 28/09/2022 07:19, Niranjana Vishwanathapura wrote: Add function __i915_sw_fence_await_reservation() for asynchronous wait on a dma-resv object with specified dma_resv_usage. This is required for async vma unbind with vm_bind.

Re: [PATCH 1/7] mm/memory.c: Fix race when faulting a device private page

2022-09-28 Thread Michael Ellerman
Alistair Popple writes: > Michael Ellerman writes: >> Alistair Popple writes: >>> When the CPU tries to access a device private page the migrate_to_ram() >>> callback associated with the pgmap for the page is called. However no >>> reference is taken on the faulting page. Therefore a concurrent

Bug in the VirtIO GPU driver since the RC7 of kernel 6.0

2022-09-28 Thread Christian Zigotzky
Hi All, I have found the issue. I cross compiled this kernel with GCC 11.2.0 on Ubuntu 22.04.1. I cross compiled the same kernel with GCC 9.4.0 again. This time on Ubuntu 20.04.5. KVM with the VirtIO GPU works with the GCC 9.4.0 compiled kernel. — Christian I wrote: Hello, Xorg doesn't

Re: [Intel-gfx] [PATCH v2] overflow: Introduce overflows_type() and castable_to_type()

2022-09-28 Thread kernel test robot
Hi Kees, I love your patch! Yet something to improve: [auto build test ERROR on kees/for-next/hardening] [also build test ERROR on next-20220928] [cannot apply to drm-tip/drm-tip drm-intel/for-linux-next drm-misc/drm-misc-next linus/master v6.0-rc7] [If your patch is applied to the wrong git

[PATCH v4 3/4] drm/i915: Make the heartbeat play nice with long pre-emption timeouts

2022-09-28 Thread John . C . Harrison
From: John Harrison Compute workloads are inherently not pre-emptible for long periods on current hardware. As a workaround for this, the pre-emption timeout for compute capable engines was disabled. This is undesirable with GuC submission as it prevents per engine reset of hung contexts. Hence

[PATCH v4 4/4] drm/i915: Improve long running compute w/a for GuC submission

2022-09-28 Thread John . C . Harrison
From: John Harrison A workaround was added to the driver to allow compute workloads to run 'forever' by disabling pre-emption on the RCS engine for Gen12. It is not totally unbound as the heartbeat will kick in eventually and cause a reset of the hung engine. However, this does not work well in

[PATCH v4 1/4] drm/i915/guc: Limit scheduling properties to avoid overflow

2022-09-28 Thread John . C . Harrison
From: John Harrison GuC converts the pre-emption timeout and timeslice quantum values into clock ticks internally. That significantly reduces the point of 32bit overflow. On current platforms, worst case scenario is approximately 110 seconds. Rather than allowing the user to set higher values

[PATCH v4 2/4] drm/i915: Fix compute pre-emption w/a to apply to compute engines

2022-09-28 Thread John . C . Harrison
From: John Harrison An earlier patch added support for compute engines. However, it missed enabling the anti-pre-emption w/a for the new engine class. So move the 'compute capable' flag earlier and use it for the pre-emption w/a test. Fixes: c674c5b9342e ("drm/i915/xehp: CCS should use RCS

[PATCH v4 0/4] Improve anti-pre-emption w/a for compute workloads

2022-09-28 Thread John . C . Harrison
From: John Harrison Compute workloads are inherently not pre-emptible on current hardware. Thus the pre-emption timeout was disabled as a workaround to prevent unwanted resets. Instead, the hang detection was left to the heartbeat and its (longer) timeout. This is undesirable with GuC submission

[PATCH v2 2/2] drm/panel: simple: Use dev_err_probe() to simplify code

2022-09-28 Thread Yuan Can
In the probe path, dev_err() can be replaced with dev_err_probe() which will check if error code is -EPROBE_DEFER and prints the error name. It also sets the defer probe reason which can be checked later through debugfs. Signed-off-by: Yuan Can Reviewed-by: Douglas Anderson ---

[PATCH v2 1/2] drm/panel: panel-edp: Use dev_err_probe() to simplify code

2022-09-28 Thread Yuan Can
In the probe path, dev_err() can be replaced with dev_err_probe() which will check if error code is -EPROBE_DEFER and prints the error name. It also sets the defer probe reason which can be checked later through debugfs. Signed-off-by: Yuan Can Reviewed-by: Douglas Anderson ---

[PATCH v2 0/2] drm/panel: Use dev_err_probe() to simplify code

2022-09-28 Thread Yuan Can
This series contains two patchs simplify the error handling in probe function by switching from dev_err() to dev_err_probe(). --- changes in v2: - simplify the same case in panel_edp_probe - add Reviewed-by from Douglas Anderson Yuan Can (2): drm/panel: panel-edp: Use dev_err_probe() to

Re: [PATCH 1/7] mm/memory.c: Fix race when faulting a device private page

2022-09-28 Thread Alistair Popple
Michael Ellerman writes: > Alistair Popple writes: >> When the CPU tries to access a device private page the migrate_to_ram() >> callback associated with the pgmap for the page is called. However no >> reference is taken on the faulting page. Therefore a concurrent >> migration of the device

[PATCH v2 0/2] *** IT6505 driver read dt properties ***

2022-09-28 Thread allen
From: allen chen This series let driver can read properties from dt to restrict dp output bandwidth. allen chen (2): dt-bindings: it6505: add properties to restrict output bandwidth drm/bridge: add it6505 driver to read data-lanes and max-pixel-clock-khz from dt

[PATCH v2 1/2] dt-bindings: it6505: add properties to restrict output bandwidth

2022-09-28 Thread allen
From: allen chen Add properties to restrict dp output data-lanes and clock. Signed-off-by: Pin-Yen Lin Signed-off-by: Allen Chen --- .../devicetree/bindings/display/bridge/ite,it6505.yaml | 10 ++ 1 file changed, 10 insertions(+) diff --git

[PATCH v2 2/2] drm/bridge: add it6505 driver to read data-lanes and max-pixel-clock-khz from dt

2022-09-28 Thread allen
From: allen chen Add driver to read data-lanes and max-pixel-clock-khz from dt property to restrict output bandwidth. Signed-off-by: Allen chen Signed-off-by: Pin-yen Lin --- drivers/gpu/drm/bridge/ite-it6505.c | 35 ++--- 1 file changed, 32 insertions(+), 3

[PATCH] drm/bridge: ps8640: Add software to support aux defer

2022-09-28 Thread Jason Yen
This chip can not handle aux defer if the host directly program its aux registers to access edid/dpcd. So we need let software to handle the aux defer situation. Signed-off-by: Jason Yen --- drivers/gpu/drm/bridge/parade-ps8640.c | 8 1 file changed, 8 insertions(+) diff --git

Re: [PATCH 10/10] drm/panel: simple: Use dev_err_probe() to simplify code

2022-09-28 Thread Yuan Can
在 2022/9/29 7:03, Doug Anderson 写道: Hi, On Fri, Sep 23, 2022 at 6:59 PM Yuan Can wrote: In the probe path, dev_err() can be replaced with dev_err_probe() which will check if error code is -EPROBE_DEFER and prints the error name. It also sets the defer probe reason which can be checked later

Re: [PATCH v2 3/7] firmware: raspberrypi: Provide a helper to query a clock max rate

2022-09-28 Thread Stephen Boyd
Quoting Maxime Ripard (2022-09-20 05:50:22) > The firmware allows to query for its clocks the operating range of a > given clock. We'll need this for some drivers (KMS, in particular) to > infer the state of some configuration options, so let's create a > function to do so. > > Signed-off-by:

Re: [PATCH 1/7] mm/memory.c: Fix race when faulting a device private page

2022-09-28 Thread Michael Ellerman
Alistair Popple writes: > When the CPU tries to access a device private page the migrate_to_ram() > callback associated with the pgmap for the page is called. However no > reference is taken on the faulting page. Therefore a concurrent > migration of the device private page can free the page and

[PATCH v6] drm/msm/dp: add atomic_check to bridge ops

2022-09-28 Thread Kuogee Hsieh
DRM commit_tails() will disable downstream crtc/encoder/bridge if both disable crtc is required and crtc->active is set before pushing a new frame downstream. There is a rare case that user space display manager issue an extra screen update immediately followed by close DRM device while down

Re: [PATCH 10/10] drm/panel: simple: Use dev_err_probe() to simplify code

2022-09-28 Thread Doug Anderson
Hi, On Fri, Sep 23, 2022 at 6:59 PM Yuan Can wrote: > > In the probe path, dev_err() can be replaced with dev_err_probe() > which will check if error code is -EPROBE_DEFER and prints the > error name. It also sets the defer probe reason which can be > checked later through debugfs. > >

Re: [PATCH 02/10] drm/panel: panel-edp: Use dev_err_probe() to simplify code

2022-09-28 Thread Doug Anderson
Hi, On Fri, Sep 23, 2022 at 6:58 PM Yuan Can wrote: > > In the probe path, dev_err() can be replaced with dev_err_probe() > which will check if error code is -EPROBE_DEFER and prints the > error name. It also sets the defer probe reason which can be > checked later through debugfs. > >

[PATCH v2 19/37] drm: xlnx: zynqmp_dpsub: Move pclk from zynqmp_disp to zynqmp_dpsub

2022-09-28 Thread Laurent Pinchart
The video clock is an external resource from the DPSUB point of view, not a resource internal to the display controller. Move it to the zynqmp_dpsub structure, to allow accessing it from outside the disp code. While at it, rename the fields from pclk and pclk_from_ps to vid_clk and

[PATCH v2 14/37] drm: xlnx: zynqmp_dpsub: Configure blender in zynqmp_disp_enable()

2022-09-28 Thread Laurent Pinchart
To prepare for control of the blender outside of the CRTC code, move the setup of the blender to the zynqmp_disp_enable() function. This doesn't introduce any functional change. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/xlnx/zynqmp_disp.c | 6 +++--- 1 file changed, 3 insertions(+), 3

[PATCH v2 36/37] arm64: dts: zynqmp: Add ports for the DisplayPort subsystem

2022-09-28 Thread Laurent Pinchart
The DPSUB DT bindings now specify ports to model the connections with the programmable logic and the DisplayPort output. Add them to the device tree. Signed-off-by: Laurent Pinchart --- arch/arm64/boot/dts/xilinx/zynqmp.dtsi | 24 1 file changed, 24 insertions(+) diff

[PATCH v2 21/37] drm: xlnx: zynqmp_dpsub: Move CRTC to zynqmp_dpsub structure

2022-09-28 Thread Laurent Pinchart
Decouple the zynqmp_disp, which handles the hardware configuration, from the DRM CRTC by moving the CRTC to the zynqmp_dpsub structure. The CRTC handling code will be moved to a separate file in a subsequent step. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/xlnx/zynqmp_disp.c | 20

[PATCH v2 04/37] drm: xlnx: zynqmp_dpsub: Create DRM bridge to model DP encoder

2022-09-28 Thread Laurent Pinchart
The DP encoder is currently modelled as a DRM encoder and DRM connector. This doesn't support system configurations where the DP encoder is driven by the FPGA programmable logic, using the live video input to the DP subsystem. To enable such use cases, we need to model the encoder as a DRM bridge.

[PATCH v2 34/37] drm: xlnx: zynqmp_dpsub: Support operation without DMA engine

2022-09-28 Thread Laurent Pinchart
To prepare for usage of the DPSUB as a DisplayPort bridge without creating a DRM device, make initialization and usage of the DMA engine optional. The flag that controls this feature is currently hardcoded to operating with the DMA engine, this will be made dynamic based on the device tree

[PATCH v2 26/37] drm: xlnx: zynqmp_dpsub: Register AUX bus at bridge attach time

2022-09-28 Thread Laurent Pinchart
To prepare for operating as a standalone DP bridge with the DRM device implemented in the PL, move registration of the AUX bus to bridge attach time, as that's the earliest point when a DRM device is available. The DRM device pointer stored in zynqmp_dp isn't used anymore, drop it.

[PATCH v2 31/37] drm: xlnx: zynqmp_dpsub: Rename zynqmp_dpsub_handle_vblank with DRM prefix

2022-09-28 Thread Laurent Pinchart
The better convey its purpose, rename the zynqmp_dpsub_handle_vblank() function that belongs to the DRM layer to zynqmp_dpsub_drm_handle_vblank(). Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/xlnx/zynqmp_dp.c | 2 +- drivers/gpu/drm/xlnx/zynqmp_kms.c | 4 ++--

[PATCH v2 37/37] arm64: dts: zynqmp: zcu106a: Describe DisplayPort connector

2022-09-28 Thread Laurent Pinchart
Add a device tree node to describe the DisplayPort connector, and connect it to the DPSUB output. Signed-off-by: Laurent Pinchart --- .../boot/dts/xilinx/zynqmp-zcu106-revA.dts| 20 +++ 1 file changed, 20 insertions(+) diff --git

[PATCH v2 27/37] drm: xlnx: zynqmp_dpsub: Move DP bridge init to zynqmp_dp_probe()

2022-09-28 Thread Laurent Pinchart
There's no need to delay bridge initialization, move it to zynqmp_dp_probe() and drop the zynqmp_dp_drm_init() function. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/xlnx/zynqmp_dp.c | 30 -- drivers/gpu/drm/xlnx/zynqmp_dp.h | 1 -

[PATCH v2 33/37] drm: xlnx: zynqmp_dpsub: Allow configuration of layer mode

2022-09-28 Thread Laurent Pinchart
Add a mode parameter to the zynqmp_disp_layer_enable() to set the layer mode, to prepare for live mode support. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/xlnx/zynqmp_disp.c | 30 +- drivers/gpu/drm/xlnx/zynqmp_disp.h | 13 -

[PATCH v2 30/37] drm: xlnx: zynqmp_dpsub: Decouple DRM device from zynqmp_dpsub

2022-09-28 Thread Laurent Pinchart
To complete the decoupling of the DRM device from the zynqmp_dpsub, group all DRM-related structures in a zynqmp_dpsub_drm structure and allocate it separately from the zynqmp_dpsub. The DRM managed allocation of the drm_device now doesn't cover the zynqmp_dpsub anymore, so we need to register a

[PATCH v2 16/37] drm: xlnx: zynqmp_dpsub: Pass format info to zynqmp_disp_layer_set_format()

2022-09-28 Thread Laurent Pinchart
The zynqmp_disp_layer_set_format() function only needs format information, not a full plane state. Get the necessary info from the plane state in the caller and pass it to zynqmp_disp_layer_set_format(). This prepares for calling the function from non-DRM code. This doesn't introduce any

[PATCH v2 17/37] drm: xlnx: zynqmp_dpsub: Remplace hardcoded values with ARRAY_SIZE()

2022-09-28 Thread Laurent Pinchart
Use the ARRAY_SIZE() macro to iterate over arrays, instead of hardcoding their size. This makes the code less error-prone should the array size change. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/xlnx/zynqmp_disp.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff

[PATCH v2 15/37] drm: xlnx: zynqmp_dpsub: Use local variable in zynqmp_disp_layer_update()

2022-09-28 Thread Laurent Pinchart
Reuse the local info variable instead of going through the layer pointer in zynqmp_disp_layer_update(). This doesn't introduce any functional change. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/xlnx/zynqmp_disp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[PATCH v2 23/37] drm: xlnx: zynqmp_dpsub: Move DRM/KMS initialization to separate file

2022-09-28 Thread Laurent Pinchart
Start preparation for using the DPSUB as a standalone DisplayPort encoder without a display controller by moving the DRM/KMS initialization to a new zynqmp_kms.c file. No functional change intended. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/xlnx/Makefile | 2 +-

[PATCH v2 25/37] drm: xlnx: zynqmp_dpsub: Move planes handling to zynqmp_kms.c

2022-09-28 Thread Laurent Pinchart
Decouple the planes handling from the display controller programming by moving the corresponding code from zynqmp_disp.c to zynqmp_kms.c. This prepares for using the DPSUB with a live video input, without creating DRM planes in the DPSUB driver. While at it, fix a typo in a comment.

[PATCH v2 22/37] drm: xlnx: zynqmp_dpsub: Move planes to zynqmp_dpsub structure

2022-09-28 Thread Laurent Pinchart
Decouple the zynqmp_disp, which handles the hardware configuration, from the DRM planes by moving the planes to the zynqmp_dpsub structure. The planes handling code will be moved to a separate file in a subsequent step. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/xlnx/zynqmp_disp.c |

[PATCH v2 32/37] drm: xlnx: zynqmp_dpsub: Parse DT to find connected ports

2022-09-28 Thread Laurent Pinchart
To prepare for live video input support, parse the device tree to find the connected ports. Warn about unsupported configurations, and error out when invalid. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/xlnx/zynqmp_dpsub.c | 54 +

[PATCH v2 12/37] drm: xlnx: zynqmp_dpsub: Drop unused zynqmp_disp_format.bus_fmt field

2022-09-28 Thread Laurent Pinchart
The bus_fmt field of the zynqmp_disp_format structure is unused. Drop it. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/xlnx/zynqmp_disp.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/gpu/drm/xlnx/zynqmp_disp.c b/drivers/gpu/drm/xlnx/zynqmp_disp.c index

[PATCH v2 35/37] drm: xlnx: zynqmp_dpsub: Add support for live video input

2022-09-28 Thread Laurent Pinchart
Add partial live video support, with a single video input that bypasses blending. Skip registration of the DRM device in that case, but register the DRM bridge instead. The DRM device will be created by the driver for the display controller in the PL. Full live video mode with concurrent usage of

[PATCH v2 29/37] drm: xlnx: zynqmp_dpsub: Move all DRM init and cleanup to zynqmp_kms.c

2022-09-28 Thread Laurent Pinchart
Continue the isolation of DRM/KMS code by moving all DRM init and cleanup from zynqmp_dpsub.c to zynqmp_kms.c. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/xlnx/zynqmp_dpsub.c | 117 +- drivers/gpu/drm/xlnx/zynqmp_dpsub.h | 5 --

[PATCH v2 07/37] drm: xlnx: zynqmp_dpsub: Move encoder to DPSUB core

2022-09-28 Thread Laurent Pinchart
As part of the transitition of the DP encoder to a DRM bridge, turn the DRM encoder into a dummy encoder and move it out of the DP code, to the DPSUB core. DP encoder operations are handled by the DP bridge, which is now attached to the encoder. Signed-off-by: Laurent Pinchart ---

[PATCH v2 18/37] drm: xlnx: zynqmp_dpsub: Don't use drmm_kcalloc() for temporary data

2022-09-28 Thread Laurent Pinchart
The array of formats passed to drm_universal_plane_init() doesn't need to outlive the function call, as it's copied internally. Use kcalloc() instead of drmm_kcalloc() to allocate it, and free it right after usage. While at it, move the allocation and initialization of the formats array to a

[PATCH v2 02/37] drm: xlnx: zynqmp_dpsub: Switch to atomic encoder enable/disable

2022-09-28 Thread Laurent Pinchart
To prepare for the transition to the DRM bridge API, switch the encoder operations to the atomic versions of .enable() and .disable(). This doesn't cause any functional change by itself. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/xlnx/zynqmp_dp.c | 10 ++ 1 file changed, 6

[PATCH v2 20/37] drm: xlnx: zynqmp_dpsub: Move audio clk from zynqmp_disp to zynqmp_dpsub

2022-09-28 Thread Laurent Pinchart
The audio clock is an external resource from the DPSUB point of view, not a resource internal to the display controller. Move it to the zynqmp_dpsub structure, to allow accessing it from outside the disp code. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/xlnx/zynqmp_disp.c | 54

[PATCH v2 09/37] drm: xlnx: zynqmp_dpsub: Use DRM connector bridge helper

2022-09-28 Thread Laurent Pinchart
Replace the manual connector implementation and registration in the DP encoder with the DRM connector bridge helper. This removes boilerplate code and simplifies the driver. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/xlnx/zynqmp_dp.c| 90 +

[PATCH v2 24/37] drm: xlnx: zynqmp_dpsub: Move CRTC handling to zynqmp_kms.c

2022-09-28 Thread Laurent Pinchart
Decouple the CRTC handling from the display controller programming by moving the corresponding code from zynqmp_disp.c to zynqmp_kms.c. This prepares for using the DPSUB with a live video input, without creating a DRM CRTC in the DPSUB driver. Signed-off-by: Laurent Pinchart ---

[PATCH v2 28/37] drm: xlnx: zynqmp_dpsub: Manage DP and DISP allocations manually

2022-09-28 Thread Laurent Pinchart
The zynqmp_disp and zynqmp_dp structures are allocated with drmm_kzalloc(). While this simplifies management of memory, it requires a DRM device, which will not be available at probe time when the DP bridge will be used standalone, with a DRM device in the PL. To prepare for this, switch to manual

[PATCH v2 06/37] drm: xlnx: zynqmp_dpsub: Move connector registration to bridge attach

2022-09-28 Thread Laurent Pinchart
Connector creation requires the DRM encoder, and it thus typically performed in the bridge attach operation. Move it there, to prepare for registration of the DRM bridge. For now the zynqmp_dp_bridge_attach() is called manually at initialization time. Signed-off-by: Laurent Pinchart ---

[PATCH v2 11/37] drm: xlnx: zynqmp_dpsub: Drop unused zynqmp_disp.event field

2022-09-28 Thread Laurent Pinchart
The event field of the zynqmp_disp structure is unused. Drop it. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/xlnx/zynqmp_disp.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/gpu/drm/xlnx/zynqmp_disp.c b/drivers/gpu/drm/xlnx/zynqmp_disp.c index cc32aa89cf8f..31b52f01c32d

[PATCH v2 08/37] drm: xlnx: zynqmp_dpsub: Attach to the next bridge

2022-09-28 Thread Laurent Pinchart
The next component in the display chain, after the DP encoder, is most likely a DP connector. The display connector driver registers a bridge for it. That bridge doesn't need to be controlled, but is needed in order to use the DRM connector bridge helper. Retrieve it at init time, and attach to it

[PATCH v2 13/37] drm: xlnx: zynqmp_dpsub: Don't pass CRTC to zynqmp_disp_setup_clock()

2022-09-28 Thread Laurent Pinchart
To prepare for usage of the clock setup function outside of the CRTC code, replace the DRM-specific structures passed as parameters with a pointer to the zynqmp_disp and the requested clock rate. This doesn't introduce any functional change. Signed-off-by: Laurent Pinchart ---

[PATCH v2 05/37] drm: xlnx: zynqmp_dpsub: Don't access connector in zynqmp_dp_set_format()

2022-09-28 Thread Laurent Pinchart
To prepare for the removal of the connector from the DP encoder, pass the display info pointer to the zynqmp_dp_set_format() function instead of accessing the connector internally. The display info is NULL when the function is called at initialization time, as we have no display info at that

[PATCH v2 10/37] drm: xlnx: zynqmp_dpsub: Report HPD through the bridge

2022-09-28 Thread Laurent Pinchart
Now that the driver uses the connector bridge helper, HPD can be reported directly for the connector through the drm_bridge_hpd_notify() function. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/xlnx/zynqmp_dp.c | 11 +-- 1 file changed, 5 insertions(+), 6 deletions(-) diff --git

[PATCH v2 03/37] drm: xlnx: zynqmp_dpsub: Constify mode argument to function

2022-09-28 Thread Laurent Pinchart
The zynqmp_dp_encoder_mode_set_transfer_unit() function takes a mode pointer argument that it doesn't need to modify. Make it const. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/xlnx/zynqmp_dp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[PATCH v2 00/37] drm: xlnx: zynqmp_dpsub: Initial live video input support

2022-09-28 Thread Laurent Pinchart
Hello, The DPSUB is the DisplayPort subsystem, a set of hard IP cores found in the ZynqMP family of SoCs. It combines a DisplayPort encoder, a video blender with two input channels, and a DMA engine. The zynqmp_dpsub driver exposes this as a DRM device with one CRTC and two planes. In addition

[PATCH v2 01/37] dt-bindings: display: xlnx: zynqmp-dpsub: Add OF graph ports

2022-09-28 Thread Laurent Pinchart
The DPSUB doesn't live in isolation, but is connected to the programmable logic for live inputs and outputs, and also has a DisplayPort output. Model all those using OF graph. Signed-off-by: Laurent Pinchart Reviewed-by: Rob Herring --- .../display/xlnx/xlnx,zynqmp-dpsub.yaml | 67

Re: [PATCH v2 01/16] slab: Remove __malloc attribute from realloc functions

2022-09-28 Thread Vlastimil Babka
On 9/28/22 19:13, Kees Cook wrote: On Wed, Sep 28, 2022 at 09:26:15AM +0200, Geert Uytterhoeven wrote: Hi Kees, On Fri, Sep 23, 2022 at 10:35 PM Kees Cook wrote: The __malloc attribute should not be applied to "realloc" functions, as the returned pointer may alias the storage of the prior

Re: [PATCH 6/7] nouveau/dmem: Evict device private memory during release

2022-09-28 Thread Lyude Paul
Re comments about infinite retry: gotcha, makes sense to me. On Tue, 2022-09-27 at 09:45 +1000, Alistair Popple wrote: > John Hubbard writes: > > > On 9/26/22 14:35, Lyude Paul wrote: > > > > + for (i = 0; i < npages; i++) { > > > > + if (src_pfns[i] & MIGRATE_PFN_MIGRATE) {

Re: [PATCH v2 7/8] nouveau/dmem: Evict device private memory during release

2022-09-28 Thread Lyude Paul
Reviewed-by: Lyude Paul On Wed, 2022-09-28 at 22:01 +1000, Alistair Popple wrote: > When the module is unloaded or a GPU is unbound from the module it is > possible for device private pages to still be mapped in currently > running processes. This can lead to a hangs and RCU stall warnings when

Re: [PATCH 6/7] nouveau/dmem: Evict device private memory during release

2022-09-28 Thread Lyude Paul
On Tue, 2022-09-27 at 11:39 +1000, Alistair Popple wrote: > Felix Kuehling writes: > > > On 2022-09-26 17:35, Lyude Paul wrote: > > > On Mon, 2022-09-26 at 16:03 +1000, Alistair Popple wrote: > > > > When the module is unloaded or a GPU is unbound from the module it is > > > > possible for

Re: [PATCH] drm/i915/gt: Perf_limit_reasons are only available for Gen11+

2022-09-28 Thread Rodrigo Vivi
On Wed, Sep 28, 2022 at 12:02:12PM -0700, Ashutosh Dixit wrote: > Register GT0_PERF_LIMIT_REASONS (0x1381a8) is available only for > Gen11+. Therefore ensure perf_limit_reasons sysfs files are created only > for Gen11+. Otherwise on Gen < 5 accessing these files results in the > following oops: >

Re: [Intel-gfx] [PATCH 05/16] drm/i915/vm_bind: Implement bind and unbind of object

2022-09-28 Thread Welty, Brian
On 9/27/2022 11:19 PM, Niranjana Vishwanathapura wrote: Add uapi and implement support for bind and unbind of an object at the specified GPU virtual addresses. The vm_bind mode is not supported in legacy execbuf2 ioctl. It will be supported only in the newer execbuf3 ioctl. Signed-off-by:

[RFC PATCH v5 0/6] Add DSS support for AM625 SoC

2022-09-28 Thread Aradhya Bhatia
This patch series adds a new compatible for the Display SubSyetem controller on TI's AM625 SoC. It further adds the required support for the same in the tidss driver. The AM625-DSS is a newer version of the DSS from the AM65X version with the major change being the addition of another OLDI TX.

[RFC PATCH v5 5/6] drm/tidss: Add IO CTRL and Power support for OLDI TX in am625

2022-09-28 Thread Aradhya Bhatia
The ctrl mmr module of the AM625 is different from the AM65X SoC. Thus the ctrl mmr registers that supported the OLDI TX power have become different in AM625 SoC. Add IO CTRL support and control the OLDI TX power for AM625. Signed-off-by: Aradhya Bhatia --- drivers/gpu/drm/tidss/tidss_dispc.c

[PATCH v6 11/21] misc: fastrpc: Prepare to dynamic dma-buf locking specification

2022-09-28 Thread Dmitry Osipenko
Prepare fastrpc to the common dynamic dma-buf locking convention by starting to use the unlocked versions of dma-buf API functions. Acked-by: Christian König Acked-by: Srinivas Kandagatla Signed-off-by: Dmitry Osipenko --- drivers/misc/fastrpc.c | 6 +++--- 1 file changed, 3 insertions(+), 3

[PATCH v6 10/21] RDMA/umem: Prepare to dynamic dma-buf locking specification

2022-09-28 Thread Dmitry Osipenko
Prepare InfiniBand drivers to the common dynamic dma-buf locking convention by starting to use the unlocked versions of dma-buf API functions. Acked-by: Christian König Signed-off-by: Dmitry Osipenko --- drivers/infiniband/core/umem_dmabuf.c | 7 --- 1 file changed, 4 insertions(+), 3

[PATCH v6 08/21] drm/tegra: Prepare to dynamic dma-buf locking specification

2022-09-28 Thread Dmitry Osipenko
Prepare Tegra DRM driver to the common dynamic dma-buf locking convention by starting to use the unlocked versions of dma-buf API functions. Acked-by: Christian König Signed-off-by: Dmitry Osipenko --- drivers/gpu/drm/tegra/gem.c | 17 + 1 file changed, 9 insertions(+), 8

[PATCH v6 18/21] dma-buf: Move dma_buf_mmap() to dynamic locking specification

2022-09-28 Thread Dmitry Osipenko
Move dma_buf_mmap() function to the dynamic locking specification by taking the reservation lock. Neither of the today's drivers take the reservation lock within the mmap() callback, hence it's safe to enforce the locking. Acked-by: Sumit Semwal Acked-by: Christian König Signed-off-by: Dmitry

[PATCH v6 16/21] dma-buf: Move dma_buf_attach() to dynamic locking specification

2022-09-28 Thread Dmitry Osipenko
Move dma-buf attachment API functions to the dynamic locking specification by taking the reservation lock around the mapping operations. The strict locking convention prevents deadlock situations for dma-buf importers and exporters. Acked-by: Sumit Semwal Reviewed-by: Christian König

[PATCH v6 19/21] dma-buf: Document dynamic locking convention

2022-09-28 Thread Dmitry Osipenko
Add documentation for the dynamic locking convention. The documentation tells dma-buf API users when they should take the reservation lock and when not. Acked-by: Sumit Semwal Reviewed-by: Christian König Signed-off-by: Dmitry Osipenko --- Documentation/driver-api/dma-buf.rst | 6 +++

[PATCH v6 14/21] media: tegra-vde: Prepare to dynamic dma-buf locking specification

2022-09-28 Thread Dmitry Osipenko
Prepare Tegra video decoder driver to the common dynamic dma-buf locking convention by starting to use the unlocked versions of dma-buf API functions. Acked-by: Christian König Signed-off-by: Dmitry Osipenko --- drivers/media/platform/nvidia/tegra-vde/dmabuf-cache.c | 6 +++--- 1 file changed,

[PATCH v6 15/21] dma-buf: Move dma_buf_vmap() to dynamic locking specification

2022-09-28 Thread Dmitry Osipenko
Move dma_buf_vmap/vunmap() functions to the dynamic locking specification by asserting that the reservation lock is held. Acked-by: Sumit Semwal Acked-by: Christian König Signed-off-by: Dmitry Osipenko --- drivers/dma-buf/dma-buf.c | 4 1 file changed, 4 insertions(+) diff --git

[PATCH v6 20/21] media: videobuf2: Stop using internal dma-buf lock

2022-09-28 Thread Dmitry Osipenko
All drivers that use dma-bufs have been moved to the updated locking specification and now dma-buf reservation is guaranteed to be locked by importers during the mapping operations. There is no need to take the internal dma-buf lock anymore. Remove locking from the videobuf2 memory allocators.

[PATCH v6 17/21] dma-buf: Move dma_buf_map_attachment() to dynamic locking specification

2022-09-28 Thread Dmitry Osipenko
Move dma-buf attachment mapping functions to the dynamic locking specification by asserting that the reservation lock is held. Acked-by: Sumit Semwal Reviewed-by: Christian König Signed-off-by: Dmitry Osipenko --- drivers/dma-buf/dma-buf.c | 10 ++ 1 file changed, 2 insertions(+), 8

[PATCH v6 21/21] dma-buf: Remove obsoleted internal lock

2022-09-28 Thread Dmitry Osipenko
The internal dma-buf lock isn't needed anymore because the updated locking specification claims that dma-buf reservation must be locked by importers, and thus, the internal data is already protected by the reservation lock. Remove the obsoleted internal lock. Acked-by: Sumit Semwal Acked-by:

[PATCH v6 13/21] media: videobuf2: Prepare to dynamic dma-buf locking specification

2022-09-28 Thread Dmitry Osipenko
Prepare V4L2 memory allocators to the common dynamic dma-buf locking convention by starting to use the unlocked versions of dma-buf API functions. Acked-by: Tomasz Figa Acked-by: Christian König Signed-off-by: Dmitry Osipenko --- drivers/media/common/videobuf2/videobuf2-dma-contig.c | 11

[PATCH v6 05/21] drm/armada: Prepare to dynamic dma-buf locking specification

2022-09-28 Thread Dmitry Osipenko
Prepare Armada driver to the common dynamic dma-buf locking convention by starting to use the unlocked versions of dma-buf API functions. Acked-by: Christian König Signed-off-by: Dmitry Osipenko --- drivers/gpu/drm/armada/armada_gem.c | 8 1 file changed, 4 insertions(+), 4

[PATCH v6 12/21] xen/gntdev: Prepare to dynamic dma-buf locking specification

2022-09-28 Thread Dmitry Osipenko
Prepare gntdev driver to the common dynamic dma-buf locking convention by starting to use the unlocked versions of dma-buf API functions. Acked-by: Juergen Gross Acked-by: Christian König Signed-off-by: Dmitry Osipenko --- drivers/xen/gntdev-dmabuf.c | 8 1 file changed, 4

[PATCH v6 09/21] drm/etnaviv: Prepare to dynamic dma-buf locking specification

2022-09-28 Thread Dmitry Osipenko
Prepare Etnaviv driver to the common dynamic dma-buf locking convention by starting to use the unlocked versions of dma-buf API functions. Acked-by: Christian König Signed-off-by: Dmitry Osipenko --- drivers/gpu/drm/etnaviv/etnaviv_gem_prime.c | 2 +- 1 file changed, 1 insertion(+), 1

[PATCH v6 07/21] drm/omapdrm: Prepare to dynamic dma-buf locking specification

2022-09-28 Thread Dmitry Osipenko
Prepare OMAP DRM driver to the common dynamic dma-buf locking convention by starting to use the unlocked versions of dma-buf API functions. Acked-by: Christian König Signed-off-by: Dmitry Osipenko --- drivers/gpu/drm/omapdrm/omap_gem_dmabuf.c | 4 ++-- 1 file changed, 2 insertions(+), 2

[PATCH v6 03/21] drm/gem: Take reservation lock for vmap/vunmap operations

2022-09-28 Thread Dmitry Osipenko
The new common dma-buf locking convention will require buffer importers to hold the reservation lock around mapping operations. Make DRM GEM core to take the lock around the vmapping operations and update DRM drivers to use the locked functions for the case where DRM core now holds the lock. This

[PATCH v6 06/21] drm/i915: Prepare to dynamic dma-buf locking specification

2022-09-28 Thread Dmitry Osipenko
Prepare i915 driver to the common dynamic dma-buf locking convention by starting to use the unlocked versions of dma-buf API functions and handling cases where importer now holds the reservation lock. Acked-by: Christian König Reviewed-by: Michael J. Ruhl Signed-off-by: Dmitry Osipenko ---

[PATCH v6 01/21] dma-buf: Add unlocked variant of vmapping functions

2022-09-28 Thread Dmitry Osipenko
Add unlocked variant of dma_buf_vmap/vunmap() that will be utilized by drivers that don't take the reservation lock explicitly. Acked-by: Sumit Semwal Acked-by: Christian König Signed-off-by: Dmitry Osipenko --- drivers/dma-buf/dma-buf.c | 41 +++

[PATCH v6 04/21] drm/prime: Prepare to dynamic dma-buf locking specification

2022-09-28 Thread Dmitry Osipenko
Prepare DRM prime core to the common dynamic dma-buf locking convention by starting to use the unlocked versions of dma-buf API functions. Reviewed-by: Christian König Signed-off-by: Dmitry Osipenko --- drivers/gpu/drm/drm_prime.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)

[PATCH v6 02/21] dma-buf: Add unlocked variant of attachment-mapping functions

2022-09-28 Thread Dmitry Osipenko
Add unlocked variant of dma_buf_map/unmap_attachment() that will be used by drivers that don't take the reservation lock explicitly. Acked-by: Sumit Semwal Acked-by: Christian König Signed-off-by: Dmitry Osipenko --- drivers/dma-buf/dma-buf.c | 53 +++

[PATCH v6 00/21] Move all drivers to a common dma-buf locking convention

2022-09-28 Thread Dmitry Osipenko
Hello, This series moves all drivers to a dynamic dma-buf locking specification. >From now on all dma-buf importers are made responsible for holding dma-buf's reservation lock around all operations performed over dma-bufs in accordance to the locking specification. This allows us to utilize

Re: [PATCH v5] drm/sched: Add FIFO sched policy to run queue

2022-09-28 Thread Luben Tuikov
Inlined: On 2022-09-28 14:49, Andrey Grodzovsky wrote: > When many entities are competing for the same run queue > on the same scheduler, we observe an unusually long wait > times and some jobs get starved. This has been observed on GPUVis. > > The issue is due to the Round Robin policy used by

Re: [Intel-gfx] [PATCH] drm/i915: Perf_limit_reasons are only available for Gen11+

2022-09-28 Thread Dixit, Ashutosh
On Wed, 28 Sep 2022 11:35:18 -0700, Rodrigo Vivi wrote: > > On Wed, Sep 28, 2022 at 11:17:06AM -0700, Dixit, Ashutosh wrote: > > On Wed, 28 Sep 2022 04:38:46 -0700, Jani Nikula wrote: > > > > > > On Mon, 19 Sep 2022, Ashutosh Dixit wrote: > > > > Register GT0_PERF_LIMIT_REASONS (0x1381a8) is

[PATCH] drm/i915/gt: Perf_limit_reasons are only available for Gen11+

2022-09-28 Thread Ashutosh Dixit
Register GT0_PERF_LIMIT_REASONS (0x1381a8) is available only for Gen11+. Therefore ensure perf_limit_reasons sysfs files are created only for Gen11+. Otherwise on Gen < 5 accessing these files results in the following oops: <1> [88.829420] BUG: unable to handle page fault for address:

[PATCH v5] drm/sched: Add FIFO sched policy to run queue

2022-09-28 Thread Andrey Grodzovsky
When many entities are competing for the same run queue on the same scheduler, we observe an unusually long wait times and some jobs get starved. This has been observed on GPUVis. The issue is due to the Round Robin policy used by schedulers to pick up the next entity's job queue for execution.

[RFC PATCH v5 3/6] drm/tidss: Add support for AM625 DSS

2022-09-28 Thread Aradhya Bhatia
Add support for the DSS controller on TI's new AM625 SoC in the tidss driver. The first video port (VP0) in am625-dss can output OLDI signals through 2 OLDI TXes. A 3rd port has been added with "DISPC_VP_OLDI" bus type. Signed-off-by: Aradhya Bhatia --- drivers/gpu/drm/tidss/tidss_dispc.c | 61

  1   2   3   >