[PATCH v2] media: mtk-vcodec: Align width and height to 64 bytes

2021-11-02 Thread Yunfei Dong
Width and height need to 64 bytes aligned when setting the format. Need to make sure all is 64 bytes align when use width and height to calculate buffer size. Signed-off-by: Yunfei Dong Change-Id: I39886b1a6b433c92565ddbf297eb193456eec1d2 --- drivers/media/platform/mtk-vcodec/mtk_vcodec_dec.h

Re: [PATCH v1] media: mtk-vcodec: Align width and height to 64

2021-11-02 Thread yunfei.d...@mediatek.com
Hi steve, Thanks for your suggestion.On Tue, 2021-11-02 at 09:43 -0700, Steve Cho wrote: > Thank you Yunfei for following up with this change. > This change is the last missing piece to enable VD on Kukui with > Chromium. > This patch fixed the corruption we were seeing on Kukui with certain > te

[Bug 214921] New: amdgpu hangs HP Laptop on shutdown

2021-11-02 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=214921 Bug ID: 214921 Summary: amdgpu hangs HP Laptop on shutdown Product: Drivers Version: 2.5 Kernel Version: 5.15 Hardware: All OS: Linux Tree: Mainline

Re: [PATCH -V2] drm/sun4i: Grab reference of connector before return connector from sun4i_tcon_get_connector

2021-11-02 Thread He Ying
在 2021/11/2 23:03, Maxime Ripard 写道: Hi, On Tue, Nov 02, 2021 at 04:46:28AM -0400, He Ying wrote: From the comments of drm_for_each_connector_iter(), we know that "connector is only valid within the list body, if you want to use connector after calling drm_connector_list_iter_end() then you

[Bug 214859] drm-amdgpu-init-iommu~fd-device-init.patch introduce bug

2021-11-02 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=214859 James Zhu (jam...@amd.com) changed: What|Removed |Added CC||jam...@amd.com --- Comment #

Re: [git pull] drm for 5.16-rc1

2021-11-02 Thread pr-tracker-bot
The pull request you sent on Wed, 3 Nov 2021 09:34:23 +1000: > git://anongit.freedesktop.org/drm/drm tags/drm-next-2021-11-03 has been merged into torvalds/linux.git: https://git.kernel.org/torvalds/c/56d33754481fe0dc7436dc4ee4fbd44b3039361d Thank you! -- Deet-doot-dot, I am a bot. https://kor

Re: [Intel-gfx] [PATCH v2 2/2] drm/i915/uapi: Add query for hwconfig table

2021-11-02 Thread John Harrison
On 11/1/2021 08:39, Jordan Justen wrote: writes: From: Rodrigo Vivi GuC contains a consolidated table with a bunch of information about the current device. Previously, this information was spread and hardcoded to all the components including GuC, i915 and various UMDs. The goal here is to c

Re: [PATCH v7 15/20] drm/mediatek: add display merge mute/unmute support for MT8195

2021-11-02 Thread Chun-Kuang Hu
Hi, Nancy: Nancy.Lin 於 2021年10月29日 週五 下午3:52寫道: > > Add merge mute/unmute setting for MT8195. > MT8195 Vdosys1 merge1~merge4 support HW mute function. Reviewed-by: Chun-Kuang Hu > > Signed-off-by: Nancy.Lin > --- > drivers/gpu/drm/mediatek/mtk_disp_merge.c | 23 ++- > 1 f

Re: [PATCH v7 14/20] drm/mediatek: add display merge start/stop API for cmdq support

2021-11-02 Thread Chun-Kuang Hu
Hi, Nancy: Nancy.Lin 於 2021年10月29日 週五 下午3:52寫道: > > Add merge start/stop API for cmdq support. The ovl_adaptor merges > are configured with each drm plane update. Need to enable/disable > merge with cmdq making sure all the settings taken effect in the > same vblank. Reviewed-by: Chun-Kuang Hu

Re: [PATCH v7 13/20] drm/mediatek: add display merge advance config API for MT8195

2021-11-02 Thread Chun-Kuang Hu
Hi, Nancy: Nancy.Lin 於 2021年10月29日 週五 下午3:52寫道: > > Add merge new advance config API. The original merge API is > mtk_ddp_comp_funcs function prototype. The API interface parameters > cannot be modified, so add a new config API for extension. This is > the preparation for ovl_adaptor merge contro

Re: [PATCH v7 12/20] drm/mediatek: add display MDP RDMA support for MT8195

2021-11-02 Thread Chun-Kuang Hu
Hi, Nancy: Nancy.Lin 於 2021年10月29日 週五 下午3:52寫道: > > Add MDP_RDMA driver for MT8195. MDP_RDMA is the DMA engine of > the ovl_adaptor component. Reviewed-by: Chun-Kuang Hu > > Signed-off-by: Nancy.Lin > --- > drivers/gpu/drm/mediatek/Makefile | 3 +- > drivers/gpu/drm/mediatek/mtk_disp

[PATCH v2 3/3] backlight: lp855x: Add support ACPI enumeration

