[Freedreno] [PATCH v4 01/13] drm/msm: Docs and misc cleanup

2021-07-27 Thread Rob Clark
From: Rob Clark Fix a couple incorrect or misspelt comments, and add submitqueue doc comment. Signed-off-by: Rob Clark Acked-by: Christian König --- drivers/gpu/drm/msm/msm_gem.h | 3 +-- drivers/gpu/drm/msm/msm_gem_submit.c | 1 + drivers/gpu/drm/msm/msm_gpu.h | 15

[Freedreno] [PATCH v4 02/13] drm/msm: Small submitqueue creation cleanup

2021-07-27 Thread Rob Clark
From: Rob Clark If we don't have a gpu, there is no need to create a submitqueue, which lets us simplify the error handling and submitqueue creation. Signed-off-by: Rob Clark Acked-by: Christian König --- drivers/gpu/drm/msm/msm_submitqueue.c | 22 +++--- 1 file change

[Freedreno] [PATCH v4 03/13] drm/msm: drop drm_gem_object_put_locked()

2021-07-27 Thread Rob Clark
From: Rob Clark No idea why we were still using this. It certainly hasn't been needed for some time. So drop the pointless twin codepaths. Signed-off-by: Rob Clark Acked-by: Christian König --- drivers/gpu/drm/msm/adreno/a5xx_debugfs.c | 4 +- drivers/gpu/drm/msm/adreno/a5xx_

[Freedreno] [PATCH v4 04/13] drm: Drop drm_gem_object_put_locked()

2021-07-27 Thread Rob Clark
From: Rob Clark Now that no one is using it, remove it. Signed-off-by: Rob Clark Acked-by: Christian König Reviewed-by: Daniel Vetter --- drivers/gpu/drm/drm_gem.c | 22 -- include/drm/drm_gem.h | 2 -- 2 files changed, 24 deletions(-) diff --git a/drivers/gpu/drm

[Freedreno] [PATCH v4 05/13] drm/msm/submit: Simplify out-fence-fd handling

2021-07-27 Thread Rob Clark
From: Rob Clark No need for this to be split in two parts. Signed-off-by: Rob Clark Acked-by: Christian König --- drivers/gpu/drm/msm/msm_gem_submit.c | 10 +++--- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/drivers/gpu/drm/msm/msm_gem_submit.c b/drivers/gpu/drm/msm

[Freedreno] [PATCH v4 06/13] drm/msm: Consolidate submit bo state

2021-07-27 Thread Rob Clark
From: Rob Clark Move all the locked/active/pinned state handling to msm_gem_submit.c. In particular, for drm/scheduler, we'll need to do all this before pushing the submit job to the scheduler. But while we're at it we can get rid of the dupicate pin and refcnt. Signed-off-by: Rob Cl

[Freedreno] [PATCH v4 07/13] drm/msm: Track "seqno" fences by idr

2021-07-27 Thread Rob Clark
From: Rob Clark Previously the (non-fd) fence returned from submit ioctl was a raw seqno, which is scoped to the ring. But from UABI standpoint, the ioctls related to seqno fences all specify a submitqueue. We can take advantage of that to replace the seqno fences with a cyclic idr handle

[Freedreno] [PATCH v4 10/13] drm/msm: Drop submit bo_list

2021-07-27 Thread Rob Clark
From: Rob Clark This was only used to detect userspace including the same bo multiple times in a submit. But ww_mutex can already tell us this. When we drop struct_mutex around the submit ioctl, we'd otherwise need to lock the bo before adding it to the bo_list. But since ww_mutex can al

[Freedreno] [PATCH v4 11/13] drm/msm: Drop struct_mutex in submit path

2021-07-27 Thread Rob Clark
From: Rob Clark It is sufficient to serialize on the submit queue now. Signed-off-by: Rob Clark Acked-by: Christian König --- drivers/gpu/drm/msm/msm_gem_submit.c | 12 +--- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/drivers/gpu/drm/msm/msm_gem_submit.c b/drivers

[Freedreno] [PATCH v4 09/13] drm/msm: Conversion to drm scheduler

2021-07-27 Thread Rob Clark
From: Rob Clark For existing adrenos, there is one or more ringbuffer, depending on whether preemption is supported. When preemption is supported, each ringbuffer has it's own priority. A submitqueue (which maps to a gl context or vk queue in userspace) is mapped to a specific ring- buff

[Freedreno] [PATCH v4 08/13] drm/msm: Return ERR_PTR() from submit_create()

2021-07-27 Thread Rob Clark
From: Rob Clark In the next patch, we start having more than a single potential failure reason. Signed-off-by: Rob Clark Acked-by: Christian König --- drivers/gpu/drm/msm/msm_gem_submit.c | 21 + 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/drivers/gpu

[Freedreno] [PATCH v4 12/13] drm/msm: Utilize gpu scheduler priorities

2021-07-27 Thread Rob Clark
From: Rob Clark The drm/scheduler provides additional prioritization on top of that provided by however many number of ringbuffers (each with their own priority level) is supported on a given generation. Expose the additional levels of priority to userspace and map the userspace priority back

[Freedreno] [PATCH v4 13/13] drm/msm/gem: Mark active before pinning

2021-07-27 Thread Rob Clark
From: Rob Clark Mark all the bos in the submit as active, before pinning, to prevent evicting a buffer in the same submit to make room for a buffer earlier in the table. Signed-off-by: Rob Clark --- drivers/gpu/drm/msm/msm_gem.c| 2 -- drivers/gpu/drm/msm/msm_gem_submit.c | 28

[Freedreno] [early pull] drm/msm: drm-msm-next-2021-07-28 for v5.15

