mirror of
https://github.com/followmsi/android_kernel_google_msm.git
synced 2024-11-06 23:17:41 +00:00
msm: kgsl: Always add a start identifier to a command sequence
Add command sequence start identifier for commands submitted from kgsl as well since this will be used during recovery. We will just try recovery and not try to differentiate between commands from kgsl or from user space. Change-Id: I433e9f2786268c6c51a446e3c7cf9eb5fd429197 Signed-off-by: Shubhraprakash Das <sadas@codeaurora.org>
This commit is contained in:
parent
0145b4df7d
commit
15bb6b641d
2 changed files with 6 additions and 8 deletions
|
@ -33,7 +33,6 @@
|
||||||
#define KGSL_CMD_FLAGS_NONE 0x00000000
|
#define KGSL_CMD_FLAGS_NONE 0x00000000
|
||||||
#define KGSL_CMD_FLAGS_PMODE 0x00000001
|
#define KGSL_CMD_FLAGS_PMODE 0x00000001
|
||||||
#define KGSL_CMD_FLAGS_NO_TS_CMP 0x00000002
|
#define KGSL_CMD_FLAGS_NO_TS_CMP 0x00000002
|
||||||
#define KGSL_CMD_FLAGS_NOT_KERNEL_CMD 0x00000004
|
|
||||||
|
|
||||||
/* Command identifiers */
|
/* Command identifiers */
|
||||||
#define KGSL_CONTEXT_TO_MEM_IDENTIFIER 0x2EADBEEF
|
#define KGSL_CONTEXT_TO_MEM_IDENTIFIER 0x2EADBEEF
|
||||||
|
|
|
@ -493,7 +493,8 @@ adreno_ringbuffer_addcmds(struct adreno_ringbuffer *rb,
|
||||||
*/
|
*/
|
||||||
total_sizedwords += flags & KGSL_CMD_FLAGS_PMODE ? 4 : 0;
|
total_sizedwords += flags & KGSL_CMD_FLAGS_PMODE ? 4 : 0;
|
||||||
total_sizedwords += !(flags & KGSL_CMD_FLAGS_NO_TS_CMP) ? 7 : 0;
|
total_sizedwords += !(flags & KGSL_CMD_FLAGS_NO_TS_CMP) ? 7 : 0;
|
||||||
total_sizedwords += !(flags & KGSL_CMD_FLAGS_NOT_KERNEL_CMD) ? 2 : 0;
|
/* 2 dwords to store the start of command sequence */
|
||||||
|
total_sizedwords += 2;
|
||||||
|
|
||||||
if (adreno_is_a3xx(adreno_dev))
|
if (adreno_is_a3xx(adreno_dev))
|
||||||
total_sizedwords += 7;
|
total_sizedwords += 7;
|
||||||
|
@ -521,10 +522,9 @@ adreno_ringbuffer_addcmds(struct adreno_ringbuffer *rb,
|
||||||
rcmd_gpu = rb->buffer_desc.gpuaddr
|
rcmd_gpu = rb->buffer_desc.gpuaddr
|
||||||
+ sizeof(uint)*(rb->wptr-total_sizedwords);
|
+ sizeof(uint)*(rb->wptr-total_sizedwords);
|
||||||
|
|
||||||
if (!(flags & KGSL_CMD_FLAGS_NOT_KERNEL_CMD)) {
|
GSL_RB_WRITE(ringcmds, rcmd_gpu, cp_nop_packet(1));
|
||||||
GSL_RB_WRITE(ringcmds, rcmd_gpu, cp_nop_packet(1));
|
GSL_RB_WRITE(ringcmds, rcmd_gpu, KGSL_CMD_IDENTIFIER);
|
||||||
GSL_RB_WRITE(ringcmds, rcmd_gpu, KGSL_CMD_IDENTIFIER);
|
|
||||||
}
|
|
||||||
if (flags & KGSL_CMD_FLAGS_PMODE) {
|
if (flags & KGSL_CMD_FLAGS_PMODE) {
|
||||||
/* disable protected mode error checking */
|
/* disable protected mode error checking */
|
||||||
GSL_RB_WRITE(ringcmds, rcmd_gpu,
|
GSL_RB_WRITE(ringcmds, rcmd_gpu,
|
||||||
|
@ -926,8 +926,7 @@ adreno_ringbuffer_issueibcmds(struct kgsl_device_private *dev_priv,
|
||||||
adreno_drawctxt_switch(adreno_dev, drawctxt, flags);
|
adreno_drawctxt_switch(adreno_dev, drawctxt, flags);
|
||||||
|
|
||||||
*timestamp = adreno_ringbuffer_addcmds(&adreno_dev->ringbuffer,
|
*timestamp = adreno_ringbuffer_addcmds(&adreno_dev->ringbuffer,
|
||||||
drawctxt,
|
drawctxt, 0,
|
||||||
KGSL_CMD_FLAGS_NOT_KERNEL_CMD,
|
|
||||||
&link[0], (cmds - link));
|
&link[0], (cmds - link));
|
||||||
|
|
||||||
KGSL_CMD_INFO(device, "ctxt %d g %08x numibs %d ts %d\n",
|
KGSL_CMD_INFO(device, "ctxt %d g %08x numibs %d ts %d\n",
|
||||||
|
|
Loading…
Reference in a new issue