2021-11-02 Thread Hans de Goede
The Xiaomi Mi Pad 2 tablet uses an ACPI enumerated LP8556 backlight controller for its LCD-panel, with a Xiaomi specific ACPI HID of "XMCC0001", add support for this. Note the new "if (id)" check also fixes a NULL pointer deref when a user tries to manually bind the driver from sysfs. When CONFIG

[PATCH v2 1/3] backlight: lp855x: Move device_config setting out of lp855x_configure()

2021-11-02 Thread Hans de Goede
Move the setting of the lp->cfg pointer to the chip specific lp855x_device_config struct from lp855x_configure() to lp855x_probe(), before calling lp855x_parse_dt(). This is a preperation patch for adding ACPI enumeration support. Reviewed-by: Daniel Thompson Signed-off-by: Hans de Goede --- d

[PATCH v2 2/3] backlight: lp855x: Add dev helper variable to lp855x_probe()

2021-11-02 Thread Hans de Goede
Add a dev local variable to the lp855x_probe(), to replace "&cl->dev" and "lp->dev" in various places. Also switch to dev_err_probe() in one case which takes care of not printing -EPROBE_DEFER errors for us. This is mostly a preparation for adding ACPI enumeration support which will use the new "

Re: [PATCH 3/3] backlight: lp855x: Add support ACPI enumeration

2021-11-02 Thread Hans de Goede
Hi Daniel, Thank you for the quick review of this series. On 11/2/21 13:22, Daniel Thompson wrote: > On Mon, Nov 01, 2021 at 07:55:17PM +0100, Hans de Goede wrote: >> The Xiaomi Mi Pad 2 tablet uses an ACPI enumerated LP8556 backlight >> controller for its LCD-panel, with a Xiaomi specific ACPI H

Re: [PATCH 2/4] drm/dp_mst: Only create connector for connected end device

2021-11-02 Thread Lyude Paul
On Fri, 2021-10-29 at 12:11 +, Lin, Wayne wrote: > [Public] > > Thanks Lyude for patiently guiding on this : ) > Would like to learn more as following I do follow your bit about connectors only being created when a virtual path is instantiated, but that still doesn't follow how connectors in

[PATCH 0/3] i915: Initial workarounds for Xe_HP SDV and DG2