2021-07-28 Thread Rob Clark
09:19:00 -0700) -------- Rob Clark (18): drm/msm: Let fences read directly from memptrs drm/msm: Signal fences sooner drm/msm: Split out devfreq handling drm/msm: Split out get_freq() helper drm/msm: Devfreq tuning drm/msm:

Re: [Freedreno] [early pull] drm/msm: drm-msm-next-2021-07-28 for v5.15

2021-07-28 Thread Rob Clark
shortly after reaching UI with the following errors: > > https://paste.ubuntu.com/p/HvjmzZYtgw/ > > I did a git bisect and the patch ("drm/msm: Devfreq tuning") seems to be > the cause of the crash, reverting it resolves the issue. > > > On 28/07/2021 21:52, Rob Clark

Re: [Freedreno] [early pull] drm/msm: drm-msm-next-2021-07-28 for v5.15

2021-07-28 Thread Rob Clark
On Wed, Jul 28, 2021 at 7:18 PM Caleb Connolly wrote: > > > > On 29/07/2021 02:02, Rob Clark wrote: > > Jordan, any idea if more frequent frequency changes would for some > > reason make a630 grumpy? I was expecting it should be somewhat > > similar to a618 (same

Re: [Freedreno] [PATCH v2 2/3] drm/msm/a6xx: Use rev to identify SKU

2021-07-29 Thread Rob Clark
On Thu, Jul 29, 2021 at 7:33 AM Akhil P Oommen wrote: > > Use rev instead of revn to identify the SKU. This is in > preparation to the introduction of 7c3 gpu which won't have a > revn. > > Signed-off-by: Akhil P Oommen > --- > > (no changes since v1) > > drivers/gpu/drm/msm/adreno/a6xx_gpu.c |

Re: [Freedreno] [PATCH v3 3/3] drm/msm/a6xx: Add support for Adreno 7c Gen 3 gpu

2021-07-29 Thread Rob Clark
On Thu, Jul 29, 2021 at 8:21 AM Akhil P Oommen wrote: > > This patch adds support for the gpu found in the Snapdragon 7c Gen 3 > compute platform. This gpu is similar to the exisiting a660 gpu with > minor delta in the programing sequence. As the Adreno GPUs are moving > away from a numeric chipid

Re: [Freedreno] [PATCH v2 2/3] drm/msm/a6xx: Use rev to identify SKU

2021-07-29 Thread Rob Clark
On Thu, Jul 29, 2021 at 8:36 AM Akhil P Oommen wrote: > > On 7/29/2021 8:57 PM, Rob Clark wrote: > > On Thu, Jul 29, 2021 at 7:33 AM Akhil P Oommen > > wrote: > >> > >> Use rev instead of revn to identify the SKU. This is in > >> preparation to t

Re: [Freedreno] [RFC PATCH] drm/msm: Introduce Adreno Features

2021-07-29 Thread Rob Clark
On Thu, Jul 29, 2021 at 8:31 AM Akhil P Oommen wrote: > > Introduce a feature flag in gpulist to easily identify the capabilities > of each gpu revision. This will help to avoid a lot of adreno_is_axxx() > check when we add new features. In the current patch, HW APRIV feature > is converted to a f

Re: [Freedreno] [PATCH v3 1/2] arm64: dts: qcom: sc7280: Add gpu support

2021-07-29 Thread Rob Clark
On Thu, Jul 29, 2021 at 10:19 AM Stephen Boyd wrote: > > Quoting Akhil P Oommen (2021-07-28 04:54:01) > > diff --git a/arch/arm64/boot/dts/qcom/sc7280.dtsi > > b/arch/arm64/boot/dts/qcom/sc7280.dtsi > > index 029723a..c88f366 100644 > > --- a/arch/arm64/boot/dts/qcom/sc7280.dtsi > > +++ b/arch/ar

[Freedreno] [PATCH] drm/msm: Disable frequency clamping on a630

2021-07-29 Thread Rob Clark
From: Rob Clark The more frequent frequency transitions resulting from clamping freq to minimum when the GPU is idle seems to be causing some issue with the bus getting voted off when it should be on. (An enable racing with an async disable?) This might be a problem outside of the GPU, as I

Re: [Freedreno] [PATCH] drm/msm: Disable frequency clamping on a630

2021-07-29 Thread Rob Clark
27;m dropping), since there is nothing stopping other workloads from hitting higher OPPs. I'm slightly curious why I didn't have problems at higher OPPs on my c630 laptop (sdm850) BR, -R > > On 29/07/2021 19:39, Rob Clark wrote: > > From: Rob Clark > > > > The mor

Re: [Freedreno] [PATCH] drm/msm: Disable frequency clamping on a630

2021-07-29 Thread Rob Clark
On Thu, Jul 29, 2021 at 1:28 PM Caleb Connolly wrote: > > > > On 29/07/2021 21:24, Rob Clark wrote: > > On Thu, Jul 29, 2021 at 1:06 PM Caleb Connolly > > wrote: > >> > >> Hi Rob, > >> > >> I've done some more testing! It looks

Re: [Freedreno] [PATCH] drm: msm: Add 680 gpu to the adreno gpu list

2021-07-29 Thread Rob Clark
On Sat, Jul 24, 2021 at 8:21 PM Bjorn Andersson wrote: > > This patch adds a Adreno 680 entry to the gpulist. Looks reasonable, but I wonder if we should just go ahead and add adreno_is_a640_family() in a similar vein to adreno_is_a650_familiy()/adreno_is_a660_family().. I think most of the 'if (

Re: [Freedreno] [PATCH] drm: msm: Add 680 gpu to the adreno gpu list

2021-07-29 Thread Rob Clark
On Thu, Jul 29, 2021 at 8:53 PM Akhil P Oommen wrote: > > On 7/30/2021 5:38 AM, Rob Clark wrote: > > On Sat, Jul 24, 2021 at 8:21 PM Bjorn Andersson > > wrote: > >> > >> This patch adds a Adreno 680 entry to the gpulist. > > > > Looks reasonable,

