Files
kernel_xiaomi_sm8250/drivers/gpu/msm/adreno_snapshot.h
Urvashi Agrawal 0a88312f6b msm: kgsl: Add Qualcomm GPU driver for kona
Add snapshot of GPU driver as of commit 9ac69cf (clk: qcom: gcc:
Support code for clock controller for sdxprairie).

Fixed compile errors,checkpatch issues, header refs and API changes:
	* Fix setup_timer API to use the new API
	* Add a missing argument to of_dma_configure
	* Rename cmd_db_get_aux_data
	* Change member name of tcs_cmd from complete to wait
	* Support new IDR_INIT API
	* Support new usage of llcc_slice_getd API
	* Remove the custom KGSL logging macros
	* Add utility functions for CP P4 identifiers
	  and CP protected mode
	* Add functions for GMU core operations
	* Add helper functions to request interrupts
	* Replace adreno_getproperty with an array
	* Remove module params
	* Fix Coccinelle warnings

Change-Id: Ifa57a94f2247fe90c713f1943882d75a60a554a5
Signed-off-by: Urvashi Agrawal <urvaagra@codeaurora.org>
2018-11-28 14:38:14 -08:00

51 lines
1.7 KiB
C

/* SPDX-License-Identifier: GPL-2.0 */
/*
* Copyright (c) 2013-2015, The Linux Foundation. All rights reserved.
*/
#ifndef __ADRENO_SNAPSHOT_H
#define __ADRENO_SNAPSHOT_H
#include "kgsl_snapshot.h"
#define CP_CRASH_DUMPER_TIMEOUT 1000
#define DEBUG_SECTION_SZ(_dwords) (((_dwords) * sizeof(unsigned int)) \
+ sizeof(struct kgsl_snapshot_debug))
#define SHADER_SECTION_SZ(_dwords) (((_dwords) * sizeof(unsigned int)) \
+ sizeof(struct kgsl_snapshot_shader))
/* Section sizes for A320 */
#define A320_SNAPSHOT_CP_STATE_SECTION_SIZE 0x2e
#define A320_SNAPSHOT_ROQ_SECTION_SIZE 512
#define A320_SNAPSHOT_CP_MERCIU_SECTION_SIZE 32
/* Macro to make it super easy to dump registers */
#define SNAPSHOT_REGISTERS(_d, _s, _r) \
adreno_snapshot_registers((_d), (_s), \
(unsigned int *) _r, ARRAY_SIZE(_r) / 2)
size_t adreno_snapshot_cp_merciu(struct kgsl_device *device, u8 *buf,
size_t remain, void *priv);
size_t adreno_snapshot_cp_roq(struct kgsl_device *device, u8 *buf,
size_t remain, void *priv);
size_t adreno_snapshot_cp_pm4_ram(struct kgsl_device *device, u8 *buf,
size_t remain, void *priv);
size_t adreno_snapshot_cp_pfp_ram(struct kgsl_device *device, u8 *buf,
size_t remain, void *priv);
size_t adreno_snapshot_cp_meq(struct kgsl_device *device, u8 *buf,
size_t remain, void *priv);
size_t adreno_snapshot_vpc_memory(struct kgsl_device *device, u8 *buf,
size_t remain, void *priv);
void adreno_snapshot_registers(struct kgsl_device *device,
struct kgsl_snapshot *snapshot,
const unsigned int *regs, unsigned int count);
void adreno_snapshot_vbif_registers(struct kgsl_device *device,
struct kgsl_snapshot *snapshot,
const struct adreno_vbif_snapshot_registers *list,
unsigned int count);
#endif /*__ADRENO_SNAPSHOT_H */