From 583a737cb51e00192adb02e8f1087b6fff91f00f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Eder=20S=C3=A1nchez?= Date: Thu, 9 Apr 2026 14:03:21 -0600 Subject: [PATCH] Fix Windows build in ZOTAC Blackwell GPU controller --- .../ZotacBlackwellGPUController/ZotacBlackwellGPUController.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/Controllers/ZotacBlackwellGPUController/ZotacBlackwellGPUController.cpp b/Controllers/ZotacBlackwellGPUController/ZotacBlackwellGPUController.cpp index 9a441b36..361dc00d 100644 --- a/Controllers/ZotacBlackwellGPUController/ZotacBlackwellGPUController.cpp +++ b/Controllers/ZotacBlackwellGPUController/ZotacBlackwellGPUController.cpp @@ -9,7 +9,8 @@ | SPDX-License-Identifier: GPL-2.0-or-later | \*---------------------------------------------------------*/ -#include +#include +#include #include "ZotacBlackwellGPUController.h" #include "LogManager.h" @@ -107,7 +108,7 @@ void ZotacBlackwellGPUController::SetMode for(int i = 0; i < 16; i++) { bus->i2c_smbus_write_byte_data(dev, (u8)(ZOTAC_BLACKWELL_GPU_REG_FIXED + i), regs[i]); - usleep(ZOTAC_BLACKWELL_GPU_DELAY_US); + std::this_thread::sleep_for(std::chrono::microseconds(ZOTAC_BLACKWELL_GPU_DELAY_US)); } } @@ -120,5 +121,5 @@ void ZotacBlackwellGPUController::Commit() | effects don't visually update until a parameter changes. | \*---------------------------------------------------------*/ bus->i2c_smbus_write_byte_data(dev, ZOTAC_BLACKWELL_GPU_REG_COMMIT, 0x01); - usleep(ZOTAC_BLACKWELL_GPU_COMMIT_DELAY_US); + std::this_thread::sleep_for(std::chrono::microseconds(ZOTAC_BLACKWELL_GPU_COMMIT_DELAY_US)); }