File indexing completed on 2024-05-12 17:00:15
0001 /* 0002 * SPDX-FileCopyrightText: 2020 Arjen Hiemstra <ahiemstra@heimr.nl> 0003 * 0004 * SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL 0005 */ 0006 0007 #pragma once 0008 0009 #include "GpuDevice.h" 0010 0011 struct udev_device; 0012 0013 namespace KSysGuard 0014 { 0015 class SysFsSensor; 0016 } 0017 0018 class LinuxAmdGpu : public GpuDevice 0019 { 0020 Q_OBJECT 0021 0022 public: 0023 LinuxAmdGpu(const QString& id, const QString& name, udev_device *device); 0024 ~LinuxAmdGpu() override; 0025 0026 void initialize() override; 0027 void update() override; 0028 0029 protected: 0030 void makeSensors() override; 0031 0032 private: 0033 void discoverSensors(); 0034 0035 udev_device *m_device; 0036 QVector<KSysGuard::SysFsSensor*> m_sysFsSensors; 0037 QVector<KSysGuard::SensorProperty*> m_sensorsSensors; 0038 };