Re: [Freedreno] [PATCH 0/3] iommu/drm/msm: Allow non-coherent masters to use system cache

2021-08-02 Thread Rob Clark
On Mon, Aug 2, 2021 at 3:55 AM Will Deacon wrote: > > On Thu, Jul 29, 2021 at 10:08:22AM +0530, Sai Prakash Ranjan wrote: > > On 2021-07-28 19:30, Georgi Djakov wrote: > > > On Mon, Jan 11, 2021 at 07:45:02PM +0530, Sai Prakash Ranjan wrote: > > > > commit ecd7274fb4cd ("iommu: Remove unused IOMMU

Re: [Freedreno] [PATCH 0/3] iommu/drm/msm: Allow non-coherent masters to use system cache

2021-08-02 Thread Rob Clark
On Mon, Aug 2, 2021 at 8:14 AM Will Deacon wrote: > > On Mon, Aug 02, 2021 at 08:08:07AM -0700, Rob Clark wrote: > > On Mon, Aug 2, 2021 at 3:55 AM Will Deacon wrote: > > > > > > On Thu, Jul 29, 2021 at 10:08:22AM +0530, Sai Prakash Ranjan wrote: > > > >

Re: [Freedreno] [PATCH v2 07/14] drm/msm: Convert to Linux IRQ interfaces

2021-08-03 Thread Rob Clark
On Tue, Aug 3, 2021 at 2:37 AM Dmitry Baryshkov wrote: > > On 03/08/2021 12:06, Thomas Zimmermann wrote: > > Drop the DRM IRQ midlayer in favor of Linux IRQ interfaces. DRM's > > IRQ helpers are mostly useful for UMS drivers. Modern KMS drivers > > don't benefit from using it. > > > > DRM IRQ call

Re: [Freedreno] [PATCH v5 02/20] drm/msm: Fix drm/sched point of no return rules

2021-08-05 Thread Rob Clark
not skip to error paths after > that. Other drivers do this the same for out-fence and similar things. > > Fixes: 1d8a5ca436ee ("drm/msm: Conversion to drm scheduler") > Cc: Rob Clark > Cc: Rob Clark > Cc: Sean Paul > Cc: Sumit Semwal > Cc: "Chri

Re: [Freedreno] [PATCH v5 02/20] drm/msm: Fix drm/sched point of no return rules

2021-08-06 Thread Rob Clark
On Fri, Aug 6, 2021 at 9:42 AM Daniel Vetter wrote: > > On Fri, Aug 6, 2021 at 12:58 AM Rob Clark wrote: > > > > On Thu, Aug 5, 2021 at 3:47 AM Daniel Vetter wrote: > > > > > > Originally drm_sched_job_init was the point of no return, after which > > &g

Re: [Freedreno] [PATCH v5 02/20] drm/msm: Fix drm/sched point of no return rules

2021-08-06 Thread Rob Clark
On Fri, Aug 6, 2021 at 11:41 AM Daniel Vetter wrote: > > On Fri, Aug 6, 2021 at 7:15 PM Rob Clark wrote: > > > > On Fri, Aug 6, 2021 at 9:42 AM Daniel Vetter wrote: > > > > > > On Fri, Aug 6, 2021 at 12:58 AM Rob Clark wrote: > > > > >

Re: [Freedreno] [PATCH v5 02/20] drm/msm: Fix drm/sched point of no return rules

2021-08-06 Thread Rob Clark
On Fri, Aug 6, 2021 at 12:11 PM Daniel Vetter wrote: > > On Fri, Aug 6, 2021 at 8:57 PM Rob Clark wrote: > > > > On Fri, Aug 6, 2021 at 11:41 AM Daniel Vetter > > wrote: > > > > > > On Fri, Aug 6, 2021 at 7:15 PM Rob Clark wrote: > > > >

[Freedreno] [PATCH 1/2] drm/msm: Add adreno_is_a640_family()

2021-08-07 Thread Rob Clark
From: Rob Clark Combine adreno_is_a640() and adreno_is_a680(). Signed-off-by: Rob Clark --- drivers/gpu/drm/msm/adreno/a6xx_gmu.c | 5 ++--- drivers/gpu/drm/msm/adreno/a6xx_gpu.c | 15 +++ drivers/gpu/drm/msm/adreno/a6xx_hfi.c | 2 +- drivers/gpu/drm/msm/adreno

[Freedreno] [PATCH 2/2] drm/msm: Rework SQE version check

2021-08-07 Thread Rob Clark
From: Rob Clark This check is really about which SQE firmware, rather than which GPU. Rework to match minimum version based on firmware name, so it doesn't need to be updated when adding additional GPUs using the same fw. Signed-off-by: Rob Clark --- drivers/gpu/drm/msm/adreno/a6xx_gpu.

Re: [Freedreno] [PATCH v2 07/14] drm/msm: Convert to Linux IRQ interfaces

2021-08-07 Thread Rob Clark
On Tue, Aug 3, 2021 at 2:37 AM Dmitry Baryshkov wrote: > > On 03/08/2021 12:06, Thomas Zimmermann wrote: > > Drop the DRM IRQ midlayer in favor of Linux IRQ interfaces. DRM's > > IRQ helpers are mostly useful for UMS drivers. Modern KMS drivers > > don't benefit from using it. > > > > DRM IRQ call

Re: [Freedreno] [PATCH v2] drm/msm: Implement mmap as GEM object function

2021-08-07 Thread Rob Clark
On Tue, Jul 6, 2021 at 1:47 AM Thomas Zimmermann wrote: > > Moving the driver-specific mmap code into a GEM object function allows > for using DRM helpers for various mmap callbacks. > > The respective msm functions are being removed. The file_operations > structure fops is now being created by th

[Freedreno] [PATCH v2 0/5] dma-fence: Deadline awareness

2021-08-07 Thread Rob Clark
From: Rob Clark Based on discussion from a previous series[1] to add a "boost" mechanism when, for example, vblank deadlines are missed. Instead of a boost callback, this approach adds a way to set a deadline on the fence, by which the waiter would like to see the fence signalled. I&

[Freedreno] [PATCH v2 1/5] dma-fence: Add deadline awareness

2021-08-07 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

[Freedreno] [PATCH v2 2/5] drm/vblank: Add helper to get next vblank time

2021-08-07 Thread Rob Clark
From: Rob Clark Signed-off-by: Rob Clark --- drivers/gpu/drm/drm_vblank.c | 31 +++ include/drm/drm_vblank.h | 1 + 2 files changed, 32 insertions(+) diff --git a/drivers/gpu/drm/drm_vblank.c b/drivers/gpu/drm/drm_vblank.c index 3417e1ac7918..88c824c294dc

[Freedreno] [PATCH v2 4/5] drm/scheduler: Add fence deadline support

2021-08-07 Thread Rob Clark
From: 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. Signed-off-by: Rob Clark --- drivers/gpu/drm

[Freedreno] [PATCH v2 3/5] drm/atomic-helper: Set fence deadline for vblank

2021-08-07 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. Signed-off-by: Rob Clark --- drivers/gpu/drm/drm_atomic_helper.c | 36 + 1 file changed, 36 insertions(+) diff

[Freedreno] [PATCH v2 5/5] drm/msm: Add deadline based boost support

2021-08-07 Thread Rob Clark
From: Rob Clark Signed-off-by: Rob Clark --- drivers/gpu/drm/msm/msm_fence.c | 76 +++ drivers/gpu/drm/msm/msm_fence.h | 20 +++ drivers/gpu/drm/msm/msm_gpu.h | 1 + drivers/gpu/drm/msm/msm_gpu_devfreq.c | 20 +++ 4 files changed, 117

Re: [Freedreno] [PATCH v2 07/14] drm/msm: Convert to Linux IRQ interfaces

2021-08-07 Thread Rob Clark
On Sat, Aug 7, 2021 at 11:40 AM Thomas Zimmermann wrote: > > Hi > > Am 07.08.21 um 19:08 schrieb Rob Clark: > > On Tue, Aug 3, 2021 at 2:37 AM Dmitry Baryshkov > > wrote: > >> > >> On 03/08/2021 12:06, Thomas Zimmermann wrote: > >>> Drop

Re: [Freedreno] [PATCH] drm/msm: Disable frequency clamping on a630

2021-08-07 Thread Rob Clark
On Sat, Aug 7, 2021 at 12:21 PM Caleb Connolly wrote: > > Hi Rob, Akhil, > > On 29/07/2021 21:53, Rob Clark wrote: > > On Thu, Jul 29, 2021 at 1:28 PM Caleb Connolly > > wrote: > >> > >> > >> > >> On 29/07/2021 21:24, Rob Clark

Re: [Freedreno] [PATCH] drm/msm: Disable frequency clamping on a630

2021-08-08 Thread Rob Clark
On Sun, Aug 8, 2021 at 7:33 AM Caleb Connolly wrote: > > > > On 07/08/2021 21:04, Rob Clark wrote: > > On Sat, Aug 7, 2021 at 12:21 PM Caleb Connolly > > wrote: > >> > >> Hi Rob, Akhil, > >> > >> On 29/07/2021 21:53, Rob Clark

Re: [Freedreno] [PATCH] drm/msm: Disable frequency clamping on a630

2021-08-09 Thread Rob Clark
On Mon, Aug 9, 2021 at 7:52 AM Akhil P Oommen wrote: > > On 8/8/2021 10:22 PM, Rob Clark wrote: > > On Sun, Aug 8, 2021 at 7:33 AM Caleb Connolly > > wrote: > >> > >> > >> > >> On 07/08/2021 21:04, Rob Clark wrote: > >&g

Re: [Freedreno] [PATCH 0/3] iommu/drm/msm: Allow non-coherent masters to use system cache

2021-08-09 Thread Rob Clark
On Mon, Aug 9, 2021 at 7:56 AM Will Deacon wrote: > > On Mon, Aug 02, 2021 at 06:36:04PM -0700, Rob Clark wrote: > > On Mon, Aug 2, 2021 at 8:14 AM Will Deacon wrote: > > > > > > On Mon, Aug 02, 2021 at 08:08:07AM -0700, Rob Clark wrote: > > > > On Mon,

Re: [Freedreno] [PATCH 0/3] iommu/drm/msm: Allow non-coherent masters to use system cache

2021-08-09 Thread Rob Clark
On Mon, Aug 9, 2021 at 10:05 AM Will Deacon wrote: > > On Mon, Aug 09, 2021 at 09:57:08AM -0700, Rob Clark wrote: > > On Mon, Aug 9, 2021 at 7:56 AM Will Deacon wrote: > > > On Mon, Aug 02, 2021 at 06:36:04PM -0700, Rob Clark wrote: > > > > On Mon, Aug 2, 2

Re: [Freedreno] [PATCH] drm/msm: Disable frequency clamping on a630

2021-08-09 Thread Rob Clark
On Mon, Aug 9, 2021 at 10:28 AM Akhil P Oommen wrote: > > On 8/9/2021 9:48 PM, Caleb Connolly wrote: > > > > > > On 09/08/2021 17:12, Rob Clark wrote: > >> On Mon, Aug 9, 2021 at 7:52 AM Akhil P Oommen > >> wrote: > >>> > >>> On 8

Re: [Freedreno] [PATCH 0/3] iommu/drm/msm: Allow non-coherent masters to use system cache

2021-08-09 Thread Rob Clark
On Mon, Aug 9, 2021 at 10:47 AM Sai Prakash Ranjan wrote: > > On 2021-08-09 23:10, Will Deacon wrote: > > On Mon, Aug 09, 2021 at 10:18:21AM -0700, Rob Clark wrote: > >> On Mon, Aug 9, 2021 at 10:05 AM Will Deacon wrote: > >> > > >> > On Mon, Aug

Re: [Freedreno] [PATCH 0/3] iommu/drm/msm: Allow non-coherent masters to use system cache

2021-08-09 Thread Rob Clark
On Mon, Aug 9, 2021 at 11:11 AM Sai Prakash Ranjan wrote: > > On 2021-08-09 23:37, Rob Clark wrote: > > On Mon, Aug 9, 2021 at 10:47 AM Sai Prakash Ranjan > > wrote: > >> > >> On 2021-08-09 23:10, Will Deacon wrote: > >> > On Mon, Aug 09, 2021 at 1

Re: [Freedreno] [PATCH] drm/msm: Disable frequency clamping on a630

2021-08-09 Thread Rob Clark
On Mon, Aug 9, 2021 at 1:35 PM Caleb Connolly wrote: > > > > On 09/08/2021 18:58, Rob Clark wrote: > > On Mon, Aug 9, 2021 at 10:28 AM Akhil P Oommen > > wrote: > >> > >> On 8/9/2021 9:48 PM, Caleb Connolly wrote: > >>> > >>>

Re: [Freedreno] [PATCH] drm/msm: Read frame_count and line_count even when disabled.

2021-08-11 Thread Rob Clark
7;s unsigned), which inflates the vblank count when the diff > is added to the current vblank->count. > > [How] > Read frame_count register whether interface timing engine is enabled or > not. > > Fixes: IGT:kms_flip::modeset-vs-vblank-race-interruptible > Tested on Chrome

