[Freedreno] [PATCH v2 2/3] drm/msm/shrinker: We can vmap shrink active_list too

2020-11-16 Thread Rob Clark
From: Rob Clark Just because a obj is active, if the vmap_count is zero, we can still tear down the vmap. Signed-off-by: Rob Clark --- drivers/gpu/drm/msm/msm_gem_shrinker.c | 47 +++--- 1 file changed, 35 insertions(+), 12 deletions(-) diff --git

[Freedreno] [PATCH v2 0/3] drm/msm: Shrinker fixes and opts

2020-11-16 Thread Rob Clark
From: Rob Clark The last patch is the main thing, motivated by some cases where we would spend a lot of time in msm_gem_shrinker_count(). First two are fixes I noticed along the way. Rob Clark (3): drm/msm: Protect obj->active_count under obj lock drm/msm/shrinker: We can vmap shrink

[Freedreno] [PATCH v2 3/3] drm/msm/shrinker: Only iterate dontneed objs

2020-11-16 Thread Rob Clark
From: Rob Clark In situations where the GPU is mostly idle, all or nearly all buffer objects will be in the inactive list. But if the system is under memory pressure (from something other than GPU), we could still get a lot of shrinker calls. Which results in traversing a list of thousands of

[Freedreno] [PATCH 17/42] drm/msm/disp/mdp5/mdp5_ctl: Demote non-conformant kernel-doc headers

2020-11-16 Thread Lee Jones
Very little attempt has been made to document these functions. Fixes the following W=1 kernel build warning(s): drivers/gpu/drm/msm/disp/mdp5/mdp5_ctl.c:227: warning: Function parameter or member 'ctl' not described in 'mdp5_ctl_set_encoder_state' drivers/gpu/drm/msm/disp/mdp5/mdp5_ctl.c:227:

[Freedreno] [PATCH 18/42] drm/msm/disp/mdp5/mdp5_kms: Make local functions 'mdp5_{en, dis}able()' static

2020-11-16 Thread Lee Jones
Fixes the following W=1 kernel build warning(s): drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.c:299:5: warning: no previous prototype for ‘mdp5_disable’ [-Wmissing-prototypes] drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.c:319:5: warning: no previous prototype for ‘mdp5_enable’ [-Wmissing-prototypes]

[Freedreno] [PATCH 15/42] drm/msm/adreno/a6xx_gpu: Staticise local function 'a6xx_idle'

2020-11-16 Thread Lee Jones
Fixes the following W=1 kernel build warning(s): drivers/gpu/drm/msm/adreno/a6xx_gpu.c:33:6: warning: no previous prototype for ‘a6xx_idle’ [-Wmissing-prototypes] Cc: Rob Clark Cc: Sean Paul Cc: David Airlie Cc: Daniel Vetter Cc: linux-arm-...@vger.kernel.org Cc:

[Freedreno] [PATCH 16/42] drm/msm/disp/mdp5/mdp5_crtc: Make local function 'mdp5_crtc_setup_pipeline()' static

2020-11-16 Thread Lee Jones
Fixes the following W=1 kernel build warning(s): drivers/gpu/drm/msm/disp/mdp5/mdp5_crtc.c:581:5: warning: no previous prototype for ‘mdp5_crtc_setup_pipeline’ [-Wmissing-prototypes] Cc: Rob Clark Cc: Sean Paul Cc: David Airlie Cc: Daniel Vetter Cc: Thomas Zimmermann Cc:

[Freedreno] [PATCH 20/42] drm/msm/disp/dpu1/dpu_encoder: Remove a bunch of unused variables

2020-11-16 Thread Lee Jones
Fixes the following W=1 kernel build warning(s): drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c: In function ‘dpu_encoder_virt_mode_set’: drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c:981:31: warning: variable ‘num_dspp’ set but not used [-Wunused-but-set-variable]

[Freedreno] [PATCH 19/42] drm/msm/disp/dpu1/dpu_core_perf: Remove set but unused variable 'dpu_cstate'

2020-11-16 Thread Lee Jones
Fixes the following W=1 kernel build warning(s): drivers/gpu/drm/msm/disp/dpu1/dpu_core_perf.c: In function ‘_dpu_core_perf_calc_crtc’: drivers/gpu/drm/msm/disp/dpu1/dpu_core_perf.c:113:25: warning: variable ‘dpu_cstate’ set but not used [-Wunused-but-set-variable] Cc: Rob Clark Cc: Sean

Re: [Freedreno] [RESEND PATCH v2 4/5] drm/msm: add DRM_MSM_GEM_SYNC_CACHE for non-coherent cache maintenance

2020-11-16 Thread Christoph Hellwig
On Sat, Nov 14, 2020 at 03:07:20PM -0500, Jonathan Marek wrote: > qcom's vulkan driver has nonCoherentAtomSize=1, and it looks like > dma_sync_single_for_cpu() does deal in some way with the partial cache line > case, although I'm not sure that means we can have a nonCoherentAtomSize=1. No, it

