[Freedreno] [PATCH 05/10] drm/msm/gpu: Rearrange the code that collects the task during a hang

2018-04-05 Thread Jordan Crouse
Do a bit of cleanup to prepare for upcoming changes to pass the hanging task comm and cmdline to the crash dump function. Signed-off-by: Jordan Crouse --- drivers/gpu/drm/msm/msm_gpu.c | 18 ++ 1 file changed, 10 insertions(+), 8 deletions(-) diff --git

[Freedreno] [PATCH 03/10] drm/msm/gpu: Capture the state of the GPU

2018-04-05 Thread Jordan Crouse
Add the infrastructure to capture the state current state of the GPU and store it in memory. This is useful for storing the state of a hung GPU so it can be dumped later. For now grab the same basic ringbuffer information and registers that are provided by the debugfs 'gpu' node but obviously

[Freedreno] [v4 00/10] drm/msm: GPU crash state

2018-04-05 Thread Jordan Crouse
This is revision 4 implementing a GPU crash state for drm/msm (https://patchwork.freedesktop.org/series/36097/). I think its mature enough to pull out of RFC status and think about merging. The goal is to store and provide enough information to debug software and hardware issues on the Adreno

[Freedreno] [PATCH 07/10] drm/msm/adreno: Convert the show/crash file format

2018-04-05 Thread Jordan Crouse
Convert the format of the 'show' debugfs file and the crash dump to a format resembling YAML. This should be easier to parse and be more flexible for future changes and expansions. Signed-off-by: Jordan Crouse --- Documentation/gpu/drm-msm-crash-dump.txt | 30

[Freedreno] [PATCH 04/10] drm/msm/gpu: Convert the GPU show function to use the GPU state

2018-04-05 Thread Jordan Crouse
Convert the existing GPU show function to use the GPU state to dump the information rather than reading it directly from the hardware. This will require an additional step to capture the state before dumping it for the existing nodes but it will greatly facilitate reusing the same code for dumping

[Freedreno] [PATCH 01/10] include: Move ascii85 functions from i915 to linux/ascii85.h

2018-04-05 Thread Jordan Crouse
The i915 DRM driver very cleverly used ascii85 encoding for their GPU state file. Move the encode functions to a general header file to support other drivers that might be interested in the same functionality. Reviewed-by: Chris Wilson Signed-off-by: Jordan Crouse

[Freedreno] [PATCH 09/10] drm/msm/adreno: Add a5xx specific registers for the GPU state

2018-04-05 Thread Jordan Crouse
HLSQ, SP and TP registers are only accessible from a special aperture and to make matters worse the aperture is blocked from the CPU on targets that can support secure rendering. Luckily the GPU hardware has its own purpose built register dumper that can access the registers from the aperture.

[Freedreno] [PATCH 08/10] drm/msm/adreno: Add ringbuffer data to the GPU state

2018-04-05 Thread Jordan Crouse
Add the contents of each ringbuffer to the GPU state and dump the data in the crash file encoded with ascii85. To save space only the used portions of the ringbuffer are dumped. Signed-off-by: Jordan Crouse --- Documentation/gpu/drm-msm-crash-dump.txt | 5

[Freedreno] [PATCH 02/10] drm: drm_printer: Add printer for devcoredump

2018-04-05 Thread Jordan Crouse
Add a drm printer suitable for use with the read callback for devcoredump or any other file operation read() function that isn't otherwise covered by seq_file. Signed-off-by: Jordan Crouse --- drivers/gpu/drm/drm_print.c | 54 +

[Freedreno] [PATCH 06/10] drm/msm/gpu: Capture the GPU state on a GPU hang

2018-04-05 Thread Jordan Crouse
Capture the GPU state on a GPU hang and store it for later playback via the devcoredump facility. Only one crash state is stored at a time on the assumption that the first hang is usually the most interesting. The existing crash state can be cleared after capturing it and then a new one will be

Re: [Freedreno] [PATCH 01/10] include: Move ascii85 functions from i915 to linux/ascii85.h

2018-04-05 Thread Jordan Crouse
On Thu, Apr 05, 2018 at 04:00:47PM -0600, Jordan Crouse wrote: > The i915 DRM driver very cleverly used ascii85 encoding for their > GPU state file. Move the encode functions to a general header file to > support other drivers that might be interested in the same > functionality. In a previous

Re: [Freedreno] [RFC] drm/atomic+msm: add helper to implement legacy dirtyfb

2018-04-05 Thread Rob Clark
On Thu, Apr 5, 2018 at 9:30 AM, Thomas Hellstrom wrote: > On 04/04/2018 11:56 AM, Daniel Vetter wrote: >> >> On Wed, Apr 04, 2018 at 11:10:08AM +0200, Thomas Hellstrom wrote: >>> >>> On 04/04/2018 10:43 AM, Daniel Vetter wrote: On Wed, Apr 04, 2018 at 10:22:21AM

Re: [Freedreno] [RFC] drm/atomic+msm: add helper to implement legacy dirtyfb

2018-04-05 Thread Deepak Singh Rawat
> >>> 1) Expose a dirty (or content_age property) > >>> 2) Attach a clip-rect blob property. > >>> 3) Fake a page-flip by ping-ponging two frame-buffers pointing to the > >>> same > >>> underlying buffer object. > >>> > >>> Are you saying that people are already using 3) and we should keep > using