Re: [Freedreno] [PATCH] drm/msm: Read frame_count and line_count even when disabled.

2021-08-11 Thread Rob Clark
On Wed, Aug 11, 2021 at 4:11 PM wrote: > > On 2021-08-11 11:43, Rob Clark wrote: > > On Wed, Aug 11, 2021 at 11:12 AM Mark Yacoub > > wrote: > >> > >> From: Mark Yacoub > >> > >> [why] > >> Reading frame count register used to ge

[Freedreno] [PATCH 0/4] drm/msm+ti-sn65dsi86: Fix NO_CONNECTOR fallout

2021-08-11 Thread Rob Clark
From: Rob Clark The first patch fixes breakage in drm-next for the ti eDP bridge (which is used on nearly all the snapdragon windows laptops and chromebooks). The second add drm/msm NO_CONNECTOR support, and the final two add NO_CONNECTOR support to the ti eDP bridge. Would be nice to get at

[Freedreno] [PATCH 1/4] drm/bridge: ti-sn65dsi86: Avoid creating multiple connectors

2021-08-11 Thread Rob Clark
From: Rob Clark If we created our own connector because the driver does not support the NO_CONNECTOR flag, we don't want the downstream bridge to *also* create a connector. And if this driver did pass the NO_CONNECTOR flag (and we supported that mode) this would change nothing.