[Freedreno] [RESEND 00/42] Rid W=1 warnings from GPU (non-Radeon)

2020-11-16 Thread Lee Jones
This set contains fixes for some "wouldn't it be nice if" issues, however most of the patches seen here have been on the MLs, but were left unreviewed. Lee Jones (42): drm/amd/amdgpu/atombios_encoders: Remove set but unused variable 'backlight_level' drm/armada/armada_overlay: Staticify

Re: [Freedreno] [PATCH 3/3] drm/msm/shrinker: Only iterate dontneed objs

2020-11-16 Thread Rob Clark
On Mon, Nov 16, 2020 at 9:20 AM Jordan Crouse wrote: > > On Sat, Nov 14, 2020 at 11:30:10AM -0800, Rob Clark wrote: > > From: Rob Clark > > > > In situations where the GPU is mostly idle, all or nearly all buffer > > objects will be in the inactive list. But if the system is under memory > >

Re: [Freedreno] [RESEND PATCH v2 4/5] drm/msm: add DRM_MSM_GEM_SYNC_CACHE for non-coherent cache maintenance

2020-11-16 Thread Jordan Crouse
On Sat, Nov 14, 2020 at 11:39:45AM -0800, Rob Clark wrote: > On Sat, Nov 14, 2020 at 10:58 AM Jonathan Marek wrote: > > > > On 11/14/20 1:46 PM, Rob Clark wrote: > > > On Sat, Nov 14, 2020 at 8:24 AM Christoph Hellwig wrote: > > >> > > >> On Sat, Nov 14, 2020 at 10:17:12AM -0500, Jonathan Marek

Re: [Freedreno] [RESEND PATCH v2 4/5] drm/msm: add DRM_MSM_GEM_SYNC_CACHE for non-coherent cache maintenance

2020-11-16 Thread Jordan Crouse
On Sat, Nov 14, 2020 at 10:17:12AM -0500, Jonathan Marek wrote: > This makes it possible to use the non-coherent cached MSM_BO_CACHED mode, > which otherwise doesn't provide any method for cleaning/invalidating the > cache to sync with the device. > > Signed-off-by: Jonathan Marek > --- >

Re: [Freedreno] [PATCH 3/3] drm/msm/shrinker: Only iterate dontneed objs

2020-11-16 Thread Jordan Crouse
On Sat, Nov 14, 2020 at 11:30:10AM -0800, Rob Clark wrote: > From: Rob Clark > > In situations where the GPU is mostly idle, all or nearly all buffer > objects will be in the inactive list. But if the system is under memory > pressure (from something other than GPU), we could still get a lot of

Re: [Freedreno] [PATCH] drm/msm: adreno: Make speed-bin support generic

2020-11-16 Thread Jordan Crouse
On Mon, Nov 16, 2020 at 07:40:03PM +0530, Akhil P Oommen wrote: > On 11/12/2020 10:05 PM, Jordan Crouse wrote: > >On Thu, Nov 12, 2020 at 09:19:04PM +0530, Akhil P Oommen wrote: > >>So far a530v2 gpu has support for detecting its supported opps > >>based on a fuse value called speed-bin. This

Re: [Freedreno] [PATCH] drm/msm: adreno: Make speed-bin support generic

2020-11-16 Thread Rob Clark
On Mon, Nov 16, 2020 at 6:34 AM Akhil P Oommen wrote: > > On 11/12/2020 10:07 PM, Rob Clark wrote: > > On Thu, Nov 12, 2020 at 7:49 AM Akhil P Oommen > > wrote: > >> > >> So far a530v2 gpu has support for detecting its supported opps > >> based on a fuse value called speed-bin. This patch makes

Re: [Freedreno] [PATCH V2 Resend 1/2] drm/lima: Unconditionally call dev_pm_opp_of_remove_table()

2020-11-16 Thread Qiang Yu
Applied to drm-misc-next. On Wed, Oct 28, 2020 at 2:44 PM Viresh Kumar wrote: > > dev_pm_opp_of_remove_table() doesn't report any errors when it fails to > find the OPP table with error -ENODEV (i.e. OPP table not present for > the device). And we can call dev_pm_opp_of_remove_table() >

Re: [Freedreno] [PATCH] drm/msm: adreno: Make speed-bin support generic

2020-11-16 Thread Akhil P Oommen
On 11/12/2020 10:07 PM, Rob Clark wrote: On Thu, Nov 12, 2020 at 7:49 AM Akhil P Oommen wrote: So far a530v2 gpu has support for detecting its supported opps based on a fuse value called speed-bin. This patch makes this support generic across gpu families. This is in preparation to extend

Re: [Freedreno] [PATCH] drm/msm: adreno: Make speed-bin support generic

2020-11-16 Thread Akhil P Oommen
On 11/12/2020 10:05 PM, Jordan Crouse wrote: On Thu, Nov 12, 2020 at 09:19:04PM +0530, Akhil P Oommen wrote: So far a530v2 gpu has support for detecting its supported opps based on a fuse value called speed-bin. This patch makes this support generic across gpu families. This is in preparation