lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20200812150459.GB3221@jcrouse1-lnx.qualcomm.com>
Date:   Wed, 12 Aug 2020 09:05:00 -0600
From:   Jordan Crouse <jcrouse@...eaurora.org>
To:     Rob Clark <robdclark@...il.com>
Cc:     dri-devel@...ts.freedesktop.org,
        Rob Clark <robdclark@...omium.org>,
        Sean Paul <sean@...rly.run>, David Airlie <airlied@...ux.ie>,
        Daniel Vetter <daniel@...ll.ch>,
        Sharat Masetty <smasetty@...eaurora.org>,
        Jonathan Marek <jonathan@...ek.ca>,
        AngeloGioacchino Del Regno <kholk11@...il.com>,
        Shawn Guo <shawn.guo@...aro.org>,
        Wambui Karuga <wambui.karugax@...il.com>,
        Brian Masney <masneyb@...tation.org>,
        "open list:DRM DRIVER FOR MSM ADRENO GPU" 
        <linux-arm-msm@...r.kernel.org>,
        "open list:DRM DRIVER FOR MSM ADRENO GPU" 
        <freedreno@...ts.freedesktop.org>,
        open list <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] drm/msm/a6xx: add module param to enable debugbus
 snapshot

On Tue, Aug 11, 2020 at 04:36:57PM -0700, Rob Clark wrote:
> From: Rob Clark <robdclark@...omium.org>
> 
> For production devices, the debugbus sections will typically be fused
> off and empty in the gpu device coredump.  But since this may contain
> data like cache contents, don't capture it by default.

Reviewed-by: Jordan Crouse <jcrouse@...eaurora.org>

> Signed-off-by: Rob Clark <robdclark@...omium.org>
> ---
>  drivers/gpu/drm/msm/adreno/a6xx_gpu_state.c | 3 ++-
>  drivers/gpu/drm/msm/adreno/adreno_device.c  | 4 ++++
>  drivers/gpu/drm/msm/adreno/adreno_gpu.h     | 2 ++
>  3 files changed, 8 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/msm/adreno/a6xx_gpu_state.c b/drivers/gpu/drm/msm/adreno/a6xx_gpu_state.c
> index 959656ad6987..b12f5b4a1bea 100644
> --- a/drivers/gpu/drm/msm/adreno/a6xx_gpu_state.c
> +++ b/drivers/gpu/drm/msm/adreno/a6xx_gpu_state.c
> @@ -938,7 +938,8 @@ struct msm_gpu_state *a6xx_gpu_state_get(struct msm_gpu *gpu)
>  		msm_gem_kernel_put(dumper.bo, gpu->aspace, true);
>  	}
>  
> -	a6xx_get_debugbus(gpu, a6xx_state);
> +	if (snapshot_debugbus)
> +		a6xx_get_debugbus(gpu, a6xx_state);
>  
>  	return  &a6xx_state->base;
>  }
> diff --git a/drivers/gpu/drm/msm/adreno/adreno_device.c b/drivers/gpu/drm/msm/adreno/adreno_device.c
> index 4e84f3c76f4f..9eeb46bf2a5d 100644
> --- a/drivers/gpu/drm/msm/adreno/adreno_device.c
> +++ b/drivers/gpu/drm/msm/adreno/adreno_device.c
> @@ -14,6 +14,10 @@ bool hang_debug = false;
>  MODULE_PARM_DESC(hang_debug, "Dump registers when hang is detected (can be slow!)");
>  module_param_named(hang_debug, hang_debug, bool, 0600);
>  
> +bool snapshot_debugbus = false;
> +MODULE_PARM_DESC(snapshot_debugbus, "Include debugbus sections in GPU devcoredump (if not fused off)");
> +module_param_named(snapshot_debugbus, snapshot_debugbus, bool, 0600);
> +
>  static const struct adreno_info gpulist[] = {
>  	{
>  		.rev   = ADRENO_REV(2, 0, 0, 0),
> diff --git a/drivers/gpu/drm/msm/adreno/adreno_gpu.h b/drivers/gpu/drm/msm/adreno/adreno_gpu.h
> index 99bb468f5f24..e55abae365b5 100644
> --- a/drivers/gpu/drm/msm/adreno/adreno_gpu.h
> +++ b/drivers/gpu/drm/msm/adreno/adreno_gpu.h
> @@ -21,6 +21,8 @@
>  #define REG_SKIP ~0
>  #define REG_ADRENO_SKIP(_offset) [_offset] = REG_SKIP
>  
> +extern bool snapshot_debugbus;
> +
>  /**
>   * adreno_regs: List of registers that are used in across all
>   * 3D devices. Each device type has different offset value for the same
> -- 
> 2.26.2
> 

-- 
The Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum,
a Linux Foundation Collaborative Project

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