[Freedreno] [PATCH 2/4] drm/msm/dsi: Support NO_CONNECTOR bridges

2021-08-11 Thread Rob Clark
From: Rob Clark For now, since we have a mix of bridges which support this flag, which which do *not* support this flag, or work both ways, try it once with NO_CONNECTOR and then fall back to the old way if that doesn't work. Eventually we can drop the fallback path. Signed-off-by: Rob

[Freedreno] [PATCH 3/4] drm/bridge: ti-sn65dsi86: Implement bridge->mode_valid()

2021-08-11 Thread Rob Clark
From: Rob Clark For the brave new world of bridges not creating their own connectors, we need to implement the max clock limitation via bridge->mode_valid() instead of connector->mode_valid(). Signed-off-by: Rob Clark --- drivers/gpu/drm/bridge/ti-sn65dsi86.c | 24 +++--

[Freedreno] [PATCH 4/4] drm/bridge: ti-sn65dsi86: Add NO_CONNECTOR support

2021-08-11 Thread Rob Clark
From: Rob Clark Slightly awkward to fish out the display_info when we aren't creating own connector. But I don't see an obvious better way. Signed-off-by: Rob Clark --- drivers/gpu/drm/bridge/ti-sn65dsi86.c | 34 +++ 1 file changed, 29 insertions(+), 5

[Freedreno] [pull] drm/msm: drm-msm-next-2021-08-12 for v5.15

2021-08-12 Thread Rob Clark
dsi phy drm/msm/dsi: Add PHY configuration for SC7280 drm/msm/dsi: Add DSI support for SC7280 Rob Clark (3): drm/msm: Periodically update RPTR shadow drm/msm: Add adreno_is_a640_family() drm/msm: Rework SQE version check Souptick Joarder (1): drm/msm/dp: Remove unus

Re: [Freedreno] [PATCH 1/4] drm/bridge: ti-sn65dsi86: Avoid creating multiple connectors

2021-08-12 Thread Rob Clark
On Thu, Aug 12, 2021 at 9:55 AM Doug Anderson wrote: > > Hi, > > On Wed, Aug 11, 2021 at 4:51 PM Rob Clark wrote: > > > > From: Rob Clark > > > > If we created our own connector because the driver does not support the > > NO_CONNECTOR flag, we don

Re: [Freedreno] [PATCH 2/4] drm/msm/dsi: Support NO_CONNECTOR bridges

