mirror of
https://github.com/gnif/LookingGlass.git
synced 2025-10-11 01:48:09 +00:00
[idd] debug: add debug defines and make use of them
This commit is contained in:
@@ -102,7 +102,7 @@ bool CIVSHMEM::Init()
|
||||
{
|
||||
DWORD bus = it->busAddr >> 32;
|
||||
DWORD addr = it->busAddr & 0xFFFFFFFF;
|
||||
DBGPRINT("IVSHMEM %u%c on bus 0x%lx, device 0x%lx, function 0x%lx",
|
||||
DEBUG_INFO("IVSHMEM %u%c on bus 0x%lx, device 0x%lx, function 0x%lx",
|
||||
i, i == shmDevice ? '*' : ' ', bus, addr >> 16, addr & 0xFFFF);
|
||||
|
||||
if (i == shmDevice)
|
||||
@@ -153,7 +153,7 @@ bool CIVSHMEM::Open()
|
||||
IVSHMEM_SIZE size;
|
||||
if (!DeviceIoControl(m_handle, IOCTL_IVSHMEM_REQUEST_SIZE, nullptr, 0, &size, sizeof(size), nullptr, nullptr))
|
||||
{
|
||||
DBGPRINT("Failed to request ivshmem size");
|
||||
DEBUG_ERROR("Failed to request ivshmem size");
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -163,7 +163,7 @@ bool CIVSHMEM::Open()
|
||||
config.cacheMode = IVSHMEM_CACHE_WRITECOMBINED;
|
||||
if (!DeviceIoControl(m_handle, IOCTL_IVSHMEM_REQUEST_MMAP, &config, sizeof(config), &map, sizeof(map), nullptr, nullptr))
|
||||
{
|
||||
DBGPRINT("Failed to request ivshmem mmap");
|
||||
DEBUG_ERROR("Failed to request ivshmem mmap");
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -180,7 +180,7 @@ void CIVSHMEM::Close()
|
||||
|
||||
if (!DeviceIoControl(m_handle, IOCTL_IVSHMEM_RELEASE_MMAP, nullptr, 0, nullptr, 0, nullptr, nullptr))
|
||||
{
|
||||
DBGPRINT("Failed to release ivshmem mmap");
|
||||
DEBUG_ERROR("Failed to release ivshmem mmap");
|
||||
return;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user