2021-11-02 Thread Matt Roper
This is the initial batch of workarounds for these two platforms. There are still more workarounds to come in the future (e.g., related to other functionality that hasn't landed yet like compute engines, multi-tile, etc.). Matt Roper (2): drm/i915/dg2: Add initial gt/ctx/engine workarounds d

[PATCH 2/3] drm/i915/dg2: Add initial gt/ctx/engine workarounds

2021-11-02 Thread Matt Roper
Bspec: 54077,68173,54833 Cc: Anusha Srivatsa Signed-off-by: Matt Roper --- drivers/gpu/drm/i915/gt/intel_workarounds.c | 278 +++- drivers/gpu/drm/i915/i915_reg.h | 94 +-- drivers/gpu/drm/i915/intel_pm.c | 21 +- 3 files changed, 372 insertions(+),

[PATCH 1/3] drm/i915/xehpsdv: Add initial workarounds

2021-11-02 Thread Matt Roper
From: Stuart Summers Add the initial set of workarounds for Xe_HP SDV. There are some additional workarounds specific to the compute engines that we're holding back for now. Those will be added later, after general compute engine support lands. Cc: Lucas De Marchi Signed-off-by: Stuart Summer

[PATCH 3/3] drm/i915/dg2: Program recommended HW settings

2021-11-02 Thread Matt Roper
The bspec's performance guide suggests programming specific values into a few registers for optimal performance. Although these aren't workarounds, it's easiest to handle them inside the GT workaround functions (which will also ensure that the values set here are properly melded with other bits in

[PATCH] drm/msm/dp: employ bridge mechanism for display enable and disable

2021-11-02 Thread Kuogee Hsieh
Current display mode_set, enable and disable functions are implemented as function called directly from drm encoder. This patch have display mode_set, enable and disable be implemented as callback function of drm bridge. Signed-off-by: Kuogee Hsieh --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c

Re: [PATCH] backlight: led_bl: Add support for an "enable" GPIO

2021-11-02 Thread LABBE Corentin
Le Tue, Nov 02, 2021 at 11:25:14AM +, Daniel Thompson a écrit : > On Tue, Nov 02, 2021 at 11:19:42AM +, Daniel Thompson wrote: > > On Tue, Nov 02, 2021 at 10:04:55AM +, Corentin LABBE wrote: > > > From: Jean-Jacques Hiblot > > > > > > This patch adds support for an "enable GPIO". > >

Re: [Intel-gfx] [PATCH v3 05/10] drm/i915: Prepare for multiple gts

2021-11-02 Thread Andi Shyti
Hi Tvrtko, > > > > [...] > > > > > > > > >static int > > > > >intel_gt_tile_setup(struct intel_gt *gt, unsigned int id, > > > > > phys_addr_t phys_addr) > > > > > > > > we don't actually need 'id', it's gt->info.id. It's introduced in > > > > patch 3 with the value '0' but it's not need

[Bug 214859] drm-amdgpu-init-iommu~fd-device-init.patch introduce bug

2021-11-02 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=214859 Alex Deucher (alexdeuc...@gmail.com) changed: What|Removed |Added CC||alexdeuc...@gmail.c

[Bug 214901] amdgpu freezes HP laptop at start up

2021-11-02 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=214901 spassw...@web.de changed: What|Removed |Added Regression|No |Yes -- You may reply to this email to

Re: [PATCH v3 2/2] drm/i915/ttm: Failsafe migration blits

2021-11-02 Thread Matthew Auld
On Tue, 2 Nov 2021 at 17:55, Thomas Hellström wrote: > > > On 11/2/21 18:40, Matthew Auld wrote: > > On Tue, 2 Nov 2021 at 16:39, Thomas Hellström > > wrote: > >> If the initial fill blit or copy blit of an object fails, the old > >> content of the data might be exposed and read as soon as either

Re: [PATCH] drm/amd/display: remove unnecessary conditional operators

2021-11-02 Thread Alex Deucher
Applied. Thanks! Alex On Tue, Nov 2, 2021 at 4:58 AM Simon Ser wrote: > > Reviewed-by: Simon Ser

[Bug 204987] fault in amdgpu_dm_atomic_commit_tail on Vega64 with compton and redshift

2021-11-02 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=204987 Frank Steinborn (stei...@nognu.de) changed: What|Removed |Added Status|NEW |RESOLVED Res

Re: [PATCH v3 2/2] drm/i915/ttm: Failsafe migration blits

2021-11-02 Thread Thomas Hellström
On 11/2/21 18:40, Matthew Auld wrote: On Tue, 2 Nov 2021 at 16:39, Thomas Hellström wrote: If the initial fill blit or copy blit of an object fails, the old content of the data might be exposed and read as soon as either CPU- or GPU PTEs are set up to point at the pages. Intercept the blit f

Re: [PATCH 01/13] drm/connector: Add define for HDMI 1.4 Maximum Pixel Rate

2021-11-02 Thread Alex Deucher
On Tue, Nov 2, 2021 at 10:59 AM Maxime Ripard wrote: > > A lot of drivers open-code the HDMI 1.4 maximum pixel rate in their > driver to test whether the resolutions are supported or if the > scrambling needs to be enabled. > > Let's create a common define for everyone to use it. > > Cc: Alex Deuc

Re: [PATCH v3 2/2] drm/i915/ttm: Failsafe migration blits

2021-11-02 Thread Matthew Auld
On Tue, 2 Nov 2021 at 16:39, Thomas Hellström wrote: > > If the initial fill blit or copy blit of an object fails, the old > content of the data might be exposed and read as soon as either CPU- or > GPU PTEs are set up to point at the pages. > > Intercept the blit fence with an async callback that

Re: [PATCH v8 01/10] drm/vc4: hdmi: Remove the DDC probing for status detection

2021-11-02 Thread Dave Stevenson
On Mon, 25 Oct 2021 at 16:29, Maxime Ripard wrote: > > Commit 9d44a8d5 ("drm/vc4: Fall back to using an EDID probe in the > absence of a GPIO.") added some code to read the EDID through DDC in the > HDMI driver detect hook since the Pi3 had no HPD GPIO back then. > However, commit b1b8f45b3130

Re: [PATCH v8 10/10] drm/vc4: Increase the core clock based on HVS load

2021-11-02 Thread Dave Stevenson
On Mon, 25 Oct 2021 at 16:29, Maxime Ripard wrote: > > Depending on a given HVS output (HVS to PixelValves) and input (planes > attached to a channel) load, the HVS needs for the core clock to be > raised above its boot time default. > > Failing to do so will result in a vblank timeout and a stall

Re: [PATCH v8 09/10] drm/vc4: hdmi: Enable the scrambler on reconnection

2021-11-02 Thread Dave Stevenson
On Mon, 25 Oct 2021 at 16:29, Maxime Ripard wrote: > > If we have a state already and disconnect/reconnect the display, the > SCDC messages won't be sent again since we didn't go through a disable / > enable cycle. > > In order to fix this, let's call the vc4_hdmi_enable_scrambling function > in t

Re: [PATCH v8 07/10] drm/vc4: Leverage the load tracker on the BCM2711

2021-11-02 Thread Dave Stevenson
On Mon, 25 Oct 2021 at 16:29, Maxime Ripard wrote: > > The load tracker was initially designed to report and warn about a load > too high for the HVS. To do so, it computes for each plane the impact > it's going to have on the HVS, and will warn (if it's enabled) if we go > over what the hardware

Re: [PATCH 29/29] drm/i915/gvt: merge gvt.c into kvmgvt.c

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:06:01AM +0100, Christoph Hellwig wrote: > The code in both files is deeply interconnected, so merge it and > keep a bunch of structures and functions static. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/Makefile| 1 - > drivers/gpu/drm/i915/g

Re: [PATCH 28/29] drm/i915/gvt: convert to use vfio_register_group_dev()

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:06:00AM +0100, Christoph Hellwig wrote: > This is straightforward conversion, the intel_vgpu already has a pointer > to the vfio_dev, which can be replaced with the embedded structure and > we can replace all the mdev_get_drvdata() with a simple container_of(). This shou

[PATCH v3 2/2] drm/i915/ttm: Failsafe migration blits