2021-08-12 Thread Rob Clark
On Thu, Aug 12, 2021 at 10:31 AM Sam Ravnborg wrote: > > Hi Rob, > > On Wed, Aug 11, 2021 at 04:52:48PM -0700, Rob Clark wrote: > > From: Rob Clark > > > > For now, since we have a mix of bridges which support this flag, which > > which do *not* support this

Re: [Freedreno] [PATCH 3/4] drm/bridge: ti-sn65dsi86: Implement bridge->mode_valid()

2021-08-12 Thread Rob Clark
On Thu, Aug 12, 2021 at 11:44 AM Laurent Pinchart wrote: > > Hi Rob, > > Thank you for the patch. > > On Wed, Aug 11, 2021 at 04:52:49PM -0700, Rob Clark wrote: > > From: Rob Clark > > > > For the brave new world of bridges not creating their own connecto

Re: [Freedreno] [PATCH v2 4/5] drm/scheduler: Add fence deadline support

2021-08-16 Thread Rob Clark
On Mon, Aug 16, 2021 at 8:38 AM Daniel Vetter wrote: > > On Mon, Aug 16, 2021 at 12:14:35PM +0200, Christian König wrote: > > Am 07.08.21 um 20:37 schrieb Rob Clark: > > > From: Rob Clark > > > > > > As the finished fence is the one that is exposed to user

Re: [Freedreno] [PATCH v2 0/5] dma-fence: Deadline awareness

2021-08-16 Thread Rob Clark
wrote: > > The general approach seems to make sense now I think. > > One minor thing which I'm missing is adding support for this to the > dma_fence_array and dma_fence_chain containers. > > Regards, > Christian. > > Am 07.08.21 um 20:37 schrieb Rob Clark: &g

[Freedreno] [PATCH igt 0/3] Initial igt tests for drm/msm ioctls

2021-08-24 Thread Rob Clark
From: Rob Clark Add an initial set of tests for the gpu SUBMIT ioctl. There is plenty more we can add, but need to start somewhere. Rob Clark (3): drmtest: Add DRIVER_MSM support msm: Add helper library msm: Add submit ioctl tests lib/drmtest.c | 3 + lib/drmtest.h | 1

[Freedreno] [PATCH igt 1/3] drmtest: Add DRIVER_MSM support

2021-08-24 Thread Rob Clark
From: Rob Clark Signed-off-by: Rob Clark --- lib/drmtest.c | 3 +++ lib/drmtest.h | 1 + 2 files changed, 4 insertions(+) diff --git a/lib/drmtest.c b/lib/drmtest.c index e1f9b115..29cb3f4c 100644 --- a/lib/drmtest.c +++ b/lib/drmtest.c @@ -179,6 +179,7 @@ static const struct module

[Freedreno] [PATCH igt 2/3] msm: Add helper library

2021-08-24 Thread Rob Clark
From: Rob Clark Handle some of the boilerplate for tests. Signed-off-by: Rob Clark --- lib/igt_msm.c | 163 lib/igt_msm.h | 128 + lib/meson.build | 1 + 3 files changed, 292 insertions(+) create mode

[Freedreno] [PATCH igt 3/3] msm: Add submit ioctl tests

2021-08-24 Thread Rob Clark
From: Rob Clark Add an initial set of tests for the submit ioctl. Signed-off-by: Rob Clark --- tests/meson.build | 1 + tests/msm_submit.c | 188 + 2 files changed, 189 insertions(+) create mode 100644 tests/msm_submit.c diff --git a/tests

Re: [Freedreno] [igt-dev] [PATCH igt 2/3] msm: Add helper library

2021-08-25 Thread Rob Clark
On Wed, Aug 25, 2021 at 1:44 AM Petri Latvala wrote: > > On Tue, Aug 24, 2021 at 03:49:31PM -0700, Rob Clark wrote: > > From: Rob Clark > > > > Handle some of the boilerplate for tests. > > > > Signed-off-by: Rob Clark

[Freedreno] [PATCH igt v2 0/3] Initial igt tests for drm/msm ioctls

2021-08-25 Thread Rob Clark
From: Rob Clark Add an initial set of tests for the gpu SUBMIT ioctl. There is plenty more we can add, but need to start somewhere. v2: add msm_device::gen and drop igt_msm_pipe_gen().. any test that needs to build even trivial cmdstream will need this so make it part of the util

[Freedreno] [PATCH igt v2 1/3] drmtest: Add DRIVER_MSM support

2021-08-25 Thread Rob Clark
From: Rob Clark Signed-off-by: Rob Clark --- lib/drmtest.c | 3 +++ lib/drmtest.h | 1 + 2 files changed, 4 insertions(+) diff --git a/lib/drmtest.c b/lib/drmtest.c index e1f9b115..29cb3f4c 100644 --- a/lib/drmtest.c +++ b/lib/drmtest.c @@ -179,6 +179,7 @@ static const struct module

[Freedreno] [PATCH igt v2 2/3] msm: Add helper library

2021-08-25 Thread Rob Clark
From: Rob Clark Handle some of the boilerplate for tests. Signed-off-by: Rob Clark --- lib/igt_msm.c | 171 lib/igt_msm.h | 119 + lib/meson.build | 1 + 3 files changed, 291 insertions(+) create mode

[Freedreno] [PATCH igt v2 3/3] msm: Add submit ioctl tests

2021-08-25 Thread Rob Clark
From: Rob Clark Add an initial set of tests for the submit ioctl. Signed-off-by: Rob Clark --- tests/meson.build | 1 + tests/msm_submit.c | 186 + 2 files changed, 187 insertions(+) create mode 100644 tests/msm_submit.c diff --git a/tests

