diff --git a/media_driver/linux/common/os/mos_gpucontext_specific.cpp b/media_driver/linux/common/os/mos_gpucontext_specific.cpp index 6ae7ef4c2b2..2c2a15aa845 100644 --- a/media_driver/linux/common/os/mos_gpucontext_specific.cpp +++ b/media_driver/linux/common/os/mos_gpucontext_specific.cpp @@ -1097,6 +1097,8 @@ MOS_STATUS GpuContextSpecific::SubmitCommandBuffer( return MOS_STATUS_UNKNOWN; } } + // dump before cmd buffer unmap + MOS_TraceDumpExt("CmdBuffer", m_gpuContext, cmdBuffer->pCmdBase, cmdBuffer->iOffset); // Now, we can unmap the video command buffer, since we don't need CPU access anymore. MOS_OS_CHK_NULL_RETURN(cmdBuffer->OsResource.pGfxResource); diff --git a/media_softlet/agnostic/common/os/mos_utilities.h b/media_softlet/agnostic/common/os/mos_utilities.h index 19baf6bb920..9556b52f8dd 100644 --- a/media_softlet/agnostic/common/os/mos_utilities.h +++ b/media_softlet/agnostic/common/os/mos_utilities.h @@ -3308,7 +3308,10 @@ inline void MOS_TraceDataDump( const void *pBuf, uint32_t dwSize) { - MosUtilities::MosTraceDataDump(pcName, flags, pBuf, dwSize); + if (MosUtilities::TraceKeyEnabled(TR_KEY_DATA_DUMP)) + { + MosUtilities::MosTraceDataDump(pcName, flags, pBuf, dwSize); + } } inline void MOS_TraceDataDump( diff --git a/media_softlet/linux/common/os/mos_gpucontext_specific_next.cpp b/media_softlet/linux/common/os/mos_gpucontext_specific_next.cpp index 8abbaed4c1c..2a9b050e2fe 100644 --- a/media_softlet/linux/common/os/mos_gpucontext_specific_next.cpp +++ b/media_softlet/linux/common/os/mos_gpucontext_specific_next.cpp @@ -1445,6 +1445,8 @@ MOS_STATUS GpuContextSpecificNext::SubmitCommandBuffer( return MOS_STATUS_UNKNOWN; } } + // dump before cmd buffer unmap + MOS_TraceDumpExt("CmdBuffer", m_gpuContext, cmdBuffer->pCmdBase, cmdBuffer->iOffset); // Now, we can unmap the video command buffer, since we don't need CPU access anymore. MOS_OS_CHK_NULL_RETURN(cmdBuffer->OsResource.pGfxResourceNext);