2021-11-02 Thread Thomas Hellström
If the initial fill blit or copy blit of an object fails, the old content of the data might be exposed and read as soon as either CPU- or GPU PTEs are set up to point at the pages. Intercept the blit fence with an async callback that checks the blit fence for errors and if there are errors perform

[PATCH v3 0/2] drm/i915: Failsafe migration blits

2021-11-02 Thread Thomas Hellström
This patch series introduces failsafe migration blits. The reason for this seemingly strange concept is that if the initial clearing or readback of LMEM fails for some reason[1], and we then set up either GPU- or CPU ptes to the allocated LMEM, we can expose old contents from other clients. So aft

[PATCH v3 1/2] drm/i915/ttm: Reorganize the ttm move code

2021-11-02 Thread Thomas Hellström
We are about to introduce failsafe- and asynchronous migration and ttm moves. This will add complexity and code to the TTM move code so it makes sense to split it out to a separate file to make the i915 TTM code easer to digest. Split the i915 TTM move code out and since we will have to change the

Re: [PATCH 27/29] drm/i915/gvt: remove kvmgt_guest_{init,exit}

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:59AM +0100, Christoph Hellwig wrote: > Merge these into their only callers. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/gvt/kvmgt.c | 129 ++- > 1 file changed, 60 insertions(+), 69 deletions(-) Reviewed-by: Jason G

Re: [PATCH v8 06/10] drm/vc4: crtc: Add some logging

2021-11-02 Thread Dave Stevenson
On Mon, 25 Oct 2021 at 16:29, Maxime Ripard wrote: > > The encoder retrieval code has been a source of bugs and glitches in the > past and the crtc <-> encoder association been wrong in a number of > different ways. > > Add some logging to quickly spot issues if they occur. > > Signed-off-by: Maxi

Re: [PATCH v8 05/10] drm/vc4: crtc: Rework the encoder retrieval code (again)

2021-11-02 Thread Dave Stevenson
On Mon, 25 Oct 2021 at 16:29, Maxime Ripard wrote: > > It turns out the encoder retrieval code, in addition to being > unnecessarily complicated, has a bug when only the planes and crtcs are > affected by a given atomic commit. > > Indeed, in such a case, either drm_atomic_get_old_connector_state

Re: [PATCH v8 04/10] drm/vc4: crtc: Add encoder to vc4_crtc_config_pv prototype

2021-11-02 Thread Dave Stevenson
On Mon, 25 Oct 2021 at 16:29, Maxime Ripard wrote: > > vc4_crtc_config_pv() retrieves the encoder again, even though its only > caller, vc4_crtc_atomic_enable(), already did. > > Pass the encoder pointer as an argument instead of going through all the > connectors to retrieve it again. > > Signed-

Re: [PATCH v8 03/10] drm/vc4: Make vc4_crtc_get_encoder public

2021-11-02 Thread Dave Stevenson
On Mon, 25 Oct 2021 at 16:29, Maxime Ripard wrote: > > We'll need that function in vc4_kms to compute the core clock rate > requirements. > > Signed-off-by: Maxime Ripard Reviewed-by: Dave Stevenson > --- > drivers/gpu/drm/vc4/vc4_crtc.c | 8 > drivers/gpu/drm/vc4/vc4_drv.h | 5

Re: [PATCH 26/29] drm/i915/gvt: pass a struct intel_vgpu to the vfio read/write helpers

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:58AM +0100, Christoph Hellwig wrote: > Pass the structure we actually care about instead of deriving it from > the mdev_device in the lower level code. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/gvt/kvmgt.c | 28 ++-- >

Re: [PATCH 25/29] drm/i915/gvt: streamline intel_vgpu_create

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:57AM +0100, Christoph Hellwig wrote: > Initialize variables at declaration time, avoid pointless gotos and > cater for the fact that intel_gvt_create_vgpu can't return NULL. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/gvt/kvmgt.c | 28 +

Re: [PATCH 24/29] drm/i915/gvt: remove the extra vfio_device refcounting for dmabufs

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:56AM +0100, Christoph Hellwig wrote: > All the dmabufs are torn down when th VGPU is released, so there is > no need for extra refcounting here. > > Based on an patch from Jason Gunthorpe. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/gvt/dmabuf

Re: [PATCH 23/29] drm/i915/gvt: remove struct intel_gvt_mpt

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:55AM +0100, Christoph Hellwig wrote: > Just call the initializion and exit functions directly and remove > this abstraction entirely. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/gvt/gvt.c | 11 - > drivers/gpu/drm/i915/gvt/gvt.h

Re: [PATCH 22/29] drm/i915/gvt: devirtualize dma_pin_guest_page

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:54AM +0100, Christoph Hellwig wrote: > Just call the function directly and remove a pointless wrapper. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/gvt/dmabuf.c| 14 +- > drivers/gpu/drm/i915/gvt/gvt.h | 1 + > drivers/gpu

Re: [PATCH 21/29] drm/i915/gvt: devirtualize ->dma_{,un}map_guest_page

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:53AM +0100, Christoph Hellwig wrote: > Just call the functions directly. Also remove a pointless wrapper. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/gvt/dmabuf.c| 10 ++ > drivers/gpu/drm/i915/gvt/gtt.c | 20 +---

