Move bind logging to separate debug flag

Change-Id: I022fa8662c27228f7c559874fc042f8a31381fb5
Signed-off-by: Lukasz Jobczyk <lukasz.jobczyk@intel.com>
This commit is contained in:
Lukasz Jobczyk
2020-08-27 10:43:29 +02:00
parent b457ca27d0
commit 2368972012
3 changed files with 4 additions and 2 deletions

View File

@@ -150,7 +150,7 @@ void BufferObject::bind(OsContext *osContext, uint32_t vmHandleId) {
if (!this->bindInfo[contextId][vmHandleId]) {
auto ret = this->drm->bindBufferObject(osContext, vmHandleId, this);
auto err = this->drm->getErrno();
printDebugString(DebugManager.flags.PrintDebugMessages.get(), stderr, "bind buffer object returned with %d. errno=%d(%s)\n", ret, err, strerror(err));
printDebugString(DebugManager.flags.PrintBOBindingResult.get(), stderr, "bind BO-%d, range: %llx - %llx, size: %lld, result: %d, errno: %d(%s)\n", this->handle, this->gpuAddress, ptrOffset(this->gpuAddress, this->size), this->size, ret, err, strerror(err));
UNRECOVERABLE_IF(ret != 0);
this->bindInfo[contextId][vmHandleId] = true;
}
@@ -161,7 +161,7 @@ void BufferObject::unbind(OsContext *osContext, uint32_t vmHandleId) {
if (this->bindInfo[contextId][vmHandleId]) {
auto ret = this->drm->unbindBufferObject(osContext, vmHandleId, this);
auto err = this->drm->getErrno();
printDebugString(DebugManager.flags.PrintDebugMessages.get(), stderr, "unbind buffer object returned with %d. errno=%d(%s)\n", ret, err, strerror(err));
printDebugString(DebugManager.flags.PrintBOBindingResult.get(), stderr, "unbind BO-%d, rande: %llx - %llx, size: %lld, result: %d, errno: %d(%s)\n", this->handle, this->gpuAddress, ptrOffset(this->gpuAddress, this->size), this->size, ret, err, strerror(err));
UNRECOVERABLE_IF(ret != 0);
this->bindInfo[contextId][vmHandleId] = false;
}