Re: [Freedreno] [PATCH igt v2 3/3] msm: Add submit ioctl tests

2021-08-26 Thread Rob Clark
On Wed, Aug 25, 2021 at 10:28 PM Petri Latvala wrote: > > On Wed, Aug 25, 2021 at 04:31:39PM -0700, Rob Clark wrote: > > From: Rob Clark > > > > Add an initial set of tests for the submit ioctl. > > > > Signed-off-by: Rob Clark > > --- > > te

Re: [Freedreno] [PATCH] drm/msm: Improve drm/sched point of no return rules

2021-08-26 Thread Rob Clark
rm_sched_job doesn't escape anywhere at all. > > For robustness it's still better to align with other drivers here and > not bail out after job_arm(). > > v3: I misplaced drm_sched_job_arm by _one_ line! Thanks to Rob for > testing and debug help. > > Cc: Rob Clark > C

Re: [Freedreno] [PATCH v5 12/20] drm/msm: Use scheduler dependency handling

2021-08-26 Thread Rob Clark
On Thu, Aug 5, 2021 at 3:47 AM Daniel Vetter wrote: > > drm_sched_job_init is already at the right place, so this boils down > to deleting code. > > Signed-off-by: Daniel Vetter > Cc: Rob Clark > Cc: Sean Paul > Cc: Sumit Semwal > Cc: "Christian König"

Re: [Freedreno] [PATCH v5 16/20] drm/msm: Don't break exclusive fence ordering

2021-08-26 Thread Rob Clark
t seem to care much, > - and it probably makes sense to lift this into dma-resv.c code as a > proper concept, so that drivers don't have to hack up their own > solution each on their own. > > v2: Improve commit message per Lucas' suggestion. > > Cc: Lucas Stach

[Freedreno] [PATCH igt v3 1/3] drmtest: Add DRIVER_MSM support

2021-08-30 Thread Rob Clark
From: Rob Clark Signed-off-by: Rob Clark Reviewed-by: Petri Latvala --- lib/drmtest.c | 3 +++ lib/drmtest.h | 1 + 2 files changed, 4 insertions(+) diff --git a/lib/drmtest.c b/lib/drmtest.c index e1f9b115..29cb3f4c 100644 --- a/lib/drmtest.c +++ b/lib/drmtest.c @@ -179,6 +179,7 @@ static

[Freedreno] [PATCH igt v3 0/3] Initial igt tests for drm/msm ioctls

2021-08-30 Thread Rob Clark
From: Rob Clark Add an initial set of tests for the gpu SUBMIT ioctl. There is plenty more we can add, but need to start somewhere. Rob Clark (3): drmtest: Add DRIVER_MSM support msm: Add helper library msm: Add submit ioctl tests .../igt-gpu-tools/igt-gpu-tools-docs.xml | 1

[Freedreno] [PATCH igt v3 3/3] msm: Add submit ioctl tests

2021-08-30 Thread Rob Clark
From: Rob Clark Add an initial set of tests for the submit ioctl. v2: Add NULL inits, igt_describe() Signed-off-by: Rob Clark --- tests/meson.build | 1 + tests/msm_submit.c | 194 + 2 files changed, 195 insertions(+) create mode 100644 tests

[Freedreno] [PATCH igt v3 2/3] msm: Add helper library

2021-08-30 Thread Rob Clark
From: Rob Clark Handle some of the boilerplate for tests. v2: fix comment, drop unnecessary drm_open_driver_render() error handling, docs fixes, drop igt_msm_pipe_get_param() (for now), handle NULL in destructors Signed-off-by: Rob Clark --- .../igt-gpu-tools/igt-gpu-tools-docs.xml

[Freedreno] [PATCH igt v4 0/3] Initial igt tests for drm/msm ioctls

2021-08-31 Thread Rob Clark
From: Rob Clark Add an initial set of tests for the gpu SUBMIT ioctl. There is plenty more we can add, but need to start somewhere. Rob Clark (3): drmtest: Add DRIVER_MSM support msm: Add helper library msm: Add submit ioctl tests .../igt-gpu-tools/igt-gpu-tools-docs.xml | 1

[Freedreno] [PATCH igt v4 1/3] drmtest: Add DRIVER_MSM support

2021-08-31 Thread Rob Clark
From: Rob Clark Signed-off-by: Rob Clark Reviewed-by: Petri Latvala --- lib/drmtest.c | 3 +++ lib/drmtest.h | 1 + 2 files changed, 4 insertions(+) diff --git a/lib/drmtest.c b/lib/drmtest.c index e1f9b115..29cb3f4c 100644 --- a/lib/drmtest.c +++ b/lib/drmtest.c @@ -179,6 +179,7 @@ static

[Freedreno] [PATCH igt v4 2/3] msm: Add helper library

2021-08-31 Thread Rob Clark
From: Rob Clark Handle some of the boilerplate for tests. v2: fix comment, drop unnecessary drm_open_driver_render() error handling, docs fixes, drop igt_msm_pipe_get_param() (for now), handle NULL in destructors Signed-off-by: Rob Clark Reviewed-by: Petri Latvala --- .../igt-gpu

[Freedreno] [PATCH igt v4 3/3] msm: Add submit ioctl tests

2021-08-31 Thread Rob Clark
From: Rob Clark Add an initial set of tests for the submit ioctl. v2: Add NULL inits, igt_describe() v3: Alphabetize meson.build Signed-off-by: Rob Clark Acked-by: Petri Latvala --- tests/meson.build | 1 + tests/msm_submit.c | 194 + 2 files

[Freedreno] [PATCH v3 0/9] dma-fence: Deadline awareness

2021-09-03 Thread Rob Clark
From: Rob Clark This series adds deadline awareness 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