Re: [PATCH v8 02/10] drm/vc4: hdmi: Fix HPD GPIO detection

2021-11-02 Thread Dave Stevenson
On Mon, 25 Oct 2021 at 16:29, Maxime Ripard wrote: > > Prior to commit 6800234ceee0 ("drm/vc4: hdmi: Convert to gpiod"), in the > detect hook, if we had an HPD GPIO we would only rely on it and return > whatever state it was in. > > However, that commit changed that by mistake to only consider the

Re: [PATCH 20/29] drm/i915/gvt: devirtualize ->{enable,disable}_page_track

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:52AM +0100, Christoph Hellwig wrote: > Just call the kvmgt functions directly. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/gvt/gvt.h| 3 +++ > drivers/gpu/drm/i915/gvt/hypercall.h | 2 -- > drivers/gpu/drm/i915/gvt/kvmgt.c | 6

Re: [PATCH 19/29] drm/i915/gvt: devirtualize ->gfn_to_mfn

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:51AM +0100, Christoph Hellwig wrote: > Just open code it in the only caller. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/gvt/gtt.c | 9 + > drivers/gpu/drm/i915/gvt/hypercall.h | 1 - > drivers/gpu/drm/i915/gvt/kvmgt.c | 16

Re: [PATCH 18/29] drm/i915/gvt: devirtualize ->is_valid_gfn

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:50AM +0100, Christoph Hellwig wrote: > Just call the code directly and move towards the callers. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/gvt/gtt.c | 20 ++-- > drivers/gpu/drm/i915/gvt/hypercall.h | 1 - > drivers/gpu

Re: [Intel-gfx] [PATCH 11/28] drm/i915/pm: Move CONTEXT_VALID_BIT check

2021-11-02 Thread Matthew Auld
On Thu, 21 Oct 2021 at 11:37, Maarten Lankhorst wrote: > > Resetting will clear the CONTEXT_VALID_BIT, so wait until after that to test. > AFAIK this seems to be fixing something earlier in the series(maybe patch 7?) i.e without this patch we seem to trigger the BUG_ON. If so, this needs to be mu

Re: [PATCH 17/29] drm/i915/gvt: devirtualize ->inject_msi

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:49AM +0100, Christoph Hellwig wrote: > Just open code the MSI injection in a single place instead of going > through the method table. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/gvt/hypercall.h | 1 - > drivers/gpu/drm/i915/gvt/interrupt.c |

Re: [PATCH 16/29] drm/i915/gvt: devirtualize ->detach_vgpu

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:48AM +0100, Christoph Hellwig wrote: > Just call the function directly. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/gvt/gvt.h | 1 + > drivers/gpu/drm/i915/gvt/hypercall.h | 1 - > drivers/gpu/drm/i915/gvt/kvmgt.c | 3 +-- > driver

Re: [PATCH 15/29] drm/i915/gvt: devirtualize ->set_edid and ->set_opregion

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:47AM +0100, Christoph Hellwig wrote: > Just call the code to setup the opregions and EDID data directly. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/gvt/gvt.h | 3 +++ > drivers/gpu/drm/i915/gvt/hypercall.h | 3 --- > drivers/gpu/drm/i9

Re: [PATCH 14/29] drm/i915/gvt: devirtualize ->{get,put}_vfio_device

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:46AM +0100, Christoph Hellwig wrote: > Just open code the calls to the VFIO APIs. > > Signed-off-by: Christoph Hellwig > drivers/gpu/drm/i915/gvt/dmabuf.c| 12 ++- > drivers/gpu/drm/i915/gvt/hypercall.h | 2 -- > drivers/gpu/drm/i915/gvt/kvmgt.c | 2

Re: [PATCH 13/29] drm/i915/gvt: devirtualize ->{read,write}_gpa

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:45AM +0100, Christoph Hellwig wrote: > Just call the VFIO functions directly instead of through the method > table. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/gvt/cmd_parser.c | 4 +-- > drivers/gpu/drm/i915/gvt/execlist.c | 12 - >

Re: [PATCH] drm/i915: fixup dma_fence_wait usage

2021-11-02 Thread Thomas Hellström
On 11/2/21 16:50, Matthew Auld wrote: dma_fence_wait expects a boolean for whether it should be interruptible, not a timeout value. Signed-off-by: Matthew Auld Cc: Thomas Hellström --- drivers/gpu/drm/i915/i915_vma.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/driv

Re: [PATCH 12/29] drm/i915/gvt: remove vgpu->handle

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:44AM +0100, Christoph Hellwig wrote: > Always pass the actual vgpu structure instead of encoding it as a > "handle" and add a bool flag to denote if a VGPU is attached. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/gvt/gvt.h | 3 +- > dri

[PATCH] drm/i915: fixup dma_fence_wait usage

2021-11-02 Thread Matthew Auld
dma_fence_wait expects a boolean for whether it should be interruptible, not a timeout value. Signed-off-by: Matthew Auld Cc: Thomas Hellström --- drivers/gpu/drm/i915/i915_vma.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/i915_vma.c b/drivers/gpu/dr