Re: [Freedreno] [PATCH 2/5] arm64:dts:sdm845: Add support for GPU LLCC

2018-04-05 Thread Vivek Gautam
Hi Sharat, On 3/23/2018 12:49 PM, Sharat Masetty wrote: Add client side bindings required for the GPU to use the last level system cache. Also add a register range in the GPU CX domain. Signed-off-by: Sharat Masetty --- arch/arm64/boot/dts/qcom/sdm845.dtsi | 8

Re: [Freedreno] [PATCH 5/5] drm/msm/A6xx: Add support for using system cache(llc)

2018-04-05 Thread Vivek Gautam
Hi Sharat, On 3/23/2018 12:49 PM, Sharat Masetty wrote: The last level system cache can be partitioned to 32 different slices of which GPU has two slices preallocated. The "gpu" slice is used for caching GPU buffers and the "gpuhtw" slice is used for caching the GPU SMMU pagetables. This

Re: [Freedreno] [PATCH 4/5] drm/msm: Pass mmu features to generic layers

2018-04-05 Thread Vivek Gautam
Hi Sharat, On 3/23/2018 12:49 PM, Sharat Masetty wrote: Allow different Adreno targets the ability to pass specific mmu features to the generic layers. This will help conditionally configure certain iommu features for certain Adreno targets. Also Add a few simple support functions to support

Re: [Freedreno] [RFC] drm/atomic+msm: add helper to implement legacy dirtyfb

2018-04-05 Thread Daniel Vetter
On Thu, Apr 5, 2018 at 3:30 PM, Thomas Hellstrom wrote: > On 04/04/2018 11:56 AM, Daniel Vetter wrote: >> >> On Wed, Apr 04, 2018 at 11:10:08AM +0200, Thomas Hellstrom wrote: >>> >>> On 04/04/2018 10:43 AM, Daniel Vetter wrote: On Wed, Apr 04, 2018 at 10:22:21AM

Re: [Freedreno] [RFC] drm/atomic+msm: add helper to implement legacy dirtyfb

2018-04-05 Thread Thomas Hellstrom
On 04/04/2018 11:56 AM, Daniel Vetter wrote: On Wed, Apr 04, 2018 at 11:10:08AM +0200, Thomas Hellstrom wrote: On 04/04/2018 10:43 AM, Daniel Vetter wrote: On Wed, Apr 04, 2018 at 10:22:21AM +0200, Thomas Hellstrom wrote: Hi, On 04/04/2018 08:58 AM, Daniel Vetter wrote: On Wed, Apr 4, 2018

[Freedreno] [PATCH 9/9] drm/msm: Always obey implicit fencing

2018-04-05 Thread Daniel Vetter
Again same justification as for drm_gem_fb_prepare_fb(). Definitely needs some testing because Rob doesn't remember why he did this, and Google/git.fd.o or anything also doesn't shed some light on it. Signed-off-by: Daniel Vetter Cc: Rob Clark Cc:

[Freedreno] [PATCH 07/13] drm/msm: Stop updating plane->fb/crtc

2018-04-05 Thread Ville Syrjala
From: Ville Syrjälä We want to get rid of plane->fb/crtc on atomic drivers. Stop setting them. v2: Catch a few more cases Cc: Rob Clark Cc: linux-arm-...@vger.kernel.org Cc: freedreno@lists.freedesktop.org Signed-off-by: Ville Syrjälä

[Freedreno] [PATCH 01/13] drm/msm: Stop consulting plane->fb/crtc

2018-04-05 Thread Ville Syrjala
From: Ville Syrjälä We want to get rid of plane->fb/crtc on atomic drivers. Stop looking at them. v2: Catch the plane->crtc case too Cc: Rob Clark Cc: linux-arm-...@vger.kernel.org Cc: freedreno@lists.freedesktop.org Signed-off-by: Ville

Re: [Freedreno] [PATCH 07/13] drm/msm: Stop updating plane->fb/crtc

2018-04-05 Thread Daniel Vetter
On Thu, Apr 05, 2018 at 06:13:54PM +0300, Ville Syrjala wrote: > From: Ville Syrjälä > > We want to get rid of plane->fb/crtc on atomic drivers. Stop setting > them. > > v2: Catch a few more cases > > Cc: Rob Clark > Cc:

Re: [Freedreno] [PATCH 01/13] drm/msm: Stop consulting plane->fb/crtc

2018-04-05 Thread Daniel Vetter
On Thu, Apr 05, 2018 at 06:13:48PM +0300, Ville Syrjala wrote: > From: Ville Syrjälä > > We want to get rid of plane->fb/crtc on atomic drivers. Stop > looking at them. > > v2: Catch the plane->crtc case too > > Cc: Rob Clark > Cc: