From ec59cc59b05f7b9f67c5efa2fbbb039b65a95ed1 Mon Sep 17 00:00:00 2001 From: Adam Honse Date: Fri, 31 May 2024 11:41:23 -0500 Subject: [PATCH] Update MSI GPU controller files to new standardized header comment --- .../MSIGPUController/MSIGPUController.cpp | 14 ++++++----- .../MSIGPUController/MSIGPUController.h | 18 +++++++------- .../MSIGPUControllerDetect.cpp | 24 ++++++++++--------- .../MSIGPUController/RGBController_MSIGPU.cpp | 18 +++++++------- .../MSIGPUController/RGBController_MSIGPU.h | 14 ++++++----- 5 files changed, 49 insertions(+), 39 deletions(-) diff --git a/Controllers/MSIGPUController/MSIGPUController/MSIGPUController.cpp b/Controllers/MSIGPUController/MSIGPUController/MSIGPUController.cpp index 13ab609d..f75f853e 100644 --- a/Controllers/MSIGPUController/MSIGPUController/MSIGPUController.cpp +++ b/Controllers/MSIGPUController/MSIGPUController/MSIGPUController.cpp @@ -1,9 +1,11 @@ -/*-----------------------------------------*\ -| MSIGPUController.cpp | -| | -| Driver for MSI GPUs | -| | -\*-----------------------------------------*/ +/*---------------------------------------------------------*\ +| MSIGPUController.cpp | +| | +| Driver for MSI GPU | +| | +| This file is part of the OpenRGB project | +| SPDX-License-Identifier: GPL-2.0-only | +\*---------------------------------------------------------*/ #include "MSIGPUController.h" #include diff --git a/Controllers/MSIGPUController/MSIGPUController/MSIGPUController.h b/Controllers/MSIGPUController/MSIGPUController/MSIGPUController.h index d3be2e12..0d3c3034 100644 --- a/Controllers/MSIGPUController/MSIGPUController/MSIGPUController.h +++ b/Controllers/MSIGPUController/MSIGPUController/MSIGPUController.h @@ -1,15 +1,17 @@ -/*-----------------------------------------*\ -| MSIGPUController.h | -| | -| Definitions for MSI GPUs | -| | -\*-----------------------------------------*/ +/*---------------------------------------------------------*\ +| MSIGPUController.h | +| | +| Driver for MSI GPU | +| | +| This file is part of the OpenRGB project | +| SPDX-License-Identifier: GPL-2.0-only | +\*---------------------------------------------------------*/ + +#pragma once #include #include "i2c_smbus.h" -#pragma once - typedef unsigned char msi_gpu_dev_id; #define MSI_GPU_SPEED_MIN 0 diff --git a/Controllers/MSIGPUController/MSIGPUController/MSIGPUControllerDetect.cpp b/Controllers/MSIGPUController/MSIGPUController/MSIGPUControllerDetect.cpp index 2b536a3c..89c0a9f3 100644 --- a/Controllers/MSIGPUController/MSIGPUController/MSIGPUControllerDetect.cpp +++ b/Controllers/MSIGPUController/MSIGPUController/MSIGPUControllerDetect.cpp @@ -1,10 +1,15 @@ -/*-----------------------------------------*\ -| MSIGPUControllerDetect.cpp | -| | -| Driver for MSI GPUs | -| | -\*-----------------------------------------*/ +/*---------------------------------------------------------*\ +| MSIGPUControllerDetect.cpp | +| | +| Detector for MSI GPU | +| | +| This file is part of the OpenRGB project | +| SPDX-License-Identifier: GPL-2.0-only | +\*---------------------------------------------------------*/ +#include +#include +#include #include "Detector.h" #include "MSIGPUController.h" #include "LogManager.h" @@ -12,15 +17,12 @@ #include "RGBController_MSIGPU.h" #include "i2c_smbus.h" #include "pci_ids.h" -#include -#include -#include /******************************************************************************************\ * * -* DetectMSIGPUControllers * +* DetectMSIGPUControllers * * * -* Detect MSI GPU controllers on the enumerated I2C busses. * +* Detect MSI GPU controllers on the enumerated I2C busses. * * * \******************************************************************************************/ diff --git a/Controllers/MSIGPUController/MSIGPUController/RGBController_MSIGPU.cpp b/Controllers/MSIGPUController/MSIGPUController/RGBController_MSIGPU.cpp index ae64e596..7db1fe5f 100644 --- a/Controllers/MSIGPUController/MSIGPUController/RGBController_MSIGPU.cpp +++ b/Controllers/MSIGPUController/MSIGPUController/RGBController_MSIGPU.cpp @@ -1,12 +1,14 @@ -/*-----------------------------------------*\ -| RGBController_MSIGPU.h | -| | -| Generic RGB Interface for MSI GPU | -| | -\*-----------------------------------------*/ +/*---------------------------------------------------------*\ +| RGBController_MSIGPU.cpp | +| | +| RGBController for MSI GPU | +| | +| This file is part of the OpenRGB project | +| SPDX-License-Identifier: GPL-2.0-only | +\*---------------------------------------------------------*/ -#include "RGBController_MSIGPU.h" #include +#include "RGBController_MSIGPU.h" static const std::array speed_values = { 0x04, 0x02, 0x01 }; @@ -424,7 +426,7 @@ void RGBController_MSIGPU::UpdateSingleLED(int /*led*/) void RGBController_MSIGPU::DeviceUpdateMode() { if(TimeToSend()) - { + { if(modes[active_mode].flags & MODE_FLAG_HAS_BRIGHTNESS) { msi_gpu->MSIGPURegisterWrite(MSI_GPU_REG_BRIGHTNESS, modes[active_mode].brightness * MSI_GPU_BRIGHTNESS_MULTI); diff --git a/Controllers/MSIGPUController/MSIGPUController/RGBController_MSIGPU.h b/Controllers/MSIGPUController/MSIGPUController/RGBController_MSIGPU.h index f305233f..24a6b3a2 100644 --- a/Controllers/MSIGPUController/MSIGPUController/RGBController_MSIGPU.h +++ b/Controllers/MSIGPUController/MSIGPUController/RGBController_MSIGPU.h @@ -1,9 +1,11 @@ -/*-----------------------------------------*\ -| RGBController_MSIGPU.h | -| | -| Generic RGB Interface for MSI GPU | -| | -\*-----------------------------------------*/ +/*---------------------------------------------------------*\ +| RGBController_MSIGPU.h | +| | +| RGBController for MSI GPU | +| | +| This file is part of the OpenRGB project | +| SPDX-License-Identifier: GPL-2.0-only | +\*---------------------------------------------------------*/ #pragma once