Re: [PATCH 11/29] drm/i915/gvt: merge struct kvmgt_guest_info into strut intel_vgpu

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:43AM +0100, Christoph Hellwig wrote: > Consolidate the per-VGPU structures into a single one. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/gvt/gvt.h | 8 +++ > drivers/gpu/drm/i915/gvt/kvmgt.c | 117 --- > 2 files

Re: [PATCH 10/29] drm/i915/gvt: merge struct kvmgt_vdev into struct intel_vgpu

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:42AM +0100, Christoph Hellwig wrote: > Move towards having only a single structure for the per-VGPU state. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/gvt/gvt.h | 31 ++- > drivers/gpu/drm/i915/gvt/hypercall.h | 1 - > drivers/gpu/drm/

Re: [PATCH 09/29] drm/i915/gvt: remove the unused from_virt_to_mfn op

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:41AM +0100, Christoph Hellwig wrote: > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/gvt/hypercall.h | 1 - > drivers/gpu/drm/i915/gvt/kvmgt.c | 6 -- > drivers/gpu/drm/i915/gvt/mpt.h | 12 > 3 files changed, 19 deletions(

Re: [PATCH 08/29] drm/i915/gvt: remove the map_gfn_to_mfn and set_trap_area ops

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:40AM +0100, Christoph Hellwig wrote: > The map_gfn_to_mfn and set_trap_area ops are never defined, so remove > them and clean up code that depends on them in the callers. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/gvt/cfg_space.c | 89 ++--

Re: [PATCH 07/29] drm/i915/gvt: remove intel_gvt_ops

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:39AM +0100, Christoph Hellwig wrote: > Remove these pointless indirect alls by just calling the only instance > of each method directly. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/gvt/gvt.c | 20 +-- > drivers/gpu/drm/i915/gv

Re: [PATCH v4] backlight: lp855x: Switch to atomic PWM API

2021-11-02 Thread Daniel Thompson
On Mon, Nov 01, 2021 at 10:19:21AM -0300, Maíra Canal wrote: > Remove legacy PWM interface (pwm_config, pwm_enable, pwm_disable) and > replace it for the atomic PWM API. > > Signed-off-by: Maíra Canal > --- > V1 -> V2: Initialize variable and simply conditional loop > V2 -> V3: Fix assignment of

Re: [PATCH] drm/virtio: delay pinning the pages till first use

2021-11-02 Thread Chia-I Wu
On Tue, Nov 2, 2021 at 6:07 AM Gerd Hoffmann wrote: > > On Tue, Nov 02, 2021 at 12:31:39PM +0100, Maksym Wezdecki wrote: > > From: mwezdeck > > > > The idea behind the commit: > > 1. not pin the pages during resource_create ioctl > > 2. pin the pages on the first use during: > > - trans

Re: [PATCH 05/29] drm/i915/gvt: rename intel_vgpu_ops to intel_vgpu_mdev_ops

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:37AM +0100, Christoph Hellwig wrote: > Free the intel_vgpu_ops symbol name for something that fits better. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/gvt/kvmgt.c | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) Reviewed-by: Jason

Re: [PATCH 04/29] drm/i915/gvt: remove enum hypervisor_type

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:36AM +0100, Christoph Hellwig wrote: > The only supported hypervisor is KVM, so don't bother with dead code > enumerating hypervisors. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/gvt/gvt.c | 17 +-- > drivers/gpu/drm/i915/gvt/gvt.h

Re: [PATCH 03/29] drm/i915/gvt: remove module refcounting in intel_gvt_{,un}register_hypervisor

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:35AM +0100, Christoph Hellwig wrote: > THIS_MODULE always is reference when a symbol called by it is used, so > don't bother with the additional reference. heh, these functions are only called from a module init/exit even Reviewed-by: Jason Gunthorpe Jason

Re: [PATCH] drm/sun4i: fix unmet dependency on RESET_CONTROLLER for PHY_SUN6I_MIPI_DPHY