[Freedreno] [PATCH v3 5/9] drm/msm: Add deadline based boost support

2021-09-03 Thread Rob Clark
From: Rob Clark Signed-off-by: Rob Clark --- drivers/gpu/drm/msm/msm_fence.c | 76 +++ drivers/gpu/drm/msm/msm_fence.h | 20 +++ drivers/gpu/drm/msm/msm_gpu.h | 1 + drivers/gpu/drm/msm/msm_gpu_devfreq.c | 20 +++ 4 files changed, 117

Re: [Freedreno] [PATCH] drm/msm: Disable frequency clamping on a630

2021-09-03 Thread Rob Clark
On Fri, Sep 3, 2021 at 12:39 PM John Stultz wrote: > > On Thu, Jul 29, 2021 at 1:49 PM Rob Clark wrote: > > On Thu, Jul 29, 2021 at 1:28 PM Caleb Connolly > > wrote: > > > On 29/07/2021 21:24, Rob Clark wrote: > > > > On Thu, Jul 29, 2021 a

[Freedreno] [PATCH] drm/fourcc: Add QCOM tiled modifiers

2021-09-04 Thread Rob Clark
From: Rob Clark These are mainly used internally in mesa, although I believe the display should be able to scan out the TILED3 format. Currently we define this modifier internally in mesa for use with modifier based allocation. But we can get rid of that hack if we define the modfiers properly

Re: [Freedreno] [PATCH] drm/msm: Disable frequency clamping on a630

2021-09-06 Thread Rob Clark
On Mon, Sep 6, 2021 at 1:02 AM Amit Pundir wrote: > > On Sat, 4 Sept 2021 at 01:55, Rob Clark wrote: > > > > On Fri, Sep 3, 2021 at 12:39 PM John Stultz wrote: > > > > > > On Thu, Jul 29, 2021 at 1:49 PM Rob Clark wrote: > > > > On Thu, Jul 2

Re: [Freedreno] [PATCH] drm/msm: Disable frequency clamping on a630

2021-09-06 Thread Rob Clark
On Mon, Sep 6, 2021 at 12:58 PM Amit Pundir wrote: > > On Mon, 6 Sept 2021 at 21:54, Rob Clark wrote: > > > > On Mon, Sep 6, 2021 at 1:02 AM Amit Pundir wrote: > > > > > > On Sat, 4 Sept 2021 at 01:55, Rob Clark wrote: > > > > > > > >

Re: [Freedreno] [PATCH] drm/msm: Disable frequency clamping on a630

2021-09-06 Thread Rob Clark
On Mon, Sep 6, 2021 at 1:50 PM Rob Clark wrote: > > On Mon, Sep 6, 2021 at 12:58 PM Amit Pundir wrote: > > > > On Mon, 6 Sept 2021 at 21:54, Rob Clark wrote: > > > > > > On Mon, Sep 6, 2021 at 1:02 AM Amit Pundir wrote: > > > > > &

Re: [Freedreno] [PATCH] drm/msm: Disable frequency clamping on a630

2021-09-06 Thread Rob Clark
On Mon, Sep 6, 2021 at 12:58 PM Amit Pundir wrote: > > On Mon, 6 Sept 2021 at 21:54, Rob Clark wrote: > > > > On Mon, Sep 6, 2021 at 1:02 AM Amit Pundir wrote: > > > > > > On Sat, 4 Sept 2021 at 01:55, Rob Clark wrote: > > > > > > > >

Re: [Freedreno] [PATCH] drm/msm: Disable frequency clamping on a630

2021-09-07 Thread Rob Clark
On Tue, Sep 7, 2021 at 1:25 AM Amit Pundir wrote: > > On Tue, 7 Sept 2021 at 07:11, Rob Clark wrote: > > > > One thing I thought of, which would be worth ruling out, is whether > > this issue only occurs with freq changes immediately after resuming > > the GPU, vs f

Re: [Freedreno] [PATCH v3 5/9] drm/msm: Add deadline based boost support

2021-09-08 Thread Rob Clark
On Wed, Sep 8, 2021 at 10:48 AM Daniel Vetter wrote: > > On Fri, Sep 03, 2021 at 11:47:56AM -0700, Rob Clark wrote: > > From: Rob Clark > > > > Signed-off-by: Rob Clark > > Why do you need a kthread_work here? Is this just to make sure you're > running at

Re: [Freedreno] [PATCH igt v3 0/3] Initial igt tests for drm/msm ioctls

2021-09-08 Thread Rob Clark
On Mon, Aug 30, 2021 at 9:18 AM Rob Clark wrote: > > From: Rob Clark > > Add an initial set of tests for the gpu SUBMIT ioctl. There is > plenty more we can add, but need to start somewhere. > > Rob Clark (3): > drmtest: Add DRIVER_MSM support > msm: Add helper

Re: [Freedreno] [PATCH igt v3 0/3] Initial igt tests for drm/msm ioctls

2021-09-09 Thread Rob Clark
On Wed, Sep 8, 2021 at 10:27 PM Petri Latvala wrote: > > On Wed, Sep 08, 2021 at 11:02:42AM -0700, Rob Clark wrote: > > On Mon, Aug 30, 2021 at 9:18 AM Rob Clark wrote: > > > > > > From: Rob Clark > > > > > > Add an initial set of tests for the

Re: [Freedreno] [PATCH v3 0/9] dma-fence: Deadline awareness

2021-09-09 Thread Rob Clark
On Thu, Sep 9, 2021 at 9:16 AM Simon Ser wrote: > > Out of curiosity, would it be reasonable to allow user-space (more > precisely, the compositor) to set the deadline via an IOCTL without > actually performing an atomic commit with the FB? > > Some compositors might want to wait themselves for FB

<    1   2   3   4   5   6   7   8   9   10   >