2021-11-02 Thread Maxime Ripard
Hi, On Thu, Oct 28, 2021 at 06:13:27PM -0400, Julian Braha wrote: > When PHY_SUN6I_MIPI_DPHY is selected, and RESET_CONTROLLER > is not selected, Kbuild gives the following warning: > > WARNING: unmet direct dependencies detected for PHY_SUN6I_MIPI_DPHY > Depends on [n]: (ARCH_SUNXI [=n] || COM

Re: [PATCH -V2] drm/sun4i: Grab reference of connector before return connector from sun4i_tcon_get_connector

2021-11-02 Thread Maxime Ripard
Hi, On Tue, Nov 02, 2021 at 04:46:28AM -0400, He Ying wrote: > From the comments of drm_for_each_connector_iter(), we know > that "connector is only valid within the list body, if you > want to use connector after calling drm_connector_list_iter_end() > then you need to grab your own reference fir

[PATCH 12/13] drm/vc4: hdmi: Leverage new SCDC atomic_check

2021-11-02 Thread Maxime Ripard
Now that we have a generic helper to fill the scrambling status, let's use it. Signed-off-by: Maxime Ripard --- drivers/gpu/drm/vc4/vc4_hdmi.c | 32 ++-- drivers/gpu/drm/vc4/vc4_hdmi.h | 6 ++ 2 files changed, 16 insertions(+), 22 deletions(-) diff --git a/drive

[PATCH 06/13] drm/vc4: hdmi: Remove unused argument in vc4_hdmi_supports_scrambling

2021-11-02 Thread Maxime Ripard
Even though vc4_hdmi_supports_scrambling takes a mode as an argument, it never uses it. Let's remove it. Signed-off-by: Maxime Ripard --- drivers/gpu/drm/vc4/vc4_hdmi.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/vc4/vc4_hdmi.c b/drivers/gpu/drm/vc4/v

[PATCH 13/13] drm/vc4: hdmi: Reset link on hotplug

2021-11-02 Thread Maxime Ripard
Enabling the scrambling on reconnection seems to work so far but breaks the HDMI2.0 specification and has introduced some issues in the past with i915. Let's do a mode set on the connector instead to follow the specification. Signed-off-by: Maxime Ripard --- drivers/gpu/drm/vc4/vc4_hdmi.c | 7 +

[PATCH 11/13] drm/vc4: hdmi: Switch to detect_ctx

2021-11-02 Thread Maxime Ripard
We'll need the locking context in future patch, so let's convert .detect to .detect_ctx. Signed-off-by: Maxime Ripard --- drivers/gpu/drm/vc4/vc4_hdmi.c | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/vc4/vc4_hdmi.c b/drivers/gpu/drm/vc4/vc4_hdmi.c inde

[PATCH 10/13] drm/vc4: hdmi: Simplify the connector state retrieval

2021-11-02 Thread Maxime Ripard
When we have the entire DRM state, retrieving the connector state only requires the drm_connector pointer. Fortunately for us, we have allocated it as a part of the vc4_hdmi structure, so we can retrieve get a pointer by simply accessing our field in that structure. Signed-off-by: Maxime Ripard -

[PATCH 07/13] drm/vc4: hdmi: Remove mutex in detect

2021-11-02 Thread Maxime Ripard
We recently introduced a new mutex to protect concurrent execution of ALSA and KMS hooks, and the concurrent access to some of vc4_hdmi fields. However, using it in the detect hook was creating a reentrency issue with CEC code. Indeed, calling cec_s_phys_addr_from_edid from detect might call the C

[PATCH 04/13] drm/atomic: Add HDMI reset link helper

2021-11-02 Thread Maxime Ripard
During a hotplug cycle (such as a TV going out of suspend, or when the cable is disconnected and reconnected), the expectation is that the same state used before the disconnection is reused until the next commit. However, the HDMI scrambling requires that some flags are set in the monitor, and tho

[PATCH 05/13] drm/scdc: Document hotplug gotchas

2021-11-02 Thread Maxime Ripard
There's some interactions between the SCDC setup and the disconnection / reconnection of displays. Let's document it and a solution. Signed-off-by: Maxime Ripard --- drivers/gpu/drm/drm_scdc_helper.c | 13 + 1 file changed, 13 insertions(+) diff --git a/drivers/gpu/drm/drm_scdc_help

[PATCH 08/13] drm/vc4: hdmi: Remove HDMI flag from encoder

2021-11-02 Thread Maxime Ripard
The hdmi_monitor flag in the vc4_hdmi_encoder structure is redundant with the is_hdmi flag in the drm_display_info structure. Let's convert all the users. Signed-off-by: Maxime Ripard --- drivers/gpu/drm/vc4/vc4_hdmi.c | 16 ++-- drivers/gpu/drm/vc4/vc4_hdmi.h | 1 - 2 files change

[PATCH 09/13] drm/vc4: hdmi: Simplify the hotplug handling

2021-11-02 Thread Maxime Ripard
Our detect callback has a bunch of operations to perform depending on the current and last status of the connector, such a setting the CEC physical address or enabling the scrambling again. This is currently dealt with a bunch of if / else statetements that make it fairly difficult to read and ext

[PATCH 03/13] drm/atomic: Add HDMI scrambler state helper

2021-11-02 Thread Maxime Ripard
All the drivers that implement the HDMI scrambling setup (dw-hdmi, i915, tegra, vc4) duplicate the same logic to see if the TMDS ratio or the scrambling state needs to be modified depending on the current connector state and CRTC mode. Since it's basically the same logic everywhere, let's put thes

[PATCH 01/13] drm/connector: Add define for HDMI 1.4 Maximum Pixel Rate

2021-11-02 Thread Maxime Ripard
A lot of drivers open-code the HDMI 1.4 maximum pixel rate in their driver to test whether the resolutions are supported or if the scrambling needs to be enabled. Let's create a common define for everyone to use it. Cc: Alex Deucher Cc: amd-...@lists.freedesktop.org Cc: Andrzej Hajda Cc: Benjam

[PATCH 02/13] drm/connector: Add helper to check if a mode requires scrambling

2021-11-02 Thread Maxime Ripard
Most drivers supporting the HDMI scrambling seem to have the HDMI 1.4 maximum frequency open-coded, and a function to test whether a display mode is above that threshold to control whether or not scrambling should be enabled. Let's create a common define and helper for drivers to reuse. Cc: Emma

[PATCH 00/13] drm: Add generic helpers for HDMI scrambling

2021-11-02 Thread Maxime Ripard
Hi, This is a follow-up of the work to support the interactions between the hotplug and the scrambling support for vc4: https://lore.kernel.org/dri-devel/20210507150515.257424-11-max...@cerno.tech/ https://lore.kernel.org/dri-devel/20211025152903.1088803-10-max...@cerno.tech/ Ville feedback was

Re: [PATCH 02/29] drm/i915/gvt: integrate into the main Makefile

2021-11-02 Thread Jani Nikula
On Tue, 02 Nov 2021, Christoph Hellwig wrote: > Remove the separately included Makefile and just use the relative > reference from the main i915 Makefile as for source files in other > subdirectories. > > Signed-off-by: Christoph Hellwig Acked-by: Jani Nikula > --- > drivers/gpu/drm/i915/Make

[PATCH v3 3/3] arm64: dts: qcom: sc7280: add edp display dt nodes

2021-11-02 Thread Sankeerth Billakanti
Add edp controller and phy DT nodes for sc7280. Signed-off-by: Krishna Manikandan Reviewed-by: Stephen Boyd Signed-off-by: Sankeerth Billakanti --- Changes in v3: - Add one clock cell per line (Stephen Boyd) - Unit address should match first reg property (Stephen Boyd) - Remove new

[PATCH v3 2/3] arm64: dts: qcom: sc7280: Add DSI display nodes

2021-11-02 Thread Sankeerth Billakanti
From: Krishna Manikandan Add DSI controller and PHY nodes for sc7280. Signed-off-by: Rajeev Nandan Signed-off-by: Krishna Manikandan Reviewed-by: Matthias Kaehlcke Reviewed-by: Stephen Boyd Signed-off-by: Sankeerth Billakanti --- Changes in v3: - Add the dsi_phy clocks (Kuogee Hsieh)

[PATCH v3 1/3] arm64: dts: qcom: sc7280: add display dt nodes

2021-11-02 Thread Sankeerth Billakanti
From: Krishna Manikandan Add mdss and mdp DT nodes for sc7280. Signed-off-by: Krishna Manikandan Reported-by: kernel test robot Reviewed-by: Stephen Boyd Reported-by: kernel test robot Signed-off-by: Sankeerth Billakanti --- Changes in v3: None Changes in v2: - Rename display dt n

Re: [PATCH v2 2/2] drm/i915/ttm: Failsafe migration blits

2021-11-02 Thread Thomas Hellström
Thanks for reviewing Matt, On 11/2/21 14:55, Matthew Auld wrote: On 01/11/2021 18:38, Thomas Hellström wrote: If the initial fill blit or copy blit of an object fails, the old content of the data might be exposed and read as soon as either CPU- or GPU PTEs are set up to point at the pages. Int

Re: [PATCH v2 06/13] drm/exynos: replace drm_detect_hdmi_monitor() with drm_display_info.is_hdmi

2021-11-02 Thread Claudio Suarez
On Wed, Oct 27, 2021 at 07:28:45AM +0900, Inki Dae wrote: > Hi, > > 21. 10. 17. 오전 3:42에 Claudio Suarez 이(가) 쓴 글: > > Once EDID is parsed, the monitor HDMI support information is available > > through drm_display_info.is_hdmi. Retriving the same information with > > drm_detect_hdmi_monitor() is le

Re: [Intel-gfx] [PATCH v3 05/10] drm/i915: Prepare for multiple gts

2021-11-02 Thread Tvrtko Ursulin
On 02/11/2021 11:26, Andi Shyti wrote: Hi Tvrtko, [...] static int intel_gt_tile_setup(struct intel_gt *gt, unsigned int id, phys_addr_t phys_addr) we don't actually need 'id', it's gt->info.id. It's introduced in patch 3 with the value '0' but it's not needed. I have a suspicion

Re: [PATCH 02/29] drm/i915/gvt: integrate into the main Makefile

2021-11-02 Thread Jason Gunthorpe
On Tue, Nov 02, 2021 at 08:05:34AM +0100, Christoph Hellwig wrote: > Remove the separately included Makefile and just use the relative > reference from the main i915 Makefile as for source files in other > subdirectories. > > Signed-off-by: Christoph Hellwig > --- > drivers/gpu/drm/i915/Makefile

Re: [PATCH v2 2/2] drm/i915/ttm: Failsafe migration blits

2021-11-02 Thread Matthew Auld
On 01/11/2021 18:38, Thomas Hellström wrote: If the initial fill blit or copy blit of an object fails, the old content of the data might be exposed and read as soon as either CPU- or GPU PTEs are set up to point at the pages. Intercept the blit fence with an async callback that checks the blit f

Re: [PATCH v8, 15/17] dt-bindings: media: mtk-vcodec: Adds decoder dt-bindings for mt8192

2021-11-02 Thread Rob Herring
On Fri, Oct 29, 2021 at 11:55:25AM +0800, Yunfei Dong wrote: > Adds decoder dt-bindings for mt8192. > > Signed-off-by: Yunfei Dong > --- > v8: fix yaml file check fail > --- > .../media/mediatek,vcodec-comp-decoder.yaml | 273 ++ > 1 file changed, 273 insertions(+) > create mo

  1   2   >