| 1 |
/* automatically generated by rust-bindgen 0.70.1 */ |
| 2 |
|
| 3 |
// Copyright (C) 2024 Advanced Micro Devices. All rights reserved. |
| 4 |
// |
| 5 |
// Permission is hereby granted, free of charge, to any person obtaining a copy of |
| 6 |
// this software and associated documentation files (the "Software"), to deal in |
| 7 |
// the Software without restriction, including without limitation the rights to |
| 8 |
// use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of |
| 9 |
// the Software, and to permit persons to whom the Software is furnished to do so, |
| 10 |
// subject to the following conditions: |
| 11 |
// |
| 12 |
// The above copyright notice and this permission notice shall be included in all |
| 13 |
// copies or substantial portions of the Software. |
| 14 |
// |
| 15 |
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR |
| 16 |
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS |
| 17 |
// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR |
| 18 |
// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER |
| 19 |
// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN |
| 20 |
// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. |
| 21 |
|
| 22 |
#![allow(non_upper_case_globals)] |
| 23 |
|
| 24 |
#[repr(C)] |
| 25 |
#[derive(Copy, Clone, Debug, Default, Eq, Hash, Ord, PartialEq, PartialOrd)] |
| 26 |
pub struct __BindgenBitfieldUnit<Storage> { |
| 27 |
storage: Storage, |
| 28 |
} |
| 29 |
impl<Storage> __BindgenBitfieldUnit<Storage> { |
| 30 |
#[inline] |
| 31 |
pub const fn new(storage: Storage) -> Self { |
| 32 |
Self { storage } |
| 33 |
} |
| 34 |
} |
| 35 |
impl<Storage> __BindgenBitfieldUnit<Storage> |
| 36 |
where |
| 37 |
Storage: AsRef<[u8]> + AsMut<[u8]>, |
| 38 |
{ |
| 39 |
#[inline] |
| 40 |
pub fn get_bit(&self, index: usize) -> bool { |
| 41 |
debug_assert!(index / 8 < self.storage.as_ref().len()); |
| 42 |
let byte_index = index / 8; |
| 43 |
let byte = self.storage.as_ref()[byte_index]; |
| 44 |
let bit_index = if cfg!(target_endian = "big") { |
| 45 |
7 - (index % 8) |
| 46 |
} else { |
| 47 |
index % 8 |
| 48 |
}; |
| 49 |
let mask = 1 << bit_index; |
| 50 |
byte & mask == mask |
| 51 |
} |
| 52 |
#[inline] |
| 53 |
pub fn set_bit(&mut self, index: usize, val: bool) { |
| 54 |
debug_assert!(index / 8 < self.storage.as_ref().len()); |
| 55 |
let byte_index = index / 8; |
| 56 |
let byte = &mut self.storage.as_mut()[byte_index]; |
| 57 |
let bit_index = if cfg!(target_endian = "big") { |
| 58 |
7 - (index % 8) |
| 59 |
} else { |
| 60 |
index % 8 |
| 61 |
}; |
| 62 |
let mask = 1 << bit_index; |
| 63 |
if val { |
| 64 |
*byte |= mask; |
| 65 |
} else { |
| 66 |
*byte &= !mask; |
| 67 |
} |
| 68 |
} |
| 69 |
#[inline] |
| 70 |
pub fn get(&self, bit_offset: usize, bit_width: u8) -> u64 { |
| 71 |
debug_assert!(bit_width <= 64); |
| 72 |
debug_assert!(bit_offset / 8 < self.storage.as_ref().len()); |
| 73 |
debug_assert!((bit_offset + (bit_width as usize)) / 8 <= self.storage.as_ref().len()); |
| 74 |
let mut val = 0; |
| 75 |
for i in 0..(bit_width as usize) { |
| 76 |
if self.get_bit(i + bit_offset) { |
| 77 |
let index = if cfg!(target_endian = "big") { |
| 78 |
bit_width as usize - 1 - i |
| 79 |
} else { |
| 80 |
i |
| 81 |
}; |
| 82 |
val |= 1 << index; |
| 83 |
} |
| 84 |
} |
| 85 |
val |
| 86 |
} |
| 87 |
#[inline] |
| 88 |
pub fn set(&mut self, bit_offset: usize, bit_width: u8, val: u64) { |
| 89 |
debug_assert!(bit_width <= 64); |
| 90 |
debug_assert!(bit_offset / 8 < self.storage.as_ref().len()); |
| 91 |
debug_assert!((bit_offset + (bit_width as usize)) / 8 <= self.storage.as_ref().len()); |
| 92 |
for i in 0..(bit_width as usize) { |
| 93 |
let mask = 1 << i; |
| 94 |
let val_bit_is_set = val & mask == mask; |
| 95 |
let index = if cfg!(target_endian = "big") { |
| 96 |
bit_width as usize - 1 - i |
| 97 |
} else { |
| 98 |
i |
| 99 |
}; |
| 100 |
self.set_bit(index + bit_offset, val_bit_is_set); |
| 101 |
} |
| 102 |
} |
| 103 |
} |
| 104 |
pub const AMDSMI_MAX_MM_IP_COUNT: u32 = 8; |
| 105 |
pub const AMDSMI_MAX_STRING_LENGTH: u32 = 256; |
| 106 |
pub const AMDSMI_MAX_DEVICES: u32 = 32; |
| 107 |
pub const AMDSMI_MAX_CACHE_TYPES: u32 = 10; |
| 108 |
pub const AMDSMI_MAX_ACCELERATOR_PROFILE: u32 = 32; |
| 109 |
pub const AMDSMI_MAX_CP_PROFILE_RESOURCES: u32 = 32; |
| 110 |
pub const AMDSMI_MAX_ACCELERATOR_PARTITIONS: u32 = 8; |
| 111 |
pub const AMDSMI_MAX_NUM_NUMA_NODES: u32 = 32; |
| 112 |
pub const AMDSMI_GPU_UUID_SIZE: u32 = 38; |
| 113 |
pub const AMDSMI_MAX_NUM_XGMI_PHYSICAL_LINK: u32 = 64; |
| 114 |
pub const AMDSMI_MAX_CONTAINER_TYPE: u32 = 2; |
| 115 |
pub const AMDSMI_NUM_HBM_INSTANCES: u32 = 4; |
| 116 |
pub const AMDSMI_MAX_NUM_VCN: u32 = 4; |
| 117 |
pub const AMDSMI_MAX_NUM_CLKS: u32 = 4; |
| 118 |
pub const AMDSMI_MAX_NUM_XGMI_LINKS: u32 = 8; |
| 119 |
pub const AMDSMI_MAX_NUM_GFX_CLKS: u32 = 8; |
| 120 |
pub const AMDSMI_MAX_AID: u32 = 4; |
| 121 |
pub const AMDSMI_MAX_ENGINES: u32 = 8; |
| 122 |
pub const AMDSMI_MAX_NUM_JPEG: u32 = 32; |
| 123 |
pub const AMDSMI_MAX_NUM_JPEG_ENG_V1: u32 = 40; |
| 124 |
pub const AMDSMI_MAX_NUM_XCC: u32 = 8; |
| 125 |
pub const AMDSMI_MAX_NUM_XCP: u32 = 8; |
| 126 |
pub const AMDSMI_TIME_FORMAT: &[u8; 20] = b"%02d:%02d:%02d.%03d\0"; |
| 127 |
pub const AMDSMI_DATE_FORMAT: &[u8; 35] = b"%04d-%02d-%02d:%02d:%02d:%02d.%03d\0"; |
| 128 |
pub const AMDSMI_LIB_VERSION_MAJOR: u32 = 26; |
| 129 |
pub const AMDSMI_LIB_VERSION_MINOR: u32 = 2; |
| 130 |
pub const AMDSMI_LIB_VERSION_RELEASE: u32 = 1; |
| 131 |
pub const AMDSMI_MAX_NUM_FREQUENCIES: u32 = 33; |
| 132 |
pub const AMDSMI_MAX_FAN_SPEED: u32 = 255; |
| 133 |
pub const AMDSMI_NUM_VOLTAGE_CURVE_POINTS: u32 = 3; |
| 134 |
pub const AMDSMI_MAX_UTILIZATION_VALUES: u32 = 4; |
| 135 |
pub const AMDSMI_MAX_NUM_PM_POLICIES: u32 = 32; |
| 136 |
#[repr(u32)] |
| 137 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 138 |
pub enum AmdsmiInitFlagsT { |
| 139 |
AmdsmiInitAllProcessors = 4294967295, |
| 140 |
AmdsmiInitAmdCpus = 1, |
| 141 |
AmdsmiInitAmdGpus = 2, |
| 142 |
AmdsmiInitNonAmdCpus = 4, |
| 143 |
AmdsmiInitNonAmdGpus = 8, |
| 144 |
AmdsmiInitAmdApus = 3, |
| 145 |
} |
| 146 |
#[repr(u32)] |
| 147 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 148 |
pub enum AmdsmiMmIpT { |
| 149 |
AmdsmiMmUvd = 0, |
| 150 |
AmdsmiMmVce = 1, |
| 151 |
AmdsmiMmVcn = 2, |
| 152 |
AmdsmiMmMax = 3, |
| 153 |
} |
| 154 |
#[repr(u32)] |
| 155 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 156 |
pub enum AmdsmiContainerTypesT { |
| 157 |
AmdsmiContainerLxc = 0, |
| 158 |
AmdsmiContainerDocker = 1, |
| 159 |
} |
| 160 |
pub type AmdsmiProcessorHandle = *mut ::std::os::raw::c_void; |
| 161 |
pub type AmdsmiSocketHandle = *mut ::std::os::raw::c_void; |
| 162 |
#[repr(u32)] |
| 163 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 164 |
pub enum ProcessorTypeT { |
| 165 |
AmdsmiProcessorTypeUnknown = 0, |
| 166 |
AmdsmiProcessorTypeAmdGpu = 1, |
| 167 |
AmdsmiProcessorTypeAmdCpu = 2, |
| 168 |
AmdsmiProcessorTypeNonAmdGpu = 3, |
| 169 |
AmdsmiProcessorTypeNonAmdCpu = 4, |
| 170 |
AmdsmiProcessorTypeAmdCpuCore = 5, |
| 171 |
AmdsmiProcessorTypeAmdApu = 6, |
| 172 |
} |
| 173 |
#[repr(u32)] |
| 174 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 175 |
pub enum AmdsmiStatusT { |
| 176 |
AmdsmiStatusSuccess = 0, |
| 177 |
AmdsmiStatusInval = 1, |
| 178 |
AmdsmiStatusNotSupported = 2, |
| 179 |
AmdsmiStatusNotYetImplemented = 3, |
| 180 |
AmdsmiStatusFailLoadModule = 4, |
| 181 |
AmdsmiStatusFailLoadSymbol = 5, |
| 182 |
AmdsmiStatusDrmError = 6, |
| 183 |
AmdsmiStatusApiFailed = 7, |
| 184 |
AmdsmiStatusTimeout = 8, |
| 185 |
AmdsmiStatusRetry = 9, |
| 186 |
AmdsmiStatusNoPerm = 10, |
| 187 |
AmdsmiStatusInterrupt = 11, |
| 188 |
AmdsmiStatusIo = 12, |
| 189 |
AmdsmiStatusAddressFault = 13, |
| 190 |
AmdsmiStatusFileError = 14, |
| 191 |
AmdsmiStatusOutOfResources = 15, |
| 192 |
AmdsmiStatusInternalException = 16, |
| 193 |
AmdsmiStatusInputOutOfBounds = 17, |
| 194 |
AmdsmiStatusInitError = 18, |
| 195 |
AmdsmiStatusRefcountOverflow = 19, |
| 196 |
AmdsmiStatusDirectoryNotFound = 20, |
| 197 |
AmdsmiStatusBusy = 30, |
| 198 |
AmdsmiStatusNotFound = 31, |
| 199 |
AmdsmiStatusNotInit = 32, |
| 200 |
AmdsmiStatusNoSlot = 33, |
| 201 |
AmdsmiStatusDriverNotLoaded = 34, |
| 202 |
AmdsmiStatusMoreData = 39, |
| 203 |
AmdsmiStatusNoData = 40, |
| 204 |
AmdsmiStatusInsufficientSize = 41, |
| 205 |
AmdsmiStatusUnexpectedSize = 42, |
| 206 |
AmdsmiStatusUnexpectedData = 43, |
| 207 |
AmdsmiStatusNonAmdCpu = 44, |
| 208 |
AmdsmiStatusNoEnergyDrv = 45, |
| 209 |
AmdsmiStatusNoMsrDrv = 46, |
| 210 |
AmdsmiStatusNoHsmpDrv = 47, |
| 211 |
AmdsmiStatusNoHsmpSup = 48, |
| 212 |
AmdsmiStatusNoHsmpMsgSup = 49, |
| 213 |
AmdsmiStatusHsmpTimeout = 50, |
| 214 |
AmdsmiStatusNoDrv = 51, |
| 215 |
AmdsmiStatusFileNotFound = 52, |
| 216 |
AmdsmiStatusArgPtrNull = 53, |
| 217 |
AmdsmiStatusAmdgpuRestartErr = 54, |
| 218 |
AmdsmiStatusSettingUnavailable = 55, |
| 219 |
AmdsmiStatusCorruptedEeprom = 56, |
| 220 |
AmdsmiStatusMapError = 4294967294, |
| 221 |
AmdsmiStatusUnknownError = 4294967295, |
| 222 |
} |
| 223 |
impl AmdsmiClkTypeT { |
| 224 |
pub const AmdsmiClkTypeFirst: AmdsmiClkTypeT = AmdsmiClkTypeT::AmdsmiClkTypeSys; |
| 225 |
} |
| 226 |
impl AmdsmiClkTypeT { |
| 227 |
pub const AmdsmiClkTypeGfx: AmdsmiClkTypeT = AmdsmiClkTypeT::AmdsmiClkTypeSys; |
| 228 |
} |
| 229 |
impl AmdsmiClkTypeT { |
| 230 |
pub const AmdsmiClkTypeMax: AmdsmiClkTypeT = AmdsmiClkTypeT::AmdsmiClkTypeDclk1; |
| 231 |
} |
| 232 |
#[repr(u32)] |
| 233 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 234 |
pub enum AmdsmiClkTypeT { |
| 235 |
AmdsmiClkTypeSys = 0, |
| 236 |
AmdsmiClkTypeDf = 1, |
| 237 |
AmdsmiClkTypeDcef = 2, |
| 238 |
AmdsmiClkTypeSoc = 3, |
| 239 |
AmdsmiClkTypeMem = 4, |
| 240 |
AmdsmiClkTypePcie = 5, |
| 241 |
AmdsmiClkTypeVclk0 = 6, |
| 242 |
AmdsmiClkTypeVclk1 = 7, |
| 243 |
AmdsmiClkTypeDclk0 = 8, |
| 244 |
AmdsmiClkTypeDclk1 = 9, |
| 245 |
} |
| 246 |
#[repr(u32)] |
| 247 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 248 |
pub enum AmdsmiAcceleratorPartitionTypeT { |
| 249 |
AmdsmiAcceleratorPartitionInvalid = 0, |
| 250 |
AmdsmiAcceleratorPartitionSpx = 1, |
| 251 |
AmdsmiAcceleratorPartitionDpx = 2, |
| 252 |
AmdsmiAcceleratorPartitionTpx = 3, |
| 253 |
AmdsmiAcceleratorPartitionQpx = 4, |
| 254 |
AmdsmiAcceleratorPartitionCpx = 5, |
| 255 |
AmdsmiAcceleratorPartitionMax = 6, |
| 256 |
} |
| 257 |
#[repr(u32)] |
| 258 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 259 |
pub enum AmdsmiAcceleratorPartitionResourceTypeT { |
| 260 |
AmdsmiAcceleratorXcc = 0, |
| 261 |
AmdsmiAcceleratorEncoder = 1, |
| 262 |
AmdsmiAcceleratorDecoder = 2, |
| 263 |
AmdsmiAcceleratorDma = 3, |
| 264 |
AmdsmiAcceleratorJpeg = 4, |
| 265 |
AmdsmiAcceleratorMax = 5, |
| 266 |
} |
| 267 |
#[repr(u32)] |
| 268 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 269 |
pub enum AmdsmiComputePartitionTypeT { |
| 270 |
AmdsmiComputePartitionInvalid = 0, |
| 271 |
AmdsmiComputePartitionSpx = 1, |
| 272 |
AmdsmiComputePartitionDpx = 2, |
| 273 |
AmdsmiComputePartitionTpx = 3, |
| 274 |
AmdsmiComputePartitionQpx = 4, |
| 275 |
AmdsmiComputePartitionCpx = 5, |
| 276 |
} |
| 277 |
#[repr(u32)] |
| 278 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 279 |
pub enum AmdsmiMemoryPartitionTypeT { |
| 280 |
AmdsmiMemoryPartitionUnknown = 0, |
| 281 |
AmdsmiMemoryPartitionNps1 = 1, |
| 282 |
AmdsmiMemoryPartitionNps2 = 2, |
| 283 |
AmdsmiMemoryPartitionNps4 = 4, |
| 284 |
AmdsmiMemoryPartitionNps8 = 8, |
| 285 |
} |
| 286 |
impl AmdsmiTemperatureTypeT { |
| 287 |
pub const AmdsmiTemperatureTypeFirst: AmdsmiTemperatureTypeT = |
| 288 |
AmdsmiTemperatureTypeT::AmdsmiTemperatureTypeEdge; |
| 289 |
} |
| 290 |
impl AmdsmiTemperatureTypeT { |
| 291 |
pub const AmdsmiTemperatureTypeJunction: AmdsmiTemperatureTypeT = |
| 292 |
AmdsmiTemperatureTypeT::AmdsmiTemperatureTypeHotspot; |
| 293 |
} |
| 294 |
impl AmdsmiTemperatureTypeT { |
| 295 |
pub const AmdsmiTemperatureTypeGpuboardNodeRetimerX: AmdsmiTemperatureTypeT = |
| 296 |
AmdsmiTemperatureTypeT::AmdsmiTemperatureTypeGpuboardNodeFirst; |
| 297 |
} |
| 298 |
impl AmdsmiTemperatureTypeT { |
| 299 |
pub const AmdsmiTemperatureTypeGpuboardVddcrVdd0: AmdsmiTemperatureTypeT = |
| 300 |
AmdsmiTemperatureTypeT::AmdsmiTemperatureTypeGpuboardVrFirst; |
| 301 |
} |
| 302 |
impl AmdsmiTemperatureTypeT { |
| 303 |
pub const AmdsmiTemperatureTypeBaseboardUbbFpga: AmdsmiTemperatureTypeT = |
| 304 |
AmdsmiTemperatureTypeT::AmdsmiTemperatureTypeBaseboardFirst; |
| 305 |
} |
| 306 |
impl AmdsmiTemperatureTypeT { |
| 307 |
pub const AmdsmiTemperatureTypeMax: AmdsmiTemperatureTypeT = |
| 308 |
AmdsmiTemperatureTypeT::AmdsmiTemperatureTypeBaseboardLast; |
| 309 |
} |
| 310 |
#[repr(u32)] |
| 311 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 312 |
pub enum AmdsmiTemperatureTypeT { |
| 313 |
AmdsmiTemperatureTypeEdge = 0, |
| 314 |
AmdsmiTemperatureTypeHotspot = 1, |
| 315 |
AmdsmiTemperatureTypeVram = 2, |
| 316 |
AmdsmiTemperatureTypeHbm0 = 3, |
| 317 |
AmdsmiTemperatureTypeHbm1 = 4, |
| 318 |
AmdsmiTemperatureTypeHbm2 = 5, |
| 319 |
AmdsmiTemperatureTypeHbm3 = 6, |
| 320 |
AmdsmiTemperatureTypePlx = 7, |
| 321 |
AmdsmiTemperatureTypeGpuboardNodeFirst = 100, |
| 322 |
AmdsmiTemperatureTypeGpuboardNodeOamXIbc = 101, |
| 323 |
AmdsmiTemperatureTypeGpuboardNodeOamXIbc2 = 102, |
| 324 |
AmdsmiTemperatureTypeGpuboardNodeOamXVdd18Vr = 103, |
| 325 |
AmdsmiTemperatureTypeGpuboardNodeOamX04HbmBVr = 104, |
| 326 |
AmdsmiTemperatureTypeGpuboardNodeOamX04HbmDVr = 105, |
| 327 |
AmdsmiTemperatureTypeGpuboardNodeLast = 149, |
| 328 |
AmdsmiTemperatureTypeGpuboardVrFirst = 150, |
| 329 |
AmdsmiTemperatureTypeGpuboardVddcrVdd1 = 151, |
| 330 |
AmdsmiTemperatureTypeGpuboardVddcrVdd2 = 152, |
| 331 |
AmdsmiTemperatureTypeGpuboardVddcrVdd3 = 153, |
| 332 |
AmdsmiTemperatureTypeGpuboardVddcrSocA = 154, |
| 333 |
AmdsmiTemperatureTypeGpuboardVddcrSocC = 155, |
| 334 |
AmdsmiTemperatureTypeGpuboardVddcrSocioA = 156, |
| 335 |
AmdsmiTemperatureTypeGpuboardVddcrSocioC = 157, |
| 336 |
AmdsmiTemperatureTypeGpuboardVdd085Hbm = 158, |
| 337 |
AmdsmiTemperatureTypeGpuboardVddcr11HbmB = 159, |
| 338 |
AmdsmiTemperatureTypeGpuboardVddcr11HbmD = 160, |
| 339 |
AmdsmiTemperatureTypeGpuboardVddUsr = 161, |
| 340 |
AmdsmiTemperatureTypeGpuboardVddio11E32 = 162, |
| 341 |
AmdsmiTemperatureTypeGpuboardVrLast = 199, |
| 342 |
AmdsmiTemperatureTypeBaseboardFirst = 200, |
| 343 |
AmdsmiTemperatureTypeBaseboardUbbFront = 201, |
| 344 |
AmdsmiTemperatureTypeBaseboardUbbBack = 202, |
| 345 |
AmdsmiTemperatureTypeBaseboardUbbOam7 = 203, |
| 346 |
AmdsmiTemperatureTypeBaseboardUbbIbc = 204, |
| 347 |
AmdsmiTemperatureTypeBaseboardUbbUfpga = 205, |
| 348 |
AmdsmiTemperatureTypeBaseboardUbbOam1 = 206, |
| 349 |
AmdsmiTemperatureTypeBaseboardOam01Hsc = 207, |
| 350 |
AmdsmiTemperatureTypeBaseboardOam23Hsc = 208, |
| 351 |
AmdsmiTemperatureTypeBaseboardOam45Hsc = 209, |
| 352 |
AmdsmiTemperatureTypeBaseboardOam67Hsc = 210, |
| 353 |
AmdsmiTemperatureTypeBaseboardUbbFpga0v72Vr = 211, |
| 354 |
AmdsmiTemperatureTypeBaseboardUbbFpga3v3Vr = 212, |
| 355 |
AmdsmiTemperatureTypeBaseboardRetimer01231v2Vr = 213, |
| 356 |
AmdsmiTemperatureTypeBaseboardRetimer45671v2Vr = 214, |
| 357 |
AmdsmiTemperatureTypeBaseboardRetimer010v9Vr = 215, |
| 358 |
AmdsmiTemperatureTypeBaseboardRetimer450v9Vr = 216, |
| 359 |
AmdsmiTemperatureTypeBaseboardRetimer230v9Vr = 217, |
| 360 |
AmdsmiTemperatureTypeBaseboardRetimer670v9Vr = 218, |
| 361 |
AmdsmiTemperatureTypeBaseboardOam01233v3Vr = 219, |
| 362 |
AmdsmiTemperatureTypeBaseboardOam45673v3Vr = 220, |
| 363 |
AmdsmiTemperatureTypeBaseboardIbcHsc = 221, |
| 364 |
AmdsmiTemperatureTypeBaseboardIbc = 222, |
| 365 |
AmdsmiTemperatureTypeBaseboardLast = 249, |
| 366 |
} |
| 367 |
impl AmdsmiFwBlockT { |
| 368 |
pub const AmdsmiFwIdFirst: AmdsmiFwBlockT = AmdsmiFwBlockT::AmdsmiFwIdSmu; |
| 369 |
} |
| 370 |
#[repr(u32)] |
| 371 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 372 |
pub enum AmdsmiFwBlockT { |
| 373 |
AmdsmiFwIdSmu = 1, |
| 374 |
AmdsmiFwIdCpCe = 2, |
| 375 |
AmdsmiFwIdCpPfp = 3, |
| 376 |
AmdsmiFwIdCpMe = 4, |
| 377 |
AmdsmiFwIdCpMecJt1 = 5, |
| 378 |
AmdsmiFwIdCpMecJt2 = 6, |
| 379 |
AmdsmiFwIdCpMec1 = 7, |
| 380 |
AmdsmiFwIdCpMec2 = 8, |
| 381 |
AmdsmiFwIdRlc = 9, |
| 382 |
AmdsmiFwIdSdma0 = 10, |
| 383 |
AmdsmiFwIdSdma1 = 11, |
| 384 |
AmdsmiFwIdSdma2 = 12, |
| 385 |
AmdsmiFwIdSdma3 = 13, |
| 386 |
AmdsmiFwIdSdma4 = 14, |
| 387 |
AmdsmiFwIdSdma5 = 15, |
| 388 |
AmdsmiFwIdSdma6 = 16, |
| 389 |
AmdsmiFwIdSdma7 = 17, |
| 390 |
AmdsmiFwIdVcn = 18, |
| 391 |
AmdsmiFwIdUvd = 19, |
| 392 |
AmdsmiFwIdVce = 20, |
| 393 |
AmdsmiFwIdIsp = 21, |
| 394 |
AmdsmiFwIdDmcuEram = 22, |
| 395 |
AmdsmiFwIdDmcuIsr = 23, |
| 396 |
AmdsmiFwIdRlcRestoreListGpmMem = 24, |
| 397 |
AmdsmiFwIdRlcRestoreListSrmMem = 25, |
| 398 |
AmdsmiFwIdRlcRestoreListCntl = 26, |
| 399 |
AmdsmiFwIdRlcV = 27, |
| 400 |
AmdsmiFwIdMmsch = 28, |
| 401 |
AmdsmiFwIdPspSysdrv = 29, |
| 402 |
AmdsmiFwIdPspSosdrv = 30, |
| 403 |
AmdsmiFwIdPspToc = 31, |
| 404 |
AmdsmiFwIdPspKeydb = 32, |
| 405 |
AmdsmiFwIdDfc = 33, |
| 406 |
AmdsmiFwIdPspSpl = 34, |
| 407 |
AmdsmiFwIdDrvCap = 35, |
| 408 |
AmdsmiFwIdMc = 36, |
| 409 |
AmdsmiFwIdPspBl = 37, |
| 410 |
AmdsmiFwIdCpPm4 = 38, |
| 411 |
AmdsmiFwIdRlcP = 39, |
| 412 |
AmdsmiFwIdSecPolicyStage2 = 40, |
| 413 |
AmdsmiFwIdRegAccessWhitelist = 41, |
| 414 |
AmdsmiFwIdImuDram = 42, |
| 415 |
AmdsmiFwIdImuIram = 43, |
| 416 |
AmdsmiFwIdSdmaTh0 = 44, |
| 417 |
AmdsmiFwIdSdmaTh1 = 45, |
| 418 |
AmdsmiFwIdCpMes = 46, |
| 419 |
AmdsmiFwIdMesKiq = 47, |
| 420 |
AmdsmiFwIdMesStack = 48, |
| 421 |
AmdsmiFwIdMesThread1 = 49, |
| 422 |
AmdsmiFwIdMesThread1Stack = 50, |
| 423 |
AmdsmiFwIdRlx6 = 51, |
| 424 |
AmdsmiFwIdRlx6DramBoot = 52, |
| 425 |
AmdsmiFwIdRs64Me = 53, |
| 426 |
AmdsmiFwIdRs64MeP0Data = 54, |
| 427 |
AmdsmiFwIdRs64MeP1Data = 55, |
| 428 |
AmdsmiFwIdRs64Pfp = 56, |
| 429 |
AmdsmiFwIdRs64PfpP0Data = 57, |
| 430 |
AmdsmiFwIdRs64PfpP1Data = 58, |
| 431 |
AmdsmiFwIdRs64Mec = 59, |
| 432 |
AmdsmiFwIdRs64MecP0Data = 60, |
| 433 |
AmdsmiFwIdRs64MecP1Data = 61, |
| 434 |
AmdsmiFwIdRs64MecP2Data = 62, |
| 435 |
AmdsmiFwIdRs64MecP3Data = 63, |
| 436 |
AmdsmiFwIdPptable = 64, |
| 437 |
AmdsmiFwIdPspSoc = 65, |
| 438 |
AmdsmiFwIdPspDbg = 66, |
| 439 |
AmdsmiFwIdPspIntf = 67, |
| 440 |
AmdsmiFwIdRlx6Core1 = 68, |
| 441 |
AmdsmiFwIdRlx6DramBootCore1 = 69, |
| 442 |
AmdsmiFwIdRlcvLx7 = 70, |
| 443 |
AmdsmiFwIdRlcSaveRestoreList = 71, |
| 444 |
AmdsmiFwIdAsd = 72, |
| 445 |
AmdsmiFwIdTaRas = 73, |
| 446 |
AmdsmiFwIdTaXgmi = 74, |
| 447 |
AmdsmiFwIdRlcSrlg = 75, |
| 448 |
AmdsmiFwIdRlcSrls = 76, |
| 449 |
AmdsmiFwIdPm = 77, |
| 450 |
AmdsmiFwIdDmcu = 78, |
| 451 |
AmdsmiFwIdPldmBundle = 79, |
| 452 |
AmdsmiFwIdMax = 80, |
| 453 |
} |
| 454 |
impl AmdsmiVramTypeT { |
| 455 |
pub const AmdsmiVramTypeMax: AmdsmiVramTypeT = AmdsmiVramTypeT::AmdsmiVramTypeGddr7; |
| 456 |
} |
| 457 |
#[repr(u32)] |
| 458 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 459 |
pub enum AmdsmiVramTypeT { |
| 460 |
AmdsmiVramTypeUnknown = 0, |
| 461 |
AmdsmiVramTypeHbm = 1, |
| 462 |
AmdsmiVramTypeHbm2 = 2, |
| 463 |
AmdsmiVramTypeHbm2e = 3, |
| 464 |
AmdsmiVramTypeHbm3 = 4, |
| 465 |
AmdsmiVramTypeDdr2 = 10, |
| 466 |
AmdsmiVramTypeDdr3 = 11, |
| 467 |
AmdsmiVramTypeDdr4 = 12, |
| 468 |
AmdsmiVramTypeGddr1 = 17, |
| 469 |
AmdsmiVramTypeGddr2 = 18, |
| 470 |
AmdsmiVramTypeGddr3 = 19, |
| 471 |
AmdsmiVramTypeGddr4 = 20, |
| 472 |
AmdsmiVramTypeGddr5 = 21, |
| 473 |
AmdsmiVramTypeGddr6 = 22, |
| 474 |
AmdsmiVramTypeGddr7 = 23, |
| 475 |
} |
| 476 |
#[repr(C)] |
| 477 |
#[derive(Debug, Copy, Clone)] |
| 478 |
pub struct AmdsmiRangeT { |
| 479 |
pub lower_bound: u64, |
| 480 |
pub upper_bound: u64, |
| 481 |
pub reserved: [u64; 2usize], |
| 482 |
} |
| 483 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 484 |
const _: () = { |
| 485 |
["Size of AmdsmiRangeT"][::std::mem::size_of::<AmdsmiRangeT>() - 32usize]; |
| 486 |
["Alignment of AmdsmiRangeT"][::std::mem::align_of::<AmdsmiRangeT>() - 8usize]; |
| 487 |
["Offset of field: AmdsmiRangeT::lower_bound"] |
| 488 |
[::std::mem::offset_of!(AmdsmiRangeT, lower_bound) - 0usize]; |
| 489 |
["Offset of field: AmdsmiRangeT::upper_bound"] |
| 490 |
[::std::mem::offset_of!(AmdsmiRangeT, upper_bound) - 8usize]; |
| 491 |
["Offset of field: AmdsmiRangeT::reserved"] |
| 492 |
[::std::mem::offset_of!(AmdsmiRangeT, reserved) - 16usize]; |
| 493 |
}; |
| 494 |
#[repr(C)] |
| 495 |
#[derive(Debug, Copy, Clone)] |
| 496 |
pub struct AmdsmiXgmiInfoT { |
| 497 |
pub xgmi_lanes: u8, |
| 498 |
pub xgmi_hive_id: u64, |
| 499 |
pub xgmi_node_id: u64, |
| 500 |
pub index: u32, |
| 501 |
pub reserved: [u32; 9usize], |
| 502 |
} |
| 503 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 504 |
const _: () = { |
| 505 |
["Size of AmdsmiXgmiInfoT"][::std::mem::size_of::<AmdsmiXgmiInfoT>() - 64usize]; |
| 506 |
["Alignment of AmdsmiXgmiInfoT"][::std::mem::align_of::<AmdsmiXgmiInfoT>() - 8usize]; |
| 507 |
["Offset of field: AmdsmiXgmiInfoT::xgmi_lanes"] |
| 508 |
[::std::mem::offset_of!(AmdsmiXgmiInfoT, xgmi_lanes) - 0usize]; |
| 509 |
["Offset of field: AmdsmiXgmiInfoT::xgmi_hive_id"] |
| 510 |
[::std::mem::offset_of!(AmdsmiXgmiInfoT, xgmi_hive_id) - 8usize]; |
| 511 |
["Offset of field: AmdsmiXgmiInfoT::xgmi_node_id"] |
| 512 |
[::std::mem::offset_of!(AmdsmiXgmiInfoT, xgmi_node_id) - 16usize]; |
| 513 |
["Offset of field: AmdsmiXgmiInfoT::index"] |
| 514 |
[::std::mem::offset_of!(AmdsmiXgmiInfoT, index) - 24usize]; |
| 515 |
["Offset of field: AmdsmiXgmiInfoT::reserved"] |
| 516 |
[::std::mem::offset_of!(AmdsmiXgmiInfoT, reserved) - 28usize]; |
| 517 |
}; |
| 518 |
#[repr(C)] |
| 519 |
#[derive(Debug, Copy, Clone)] |
| 520 |
pub struct AmdsmiVramUsageT { |
| 521 |
pub vram_total: u32, |
| 522 |
pub vram_used: u32, |
| 523 |
pub reserved: [u32; 2usize], |
| 524 |
} |
| 525 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 526 |
const _: () = { |
| 527 |
["Size of AmdsmiVramUsageT"][::std::mem::size_of::<AmdsmiVramUsageT>() - 16usize]; |
| 528 |
["Alignment of AmdsmiVramUsageT"][::std::mem::align_of::<AmdsmiVramUsageT>() - 4usize]; |
| 529 |
["Offset of field: AmdsmiVramUsageT::vram_total"] |
| 530 |
[::std::mem::offset_of!(AmdsmiVramUsageT, vram_total) - 0usize]; |
| 531 |
["Offset of field: AmdsmiVramUsageT::vram_used"] |
| 532 |
[::std::mem::offset_of!(AmdsmiVramUsageT, vram_used) - 4usize]; |
| 533 |
["Offset of field: AmdsmiVramUsageT::reserved"] |
| 534 |
[::std::mem::offset_of!(AmdsmiVramUsageT, reserved) - 8usize]; |
| 535 |
}; |
| 536 |
#[repr(C)] |
| 537 |
#[derive(Debug, Copy, Clone)] |
| 538 |
pub struct AmdsmiViolationStatusT { |
| 539 |
pub reference_timestamp: u64, |
| 540 |
pub violation_timestamp: u64, |
| 541 |
pub acc_counter: u64, |
| 542 |
pub acc_prochot_thrm: u64, |
| 543 |
pub acc_ppt_pwr: u64, |
| 544 |
pub acc_socket_thrm: u64, |
| 545 |
pub acc_vr_thrm: u64, |
| 546 |
pub acc_hbm_thrm: u64, |
| 547 |
pub acc_gfx_clk_below_host_limit: u64, |
| 548 |
pub per_prochot_thrm: u64, |
| 549 |
pub per_ppt_pwr: u64, |
| 550 |
pub per_socket_thrm: u64, |
| 551 |
pub per_vr_thrm: u64, |
| 552 |
pub per_hbm_thrm: u64, |
| 553 |
pub per_gfx_clk_below_host_limit: u64, |
| 554 |
pub active_prochot_thrm: u8, |
| 555 |
pub active_ppt_pwr: u8, |
| 556 |
pub active_socket_thrm: u8, |
| 557 |
pub active_vr_thrm: u8, |
| 558 |
pub active_hbm_thrm: u8, |
| 559 |
pub active_gfx_clk_below_host_limit: u8, |
| 560 |
pub acc_gfx_clk_below_host_limit_pwr: [[u64; 8usize]; 8usize], |
| 561 |
pub acc_gfx_clk_below_host_limit_thm: [[u64; 8usize]; 8usize], |
| 562 |
pub acc_low_utilization: [[u64; 8usize]; 8usize], |
| 563 |
pub acc_gfx_clk_below_host_limit_total: [[u64; 8usize]; 8usize], |
| 564 |
pub per_gfx_clk_below_host_limit_pwr: [[u64; 8usize]; 8usize], |
| 565 |
pub per_gfx_clk_below_host_limit_thm: [[u64; 8usize]; 8usize], |
| 566 |
pub per_low_utilization: [[u64; 8usize]; 8usize], |
| 567 |
pub per_gfx_clk_below_host_limit_total: [[u64; 8usize]; 8usize], |
| 568 |
pub active_gfx_clk_below_host_limit_pwr: [[u8; 8usize]; 8usize], |
| 569 |
pub active_gfx_clk_below_host_limit_thm: [[u8; 8usize]; 8usize], |
| 570 |
pub active_low_utilization: [[u8; 8usize]; 8usize], |
| 571 |
pub active_gfx_clk_below_host_limit_total: [[u8; 8usize]; 8usize], |
| 572 |
pub reserved: [[u64; 8usize]; 8usize], |
| 573 |
pub reserved2: [[u64; 8usize]; 8usize], |
| 574 |
pub reserved3: [[u64; 8usize]; 8usize], |
| 575 |
} |
| 576 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 577 |
const _: () = { |
| 578 |
["Size of AmdsmiViolationStatusT"][::std::mem::size_of::<AmdsmiViolationStatusT>() - 6016usize]; |
| 579 |
["Alignment of AmdsmiViolationStatusT"] |
| 580 |
[::std::mem::align_of::<AmdsmiViolationStatusT>() - 8usize]; |
| 581 |
["Offset of field: AmdsmiViolationStatusT::reference_timestamp"] |
| 582 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, reference_timestamp) - 0usize]; |
| 583 |
["Offset of field: AmdsmiViolationStatusT::violation_timestamp"] |
| 584 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, violation_timestamp) - 8usize]; |
| 585 |
["Offset of field: AmdsmiViolationStatusT::acc_counter"] |
| 586 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, acc_counter) - 16usize]; |
| 587 |
["Offset of field: AmdsmiViolationStatusT::acc_prochot_thrm"] |
| 588 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, acc_prochot_thrm) - 24usize]; |
| 589 |
["Offset of field: AmdsmiViolationStatusT::acc_ppt_pwr"] |
| 590 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, acc_ppt_pwr) - 32usize]; |
| 591 |
["Offset of field: AmdsmiViolationStatusT::acc_socket_thrm"] |
| 592 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, acc_socket_thrm) - 40usize]; |
| 593 |
["Offset of field: AmdsmiViolationStatusT::acc_vr_thrm"] |
| 594 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, acc_vr_thrm) - 48usize]; |
| 595 |
["Offset of field: AmdsmiViolationStatusT::acc_hbm_thrm"] |
| 596 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, acc_hbm_thrm) - 56usize]; |
| 597 |
["Offset of field: AmdsmiViolationStatusT::acc_gfx_clk_below_host_limit"] |
| 598 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, acc_gfx_clk_below_host_limit) - 64usize]; |
| 599 |
["Offset of field: AmdsmiViolationStatusT::per_prochot_thrm"] |
| 600 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, per_prochot_thrm) - 72usize]; |
| 601 |
["Offset of field: AmdsmiViolationStatusT::per_ppt_pwr"] |
| 602 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, per_ppt_pwr) - 80usize]; |
| 603 |
["Offset of field: AmdsmiViolationStatusT::per_socket_thrm"] |
| 604 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, per_socket_thrm) - 88usize]; |
| 605 |
["Offset of field: AmdsmiViolationStatusT::per_vr_thrm"] |
| 606 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, per_vr_thrm) - 96usize]; |
| 607 |
["Offset of field: AmdsmiViolationStatusT::per_hbm_thrm"] |
| 608 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, per_hbm_thrm) - 104usize]; |
| 609 |
["Offset of field: AmdsmiViolationStatusT::per_gfx_clk_below_host_limit"] |
| 610 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, per_gfx_clk_below_host_limit) - 112usize]; |
| 611 |
["Offset of field: AmdsmiViolationStatusT::active_prochot_thrm"] |
| 612 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, active_prochot_thrm) - 120usize]; |
| 613 |
["Offset of field: AmdsmiViolationStatusT::active_ppt_pwr"] |
| 614 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, active_ppt_pwr) - 121usize]; |
| 615 |
["Offset of field: AmdsmiViolationStatusT::active_socket_thrm"] |
| 616 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, active_socket_thrm) - 122usize]; |
| 617 |
["Offset of field: AmdsmiViolationStatusT::active_vr_thrm"] |
| 618 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, active_vr_thrm) - 123usize]; |
| 619 |
["Offset of field: AmdsmiViolationStatusT::active_hbm_thrm"] |
| 620 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, active_hbm_thrm) - 124usize]; |
| 621 |
["Offset of field: AmdsmiViolationStatusT::active_gfx_clk_below_host_limit"][::std::mem::offset_of!( |
| 622 |
AmdsmiViolationStatusT, |
| 623 |
active_gfx_clk_below_host_limit |
| 624 |
) - 125usize]; |
| 625 |
["Offset of field: AmdsmiViolationStatusT::acc_gfx_clk_below_host_limit_pwr"][::std::mem::offset_of!( |
| 626 |
AmdsmiViolationStatusT, |
| 627 |
acc_gfx_clk_below_host_limit_pwr |
| 628 |
) - 128usize]; |
| 629 |
["Offset of field: AmdsmiViolationStatusT::acc_gfx_clk_below_host_limit_thm"][::std::mem::offset_of!( |
| 630 |
AmdsmiViolationStatusT, |
| 631 |
acc_gfx_clk_below_host_limit_thm |
| 632 |
) - 640usize]; |
| 633 |
["Offset of field: AmdsmiViolationStatusT::acc_low_utilization"] |
| 634 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, acc_low_utilization) - 1152usize]; |
| 635 |
["Offset of field: AmdsmiViolationStatusT::acc_gfx_clk_below_host_limit_total"][::std::mem::offset_of!( |
| 636 |
AmdsmiViolationStatusT, |
| 637 |
acc_gfx_clk_below_host_limit_total |
| 638 |
) - 1664usize]; |
| 639 |
["Offset of field: AmdsmiViolationStatusT::per_gfx_clk_below_host_limit_pwr"][::std::mem::offset_of!( |
| 640 |
AmdsmiViolationStatusT, |
| 641 |
per_gfx_clk_below_host_limit_pwr |
| 642 |
) - 2176usize]; |
| 643 |
["Offset of field: AmdsmiViolationStatusT::per_gfx_clk_below_host_limit_thm"][::std::mem::offset_of!( |
| 644 |
AmdsmiViolationStatusT, |
| 645 |
per_gfx_clk_below_host_limit_thm |
| 646 |
) - 2688usize]; |
| 647 |
["Offset of field: AmdsmiViolationStatusT::per_low_utilization"] |
| 648 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, per_low_utilization) - 3200usize]; |
| 649 |
["Offset of field: AmdsmiViolationStatusT::per_gfx_clk_below_host_limit_total"][::std::mem::offset_of!( |
| 650 |
AmdsmiViolationStatusT, |
| 651 |
per_gfx_clk_below_host_limit_total |
| 652 |
) - 3712usize]; |
| 653 |
["Offset of field: AmdsmiViolationStatusT::active_gfx_clk_below_host_limit_pwr"][::std::mem::offset_of!( |
| 654 |
AmdsmiViolationStatusT, |
| 655 |
active_gfx_clk_below_host_limit_pwr |
| 656 |
) - 4224usize]; |
| 657 |
["Offset of field: AmdsmiViolationStatusT::active_gfx_clk_below_host_limit_thm"][::std::mem::offset_of!( |
| 658 |
AmdsmiViolationStatusT, |
| 659 |
active_gfx_clk_below_host_limit_thm |
| 660 |
) - 4288usize]; |
| 661 |
["Offset of field: AmdsmiViolationStatusT::active_low_utilization"] |
| 662 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, active_low_utilization) - 4352usize]; |
| 663 |
["Offset of field: AmdsmiViolationStatusT::active_gfx_clk_below_host_limit_total"][::std::mem::offset_of!( |
| 664 |
AmdsmiViolationStatusT, |
| 665 |
active_gfx_clk_below_host_limit_total |
| 666 |
) |
| 667 |
- 4416usize]; |
| 668 |
["Offset of field: AmdsmiViolationStatusT::reserved"] |
| 669 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, reserved) - 4480usize]; |
| 670 |
["Offset of field: AmdsmiViolationStatusT::reserved2"] |
| 671 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, reserved2) - 4992usize]; |
| 672 |
["Offset of field: AmdsmiViolationStatusT::reserved3"] |
| 673 |
[::std::mem::offset_of!(AmdsmiViolationStatusT, reserved3) - 5504usize]; |
| 674 |
}; |
| 675 |
#[repr(C)] |
| 676 |
#[derive(Debug, Copy, Clone)] |
| 677 |
pub struct AmdsmiFrequencyRangeT { |
| 678 |
pub supported_freq_range: AmdsmiRangeT, |
| 679 |
pub current_freq_range: AmdsmiRangeT, |
| 680 |
pub reserved: [u32; 8usize], |
| 681 |
} |
| 682 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 683 |
const _: () = { |
| 684 |
["Size of AmdsmiFrequencyRangeT"][::std::mem::size_of::<AmdsmiFrequencyRangeT>() - 96usize]; |
| 685 |
["Alignment of AmdsmiFrequencyRangeT"] |
| 686 |
[::std::mem::align_of::<AmdsmiFrequencyRangeT>() - 8usize]; |
| 687 |
["Offset of field: AmdsmiFrequencyRangeT::supported_freq_range"] |
| 688 |
[::std::mem::offset_of!(AmdsmiFrequencyRangeT, supported_freq_range) - 0usize]; |
| 689 |
["Offset of field: AmdsmiFrequencyRangeT::current_freq_range"] |
| 690 |
[::std::mem::offset_of!(AmdsmiFrequencyRangeT, current_freq_range) - 32usize]; |
| 691 |
["Offset of field: AmdsmiFrequencyRangeT::reserved"] |
| 692 |
[::std::mem::offset_of!(AmdsmiFrequencyRangeT, reserved) - 64usize]; |
| 693 |
}; |
| 694 |
#[repr(C)] |
| 695 |
#[derive(Copy, Clone)] |
| 696 |
pub union AmdsmiBdfT { |
| 697 |
pub bdf: AmdsmiBdfTBdf, |
| 698 |
pub __bindgen_anon_1: AmdsmiBdfTBindgenTy1, |
| 699 |
pub as_uint: u64, |
| 700 |
} |
| 701 |
#[repr(C)] |
| 702 |
#[derive(Debug, Copy, Clone)] |
| 703 |
pub struct AmdsmiBdfTBdf { |
| 704 |
pub _bitfield_align_1: [u64; 0], |
| 705 |
pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, |
| 706 |
} |
| 707 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 708 |
const _: () = { |
| 709 |
["Size of AmdsmiBdfTBdf"][::std::mem::size_of::<AmdsmiBdfTBdf>() - 8usize]; |
| 710 |
["Alignment of AmdsmiBdfTBdf"][::std::mem::align_of::<AmdsmiBdfTBdf>() - 8usize]; |
| 711 |
}; |
| 712 |
impl AmdsmiBdfTBdf { |
| 713 |
#[inline] |
| 714 |
pub fn function_number(&self) -> u64 { |
| 715 |
unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 3u8) as u64) } |
| 716 |
} |
| 717 |
#[inline] |
| 718 |
pub fn set_function_number(&mut self, val: u64) { |
| 719 |
unsafe { |
| 720 |
let val: u64 = ::std::mem::transmute(val); |
| 721 |
self._bitfield_1.set(0usize, 3u8, val as u64) |
| 722 |
} |
| 723 |
} |
| 724 |
#[inline] |
| 725 |
pub fn device_number(&self) -> u64 { |
| 726 |
unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 5u8) as u64) } |
| 727 |
} |
| 728 |
#[inline] |
| 729 |
pub fn set_device_number(&mut self, val: u64) { |
| 730 |
unsafe { |
| 731 |
let val: u64 = ::std::mem::transmute(val); |
| 732 |
self._bitfield_1.set(3usize, 5u8, val as u64) |
| 733 |
} |
| 734 |
} |
| 735 |
#[inline] |
| 736 |
pub fn bus_number(&self) -> u64 { |
| 737 |
unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 8u8) as u64) } |
| 738 |
} |
| 739 |
#[inline] |
| 740 |
pub fn set_bus_number(&mut self, val: u64) { |
| 741 |
unsafe { |
| 742 |
let val: u64 = ::std::mem::transmute(val); |
| 743 |
self._bitfield_1.set(8usize, 8u8, val as u64) |
| 744 |
} |
| 745 |
} |
| 746 |
#[inline] |
| 747 |
pub fn domain_number(&self) -> u64 { |
| 748 |
unsafe { ::std::mem::transmute(self._bitfield_1.get(16usize, 48u8) as u64) } |
| 749 |
} |
| 750 |
#[inline] |
| 751 |
pub fn set_domain_number(&mut self, val: u64) { |
| 752 |
unsafe { |
| 753 |
let val: u64 = ::std::mem::transmute(val); |
| 754 |
self._bitfield_1.set(16usize, 48u8, val as u64) |
| 755 |
} |
| 756 |
} |
| 757 |
#[inline] |
| 758 |
pub fn new_bitfield_1( |
| 759 |
function_number: u64, |
| 760 |
device_number: u64, |
| 761 |
bus_number: u64, |
| 762 |
domain_number: u64, |
| 763 |
) -> __BindgenBitfieldUnit<[u8; 8usize]> { |
| 764 |
let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default(); |
| 765 |
__bindgen_bitfield_unit.set(0usize, 3u8, { |
| 766 |
let function_number: u64 = unsafe { ::std::mem::transmute(function_number) }; |
| 767 |
function_number as u64 |
| 768 |
}); |
| 769 |
__bindgen_bitfield_unit.set(3usize, 5u8, { |
| 770 |
let device_number: u64 = unsafe { ::std::mem::transmute(device_number) }; |
| 771 |
device_number as u64 |
| 772 |
}); |
| 773 |
__bindgen_bitfield_unit.set(8usize, 8u8, { |
| 774 |
let bus_number: u64 = unsafe { ::std::mem::transmute(bus_number) }; |
| 775 |
bus_number as u64 |
| 776 |
}); |
| 777 |
__bindgen_bitfield_unit.set(16usize, 48u8, { |
| 778 |
let domain_number: u64 = unsafe { ::std::mem::transmute(domain_number) }; |
| 779 |
domain_number as u64 |
| 780 |
}); |
| 781 |
__bindgen_bitfield_unit |
| 782 |
} |
| 783 |
} |
| 784 |
#[repr(C)] |
| 785 |
#[derive(Debug, Copy, Clone)] |
| 786 |
pub struct AmdsmiBdfTBindgenTy1 { |
| 787 |
pub _bitfield_align_1: [u64; 0], |
| 788 |
pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>, |
| 789 |
} |
| 790 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 791 |
const _: () = { |
| 792 |
["Size of AmdsmiBdfTBindgenTy1"][::std::mem::size_of::<AmdsmiBdfTBindgenTy1>() - 8usize]; |
| 793 |
["Alignment of AmdsmiBdfTBindgenTy1"][::std::mem::align_of::<AmdsmiBdfTBindgenTy1>() - 8usize]; |
| 794 |
}; |
| 795 |
impl AmdsmiBdfTBindgenTy1 { |
| 796 |
#[inline] |
| 797 |
pub fn function_number(&self) -> u64 { |
| 798 |
unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 3u8) as u64) } |
| 799 |
} |
| 800 |
#[inline] |
| 801 |
pub fn set_function_number(&mut self, val: u64) { |
| 802 |
unsafe { |
| 803 |
let val: u64 = ::std::mem::transmute(val); |
| 804 |
self._bitfield_1.set(0usize, 3u8, val as u64) |
| 805 |
} |
| 806 |
} |
| 807 |
#[inline] |
| 808 |
pub fn device_number(&self) -> u64 { |
| 809 |
unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 5u8) as u64) } |
| 810 |
} |
| 811 |
#[inline] |
| 812 |
pub fn set_device_number(&mut self, val: u64) { |
| 813 |
unsafe { |
| 814 |
let val: u64 = ::std::mem::transmute(val); |
| 815 |
self._bitfield_1.set(3usize, 5u8, val as u64) |
| 816 |
} |
| 817 |
} |
| 818 |
#[inline] |
| 819 |
pub fn bus_number(&self) -> u64 { |
| 820 |
unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 8u8) as u64) } |
| 821 |
} |
| 822 |
#[inline] |
| 823 |
pub fn set_bus_number(&mut self, val: u64) { |
| 824 |
unsafe { |
| 825 |
let val: u64 = ::std::mem::transmute(val); |
| 826 |
self._bitfield_1.set(8usize, 8u8, val as u64) |
| 827 |
} |
| 828 |
} |
| 829 |
#[inline] |
| 830 |
pub fn domain_number(&self) -> u64 { |
| 831 |
unsafe { ::std::mem::transmute(self._bitfield_1.get(16usize, 48u8) as u64) } |
| 832 |
} |
| 833 |
#[inline] |
| 834 |
pub fn set_domain_number(&mut self, val: u64) { |
| 835 |
unsafe { |
| 836 |
let val: u64 = ::std::mem::transmute(val); |
| 837 |
self._bitfield_1.set(16usize, 48u8, val as u64) |
| 838 |
} |
| 839 |
} |
| 840 |
#[inline] |
| 841 |
pub fn new_bitfield_1( |
| 842 |
function_number: u64, |
| 843 |
device_number: u64, |
| 844 |
bus_number: u64, |
| 845 |
domain_number: u64, |
| 846 |
) -> __BindgenBitfieldUnit<[u8; 8usize]> { |
| 847 |
let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default(); |
| 848 |
__bindgen_bitfield_unit.set(0usize, 3u8, { |
| 849 |
let function_number: u64 = unsafe { ::std::mem::transmute(function_number) }; |
| 850 |
function_number as u64 |
| 851 |
}); |
| 852 |
__bindgen_bitfield_unit.set(3usize, 5u8, { |
| 853 |
let device_number: u64 = unsafe { ::std::mem::transmute(device_number) }; |
| 854 |
device_number as u64 |
| 855 |
}); |
| 856 |
__bindgen_bitfield_unit.set(8usize, 8u8, { |
| 857 |
let bus_number: u64 = unsafe { ::std::mem::transmute(bus_number) }; |
| 858 |
bus_number as u64 |
| 859 |
}); |
| 860 |
__bindgen_bitfield_unit.set(16usize, 48u8, { |
| 861 |
let domain_number: u64 = unsafe { ::std::mem::transmute(domain_number) }; |
| 862 |
domain_number as u64 |
| 863 |
}); |
| 864 |
__bindgen_bitfield_unit |
| 865 |
} |
| 866 |
} |
| 867 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 868 |
const _: () = { |
| 869 |
["Size of AmdsmiBdfT"][::std::mem::size_of::<AmdsmiBdfT>() - 8usize]; |
| 870 |
["Alignment of AmdsmiBdfT"][::std::mem::align_of::<AmdsmiBdfT>() - 8usize]; |
| 871 |
["Offset of field: AmdsmiBdfT::bdf"][::std::mem::offset_of!(AmdsmiBdfT, bdf) - 0usize]; |
| 872 |
["Offset of field: AmdsmiBdfT::as_uint"][::std::mem::offset_of!(AmdsmiBdfT, as_uint) - 0usize]; |
| 873 |
}; |
| 874 |
#[repr(C)] |
| 875 |
#[derive(Debug, Copy, Clone)] |
| 876 |
pub struct AmdsmiEnumerationInfoT { |
| 877 |
pub drm_render: u32, |
| 878 |
pub drm_card: u32, |
| 879 |
pub hsa_id: u32, |
| 880 |
pub hip_id: u32, |
| 881 |
pub hip_uuid: [::std::os::raw::c_char; 256usize], |
| 882 |
} |
| 883 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 884 |
const _: () = { |
| 885 |
["Size of AmdsmiEnumerationInfoT"][::std::mem::size_of::<AmdsmiEnumerationInfoT>() - 272usize]; |
| 886 |
["Alignment of AmdsmiEnumerationInfoT"] |
| 887 |
[::std::mem::align_of::<AmdsmiEnumerationInfoT>() - 4usize]; |
| 888 |
["Offset of field: AmdsmiEnumerationInfoT::drm_render"] |
| 889 |
[::std::mem::offset_of!(AmdsmiEnumerationInfoT, drm_render) - 0usize]; |
| 890 |
["Offset of field: AmdsmiEnumerationInfoT::drm_card"] |
| 891 |
[::std::mem::offset_of!(AmdsmiEnumerationInfoT, drm_card) - 4usize]; |
| 892 |
["Offset of field: AmdsmiEnumerationInfoT::hsa_id"] |
| 893 |
[::std::mem::offset_of!(AmdsmiEnumerationInfoT, hsa_id) - 8usize]; |
| 894 |
["Offset of field: AmdsmiEnumerationInfoT::hip_id"] |
| 895 |
[::std::mem::offset_of!(AmdsmiEnumerationInfoT, hip_id) - 12usize]; |
| 896 |
["Offset of field: AmdsmiEnumerationInfoT::hip_uuid"] |
| 897 |
[::std::mem::offset_of!(AmdsmiEnumerationInfoT, hip_uuid) - 16usize]; |
| 898 |
}; |
| 899 |
#[repr(u32)] |
| 900 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 901 |
pub enum AmdsmiCardFormFactorT { |
| 902 |
AmdsmiCardFormFactorPcie = 0, |
| 903 |
AmdsmiCardFormFactorOam = 1, |
| 904 |
AmdsmiCardFormFactorCem = 2, |
| 905 |
AmdsmiCardFormFactorUnknown = 3, |
| 906 |
} |
| 907 |
#[repr(C)] |
| 908 |
#[derive(Debug, Copy, Clone)] |
| 909 |
pub struct AmdsmiPcieInfoT { |
| 910 |
pub pcie_static: AmdsmiPcieInfoTPcieStatic, |
| 911 |
pub pcie_metric: AmdsmiPcieInfoTPcieMetric, |
| 912 |
pub reserved: [u64; 32usize], |
| 913 |
} |
| 914 |
#[repr(C)] |
| 915 |
#[derive(Debug, Copy, Clone)] |
| 916 |
pub struct AmdsmiPcieInfoTPcieStatic { |
| 917 |
pub max_pcie_width: u16, |
| 918 |
pub max_pcie_speed: u32, |
| 919 |
pub pcie_interface_version: u32, |
| 920 |
pub slot_type: AmdsmiCardFormFactorT, |
| 921 |
pub max_pcie_interface_version: u32, |
| 922 |
pub reserved: [u64; 9usize], |
| 923 |
} |
| 924 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 925 |
const _: () = { |
| 926 |
["Size of AmdsmiPcieInfoTPcieStatic"] |
| 927 |
[::std::mem::size_of::<AmdsmiPcieInfoTPcieStatic>() - 96usize]; |
| 928 |
["Alignment of AmdsmiPcieInfoTPcieStatic"] |
| 929 |
[::std::mem::align_of::<AmdsmiPcieInfoTPcieStatic>() - 8usize]; |
| 930 |
["Offset of field: AmdsmiPcieInfoTPcieStatic::max_pcie_width"] |
| 931 |
[::std::mem::offset_of!(AmdsmiPcieInfoTPcieStatic, max_pcie_width) - 0usize]; |
| 932 |
["Offset of field: AmdsmiPcieInfoTPcieStatic::max_pcie_speed"] |
| 933 |
[::std::mem::offset_of!(AmdsmiPcieInfoTPcieStatic, max_pcie_speed) - 4usize]; |
| 934 |
["Offset of field: AmdsmiPcieInfoTPcieStatic::pcie_interface_version"] |
| 935 |
[::std::mem::offset_of!(AmdsmiPcieInfoTPcieStatic, pcie_interface_version) - 8usize]; |
| 936 |
["Offset of field: AmdsmiPcieInfoTPcieStatic::slot_type"] |
| 937 |
[::std::mem::offset_of!(AmdsmiPcieInfoTPcieStatic, slot_type) - 12usize]; |
| 938 |
["Offset of field: AmdsmiPcieInfoTPcieStatic::max_pcie_interface_version"] |
| 939 |
[::std::mem::offset_of!(AmdsmiPcieInfoTPcieStatic, max_pcie_interface_version) - 16usize]; |
| 940 |
["Offset of field: AmdsmiPcieInfoTPcieStatic::reserved"] |
| 941 |
[::std::mem::offset_of!(AmdsmiPcieInfoTPcieStatic, reserved) - 24usize]; |
| 942 |
}; |
| 943 |
#[repr(C)] |
| 944 |
#[derive(Debug, Copy, Clone)] |
| 945 |
pub struct AmdsmiPcieInfoTPcieMetric { |
| 946 |
pub pcie_width: u16, |
| 947 |
pub pcie_speed: u32, |
| 948 |
pub pcie_bandwidth: u32, |
| 949 |
pub pcie_replay_count: u64, |
| 950 |
pub pcie_l0_to_recovery_count: u64, |
| 951 |
pub pcie_replay_roll_over_count: u64, |
| 952 |
pub pcie_nak_sent_count: u64, |
| 953 |
pub pcie_nak_received_count: u64, |
| 954 |
pub pcie_lc_perf_other_end_recovery_count: u32, |
| 955 |
pub reserved: [u64; 12usize], |
| 956 |
} |
| 957 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 958 |
const _: () = { |
| 959 |
["Size of AmdsmiPcieInfoTPcieMetric"] |
| 960 |
[::std::mem::size_of::<AmdsmiPcieInfoTPcieMetric>() - 160usize]; |
| 961 |
["Alignment of AmdsmiPcieInfoTPcieMetric"] |
| 962 |
[::std::mem::align_of::<AmdsmiPcieInfoTPcieMetric>() - 8usize]; |
| 963 |
["Offset of field: AmdsmiPcieInfoTPcieMetric::pcie_width"] |
| 964 |
[::std::mem::offset_of!(AmdsmiPcieInfoTPcieMetric, pcie_width) - 0usize]; |
| 965 |
["Offset of field: AmdsmiPcieInfoTPcieMetric::pcie_speed"] |
| 966 |
[::std::mem::offset_of!(AmdsmiPcieInfoTPcieMetric, pcie_speed) - 4usize]; |
| 967 |
["Offset of field: AmdsmiPcieInfoTPcieMetric::pcie_bandwidth"] |
| 968 |
[::std::mem::offset_of!(AmdsmiPcieInfoTPcieMetric, pcie_bandwidth) - 8usize]; |
| 969 |
["Offset of field: AmdsmiPcieInfoTPcieMetric::pcie_replay_count"] |
| 970 |
[::std::mem::offset_of!(AmdsmiPcieInfoTPcieMetric, pcie_replay_count) - 16usize]; |
| 971 |
["Offset of field: AmdsmiPcieInfoTPcieMetric::pcie_l0_to_recovery_count"] |
| 972 |
[::std::mem::offset_of!(AmdsmiPcieInfoTPcieMetric, pcie_l0_to_recovery_count) - 24usize]; |
| 973 |
["Offset of field: AmdsmiPcieInfoTPcieMetric::pcie_replay_roll_over_count"] |
| 974 |
[::std::mem::offset_of!(AmdsmiPcieInfoTPcieMetric, pcie_replay_roll_over_count) - 32usize]; |
| 975 |
["Offset of field: AmdsmiPcieInfoTPcieMetric::pcie_nak_sent_count"] |
| 976 |
[::std::mem::offset_of!(AmdsmiPcieInfoTPcieMetric, pcie_nak_sent_count) - 40usize]; |
| 977 |
["Offset of field: AmdsmiPcieInfoTPcieMetric::pcie_nak_received_count"] |
| 978 |
[::std::mem::offset_of!(AmdsmiPcieInfoTPcieMetric, pcie_nak_received_count) - 48usize]; |
| 979 |
["Offset of field: AmdsmiPcieInfoTPcieMetric::pcie_lc_perf_other_end_recovery_count"][::std::mem::offset_of!( |
| 980 |
AmdsmiPcieInfoTPcieMetric, |
| 981 |
pcie_lc_perf_other_end_recovery_count |
| 982 |
) |
| 983 |
- 56usize]; |
| 984 |
["Offset of field: AmdsmiPcieInfoTPcieMetric::reserved"] |
| 985 |
[::std::mem::offset_of!(AmdsmiPcieInfoTPcieMetric, reserved) - 64usize]; |
| 986 |
}; |
| 987 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 988 |
const _: () = { |
| 989 |
["Size of AmdsmiPcieInfoT"][::std::mem::size_of::<AmdsmiPcieInfoT>() - 512usize]; |
| 990 |
["Alignment of AmdsmiPcieInfoT"][::std::mem::align_of::<AmdsmiPcieInfoT>() - 8usize]; |
| 991 |
["Offset of field: AmdsmiPcieInfoT::pcie_static"] |
| 992 |
[::std::mem::offset_of!(AmdsmiPcieInfoT, pcie_static) - 0usize]; |
| 993 |
["Offset of field: AmdsmiPcieInfoT::pcie_metric"] |
| 994 |
[::std::mem::offset_of!(AmdsmiPcieInfoT, pcie_metric) - 96usize]; |
| 995 |
["Offset of field: AmdsmiPcieInfoT::reserved"] |
| 996 |
[::std::mem::offset_of!(AmdsmiPcieInfoT, reserved) - 256usize]; |
| 997 |
}; |
| 998 |
#[repr(C)] |
| 999 |
#[derive(Debug, Copy, Clone)] |
| 1000 |
pub struct AmdsmiPowerCapInfoT { |
| 1001 |
pub power_cap: u64, |
| 1002 |
pub default_power_cap: u64, |
| 1003 |
pub dpm_cap: u64, |
| 1004 |
pub min_power_cap: u64, |
| 1005 |
pub max_power_cap: u64, |
| 1006 |
pub reserved: [u64; 3usize], |
| 1007 |
} |
| 1008 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1009 |
const _: () = { |
| 1010 |
["Size of AmdsmiPowerCapInfoT"][::std::mem::size_of::<AmdsmiPowerCapInfoT>() - 64usize]; |
| 1011 |
["Alignment of AmdsmiPowerCapInfoT"][::std::mem::align_of::<AmdsmiPowerCapInfoT>() - 8usize]; |
| 1012 |
["Offset of field: AmdsmiPowerCapInfoT::power_cap"] |
| 1013 |
[::std::mem::offset_of!(AmdsmiPowerCapInfoT, power_cap) - 0usize]; |
| 1014 |
["Offset of field: AmdsmiPowerCapInfoT::default_power_cap"] |
| 1015 |
[::std::mem::offset_of!(AmdsmiPowerCapInfoT, default_power_cap) - 8usize]; |
| 1016 |
["Offset of field: AmdsmiPowerCapInfoT::dpm_cap"] |
| 1017 |
[::std::mem::offset_of!(AmdsmiPowerCapInfoT, dpm_cap) - 16usize]; |
| 1018 |
["Offset of field: AmdsmiPowerCapInfoT::min_power_cap"] |
| 1019 |
[::std::mem::offset_of!(AmdsmiPowerCapInfoT, min_power_cap) - 24usize]; |
| 1020 |
["Offset of field: AmdsmiPowerCapInfoT::max_power_cap"] |
| 1021 |
[::std::mem::offset_of!(AmdsmiPowerCapInfoT, max_power_cap) - 32usize]; |
| 1022 |
["Offset of field: AmdsmiPowerCapInfoT::reserved"] |
| 1023 |
[::std::mem::offset_of!(AmdsmiPowerCapInfoT, reserved) - 40usize]; |
| 1024 |
}; |
| 1025 |
#[repr(C)] |
| 1026 |
#[derive(Debug, Copy, Clone)] |
| 1027 |
pub struct AmdsmiVbiosInfoT { |
| 1028 |
pub name: [::std::os::raw::c_char; 256usize], |
| 1029 |
pub build_date: [::std::os::raw::c_char; 256usize], |
| 1030 |
pub part_number: [::std::os::raw::c_char; 256usize], |
| 1031 |
pub version: [::std::os::raw::c_char; 256usize], |
| 1032 |
pub boot_firmware: [::std::os::raw::c_char; 256usize], |
| 1033 |
pub reserved: [u64; 36usize], |
| 1034 |
} |
| 1035 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1036 |
const _: () = { |
| 1037 |
["Size of AmdsmiVbiosInfoT"][::std::mem::size_of::<AmdsmiVbiosInfoT>() - 1568usize]; |
| 1038 |
["Alignment of AmdsmiVbiosInfoT"][::std::mem::align_of::<AmdsmiVbiosInfoT>() - 8usize]; |
| 1039 |
["Offset of field: AmdsmiVbiosInfoT::name"] |
| 1040 |
[::std::mem::offset_of!(AmdsmiVbiosInfoT, name) - 0usize]; |
| 1041 |
["Offset of field: AmdsmiVbiosInfoT::build_date"] |
| 1042 |
[::std::mem::offset_of!(AmdsmiVbiosInfoT, build_date) - 256usize]; |
| 1043 |
["Offset of field: AmdsmiVbiosInfoT::part_number"] |
| 1044 |
[::std::mem::offset_of!(AmdsmiVbiosInfoT, part_number) - 512usize]; |
| 1045 |
["Offset of field: AmdsmiVbiosInfoT::version"] |
| 1046 |
[::std::mem::offset_of!(AmdsmiVbiosInfoT, version) - 768usize]; |
| 1047 |
["Offset of field: AmdsmiVbiosInfoT::boot_firmware"] |
| 1048 |
[::std::mem::offset_of!(AmdsmiVbiosInfoT, boot_firmware) - 1024usize]; |
| 1049 |
["Offset of field: AmdsmiVbiosInfoT::reserved"] |
| 1050 |
[::std::mem::offset_of!(AmdsmiVbiosInfoT, reserved) - 1280usize]; |
| 1051 |
}; |
| 1052 |
#[repr(u32)] |
| 1053 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 1054 |
pub enum AmdsmiCachePropertyTypeT { |
| 1055 |
AmdsmiCachePropertyEnabled = 1, |
| 1056 |
AmdsmiCachePropertyDataCache = 2, |
| 1057 |
AmdsmiCachePropertyInstCache = 4, |
| 1058 |
AmdsmiCachePropertyCpuCache = 8, |
| 1059 |
AmdsmiCachePropertySimdCache = 16, |
| 1060 |
} |
| 1061 |
#[repr(C)] |
| 1062 |
#[derive(Debug, Copy, Clone)] |
| 1063 |
pub struct AmdsmiGpuCacheInfoT { |
| 1064 |
pub num_cache_types: u32, |
| 1065 |
pub cache: [AmdsmiGpuCacheInfoTCache; 10usize], |
| 1066 |
pub reserved: [u32; 15usize], |
| 1067 |
} |
| 1068 |
#[repr(C)] |
| 1069 |
#[derive(Debug, Copy, Clone)] |
| 1070 |
pub struct AmdsmiGpuCacheInfoTCache { |
| 1071 |
pub cache_properties: u32, |
| 1072 |
pub cache_size: u32, |
| 1073 |
pub cache_level: u32, |
| 1074 |
pub max_num_cu_shared: u32, |
| 1075 |
pub num_cache_instance: u32, |
| 1076 |
pub reserved: [u32; 3usize], |
| 1077 |
} |
| 1078 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1079 |
const _: () = { |
| 1080 |
["Size of AmdsmiGpuCacheInfoTCache"] |
| 1081 |
[::std::mem::size_of::<AmdsmiGpuCacheInfoTCache>() - 32usize]; |
| 1082 |
["Alignment of AmdsmiGpuCacheInfoTCache"] |
| 1083 |
[::std::mem::align_of::<AmdsmiGpuCacheInfoTCache>() - 4usize]; |
| 1084 |
["Offset of field: AmdsmiGpuCacheInfoTCache::cache_properties"] |
| 1085 |
[::std::mem::offset_of!(AmdsmiGpuCacheInfoTCache, cache_properties) - 0usize]; |
| 1086 |
["Offset of field: AmdsmiGpuCacheInfoTCache::cache_size"] |
| 1087 |
[::std::mem::offset_of!(AmdsmiGpuCacheInfoTCache, cache_size) - 4usize]; |
| 1088 |
["Offset of field: AmdsmiGpuCacheInfoTCache::cache_level"] |
| 1089 |
[::std::mem::offset_of!(AmdsmiGpuCacheInfoTCache, cache_level) - 8usize]; |
| 1090 |
["Offset of field: AmdsmiGpuCacheInfoTCache::max_num_cu_shared"] |
| 1091 |
[::std::mem::offset_of!(AmdsmiGpuCacheInfoTCache, max_num_cu_shared) - 12usize]; |
| 1092 |
["Offset of field: AmdsmiGpuCacheInfoTCache::num_cache_instance"] |
| 1093 |
[::std::mem::offset_of!(AmdsmiGpuCacheInfoTCache, num_cache_instance) - 16usize]; |
| 1094 |
["Offset of field: AmdsmiGpuCacheInfoTCache::reserved"] |
| 1095 |
[::std::mem::offset_of!(AmdsmiGpuCacheInfoTCache, reserved) - 20usize]; |
| 1096 |
}; |
| 1097 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1098 |
const _: () = { |
| 1099 |
["Size of AmdsmiGpuCacheInfoT"][::std::mem::size_of::<AmdsmiGpuCacheInfoT>() - 384usize]; |
| 1100 |
["Alignment of AmdsmiGpuCacheInfoT"][::std::mem::align_of::<AmdsmiGpuCacheInfoT>() - 4usize]; |
| 1101 |
["Offset of field: AmdsmiGpuCacheInfoT::num_cache_types"] |
| 1102 |
[::std::mem::offset_of!(AmdsmiGpuCacheInfoT, num_cache_types) - 0usize]; |
| 1103 |
["Offset of field: AmdsmiGpuCacheInfoT::cache"] |
| 1104 |
[::std::mem::offset_of!(AmdsmiGpuCacheInfoT, cache) - 4usize]; |
| 1105 |
["Offset of field: AmdsmiGpuCacheInfoT::reserved"] |
| 1106 |
[::std::mem::offset_of!(AmdsmiGpuCacheInfoT, reserved) - 324usize]; |
| 1107 |
}; |
| 1108 |
#[repr(C)] |
| 1109 |
#[derive(Debug, Copy, Clone)] |
| 1110 |
pub struct AmdsmiFwInfoT { |
| 1111 |
pub num_fw_info: u8, |
| 1112 |
pub fw_info_list: [AmdsmiFwInfoTFwInfoList; 80usize], |
| 1113 |
pub reserved: [u32; 7usize], |
| 1114 |
} |
| 1115 |
#[repr(C)] |
| 1116 |
#[derive(Debug, Copy, Clone)] |
| 1117 |
pub struct AmdsmiFwInfoTFwInfoList { |
| 1118 |
pub fw_id: AmdsmiFwBlockT, |
| 1119 |
pub fw_version: u64, |
| 1120 |
pub reserved: [u64; 2usize], |
| 1121 |
} |
| 1122 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1123 |
const _: () = { |
| 1124 |
["Size of AmdsmiFwInfoTFwInfoList"][::std::mem::size_of::<AmdsmiFwInfoTFwInfoList>() - 32usize]; |
| 1125 |
["Alignment of AmdsmiFwInfoTFwInfoList"] |
| 1126 |
[::std::mem::align_of::<AmdsmiFwInfoTFwInfoList>() - 8usize]; |
| 1127 |
["Offset of field: AmdsmiFwInfoTFwInfoList::fw_id"] |
| 1128 |
[::std::mem::offset_of!(AmdsmiFwInfoTFwInfoList, fw_id) - 0usize]; |
| 1129 |
["Offset of field: AmdsmiFwInfoTFwInfoList::fw_version"] |
| 1130 |
[::std::mem::offset_of!(AmdsmiFwInfoTFwInfoList, fw_version) - 8usize]; |
| 1131 |
["Offset of field: AmdsmiFwInfoTFwInfoList::reserved"] |
| 1132 |
[::std::mem::offset_of!(AmdsmiFwInfoTFwInfoList, reserved) - 16usize]; |
| 1133 |
}; |
| 1134 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1135 |
const _: () = { |
| 1136 |
["Size of AmdsmiFwInfoT"][::std::mem::size_of::<AmdsmiFwInfoT>() - 2600usize]; |
| 1137 |
["Alignment of AmdsmiFwInfoT"][::std::mem::align_of::<AmdsmiFwInfoT>() - 8usize]; |
| 1138 |
["Offset of field: AmdsmiFwInfoT::num_fw_info"] |
| 1139 |
[::std::mem::offset_of!(AmdsmiFwInfoT, num_fw_info) - 0usize]; |
| 1140 |
["Offset of field: AmdsmiFwInfoT::fw_info_list"] |
| 1141 |
[::std::mem::offset_of!(AmdsmiFwInfoT, fw_info_list) - 8usize]; |
| 1142 |
["Offset of field: AmdsmiFwInfoT::reserved"] |
| 1143 |
[::std::mem::offset_of!(AmdsmiFwInfoT, reserved) - 2568usize]; |
| 1144 |
}; |
| 1145 |
#[repr(C)] |
| 1146 |
#[derive(Debug, Copy, Clone)] |
| 1147 |
pub struct AmdsmiAsicInfoT { |
| 1148 |
pub market_name: [::std::os::raw::c_char; 256usize], |
| 1149 |
pub vendor_id: u32, |
| 1150 |
pub vendor_name: [::std::os::raw::c_char; 256usize], |
| 1151 |
pub subvendor_id: u32, |
| 1152 |
pub device_id: u64, |
| 1153 |
pub rev_id: u32, |
| 1154 |
pub asic_serial: [::std::os::raw::c_char; 256usize], |
| 1155 |
pub oam_id: u32, |
| 1156 |
pub num_of_compute_units: u32, |
| 1157 |
pub target_graphics_version: u64, |
| 1158 |
pub subsystem_id: u32, |
| 1159 |
pub reserved: [u32; 21usize], |
| 1160 |
} |
| 1161 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1162 |
const _: () = { |
| 1163 |
["Size of AmdsmiAsicInfoT"][::std::mem::size_of::<AmdsmiAsicInfoT>() - 896usize]; |
| 1164 |
["Alignment of AmdsmiAsicInfoT"][::std::mem::align_of::<AmdsmiAsicInfoT>() - 8usize]; |
| 1165 |
["Offset of field: AmdsmiAsicInfoT::market_name"] |
| 1166 |
[::std::mem::offset_of!(AmdsmiAsicInfoT, market_name) - 0usize]; |
| 1167 |
["Offset of field: AmdsmiAsicInfoT::vendor_id"] |
| 1168 |
[::std::mem::offset_of!(AmdsmiAsicInfoT, vendor_id) - 256usize]; |
| 1169 |
["Offset of field: AmdsmiAsicInfoT::vendor_name"] |
| 1170 |
[::std::mem::offset_of!(AmdsmiAsicInfoT, vendor_name) - 260usize]; |
| 1171 |
["Offset of field: AmdsmiAsicInfoT::subvendor_id"] |
| 1172 |
[::std::mem::offset_of!(AmdsmiAsicInfoT, subvendor_id) - 516usize]; |
| 1173 |
["Offset of field: AmdsmiAsicInfoT::device_id"] |
| 1174 |
[::std::mem::offset_of!(AmdsmiAsicInfoT, device_id) - 520usize]; |
| 1175 |
["Offset of field: AmdsmiAsicInfoT::rev_id"] |
| 1176 |
[::std::mem::offset_of!(AmdsmiAsicInfoT, rev_id) - 528usize]; |
| 1177 |
["Offset of field: AmdsmiAsicInfoT::asic_serial"] |
| 1178 |
[::std::mem::offset_of!(AmdsmiAsicInfoT, asic_serial) - 532usize]; |
| 1179 |
["Offset of field: AmdsmiAsicInfoT::oam_id"] |
| 1180 |
[::std::mem::offset_of!(AmdsmiAsicInfoT, oam_id) - 788usize]; |
| 1181 |
["Offset of field: AmdsmiAsicInfoT::num_of_compute_units"] |
| 1182 |
[::std::mem::offset_of!(AmdsmiAsicInfoT, num_of_compute_units) - 792usize]; |
| 1183 |
["Offset of field: AmdsmiAsicInfoT::target_graphics_version"] |
| 1184 |
[::std::mem::offset_of!(AmdsmiAsicInfoT, target_graphics_version) - 800usize]; |
| 1185 |
["Offset of field: AmdsmiAsicInfoT::subsystem_id"] |
| 1186 |
[::std::mem::offset_of!(AmdsmiAsicInfoT, subsystem_id) - 808usize]; |
| 1187 |
["Offset of field: AmdsmiAsicInfoT::reserved"] |
| 1188 |
[::std::mem::offset_of!(AmdsmiAsicInfoT, reserved) - 812usize]; |
| 1189 |
}; |
| 1190 |
#[repr(C)] |
| 1191 |
#[derive(Debug, Copy, Clone)] |
| 1192 |
pub struct AmdsmiKfdInfoT { |
| 1193 |
pub kfd_id: u64, |
| 1194 |
pub node_id: u32, |
| 1195 |
pub current_partition_id: u32, |
| 1196 |
pub reserved: [u32; 12usize], |
| 1197 |
} |
| 1198 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1199 |
const _: () = { |
| 1200 |
["Size of AmdsmiKfdInfoT"][::std::mem::size_of::<AmdsmiKfdInfoT>() - 64usize]; |
| 1201 |
["Alignment of AmdsmiKfdInfoT"][::std::mem::align_of::<AmdsmiKfdInfoT>() - 8usize]; |
| 1202 |
["Offset of field: AmdsmiKfdInfoT::kfd_id"] |
| 1203 |
[::std::mem::offset_of!(AmdsmiKfdInfoT, kfd_id) - 0usize]; |
| 1204 |
["Offset of field: AmdsmiKfdInfoT::node_id"] |
| 1205 |
[::std::mem::offset_of!(AmdsmiKfdInfoT, node_id) - 8usize]; |
| 1206 |
["Offset of field: AmdsmiKfdInfoT::current_partition_id"] |
| 1207 |
[::std::mem::offset_of!(AmdsmiKfdInfoT, current_partition_id) - 12usize]; |
| 1208 |
["Offset of field: AmdsmiKfdInfoT::reserved"] |
| 1209 |
[::std::mem::offset_of!(AmdsmiKfdInfoT, reserved) - 16usize]; |
| 1210 |
}; |
| 1211 |
#[repr(C)] |
| 1212 |
#[derive(Copy, Clone)] |
| 1213 |
pub union AmdsmiNpsCapsT { |
| 1214 |
pub nps_flags: AmdsmiNpsCapsTNpsFlags, |
| 1215 |
pub nps_cap_mask: u32, |
| 1216 |
} |
| 1217 |
#[repr(C)] |
| 1218 |
#[derive(Debug, Copy, Clone)] |
| 1219 |
pub struct AmdsmiNpsCapsTNpsFlags { |
| 1220 |
pub _bitfield_align_1: [u32; 0], |
| 1221 |
pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, |
| 1222 |
} |
| 1223 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1224 |
const _: () = { |
| 1225 |
["Size of AmdsmiNpsCapsTNpsFlags"][::std::mem::size_of::<AmdsmiNpsCapsTNpsFlags>() - 4usize]; |
| 1226 |
["Alignment of AmdsmiNpsCapsTNpsFlags"] |
| 1227 |
[::std::mem::align_of::<AmdsmiNpsCapsTNpsFlags>() - 4usize]; |
| 1228 |
}; |
| 1229 |
impl AmdsmiNpsCapsTNpsFlags { |
| 1230 |
#[inline] |
| 1231 |
pub fn nps1_cap(&self) -> u32 { |
| 1232 |
unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u32) } |
| 1233 |
} |
| 1234 |
#[inline] |
| 1235 |
pub fn set_nps1_cap(&mut self, val: u32) { |
| 1236 |
unsafe { |
| 1237 |
let val: u32 = ::std::mem::transmute(val); |
| 1238 |
self._bitfield_1.set(0usize, 1u8, val as u64) |
| 1239 |
} |
| 1240 |
} |
| 1241 |
#[inline] |
| 1242 |
pub fn nps2_cap(&self) -> u32 { |
| 1243 |
unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u32) } |
| 1244 |
} |
| 1245 |
#[inline] |
| 1246 |
pub fn set_nps2_cap(&mut self, val: u32) { |
| 1247 |
unsafe { |
| 1248 |
let val: u32 = ::std::mem::transmute(val); |
| 1249 |
self._bitfield_1.set(1usize, 1u8, val as u64) |
| 1250 |
} |
| 1251 |
} |
| 1252 |
#[inline] |
| 1253 |
pub fn nps4_cap(&self) -> u32 { |
| 1254 |
unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 1u8) as u32) } |
| 1255 |
} |
| 1256 |
#[inline] |
| 1257 |
pub fn set_nps4_cap(&mut self, val: u32) { |
| 1258 |
unsafe { |
| 1259 |
let val: u32 = ::std::mem::transmute(val); |
| 1260 |
self._bitfield_1.set(2usize, 1u8, val as u64) |
| 1261 |
} |
| 1262 |
} |
| 1263 |
#[inline] |
| 1264 |
pub fn nps8_cap(&self) -> u32 { |
| 1265 |
unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 1u8) as u32) } |
| 1266 |
} |
| 1267 |
#[inline] |
| 1268 |
pub fn set_nps8_cap(&mut self, val: u32) { |
| 1269 |
unsafe { |
| 1270 |
let val: u32 = ::std::mem::transmute(val); |
| 1271 |
self._bitfield_1.set(3usize, 1u8, val as u64) |
| 1272 |
} |
| 1273 |
} |
| 1274 |
#[inline] |
| 1275 |
pub fn reserved(&self) -> u32 { |
| 1276 |
unsafe { ::std::mem::transmute(self._bitfield_1.get(4usize, 28u8) as u32) } |
| 1277 |
} |
| 1278 |
#[inline] |
| 1279 |
pub fn set_reserved(&mut self, val: u32) { |
| 1280 |
unsafe { |
| 1281 |
let val: u32 = ::std::mem::transmute(val); |
| 1282 |
self._bitfield_1.set(4usize, 28u8, val as u64) |
| 1283 |
} |
| 1284 |
} |
| 1285 |
#[inline] |
| 1286 |
pub fn new_bitfield_1( |
| 1287 |
nps1_cap: u32, |
| 1288 |
nps2_cap: u32, |
| 1289 |
nps4_cap: u32, |
| 1290 |
nps8_cap: u32, |
| 1291 |
reserved: u32, |
| 1292 |
) -> __BindgenBitfieldUnit<[u8; 4usize]> { |
| 1293 |
let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default(); |
| 1294 |
__bindgen_bitfield_unit.set(0usize, 1u8, { |
| 1295 |
let nps1_cap: u32 = unsafe { ::std::mem::transmute(nps1_cap) }; |
| 1296 |
nps1_cap as u64 |
| 1297 |
}); |
| 1298 |
__bindgen_bitfield_unit.set(1usize, 1u8, { |
| 1299 |
let nps2_cap: u32 = unsafe { ::std::mem::transmute(nps2_cap) }; |
| 1300 |
nps2_cap as u64 |
| 1301 |
}); |
| 1302 |
__bindgen_bitfield_unit.set(2usize, 1u8, { |
| 1303 |
let nps4_cap: u32 = unsafe { ::std::mem::transmute(nps4_cap) }; |
| 1304 |
nps4_cap as u64 |
| 1305 |
}); |
| 1306 |
__bindgen_bitfield_unit.set(3usize, 1u8, { |
| 1307 |
let nps8_cap: u32 = unsafe { ::std::mem::transmute(nps8_cap) }; |
| 1308 |
nps8_cap as u64 |
| 1309 |
}); |
| 1310 |
__bindgen_bitfield_unit.set(4usize, 28u8, { |
| 1311 |
let reserved: u32 = unsafe { ::std::mem::transmute(reserved) }; |
| 1312 |
reserved as u64 |
| 1313 |
}); |
| 1314 |
__bindgen_bitfield_unit |
| 1315 |
} |
| 1316 |
} |
| 1317 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1318 |
const _: () = { |
| 1319 |
["Size of AmdsmiNpsCapsT"][::std::mem::size_of::<AmdsmiNpsCapsT>() - 4usize]; |
| 1320 |
["Alignment of AmdsmiNpsCapsT"][::std::mem::align_of::<AmdsmiNpsCapsT>() - 4usize]; |
| 1321 |
["Offset of field: AmdsmiNpsCapsT::nps_flags"] |
| 1322 |
[::std::mem::offset_of!(AmdsmiNpsCapsT, nps_flags) - 0usize]; |
| 1323 |
["Offset of field: AmdsmiNpsCapsT::nps_cap_mask"] |
| 1324 |
[::std::mem::offset_of!(AmdsmiNpsCapsT, nps_cap_mask) - 0usize]; |
| 1325 |
}; |
| 1326 |
#[repr(C)] |
| 1327 |
#[derive(Copy, Clone)] |
| 1328 |
pub struct AmdsmiMemoryPartitionConfigT { |
| 1329 |
pub partition_caps: AmdsmiNpsCapsT, |
| 1330 |
pub mp_mode: AmdsmiMemoryPartitionTypeT, |
| 1331 |
pub num_numa_ranges: u32, |
| 1332 |
pub numa_range: [AmdsmiMemoryPartitionConfigTNumaRange; 32usize], |
| 1333 |
pub reserved: [u64; 11usize], |
| 1334 |
} |
| 1335 |
#[repr(C)] |
| 1336 |
#[derive(Debug, Copy, Clone)] |
| 1337 |
pub struct AmdsmiMemoryPartitionConfigTNumaRange { |
| 1338 |
pub memory_type: AmdsmiVramTypeT, |
| 1339 |
pub start: u64, |
| 1340 |
pub end: u64, |
| 1341 |
} |
| 1342 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1343 |
const _: () = { |
| 1344 |
["Size of AmdsmiMemoryPartitionConfigTNumaRange"] |
| 1345 |
[::std::mem::size_of::<AmdsmiMemoryPartitionConfigTNumaRange>() - 24usize]; |
| 1346 |
["Alignment of AmdsmiMemoryPartitionConfigTNumaRange"] |
| 1347 |
[::std::mem::align_of::<AmdsmiMemoryPartitionConfigTNumaRange>() - 8usize]; |
| 1348 |
["Offset of field: AmdsmiMemoryPartitionConfigTNumaRange::memory_type"] |
| 1349 |
[::std::mem::offset_of!(AmdsmiMemoryPartitionConfigTNumaRange, memory_type) - 0usize]; |
| 1350 |
["Offset of field: AmdsmiMemoryPartitionConfigTNumaRange::start"] |
| 1351 |
[::std::mem::offset_of!(AmdsmiMemoryPartitionConfigTNumaRange, start) - 8usize]; |
| 1352 |
["Offset of field: AmdsmiMemoryPartitionConfigTNumaRange::end"] |
| 1353 |
[::std::mem::offset_of!(AmdsmiMemoryPartitionConfigTNumaRange, end) - 16usize]; |
| 1354 |
}; |
| 1355 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1356 |
const _: () = { |
| 1357 |
["Size of AmdsmiMemoryPartitionConfigT"] |
| 1358 |
[::std::mem::size_of::<AmdsmiMemoryPartitionConfigT>() - 872usize]; |
| 1359 |
["Alignment of AmdsmiMemoryPartitionConfigT"] |
| 1360 |
[::std::mem::align_of::<AmdsmiMemoryPartitionConfigT>() - 8usize]; |
| 1361 |
["Offset of field: AmdsmiMemoryPartitionConfigT::partition_caps"] |
| 1362 |
[::std::mem::offset_of!(AmdsmiMemoryPartitionConfigT, partition_caps) - 0usize]; |
| 1363 |
["Offset of field: AmdsmiMemoryPartitionConfigT::mp_mode"] |
| 1364 |
[::std::mem::offset_of!(AmdsmiMemoryPartitionConfigT, mp_mode) - 4usize]; |
| 1365 |
["Offset of field: AmdsmiMemoryPartitionConfigT::num_numa_ranges"] |
| 1366 |
[::std::mem::offset_of!(AmdsmiMemoryPartitionConfigT, num_numa_ranges) - 8usize]; |
| 1367 |
["Offset of field: AmdsmiMemoryPartitionConfigT::numa_range"] |
| 1368 |
[::std::mem::offset_of!(AmdsmiMemoryPartitionConfigT, numa_range) - 16usize]; |
| 1369 |
["Offset of field: AmdsmiMemoryPartitionConfigT::reserved"] |
| 1370 |
[::std::mem::offset_of!(AmdsmiMemoryPartitionConfigT, reserved) - 784usize]; |
| 1371 |
}; |
| 1372 |
#[repr(C)] |
| 1373 |
#[derive(Copy, Clone)] |
| 1374 |
pub struct AmdsmiAcceleratorPartitionProfileT { |
| 1375 |
pub profile_type: AmdsmiAcceleratorPartitionTypeT, |
| 1376 |
pub num_partitions: u32, |
| 1377 |
pub memory_caps: AmdsmiNpsCapsT, |
| 1378 |
pub profile_index: u32, |
| 1379 |
pub num_resources: u32, |
| 1380 |
pub resources: [[u32; 32usize]; 8usize], |
| 1381 |
pub reserved: [u64; 13usize], |
| 1382 |
} |
| 1383 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1384 |
const _: () = { |
| 1385 |
["Size of AmdsmiAcceleratorPartitionProfileT"] |
| 1386 |
[::std::mem::size_of::<AmdsmiAcceleratorPartitionProfileT>() - 1152usize]; |
| 1387 |
["Alignment of AmdsmiAcceleratorPartitionProfileT"] |
| 1388 |
[::std::mem::align_of::<AmdsmiAcceleratorPartitionProfileT>() - 8usize]; |
| 1389 |
["Offset of field: AmdsmiAcceleratorPartitionProfileT::profile_type"] |
| 1390 |
[::std::mem::offset_of!(AmdsmiAcceleratorPartitionProfileT, profile_type) - 0usize]; |
| 1391 |
["Offset of field: AmdsmiAcceleratorPartitionProfileT::num_partitions"] |
| 1392 |
[::std::mem::offset_of!(AmdsmiAcceleratorPartitionProfileT, num_partitions) - 4usize]; |
| 1393 |
["Offset of field: AmdsmiAcceleratorPartitionProfileT::memory_caps"] |
| 1394 |
[::std::mem::offset_of!(AmdsmiAcceleratorPartitionProfileT, memory_caps) - 8usize]; |
| 1395 |
["Offset of field: AmdsmiAcceleratorPartitionProfileT::profile_index"] |
| 1396 |
[::std::mem::offset_of!(AmdsmiAcceleratorPartitionProfileT, profile_index) - 12usize]; |
| 1397 |
["Offset of field: AmdsmiAcceleratorPartitionProfileT::num_resources"] |
| 1398 |
[::std::mem::offset_of!(AmdsmiAcceleratorPartitionProfileT, num_resources) - 16usize]; |
| 1399 |
["Offset of field: AmdsmiAcceleratorPartitionProfileT::resources"] |
| 1400 |
[::std::mem::offset_of!(AmdsmiAcceleratorPartitionProfileT, resources) - 20usize]; |
| 1401 |
["Offset of field: AmdsmiAcceleratorPartitionProfileT::reserved"] |
| 1402 |
[::std::mem::offset_of!(AmdsmiAcceleratorPartitionProfileT, reserved) - 1048usize]; |
| 1403 |
}; |
| 1404 |
#[repr(C)] |
| 1405 |
#[derive(Debug, Copy, Clone)] |
| 1406 |
pub struct AmdsmiAcceleratorPartitionResourceProfileT { |
| 1407 |
pub profile_index: u32, |
| 1408 |
pub resource_type: AmdsmiAcceleratorPartitionResourceTypeT, |
| 1409 |
pub partition_resource: u32, |
| 1410 |
pub num_partitions_share_resource: u32, |
| 1411 |
pub reserved: [u64; 6usize], |
| 1412 |
} |
| 1413 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1414 |
const _: () = { |
| 1415 |
["Size of AmdsmiAcceleratorPartitionResourceProfileT"] |
| 1416 |
[::std::mem::size_of::<AmdsmiAcceleratorPartitionResourceProfileT>() - 64usize]; |
| 1417 |
["Alignment of AmdsmiAcceleratorPartitionResourceProfileT"] |
| 1418 |
[::std::mem::align_of::<AmdsmiAcceleratorPartitionResourceProfileT>() - 8usize]; |
| 1419 |
["Offset of field: AmdsmiAcceleratorPartitionResourceProfileT::profile_index"][::std::mem::offset_of!( |
| 1420 |
AmdsmiAcceleratorPartitionResourceProfileT, |
| 1421 |
profile_index |
| 1422 |
) - 0usize]; |
| 1423 |
["Offset of field: AmdsmiAcceleratorPartitionResourceProfileT::resource_type"][::std::mem::offset_of!( |
| 1424 |
AmdsmiAcceleratorPartitionResourceProfileT, |
| 1425 |
resource_type |
| 1426 |
) - 4usize]; |
| 1427 |
["Offset of field: AmdsmiAcceleratorPartitionResourceProfileT::partition_resource"][::std::mem::offset_of!( |
| 1428 |
AmdsmiAcceleratorPartitionResourceProfileT, |
| 1429 |
partition_resource |
| 1430 |
) - 8usize]; |
| 1431 |
["Offset of field: AmdsmiAcceleratorPartitionResourceProfileT::num_partitions_share_resource"] [:: std :: mem :: offset_of ! (AmdsmiAcceleratorPartitionResourceProfileT , num_partitions_share_resource) - 12usize] ; |
| 1432 |
["Offset of field: AmdsmiAcceleratorPartitionResourceProfileT::reserved"] |
| 1433 |
[::std::mem::offset_of!(AmdsmiAcceleratorPartitionResourceProfileT, reserved) - 16usize]; |
| 1434 |
}; |
| 1435 |
#[repr(C)] |
| 1436 |
#[derive(Copy, Clone)] |
| 1437 |
pub struct AmdsmiAcceleratorPartitionProfileConfigT { |
| 1438 |
pub num_profiles: u32, |
| 1439 |
pub num_resource_profiles: u32, |
| 1440 |
pub resource_profiles: [AmdsmiAcceleratorPartitionResourceProfileT; 32usize], |
| 1441 |
pub default_profile_index: u32, |
| 1442 |
pub profiles: [AmdsmiAcceleratorPartitionProfileT; 32usize], |
| 1443 |
pub reserved: [u64; 30usize], |
| 1444 |
} |
| 1445 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1446 |
const _: () = { |
| 1447 |
["Size of AmdsmiAcceleratorPartitionProfileConfigT"] |
| 1448 |
[::std::mem::size_of::<AmdsmiAcceleratorPartitionProfileConfigT>() - 39168usize]; |
| 1449 |
["Alignment of AmdsmiAcceleratorPartitionProfileConfigT"] |
| 1450 |
[::std::mem::align_of::<AmdsmiAcceleratorPartitionProfileConfigT>() - 8usize]; |
| 1451 |
["Offset of field: AmdsmiAcceleratorPartitionProfileConfigT::num_profiles"] |
| 1452 |
[::std::mem::offset_of!(AmdsmiAcceleratorPartitionProfileConfigT, num_profiles) - 0usize]; |
| 1453 |
["Offset of field: AmdsmiAcceleratorPartitionProfileConfigT::num_resource_profiles"][::std::mem::offset_of!( |
| 1454 |
AmdsmiAcceleratorPartitionProfileConfigT, |
| 1455 |
num_resource_profiles |
| 1456 |
) |
| 1457 |
- 4usize]; |
| 1458 |
["Offset of field: AmdsmiAcceleratorPartitionProfileConfigT::resource_profiles"][::std::mem::offset_of!( |
| 1459 |
AmdsmiAcceleratorPartitionProfileConfigT, |
| 1460 |
resource_profiles |
| 1461 |
) - 8usize]; |
| 1462 |
["Offset of field: AmdsmiAcceleratorPartitionProfileConfigT::default_profile_index"][::std::mem::offset_of!( |
| 1463 |
AmdsmiAcceleratorPartitionProfileConfigT, |
| 1464 |
default_profile_index |
| 1465 |
) |
| 1466 |
- 2056usize]; |
| 1467 |
["Offset of field: AmdsmiAcceleratorPartitionProfileConfigT::profiles"] |
| 1468 |
[::std::mem::offset_of!(AmdsmiAcceleratorPartitionProfileConfigT, profiles) - 2064usize]; |
| 1469 |
["Offset of field: AmdsmiAcceleratorPartitionProfileConfigT::reserved"] |
| 1470 |
[::std::mem::offset_of!(AmdsmiAcceleratorPartitionProfileConfigT, reserved) - 38928usize]; |
| 1471 |
}; |
| 1472 |
#[repr(u32)] |
| 1473 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 1474 |
pub enum AmdsmiLinkTypeT { |
| 1475 |
AmdsmiLinkTypeInternal = 0, |
| 1476 |
AmdsmiLinkTypePcie = 1, |
| 1477 |
AmdsmiLinkTypeXgmi = 2, |
| 1478 |
AmdsmiLinkTypeNotApplicable = 3, |
| 1479 |
AmdsmiLinkTypeUnknown = 4, |
| 1480 |
} |
| 1481 |
#[repr(C)] |
| 1482 |
#[derive(Debug, Copy, Clone)] |
| 1483 |
pub struct AmdsmiCpuUtilT { |
| 1484 |
pub cpu_util_total: u32, |
| 1485 |
pub cpu_util_user: u32, |
| 1486 |
pub cpu_util_nice: u32, |
| 1487 |
pub cpu_util_sys: u32, |
| 1488 |
pub cpu_util_irq: u32, |
| 1489 |
} |
| 1490 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1491 |
const _: () = { |
| 1492 |
["Size of AmdsmiCpuUtilT"][::std::mem::size_of::<AmdsmiCpuUtilT>() - 20usize]; |
| 1493 |
["Alignment of AmdsmiCpuUtilT"][::std::mem::align_of::<AmdsmiCpuUtilT>() - 4usize]; |
| 1494 |
["Offset of field: AmdsmiCpuUtilT::cpu_util_total"] |
| 1495 |
[::std::mem::offset_of!(AmdsmiCpuUtilT, cpu_util_total) - 0usize]; |
| 1496 |
["Offset of field: AmdsmiCpuUtilT::cpu_util_user"] |
| 1497 |
[::std::mem::offset_of!(AmdsmiCpuUtilT, cpu_util_user) - 4usize]; |
| 1498 |
["Offset of field: AmdsmiCpuUtilT::cpu_util_nice"] |
| 1499 |
[::std::mem::offset_of!(AmdsmiCpuUtilT, cpu_util_nice) - 8usize]; |
| 1500 |
["Offset of field: AmdsmiCpuUtilT::cpu_util_sys"] |
| 1501 |
[::std::mem::offset_of!(AmdsmiCpuUtilT, cpu_util_sys) - 12usize]; |
| 1502 |
["Offset of field: AmdsmiCpuUtilT::cpu_util_irq"] |
| 1503 |
[::std::mem::offset_of!(AmdsmiCpuUtilT, cpu_util_irq) - 16usize]; |
| 1504 |
}; |
| 1505 |
#[repr(C)] |
| 1506 |
#[derive(Copy, Clone)] |
| 1507 |
pub struct AmdsmiLinkMetricsT { |
| 1508 |
pub num_links: u32, |
| 1509 |
pub links: [AmdsmiLinkMetricsTLinks; 64usize], |
| 1510 |
pub reserved: [u64; 7usize], |
| 1511 |
} |
| 1512 |
#[repr(C)] |
| 1513 |
#[derive(Copy, Clone)] |
| 1514 |
pub struct AmdsmiLinkMetricsTLinks { |
| 1515 |
pub bdf: AmdsmiBdfT, |
| 1516 |
pub bit_rate: u32, |
| 1517 |
pub max_bandwidth: u32, |
| 1518 |
pub link_type: AmdsmiLinkTypeT, |
| 1519 |
pub read: u64, |
| 1520 |
pub write: u64, |
| 1521 |
pub reserved: [u64; 2usize], |
| 1522 |
} |
| 1523 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1524 |
const _: () = { |
| 1525 |
["Size of AmdsmiLinkMetricsTLinks"][::std::mem::size_of::<AmdsmiLinkMetricsTLinks>() - 56usize]; |
| 1526 |
["Alignment of AmdsmiLinkMetricsTLinks"] |
| 1527 |
[::std::mem::align_of::<AmdsmiLinkMetricsTLinks>() - 8usize]; |
| 1528 |
["Offset of field: AmdsmiLinkMetricsTLinks::bdf"] |
| 1529 |
[::std::mem::offset_of!(AmdsmiLinkMetricsTLinks, bdf) - 0usize]; |
| 1530 |
["Offset of field: AmdsmiLinkMetricsTLinks::bit_rate"] |
| 1531 |
[::std::mem::offset_of!(AmdsmiLinkMetricsTLinks, bit_rate) - 8usize]; |
| 1532 |
["Offset of field: AmdsmiLinkMetricsTLinks::max_bandwidth"] |
| 1533 |
[::std::mem::offset_of!(AmdsmiLinkMetricsTLinks, max_bandwidth) - 12usize]; |
| 1534 |
["Offset of field: AmdsmiLinkMetricsTLinks::link_type"] |
| 1535 |
[::std::mem::offset_of!(AmdsmiLinkMetricsTLinks, link_type) - 16usize]; |
| 1536 |
["Offset of field: AmdsmiLinkMetricsTLinks::read"] |
| 1537 |
[::std::mem::offset_of!(AmdsmiLinkMetricsTLinks, read) - 24usize]; |
| 1538 |
["Offset of field: AmdsmiLinkMetricsTLinks::write"] |
| 1539 |
[::std::mem::offset_of!(AmdsmiLinkMetricsTLinks, write) - 32usize]; |
| 1540 |
["Offset of field: AmdsmiLinkMetricsTLinks::reserved"] |
| 1541 |
[::std::mem::offset_of!(AmdsmiLinkMetricsTLinks, reserved) - 40usize]; |
| 1542 |
}; |
| 1543 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1544 |
const _: () = { |
| 1545 |
["Size of AmdsmiLinkMetricsT"][::std::mem::size_of::<AmdsmiLinkMetricsT>() - 3648usize]; |
| 1546 |
["Alignment of AmdsmiLinkMetricsT"][::std::mem::align_of::<AmdsmiLinkMetricsT>() - 8usize]; |
| 1547 |
["Offset of field: AmdsmiLinkMetricsT::num_links"] |
| 1548 |
[::std::mem::offset_of!(AmdsmiLinkMetricsT, num_links) - 0usize]; |
| 1549 |
["Offset of field: AmdsmiLinkMetricsT::links"] |
| 1550 |
[::std::mem::offset_of!(AmdsmiLinkMetricsT, links) - 8usize]; |
| 1551 |
["Offset of field: AmdsmiLinkMetricsT::reserved"] |
| 1552 |
[::std::mem::offset_of!(AmdsmiLinkMetricsT, reserved) - 3592usize]; |
| 1553 |
}; |
| 1554 |
#[repr(C)] |
| 1555 |
#[derive(Debug, Copy, Clone)] |
| 1556 |
pub struct AmdsmiVramInfoT { |
| 1557 |
pub vram_type: AmdsmiVramTypeT, |
| 1558 |
pub vram_vendor: [::std::os::raw::c_char; 256usize], |
| 1559 |
pub vram_size: u64, |
| 1560 |
pub vram_bit_width: u32, |
| 1561 |
pub vram_max_bandwidth: u64, |
| 1562 |
pub reserved: [u64; 37usize], |
| 1563 |
} |
| 1564 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1565 |
const _: () = { |
| 1566 |
["Size of AmdsmiVramInfoT"][::std::mem::size_of::<AmdsmiVramInfoT>() - 584usize]; |
| 1567 |
["Alignment of AmdsmiVramInfoT"][::std::mem::align_of::<AmdsmiVramInfoT>() - 8usize]; |
| 1568 |
["Offset of field: AmdsmiVramInfoT::vram_type"] |
| 1569 |
[::std::mem::offset_of!(AmdsmiVramInfoT, vram_type) - 0usize]; |
| 1570 |
["Offset of field: AmdsmiVramInfoT::vram_vendor"] |
| 1571 |
[::std::mem::offset_of!(AmdsmiVramInfoT, vram_vendor) - 4usize]; |
| 1572 |
["Offset of field: AmdsmiVramInfoT::vram_size"] |
| 1573 |
[::std::mem::offset_of!(AmdsmiVramInfoT, vram_size) - 264usize]; |
| 1574 |
["Offset of field: AmdsmiVramInfoT::vram_bit_width"] |
| 1575 |
[::std::mem::offset_of!(AmdsmiVramInfoT, vram_bit_width) - 272usize]; |
| 1576 |
["Offset of field: AmdsmiVramInfoT::vram_max_bandwidth"] |
| 1577 |
[::std::mem::offset_of!(AmdsmiVramInfoT, vram_max_bandwidth) - 280usize]; |
| 1578 |
["Offset of field: AmdsmiVramInfoT::reserved"] |
| 1579 |
[::std::mem::offset_of!(AmdsmiVramInfoT, reserved) - 288usize]; |
| 1580 |
}; |
| 1581 |
#[repr(C)] |
| 1582 |
#[derive(Debug, Copy, Clone)] |
| 1583 |
pub struct AmdsmiDriverInfoT { |
| 1584 |
pub driver_version: [::std::os::raw::c_char; 256usize], |
| 1585 |
pub driver_date: [::std::os::raw::c_char; 256usize], |
| 1586 |
pub driver_name: [::std::os::raw::c_char; 256usize], |
| 1587 |
} |
| 1588 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1589 |
const _: () = { |
| 1590 |
["Size of AmdsmiDriverInfoT"][::std::mem::size_of::<AmdsmiDriverInfoT>() - 768usize]; |
| 1591 |
["Alignment of AmdsmiDriverInfoT"][::std::mem::align_of::<AmdsmiDriverInfoT>() - 1usize]; |
| 1592 |
["Offset of field: AmdsmiDriverInfoT::driver_version"] |
| 1593 |
[::std::mem::offset_of!(AmdsmiDriverInfoT, driver_version) - 0usize]; |
| 1594 |
["Offset of field: AmdsmiDriverInfoT::driver_date"] |
| 1595 |
[::std::mem::offset_of!(AmdsmiDriverInfoT, driver_date) - 256usize]; |
| 1596 |
["Offset of field: AmdsmiDriverInfoT::driver_name"] |
| 1597 |
[::std::mem::offset_of!(AmdsmiDriverInfoT, driver_name) - 512usize]; |
| 1598 |
}; |
| 1599 |
#[repr(C)] |
| 1600 |
#[derive(Debug, Copy, Clone)] |
| 1601 |
pub struct AmdsmiBoardInfoT { |
| 1602 |
pub model_number: [::std::os::raw::c_char; 256usize], |
| 1603 |
pub product_serial: [::std::os::raw::c_char; 256usize], |
| 1604 |
pub fru_id: [::std::os::raw::c_char; 256usize], |
| 1605 |
pub product_name: [::std::os::raw::c_char; 256usize], |
| 1606 |
pub manufacturer_name: [::std::os::raw::c_char; 256usize], |
| 1607 |
pub reserved: [u64; 64usize], |
| 1608 |
} |
| 1609 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1610 |
const _: () = { |
| 1611 |
["Size of AmdsmiBoardInfoT"][::std::mem::size_of::<AmdsmiBoardInfoT>() - 1792usize]; |
| 1612 |
["Alignment of AmdsmiBoardInfoT"][::std::mem::align_of::<AmdsmiBoardInfoT>() - 8usize]; |
| 1613 |
["Offset of field: AmdsmiBoardInfoT::model_number"] |
| 1614 |
[::std::mem::offset_of!(AmdsmiBoardInfoT, model_number) - 0usize]; |
| 1615 |
["Offset of field: AmdsmiBoardInfoT::product_serial"] |
| 1616 |
[::std::mem::offset_of!(AmdsmiBoardInfoT, product_serial) - 256usize]; |
| 1617 |
["Offset of field: AmdsmiBoardInfoT::fru_id"] |
| 1618 |
[::std::mem::offset_of!(AmdsmiBoardInfoT, fru_id) - 512usize]; |
| 1619 |
["Offset of field: AmdsmiBoardInfoT::product_name"] |
| 1620 |
[::std::mem::offset_of!(AmdsmiBoardInfoT, product_name) - 768usize]; |
| 1621 |
["Offset of field: AmdsmiBoardInfoT::manufacturer_name"] |
| 1622 |
[::std::mem::offset_of!(AmdsmiBoardInfoT, manufacturer_name) - 1024usize]; |
| 1623 |
["Offset of field: AmdsmiBoardInfoT::reserved"] |
| 1624 |
[::std::mem::offset_of!(AmdsmiBoardInfoT, reserved) - 1280usize]; |
| 1625 |
}; |
| 1626 |
#[repr(C)] |
| 1627 |
#[derive(Debug, Copy, Clone)] |
| 1628 |
pub struct AmdsmiPowerInfoT { |
| 1629 |
pub socket_power: u64, |
| 1630 |
pub current_socket_power: u32, |
| 1631 |
pub average_socket_power: u32, |
| 1632 |
pub gfx_voltage: u64, |
| 1633 |
pub soc_voltage: u64, |
| 1634 |
pub mem_voltage: u64, |
| 1635 |
pub power_limit: u32, |
| 1636 |
pub reserved: [u64; 18usize], |
| 1637 |
} |
| 1638 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1639 |
const _: () = { |
| 1640 |
["Size of AmdsmiPowerInfoT"][::std::mem::size_of::<AmdsmiPowerInfoT>() - 192usize]; |
| 1641 |
["Alignment of AmdsmiPowerInfoT"][::std::mem::align_of::<AmdsmiPowerInfoT>() - 8usize]; |
| 1642 |
["Offset of field: AmdsmiPowerInfoT::socket_power"] |
| 1643 |
[::std::mem::offset_of!(AmdsmiPowerInfoT, socket_power) - 0usize]; |
| 1644 |
["Offset of field: AmdsmiPowerInfoT::current_socket_power"] |
| 1645 |
[::std::mem::offset_of!(AmdsmiPowerInfoT, current_socket_power) - 8usize]; |
| 1646 |
["Offset of field: AmdsmiPowerInfoT::average_socket_power"] |
| 1647 |
[::std::mem::offset_of!(AmdsmiPowerInfoT, average_socket_power) - 12usize]; |
| 1648 |
["Offset of field: AmdsmiPowerInfoT::gfx_voltage"] |
| 1649 |
[::std::mem::offset_of!(AmdsmiPowerInfoT, gfx_voltage) - 16usize]; |
| 1650 |
["Offset of field: AmdsmiPowerInfoT::soc_voltage"] |
| 1651 |
[::std::mem::offset_of!(AmdsmiPowerInfoT, soc_voltage) - 24usize]; |
| 1652 |
["Offset of field: AmdsmiPowerInfoT::mem_voltage"] |
| 1653 |
[::std::mem::offset_of!(AmdsmiPowerInfoT, mem_voltage) - 32usize]; |
| 1654 |
["Offset of field: AmdsmiPowerInfoT::power_limit"] |
| 1655 |
[::std::mem::offset_of!(AmdsmiPowerInfoT, power_limit) - 40usize]; |
| 1656 |
["Offset of field: AmdsmiPowerInfoT::reserved"] |
| 1657 |
[::std::mem::offset_of!(AmdsmiPowerInfoT, reserved) - 48usize]; |
| 1658 |
}; |
| 1659 |
#[repr(C)] |
| 1660 |
#[derive(Debug, Copy, Clone)] |
| 1661 |
pub struct AmdsmiClkInfoT { |
| 1662 |
pub clk: u32, |
| 1663 |
pub min_clk: u32, |
| 1664 |
pub max_clk: u32, |
| 1665 |
pub clk_locked: u8, |
| 1666 |
pub clk_deep_sleep: u8, |
| 1667 |
pub reserved: [u32; 4usize], |
| 1668 |
} |
| 1669 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1670 |
const _: () = { |
| 1671 |
["Size of AmdsmiClkInfoT"][::std::mem::size_of::<AmdsmiClkInfoT>() - 32usize]; |
| 1672 |
["Alignment of AmdsmiClkInfoT"][::std::mem::align_of::<AmdsmiClkInfoT>() - 4usize]; |
| 1673 |
["Offset of field: AmdsmiClkInfoT::clk"][::std::mem::offset_of!(AmdsmiClkInfoT, clk) - 0usize]; |
| 1674 |
["Offset of field: AmdsmiClkInfoT::min_clk"] |
| 1675 |
[::std::mem::offset_of!(AmdsmiClkInfoT, min_clk) - 4usize]; |
| 1676 |
["Offset of field: AmdsmiClkInfoT::max_clk"] |
| 1677 |
[::std::mem::offset_of!(AmdsmiClkInfoT, max_clk) - 8usize]; |
| 1678 |
["Offset of field: AmdsmiClkInfoT::clk_locked"] |
| 1679 |
[::std::mem::offset_of!(AmdsmiClkInfoT, clk_locked) - 12usize]; |
| 1680 |
["Offset of field: AmdsmiClkInfoT::clk_deep_sleep"] |
| 1681 |
[::std::mem::offset_of!(AmdsmiClkInfoT, clk_deep_sleep) - 13usize]; |
| 1682 |
["Offset of field: AmdsmiClkInfoT::reserved"] |
| 1683 |
[::std::mem::offset_of!(AmdsmiClkInfoT, reserved) - 16usize]; |
| 1684 |
}; |
| 1685 |
#[repr(C)] |
| 1686 |
#[derive(Debug, Copy, Clone)] |
| 1687 |
pub struct AmdsmiEngineUsageT { |
| 1688 |
pub gfx_activity: u32, |
| 1689 |
pub umc_activity: u32, |
| 1690 |
pub mm_activity: u32, |
| 1691 |
pub reserved: [u32; 13usize], |
| 1692 |
} |
| 1693 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1694 |
const _: () = { |
| 1695 |
["Size of AmdsmiEngineUsageT"][::std::mem::size_of::<AmdsmiEngineUsageT>() - 64usize]; |
| 1696 |
["Alignment of AmdsmiEngineUsageT"][::std::mem::align_of::<AmdsmiEngineUsageT>() - 4usize]; |
| 1697 |
["Offset of field: AmdsmiEngineUsageT::gfx_activity"] |
| 1698 |
[::std::mem::offset_of!(AmdsmiEngineUsageT, gfx_activity) - 0usize]; |
| 1699 |
["Offset of field: AmdsmiEngineUsageT::umc_activity"] |
| 1700 |
[::std::mem::offset_of!(AmdsmiEngineUsageT, umc_activity) - 4usize]; |
| 1701 |
["Offset of field: AmdsmiEngineUsageT::mm_activity"] |
| 1702 |
[::std::mem::offset_of!(AmdsmiEngineUsageT, mm_activity) - 8usize]; |
| 1703 |
["Offset of field: AmdsmiEngineUsageT::reserved"] |
| 1704 |
[::std::mem::offset_of!(AmdsmiEngineUsageT, reserved) - 12usize]; |
| 1705 |
}; |
| 1706 |
pub type AmdsmiProcessHandleT = u32; |
| 1707 |
#[repr(C)] |
| 1708 |
#[derive(Debug, Copy, Clone)] |
| 1709 |
pub struct AmdsmiProcInfoT { |
| 1710 |
pub name: [::std::os::raw::c_char; 256usize], |
| 1711 |
pub pid: AmdsmiProcessHandleT, |
| 1712 |
pub mem: u64, |
| 1713 |
pub engine_usage: AmdsmiProcInfoTEngineUsage, |
| 1714 |
pub memory_usage: AmdsmiProcInfoTMemoryUsage, |
| 1715 |
pub container_name: [::std::os::raw::c_char; 256usize], |
| 1716 |
pub cu_occupancy: u32, |
| 1717 |
pub reserved: [u32; 11usize], |
| 1718 |
} |
| 1719 |
#[repr(C)] |
| 1720 |
#[derive(Debug, Copy, Clone)] |
| 1721 |
pub struct AmdsmiProcInfoTEngineUsage { |
| 1722 |
pub gfx: u64, |
| 1723 |
pub enc: u64, |
| 1724 |
pub reserved: [u32; 12usize], |
| 1725 |
} |
| 1726 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1727 |
const _: () = { |
| 1728 |
["Size of AmdsmiProcInfoTEngineUsage"] |
| 1729 |
[::std::mem::size_of::<AmdsmiProcInfoTEngineUsage>() - 64usize]; |
| 1730 |
["Alignment of AmdsmiProcInfoTEngineUsage"] |
| 1731 |
[::std::mem::align_of::<AmdsmiProcInfoTEngineUsage>() - 8usize]; |
| 1732 |
["Offset of field: AmdsmiProcInfoTEngineUsage::gfx"] |
| 1733 |
[::std::mem::offset_of!(AmdsmiProcInfoTEngineUsage, gfx) - 0usize]; |
| 1734 |
["Offset of field: AmdsmiProcInfoTEngineUsage::enc"] |
| 1735 |
[::std::mem::offset_of!(AmdsmiProcInfoTEngineUsage, enc) - 8usize]; |
| 1736 |
["Offset of field: AmdsmiProcInfoTEngineUsage::reserved"] |
| 1737 |
[::std::mem::offset_of!(AmdsmiProcInfoTEngineUsage, reserved) - 16usize]; |
| 1738 |
}; |
| 1739 |
#[repr(C)] |
| 1740 |
#[derive(Debug, Copy, Clone)] |
| 1741 |
pub struct AmdsmiProcInfoTMemoryUsage { |
| 1742 |
pub gtt_mem: u64, |
| 1743 |
pub cpu_mem: u64, |
| 1744 |
pub vram_mem: u64, |
| 1745 |
pub reserved: [u32; 10usize], |
| 1746 |
} |
| 1747 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1748 |
const _: () = { |
| 1749 |
["Size of AmdsmiProcInfoTMemoryUsage"] |
| 1750 |
[::std::mem::size_of::<AmdsmiProcInfoTMemoryUsage>() - 64usize]; |
| 1751 |
["Alignment of AmdsmiProcInfoTMemoryUsage"] |
| 1752 |
[::std::mem::align_of::<AmdsmiProcInfoTMemoryUsage>() - 8usize]; |
| 1753 |
["Offset of field: AmdsmiProcInfoTMemoryUsage::gtt_mem"] |
| 1754 |
[::std::mem::offset_of!(AmdsmiProcInfoTMemoryUsage, gtt_mem) - 0usize]; |
| 1755 |
["Offset of field: AmdsmiProcInfoTMemoryUsage::cpu_mem"] |
| 1756 |
[::std::mem::offset_of!(AmdsmiProcInfoTMemoryUsage, cpu_mem) - 8usize]; |
| 1757 |
["Offset of field: AmdsmiProcInfoTMemoryUsage::vram_mem"] |
| 1758 |
[::std::mem::offset_of!(AmdsmiProcInfoTMemoryUsage, vram_mem) - 16usize]; |
| 1759 |
["Offset of field: AmdsmiProcInfoTMemoryUsage::reserved"] |
| 1760 |
[::std::mem::offset_of!(AmdsmiProcInfoTMemoryUsage, reserved) - 24usize]; |
| 1761 |
}; |
| 1762 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1763 |
const _: () = { |
| 1764 |
["Size of AmdsmiProcInfoT"][::std::mem::size_of::<AmdsmiProcInfoT>() - 704usize]; |
| 1765 |
["Alignment of AmdsmiProcInfoT"][::std::mem::align_of::<AmdsmiProcInfoT>() - 8usize]; |
| 1766 |
["Offset of field: AmdsmiProcInfoT::name"] |
| 1767 |
[::std::mem::offset_of!(AmdsmiProcInfoT, name) - 0usize]; |
| 1768 |
["Offset of field: AmdsmiProcInfoT::pid"] |
| 1769 |
[::std::mem::offset_of!(AmdsmiProcInfoT, pid) - 256usize]; |
| 1770 |
["Offset of field: AmdsmiProcInfoT::mem"] |
| 1771 |
[::std::mem::offset_of!(AmdsmiProcInfoT, mem) - 264usize]; |
| 1772 |
["Offset of field: AmdsmiProcInfoT::engine_usage"] |
| 1773 |
[::std::mem::offset_of!(AmdsmiProcInfoT, engine_usage) - 272usize]; |
| 1774 |
["Offset of field: AmdsmiProcInfoT::memory_usage"] |
| 1775 |
[::std::mem::offset_of!(AmdsmiProcInfoT, memory_usage) - 336usize]; |
| 1776 |
["Offset of field: AmdsmiProcInfoT::container_name"] |
| 1777 |
[::std::mem::offset_of!(AmdsmiProcInfoT, container_name) - 400usize]; |
| 1778 |
["Offset of field: AmdsmiProcInfoT::cu_occupancy"] |
| 1779 |
[::std::mem::offset_of!(AmdsmiProcInfoT, cu_occupancy) - 656usize]; |
| 1780 |
["Offset of field: AmdsmiProcInfoT::reserved"] |
| 1781 |
[::std::mem::offset_of!(AmdsmiProcInfoT, reserved) - 660usize]; |
| 1782 |
}; |
| 1783 |
#[repr(C)] |
| 1784 |
#[derive(Debug, Copy, Clone)] |
| 1785 |
pub struct AmdsmiP2pCapabilityT { |
| 1786 |
pub is_iolink_coherent: u8, |
| 1787 |
pub is_iolink_atomics_32bit: u8, |
| 1788 |
pub is_iolink_atomics_64bit: u8, |
| 1789 |
pub is_iolink_dma: u8, |
| 1790 |
pub is_iolink_bi_directional: u8, |
| 1791 |
} |
| 1792 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1793 |
const _: () = { |
| 1794 |
["Size of AmdsmiP2pCapabilityT"][::std::mem::size_of::<AmdsmiP2pCapabilityT>() - 5usize]; |
| 1795 |
["Alignment of AmdsmiP2pCapabilityT"][::std::mem::align_of::<AmdsmiP2pCapabilityT>() - 1usize]; |
| 1796 |
["Offset of field: AmdsmiP2pCapabilityT::is_iolink_coherent"] |
| 1797 |
[::std::mem::offset_of!(AmdsmiP2pCapabilityT, is_iolink_coherent) - 0usize]; |
| 1798 |
["Offset of field: AmdsmiP2pCapabilityT::is_iolink_atomics_32bit"] |
| 1799 |
[::std::mem::offset_of!(AmdsmiP2pCapabilityT, is_iolink_atomics_32bit) - 1usize]; |
| 1800 |
["Offset of field: AmdsmiP2pCapabilityT::is_iolink_atomics_64bit"] |
| 1801 |
[::std::mem::offset_of!(AmdsmiP2pCapabilityT, is_iolink_atomics_64bit) - 2usize]; |
| 1802 |
["Offset of field: AmdsmiP2pCapabilityT::is_iolink_dma"] |
| 1803 |
[::std::mem::offset_of!(AmdsmiP2pCapabilityT, is_iolink_dma) - 3usize]; |
| 1804 |
["Offset of field: AmdsmiP2pCapabilityT::is_iolink_bi_directional"] |
| 1805 |
[::std::mem::offset_of!(AmdsmiP2pCapabilityT, is_iolink_bi_directional) - 4usize]; |
| 1806 |
}; |
| 1807 |
impl AmdsmiDevPerfLevelT { |
| 1808 |
pub const AmdsmiDevPerfLevelFirst: AmdsmiDevPerfLevelT = |
| 1809 |
AmdsmiDevPerfLevelT::AmdsmiDevPerfLevelAuto; |
| 1810 |
} |
| 1811 |
impl AmdsmiDevPerfLevelT { |
| 1812 |
pub const AmdsmiDevPerfLevelLast: AmdsmiDevPerfLevelT = |
| 1813 |
AmdsmiDevPerfLevelT::AmdsmiDevPerfLevelDeterminism; |
| 1814 |
} |
| 1815 |
#[repr(u32)] |
| 1816 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 1817 |
pub enum AmdsmiDevPerfLevelT { |
| 1818 |
AmdsmiDevPerfLevelAuto = 0, |
| 1819 |
AmdsmiDevPerfLevelLow = 1, |
| 1820 |
AmdsmiDevPerfLevelHigh = 2, |
| 1821 |
AmdsmiDevPerfLevelManual = 3, |
| 1822 |
AmdsmiDevPerfLevelStableStd = 4, |
| 1823 |
AmdsmiDevPerfLevelStablePeak = 5, |
| 1824 |
AmdsmiDevPerfLevelStableMinMclk = 6, |
| 1825 |
AmdsmiDevPerfLevelStableMinSclk = 7, |
| 1826 |
AmdsmiDevPerfLevelDeterminism = 8, |
| 1827 |
AmdsmiDevPerfLevelUnknown = 256, |
| 1828 |
} |
| 1829 |
pub type AmdsmiEventHandleT = usize; |
| 1830 |
#[repr(u32)] |
| 1831 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 1832 |
pub enum AmdsmiEventGroupT { |
| 1833 |
AmdsmiEvntGrpXgmi = 0, |
| 1834 |
AmdsmiEvntGrpXgmiDataOut = 10, |
| 1835 |
AmdsmiEvntGrpInvalid = 4294967295, |
| 1836 |
} |
| 1837 |
impl AmdsmiEventTypeT { |
| 1838 |
pub const AmdsmiEvntXgmiFirst: AmdsmiEventTypeT = AmdsmiEventTypeT::AmdsmiEvntFirst; |
| 1839 |
} |
| 1840 |
impl AmdsmiEventTypeT { |
| 1841 |
pub const AmdsmiEvntXgmi0NopTx: AmdsmiEventTypeT = AmdsmiEventTypeT::AmdsmiEvntFirst; |
| 1842 |
} |
| 1843 |
impl AmdsmiEventTypeT { |
| 1844 |
pub const AmdsmiEvntXgmiLast: AmdsmiEventTypeT = AmdsmiEventTypeT::AmdsmiEvntXgmi1BeatsTx; |
| 1845 |
} |
| 1846 |
impl AmdsmiEventTypeT { |
| 1847 |
pub const AmdsmiEvntXgmiDataOut0: AmdsmiEventTypeT = |
| 1848 |
AmdsmiEventTypeT::AmdsmiEvntXgmiDataOutFirst; |
| 1849 |
} |
| 1850 |
impl AmdsmiEventTypeT { |
| 1851 |
pub const AmdsmiEvntXgmiDataOutLast: AmdsmiEventTypeT = |
| 1852 |
AmdsmiEventTypeT::AmdsmiEvntXgmiDataOut5; |
| 1853 |
} |
| 1854 |
impl AmdsmiEventTypeT { |
| 1855 |
pub const AmdsmiEvntLast: AmdsmiEventTypeT = AmdsmiEventTypeT::AmdsmiEvntXgmiDataOut5; |
| 1856 |
} |
| 1857 |
#[repr(u32)] |
| 1858 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 1859 |
pub enum AmdsmiEventTypeT { |
| 1860 |
AmdsmiEvntFirst = 0, |
| 1861 |
AmdsmiEvntXgmi0RequestTx = 1, |
| 1862 |
AmdsmiEvntXgmi0ResponseTx = 2, |
| 1863 |
AmdsmiEvntXgmi0BeatsTx = 3, |
| 1864 |
AmdsmiEvntXgmi1NopTx = 4, |
| 1865 |
AmdsmiEvntXgmi1RequestTx = 5, |
| 1866 |
AmdsmiEvntXgmi1ResponseTx = 6, |
| 1867 |
AmdsmiEvntXgmi1BeatsTx = 7, |
| 1868 |
AmdsmiEvntXgmiDataOutFirst = 10, |
| 1869 |
AmdsmiEvntXgmiDataOut1 = 11, |
| 1870 |
AmdsmiEvntXgmiDataOut2 = 12, |
| 1871 |
AmdsmiEvntXgmiDataOut3 = 13, |
| 1872 |
AmdsmiEvntXgmiDataOut4 = 14, |
| 1873 |
AmdsmiEvntXgmiDataOut5 = 15, |
| 1874 |
} |
| 1875 |
#[repr(u32)] |
| 1876 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 1877 |
pub enum AmdsmiCounterCommandT { |
| 1878 |
AmdsmiCntrCmdStart = 0, |
| 1879 |
AmdsmiCntrCmdStop = 1, |
| 1880 |
} |
| 1881 |
#[repr(C)] |
| 1882 |
#[derive(Debug, Copy, Clone)] |
| 1883 |
pub struct AmdsmiCounterValueT { |
| 1884 |
pub value: u64, |
| 1885 |
pub time_enabled: u64, |
| 1886 |
pub time_running: u64, |
| 1887 |
} |
| 1888 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1889 |
const _: () = { |
| 1890 |
["Size of AmdsmiCounterValueT"][::std::mem::size_of::<AmdsmiCounterValueT>() - 24usize]; |
| 1891 |
["Alignment of AmdsmiCounterValueT"][::std::mem::align_of::<AmdsmiCounterValueT>() - 8usize]; |
| 1892 |
["Offset of field: AmdsmiCounterValueT::value"] |
| 1893 |
[::std::mem::offset_of!(AmdsmiCounterValueT, value) - 0usize]; |
| 1894 |
["Offset of field: AmdsmiCounterValueT::time_enabled"] |
| 1895 |
[::std::mem::offset_of!(AmdsmiCounterValueT, time_enabled) - 8usize]; |
| 1896 |
["Offset of field: AmdsmiCounterValueT::time_running"] |
| 1897 |
[::std::mem::offset_of!(AmdsmiCounterValueT, time_running) - 16usize]; |
| 1898 |
}; |
| 1899 |
impl AmdsmiEvtNotificationTypeT { |
| 1900 |
pub const AmdsmiEvtNotifFirst: AmdsmiEvtNotificationTypeT = |
| 1901 |
AmdsmiEvtNotificationTypeT::AmdsmiEvtNotifVmfault; |
| 1902 |
} |
| 1903 |
impl AmdsmiEvtNotificationTypeT { |
| 1904 |
pub const AmdsmiEvtNotifLast: AmdsmiEvtNotificationTypeT = |
| 1905 |
AmdsmiEvtNotificationTypeT::AmdsmiEvtNotifProcessEnd; |
| 1906 |
} |
| 1907 |
#[repr(u32)] |
| 1908 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 1909 |
pub enum AmdsmiEvtNotificationTypeT { |
| 1910 |
AmdsmiEvtNotifNone = 0, |
| 1911 |
AmdsmiEvtNotifVmfault = 1, |
| 1912 |
AmdsmiEvtNotifThermalThrottle = 2, |
| 1913 |
AmdsmiEvtNotifGpuPreReset = 3, |
| 1914 |
AmdsmiEvtNotifGpuPostReset = 4, |
| 1915 |
AmdsmiEvtNotifMigrateStart = 5, |
| 1916 |
AmdsmiEvtNotifMigrateEnd = 6, |
| 1917 |
AmdsmiEvtNotifPageFaultStart = 7, |
| 1918 |
AmdsmiEvtNotifPageFaultEnd = 8, |
| 1919 |
AmdsmiEvtNotifQueueEviction = 9, |
| 1920 |
AmdsmiEvtNotifQueueRestore = 10, |
| 1921 |
AmdsmiEvtNotifUnmapFromGpu = 11, |
| 1922 |
AmdsmiEvtNotifProcessStart = 12, |
| 1923 |
AmdsmiEvtNotifProcessEnd = 13, |
| 1924 |
} |
| 1925 |
#[repr(C)] |
| 1926 |
#[derive(Debug, Copy, Clone)] |
| 1927 |
pub struct AmdsmiEvtNotificationDataT { |
| 1928 |
pub processor_handle: AmdsmiProcessorHandle, |
| 1929 |
pub event: AmdsmiEvtNotificationTypeT, |
| 1930 |
pub message: [::std::os::raw::c_char; 256usize], |
| 1931 |
} |
| 1932 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 1933 |
const _: () = { |
| 1934 |
["Size of AmdsmiEvtNotificationDataT"] |
| 1935 |
[::std::mem::size_of::<AmdsmiEvtNotificationDataT>() - 272usize]; |
| 1936 |
["Alignment of AmdsmiEvtNotificationDataT"] |
| 1937 |
[::std::mem::align_of::<AmdsmiEvtNotificationDataT>() - 8usize]; |
| 1938 |
["Offset of field: AmdsmiEvtNotificationDataT::processor_handle"] |
| 1939 |
[::std::mem::offset_of!(AmdsmiEvtNotificationDataT, processor_handle) - 0usize]; |
| 1940 |
["Offset of field: AmdsmiEvtNotificationDataT::event"] |
| 1941 |
[::std::mem::offset_of!(AmdsmiEvtNotificationDataT, event) - 8usize]; |
| 1942 |
["Offset of field: AmdsmiEvtNotificationDataT::message"] |
| 1943 |
[::std::mem::offset_of!(AmdsmiEvtNotificationDataT, message) - 12usize]; |
| 1944 |
}; |
| 1945 |
impl AmdsmiTemperatureMetricT { |
| 1946 |
pub const AmdsmiTempFirst: AmdsmiTemperatureMetricT = |
| 1947 |
AmdsmiTemperatureMetricT::AmdsmiTempCurrent; |
| 1948 |
} |
| 1949 |
impl AmdsmiTemperatureMetricT { |
| 1950 |
pub const AmdsmiTempLast: AmdsmiTemperatureMetricT = |
| 1951 |
AmdsmiTemperatureMetricT::AmdsmiTempShutdown; |
| 1952 |
} |
| 1953 |
#[repr(u32)] |
| 1954 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 1955 |
pub enum AmdsmiTemperatureMetricT { |
| 1956 |
AmdsmiTempCurrent = 0, |
| 1957 |
AmdsmiTempMax = 1, |
| 1958 |
AmdsmiTempMin = 2, |
| 1959 |
AmdsmiTempMaxHyst = 3, |
| 1960 |
AmdsmiTempMinHyst = 4, |
| 1961 |
AmdsmiTempCritical = 5, |
| 1962 |
AmdsmiTempCriticalHyst = 6, |
| 1963 |
AmdsmiTempEmergency = 7, |
| 1964 |
AmdsmiTempEmergencyHyst = 8, |
| 1965 |
AmdsmiTempCritMin = 9, |
| 1966 |
AmdsmiTempCritMinHyst = 10, |
| 1967 |
AmdsmiTempOffset = 11, |
| 1968 |
AmdsmiTempLowest = 12, |
| 1969 |
AmdsmiTempHighest = 13, |
| 1970 |
AmdsmiTempShutdown = 14, |
| 1971 |
} |
| 1972 |
impl AmdsmiVoltageMetricT { |
| 1973 |
pub const AmdsmiVoltFirst: AmdsmiVoltageMetricT = AmdsmiVoltageMetricT::AmdsmiVoltCurrent; |
| 1974 |
} |
| 1975 |
impl AmdsmiVoltageMetricT { |
| 1976 |
pub const AmdsmiVoltLast: AmdsmiVoltageMetricT = AmdsmiVoltageMetricT::AmdsmiVoltHighest; |
| 1977 |
} |
| 1978 |
#[repr(u32)] |
| 1979 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 1980 |
pub enum AmdsmiVoltageMetricT { |
| 1981 |
AmdsmiVoltCurrent = 0, |
| 1982 |
AmdsmiVoltMax = 1, |
| 1983 |
AmdsmiVoltMinCrit = 2, |
| 1984 |
AmdsmiVoltMin = 3, |
| 1985 |
AmdsmiVoltMaxCrit = 4, |
| 1986 |
AmdsmiVoltAverage = 5, |
| 1987 |
AmdsmiVoltLowest = 6, |
| 1988 |
AmdsmiVoltHighest = 7, |
| 1989 |
} |
| 1990 |
impl AmdsmiVoltageTypeT { |
| 1991 |
pub const AmdsmiVoltTypeVddgfx: AmdsmiVoltageTypeT = AmdsmiVoltageTypeT::AmdsmiVoltTypeFirst; |
| 1992 |
} |
| 1993 |
impl AmdsmiVoltageTypeT { |
| 1994 |
pub const AmdsmiVoltTypeLast: AmdsmiVoltageTypeT = AmdsmiVoltageTypeT::AmdsmiVoltTypeVddboard; |
| 1995 |
} |
| 1996 |
#[repr(u32)] |
| 1997 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 1998 |
pub enum AmdsmiVoltageTypeT { |
| 1999 |
AmdsmiVoltTypeFirst = 0, |
| 2000 |
AmdsmiVoltTypeVddboard = 1, |
| 2001 |
AmdsmiVoltTypeInvalid = 4294967295, |
| 2002 |
} |
| 2003 |
impl AmdsmiPowerProfilePresetMasksT { |
| 2004 |
pub const AmdsmiPwrProfPrstLast: AmdsmiPowerProfilePresetMasksT = |
| 2005 |
AmdsmiPowerProfilePresetMasksT::AmdsmiPwrProfPrstBootupDefault; |
| 2006 |
} |
| 2007 |
#[repr(u64)] |
| 2008 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 2009 |
pub enum AmdsmiPowerProfilePresetMasksT { |
| 2010 |
AmdsmiPwrProfPrstCustomMask = 1, |
| 2011 |
AmdsmiPwrProfPrstVideoMask = 2, |
| 2012 |
AmdsmiPwrProfPrstPowerSavingMask = 4, |
| 2013 |
AmdsmiPwrProfPrstComputeMask = 8, |
| 2014 |
AmdsmiPwrProfPrstVrMask = 16, |
| 2015 |
AmdsmiPwrProfPrst3dFullScrMask = 32, |
| 2016 |
AmdsmiPwrProfPrstBootupDefault = 64, |
| 2017 |
AmdsmiPwrProfPrstInvalid = 18446744073709551615, |
| 2018 |
} |
| 2019 |
impl AmdsmiGpuBlockT { |
| 2020 |
pub const AmdsmiGpuBlockUmc: AmdsmiGpuBlockT = AmdsmiGpuBlockT::AmdsmiGpuBlockFirst; |
| 2021 |
} |
| 2022 |
impl AmdsmiGpuBlockT { |
| 2023 |
pub const AmdsmiGpuBlockLast: AmdsmiGpuBlockT = AmdsmiGpuBlockT::AmdsmiGpuBlockMpio; |
| 2024 |
} |
| 2025 |
#[repr(u64)] |
| 2026 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 2027 |
pub enum AmdsmiGpuBlockT { |
| 2028 |
AmdsmiGpuBlockInvalid = 0, |
| 2029 |
AmdsmiGpuBlockFirst = 1, |
| 2030 |
AmdsmiGpuBlockSdma = 2, |
| 2031 |
AmdsmiGpuBlockGfx = 4, |
| 2032 |
AmdsmiGpuBlockMmhub = 8, |
| 2033 |
AmdsmiGpuBlockAthub = 16, |
| 2034 |
AmdsmiGpuBlockPcieBif = 32, |
| 2035 |
AmdsmiGpuBlockHdp = 64, |
| 2036 |
AmdsmiGpuBlockXgmiWafl = 128, |
| 2037 |
AmdsmiGpuBlockDf = 256, |
| 2038 |
AmdsmiGpuBlockSmn = 512, |
| 2039 |
AmdsmiGpuBlockSem = 1024, |
| 2040 |
AmdsmiGpuBlockMp0 = 2048, |
| 2041 |
AmdsmiGpuBlockMp1 = 4096, |
| 2042 |
AmdsmiGpuBlockFuse = 8192, |
| 2043 |
AmdsmiGpuBlockMca = 16384, |
| 2044 |
AmdsmiGpuBlockVcn = 32768, |
| 2045 |
AmdsmiGpuBlockJpeg = 65536, |
| 2046 |
AmdsmiGpuBlockIh = 131072, |
| 2047 |
AmdsmiGpuBlockMpio = 262144, |
| 2048 |
AmdsmiGpuBlockReserved = 9223372036854775808, |
| 2049 |
} |
| 2050 |
#[repr(u32)] |
| 2051 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 2052 |
pub enum AmdsmiClkLimitTypeT { |
| 2053 |
ClkLimitMin = 0, |
| 2054 |
ClkLimitMax = 1, |
| 2055 |
} |
| 2056 |
#[repr(u32)] |
| 2057 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 2058 |
pub enum AmdsmiCperSevT { |
| 2059 |
AmdsmiCperSevNonFatalUncorrected = 0, |
| 2060 |
AmdsmiCperSevFatal = 1, |
| 2061 |
AmdsmiCperSevNonFatalCorrected = 2, |
| 2062 |
AmdsmiCperSevNum = 3, |
| 2063 |
AmdsmiCperSevUnused = 10, |
| 2064 |
} |
| 2065 |
#[repr(u64)] |
| 2066 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 2067 |
pub enum AmdsmiCperNotifyTypeT { |
| 2068 |
AmdsmiCperNotifyTypeCmc = 4976123370175105969, |
| 2069 |
AmdsmiCperNotifyTypeCpe = 5356425115412803478, |
| 2070 |
AmdsmiCperNotifyTypeMce = 5531987820403847166, |
| 2071 |
AmdsmiCperNotifyTypePcie = 5619395120325705759, |
| 2072 |
AmdsmiCperNotifyTypeInit = 4992964802890589160, |
| 2073 |
AmdsmiCperNotifyTypeNmi = 4812579876830546431, |
| 2074 |
AmdsmiCperNotifyTypeBoot = 4655221457236894822, |
| 2075 |
AmdsmiCperNotifyTypeDmar = 5487573144795207569, |
| 2076 |
AmdsmiCperNotifyTypeSea = 1289362001033197706, |
| 2077 |
AmdsmiCperNotifyTypeSei = 5658685719731260545, |
| 2078 |
AmdsmiCperNotifyTypePei = 4761520883332928940, |
| 2079 |
AmdsmiCperNotifyTypeCxlComponent = 5306157213770398665, |
| 2080 |
} |
| 2081 |
impl AmdsmiRasErrStateT { |
| 2082 |
pub const AmdsmiRasErrStateLast: AmdsmiRasErrStateT = |
| 2083 |
AmdsmiRasErrStateT::AmdsmiRasErrStateEnabled; |
| 2084 |
} |
| 2085 |
#[repr(u32)] |
| 2086 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 2087 |
pub enum AmdsmiRasErrStateT { |
| 2088 |
AmdsmiRasErrStateNone = 0, |
| 2089 |
AmdsmiRasErrStateDisabled = 1, |
| 2090 |
AmdsmiRasErrStateParity = 2, |
| 2091 |
AmdsmiRasErrStateSingC = 3, |
| 2092 |
AmdsmiRasErrStateMultUc = 4, |
| 2093 |
AmdsmiRasErrStatePoison = 5, |
| 2094 |
AmdsmiRasErrStateEnabled = 6, |
| 2095 |
AmdsmiRasErrStateInvalid = 4294967295, |
| 2096 |
} |
| 2097 |
impl AmdsmiMemoryTypeT { |
| 2098 |
pub const AmdsmiMemTypeVram: AmdsmiMemoryTypeT = AmdsmiMemoryTypeT::AmdsmiMemTypeFirst; |
| 2099 |
} |
| 2100 |
impl AmdsmiMemoryTypeT { |
| 2101 |
pub const AmdsmiMemTypeLast: AmdsmiMemoryTypeT = AmdsmiMemoryTypeT::AmdsmiMemTypeGtt; |
| 2102 |
} |
| 2103 |
#[repr(u32)] |
| 2104 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 2105 |
pub enum AmdsmiMemoryTypeT { |
| 2106 |
AmdsmiMemTypeFirst = 0, |
| 2107 |
AmdsmiMemTypeVisVram = 1, |
| 2108 |
AmdsmiMemTypeGtt = 2, |
| 2109 |
} |
| 2110 |
#[repr(u32)] |
| 2111 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 2112 |
pub enum AmdsmiFreqIndT { |
| 2113 |
AmdsmiFreqIndMin = 0, |
| 2114 |
AmdsmiFreqIndMax = 1, |
| 2115 |
AmdsmiFreqIndInvalid = 4294967295, |
| 2116 |
} |
| 2117 |
#[repr(u32)] |
| 2118 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 2119 |
pub enum AmdsmiXgmiStatusT { |
| 2120 |
AmdsmiXgmiStatusNoErrors = 0, |
| 2121 |
AmdsmiXgmiStatusError = 1, |
| 2122 |
AmdsmiXgmiStatusMultipleErrors = 2, |
| 2123 |
} |
| 2124 |
pub type AmdsmiBitFieldT = u64; |
| 2125 |
#[repr(u32)] |
| 2126 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 2127 |
pub enum AmdsmiMemoryPageStatusT { |
| 2128 |
AmdsmiMemPageStatusReserved = 0, |
| 2129 |
AmdsmiMemPageStatusPending = 1, |
| 2130 |
AmdsmiMemPageStatusUnreservable = 2, |
| 2131 |
} |
| 2132 |
impl AmdsmiUtilizationCounterTypeT { |
| 2133 |
pub const AmdsmiCoarseGrainGfxActivity: AmdsmiUtilizationCounterTypeT = |
| 2134 |
AmdsmiUtilizationCounterTypeT::AmdsmiUtilizationCounterFirst; |
| 2135 |
} |
| 2136 |
impl AmdsmiUtilizationCounterTypeT { |
| 2137 |
pub const AmdsmiUtilizationCounterLast: AmdsmiUtilizationCounterTypeT = |
| 2138 |
AmdsmiUtilizationCounterTypeT::AmdsmiFineDecoderActivity; |
| 2139 |
} |
| 2140 |
#[repr(u32)] |
| 2141 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 2142 |
pub enum AmdsmiUtilizationCounterTypeT { |
| 2143 |
AmdsmiUtilizationCounterFirst = 0, |
| 2144 |
AmdsmiCoarseGrainMemActivity = 1, |
| 2145 |
AmdsmiCoarseDecoderActivity = 2, |
| 2146 |
AmdsmiFineGrainGfxActivity = 100, |
| 2147 |
AmdsmiFineGrainMemActivity = 101, |
| 2148 |
AmdsmiFineDecoderActivity = 102, |
| 2149 |
} |
| 2150 |
#[repr(C)] |
| 2151 |
#[derive(Debug, Copy, Clone)] |
| 2152 |
pub struct AmdsmiUtilizationCounterT { |
| 2153 |
pub type_: AmdsmiUtilizationCounterTypeT, |
| 2154 |
pub value: u64, |
| 2155 |
pub fine_value: [u64; 4usize], |
| 2156 |
pub fine_value_count: u16, |
| 2157 |
} |
| 2158 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 2159 |
const _: () = { |
| 2160 |
["Size of AmdsmiUtilizationCounterT"] |
| 2161 |
[::std::mem::size_of::<AmdsmiUtilizationCounterT>() - 56usize]; |
| 2162 |
["Alignment of AmdsmiUtilizationCounterT"] |
| 2163 |
[::std::mem::align_of::<AmdsmiUtilizationCounterT>() - 8usize]; |
| 2164 |
["Offset of field: AmdsmiUtilizationCounterT::type_"] |
| 2165 |
[::std::mem::offset_of!(AmdsmiUtilizationCounterT, type_) - 0usize]; |
| 2166 |
["Offset of field: AmdsmiUtilizationCounterT::value"] |
| 2167 |
[::std::mem::offset_of!(AmdsmiUtilizationCounterT, value) - 8usize]; |
| 2168 |
["Offset of field: AmdsmiUtilizationCounterT::fine_value"] |
| 2169 |
[::std::mem::offset_of!(AmdsmiUtilizationCounterT, fine_value) - 16usize]; |
| 2170 |
["Offset of field: AmdsmiUtilizationCounterT::fine_value_count"] |
| 2171 |
[::std::mem::offset_of!(AmdsmiUtilizationCounterT, fine_value_count) - 48usize]; |
| 2172 |
}; |
| 2173 |
#[repr(C)] |
| 2174 |
#[derive(Debug, Copy, Clone)] |
| 2175 |
pub struct AmdsmiRetiredPageRecordT { |
| 2176 |
pub page_address: u64, |
| 2177 |
pub page_size: u64, |
| 2178 |
pub status: AmdsmiMemoryPageStatusT, |
| 2179 |
} |
| 2180 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 2181 |
const _: () = { |
| 2182 |
["Size of AmdsmiRetiredPageRecordT"] |
| 2183 |
[::std::mem::size_of::<AmdsmiRetiredPageRecordT>() - 24usize]; |
| 2184 |
["Alignment of AmdsmiRetiredPageRecordT"] |
| 2185 |
[::std::mem::align_of::<AmdsmiRetiredPageRecordT>() - 8usize]; |
| 2186 |
["Offset of field: AmdsmiRetiredPageRecordT::page_address"] |
| 2187 |
[::std::mem::offset_of!(AmdsmiRetiredPageRecordT, page_address) - 0usize]; |
| 2188 |
["Offset of field: AmdsmiRetiredPageRecordT::page_size"] |
| 2189 |
[::std::mem::offset_of!(AmdsmiRetiredPageRecordT, page_size) - 8usize]; |
| 2190 |
["Offset of field: AmdsmiRetiredPageRecordT::status"] |
| 2191 |
[::std::mem::offset_of!(AmdsmiRetiredPageRecordT, status) - 16usize]; |
| 2192 |
}; |
| 2193 |
#[repr(C)] |
| 2194 |
#[derive(Debug, Copy, Clone)] |
| 2195 |
pub struct AmdsmiPowerProfileStatusT { |
| 2196 |
pub available_profiles: AmdsmiBitFieldT, |
| 2197 |
pub current: AmdsmiPowerProfilePresetMasksT, |
| 2198 |
pub num_profiles: u32, |
| 2199 |
} |
| 2200 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 2201 |
const _: () = { |
| 2202 |
["Size of AmdsmiPowerProfileStatusT"] |
| 2203 |
[::std::mem::size_of::<AmdsmiPowerProfileStatusT>() - 24usize]; |
| 2204 |
["Alignment of AmdsmiPowerProfileStatusT"] |
| 2205 |
[::std::mem::align_of::<AmdsmiPowerProfileStatusT>() - 8usize]; |
| 2206 |
["Offset of field: AmdsmiPowerProfileStatusT::available_profiles"] |
| 2207 |
[::std::mem::offset_of!(AmdsmiPowerProfileStatusT, available_profiles) - 0usize]; |
| 2208 |
["Offset of field: AmdsmiPowerProfileStatusT::current"] |
| 2209 |
[::std::mem::offset_of!(AmdsmiPowerProfileStatusT, current) - 8usize]; |
| 2210 |
["Offset of field: AmdsmiPowerProfileStatusT::num_profiles"] |
| 2211 |
[::std::mem::offset_of!(AmdsmiPowerProfileStatusT, num_profiles) - 16usize]; |
| 2212 |
}; |
| 2213 |
#[repr(C)] |
| 2214 |
#[derive(Debug, Copy, Clone)] |
| 2215 |
pub struct AmdsmiFrequenciesT { |
| 2216 |
pub has_deep_sleep: bool, |
| 2217 |
pub num_supported: u32, |
| 2218 |
pub current: u32, |
| 2219 |
pub frequency: [u64; 33usize], |
| 2220 |
} |
| 2221 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 2222 |
const _: () = { |
| 2223 |
["Size of AmdsmiFrequenciesT"][::std::mem::size_of::<AmdsmiFrequenciesT>() - 280usize]; |
| 2224 |
["Alignment of AmdsmiFrequenciesT"][::std::mem::align_of::<AmdsmiFrequenciesT>() - 8usize]; |
| 2225 |
["Offset of field: AmdsmiFrequenciesT::has_deep_sleep"] |
| 2226 |
[::std::mem::offset_of!(AmdsmiFrequenciesT, has_deep_sleep) - 0usize]; |
| 2227 |
["Offset of field: AmdsmiFrequenciesT::num_supported"] |
| 2228 |
[::std::mem::offset_of!(AmdsmiFrequenciesT, num_supported) - 4usize]; |
| 2229 |
["Offset of field: AmdsmiFrequenciesT::current"] |
| 2230 |
[::std::mem::offset_of!(AmdsmiFrequenciesT, current) - 8usize]; |
| 2231 |
["Offset of field: AmdsmiFrequenciesT::frequency"] |
| 2232 |
[::std::mem::offset_of!(AmdsmiFrequenciesT, frequency) - 16usize]; |
| 2233 |
}; |
| 2234 |
#[repr(C)] |
| 2235 |
#[derive(Debug, Copy, Clone)] |
| 2236 |
pub struct AmdsmiDpmPolicyEntryT { |
| 2237 |
pub policy_id: u32, |
| 2238 |
pub policy_description: [::std::os::raw::c_char; 256usize], |
| 2239 |
} |
| 2240 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 2241 |
const _: () = { |
| 2242 |
["Size of AmdsmiDpmPolicyEntryT"][::std::mem::size_of::<AmdsmiDpmPolicyEntryT>() - 260usize]; |
| 2243 |
["Alignment of AmdsmiDpmPolicyEntryT"] |
| 2244 |
[::std::mem::align_of::<AmdsmiDpmPolicyEntryT>() - 4usize]; |
| 2245 |
["Offset of field: AmdsmiDpmPolicyEntryT::policy_id"] |
| 2246 |
[::std::mem::offset_of!(AmdsmiDpmPolicyEntryT, policy_id) - 0usize]; |
| 2247 |
["Offset of field: AmdsmiDpmPolicyEntryT::policy_description"] |
| 2248 |
[::std::mem::offset_of!(AmdsmiDpmPolicyEntryT, policy_description) - 4usize]; |
| 2249 |
}; |
| 2250 |
#[repr(C)] |
| 2251 |
#[derive(Debug, Copy, Clone)] |
| 2252 |
pub struct AmdsmiDpmPolicyT { |
| 2253 |
pub num_supported: u32, |
| 2254 |
pub current: u32, |
| 2255 |
pub policies: [AmdsmiDpmPolicyEntryT; 32usize], |
| 2256 |
} |
| 2257 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 2258 |
const _: () = { |
| 2259 |
["Size of AmdsmiDpmPolicyT"][::std::mem::size_of::<AmdsmiDpmPolicyT>() - 8328usize]; |
| 2260 |
["Alignment of AmdsmiDpmPolicyT"][::std::mem::align_of::<AmdsmiDpmPolicyT>() - 4usize]; |
| 2261 |
["Offset of field: AmdsmiDpmPolicyT::num_supported"] |
| 2262 |
[::std::mem::offset_of!(AmdsmiDpmPolicyT, num_supported) - 0usize]; |
| 2263 |
["Offset of field: AmdsmiDpmPolicyT::current"] |
| 2264 |
[::std::mem::offset_of!(AmdsmiDpmPolicyT, current) - 4usize]; |
| 2265 |
["Offset of field: AmdsmiDpmPolicyT::policies"] |
| 2266 |
[::std::mem::offset_of!(AmdsmiDpmPolicyT, policies) - 8usize]; |
| 2267 |
}; |
| 2268 |
#[repr(C)] |
| 2269 |
#[derive(Debug, Copy, Clone)] |
| 2270 |
pub struct AmdsmiPcieBandwidthT { |
| 2271 |
pub transfer_rate: AmdsmiFrequenciesT, |
| 2272 |
pub lanes: [u32; 33usize], |
| 2273 |
} |
| 2274 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 2275 |
const _: () = { |
| 2276 |
["Size of AmdsmiPcieBandwidthT"][::std::mem::size_of::<AmdsmiPcieBandwidthT>() - 416usize]; |
| 2277 |
["Alignment of AmdsmiPcieBandwidthT"][::std::mem::align_of::<AmdsmiPcieBandwidthT>() - 8usize]; |
| 2278 |
["Offset of field: AmdsmiPcieBandwidthT::transfer_rate"] |
| 2279 |
[::std::mem::offset_of!(AmdsmiPcieBandwidthT, transfer_rate) - 0usize]; |
| 2280 |
["Offset of field: AmdsmiPcieBandwidthT::lanes"] |
| 2281 |
[::std::mem::offset_of!(AmdsmiPcieBandwidthT, lanes) - 280usize]; |
| 2282 |
}; |
| 2283 |
#[repr(C)] |
| 2284 |
#[derive(Debug, Copy, Clone)] |
| 2285 |
pub struct AmdsmiVersionT { |
| 2286 |
pub major: u32, |
| 2287 |
pub minor: u32, |
| 2288 |
pub release: u32, |
| 2289 |
pub build: *const ::std::os::raw::c_char, |
| 2290 |
} |
| 2291 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 2292 |
const _: () = { |
| 2293 |
["Size of AmdsmiVersionT"][::std::mem::size_of::<AmdsmiVersionT>() - 24usize]; |
| 2294 |
["Alignment of AmdsmiVersionT"][::std::mem::align_of::<AmdsmiVersionT>() - 8usize]; |
| 2295 |
["Offset of field: AmdsmiVersionT::major"] |
| 2296 |
[::std::mem::offset_of!(AmdsmiVersionT, major) - 0usize]; |
| 2297 |
["Offset of field: AmdsmiVersionT::minor"] |
| 2298 |
[::std::mem::offset_of!(AmdsmiVersionT, minor) - 4usize]; |
| 2299 |
["Offset of field: AmdsmiVersionT::release"] |
| 2300 |
[::std::mem::offset_of!(AmdsmiVersionT, release) - 8usize]; |
| 2301 |
["Offset of field: AmdsmiVersionT::build"] |
| 2302 |
[::std::mem::offset_of!(AmdsmiVersionT, build) - 16usize]; |
| 2303 |
}; |
| 2304 |
#[repr(C)] |
| 2305 |
#[derive(Debug, Copy, Clone)] |
| 2306 |
pub struct AmdsmiOdVddcPointT { |
| 2307 |
pub frequency: u64, |
| 2308 |
pub voltage: u64, |
| 2309 |
} |
| 2310 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 2311 |
const _: () = { |
| 2312 |
["Size of AmdsmiOdVddcPointT"][::std::mem::size_of::<AmdsmiOdVddcPointT>() - 16usize]; |
| 2313 |
["Alignment of AmdsmiOdVddcPointT"][::std::mem::align_of::<AmdsmiOdVddcPointT>() - 8usize]; |
| 2314 |
["Offset of field: AmdsmiOdVddcPointT::frequency"] |
| 2315 |
[::std::mem::offset_of!(AmdsmiOdVddcPointT, frequency) - 0usize]; |
| 2316 |
["Offset of field: AmdsmiOdVddcPointT::voltage"] |
| 2317 |
[::std::mem::offset_of!(AmdsmiOdVddcPointT, voltage) - 8usize]; |
| 2318 |
}; |
| 2319 |
#[repr(C)] |
| 2320 |
#[derive(Debug, Copy, Clone)] |
| 2321 |
pub struct AmdsmiFreqVoltRegionT { |
| 2322 |
pub freq_range: AmdsmiRangeT, |
| 2323 |
pub volt_range: AmdsmiRangeT, |
| 2324 |
} |
| 2325 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 2326 |
const _: () = { |
| 2327 |
["Size of AmdsmiFreqVoltRegionT"][::std::mem::size_of::<AmdsmiFreqVoltRegionT>() - 64usize]; |
| 2328 |
["Alignment of AmdsmiFreqVoltRegionT"] |
| 2329 |
[::std::mem::align_of::<AmdsmiFreqVoltRegionT>() - 8usize]; |
| 2330 |
["Offset of field: AmdsmiFreqVoltRegionT::freq_range"] |
| 2331 |
[::std::mem::offset_of!(AmdsmiFreqVoltRegionT, freq_range) - 0usize]; |
| 2332 |
["Offset of field: AmdsmiFreqVoltRegionT::volt_range"] |
| 2333 |
[::std::mem::offset_of!(AmdsmiFreqVoltRegionT, volt_range) - 32usize]; |
| 2334 |
}; |
| 2335 |
#[repr(C)] |
| 2336 |
#[derive(Debug, Copy, Clone)] |
| 2337 |
pub struct AmdsmiOdVoltCurveT { |
| 2338 |
pub vc_points: [AmdsmiOdVddcPointT; 3usize], |
| 2339 |
} |
| 2340 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 2341 |
const _: () = { |
| 2342 |
["Size of AmdsmiOdVoltCurveT"][::std::mem::size_of::<AmdsmiOdVoltCurveT>() - 48usize]; |
| 2343 |
["Alignment of AmdsmiOdVoltCurveT"][::std::mem::align_of::<AmdsmiOdVoltCurveT>() - 8usize]; |
| 2344 |
["Offset of field: AmdsmiOdVoltCurveT::vc_points"] |
| 2345 |
[::std::mem::offset_of!(AmdsmiOdVoltCurveT, vc_points) - 0usize]; |
| 2346 |
}; |
| 2347 |
#[repr(C)] |
| 2348 |
#[derive(Debug, Copy, Clone)] |
| 2349 |
pub struct AmdsmiOdVoltFreqDataT { |
| 2350 |
pub curr_sclk_range: AmdsmiRangeT, |
| 2351 |
pub curr_mclk_range: AmdsmiRangeT, |
| 2352 |
pub sclk_freq_limits: AmdsmiRangeT, |
| 2353 |
pub mclk_freq_limits: AmdsmiRangeT, |
| 2354 |
pub curve: AmdsmiOdVoltCurveT, |
| 2355 |
pub num_regions: u32, |
| 2356 |
} |
| 2357 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 2358 |
const _: () = { |
| 2359 |
["Size of AmdsmiOdVoltFreqDataT"][::std::mem::size_of::<AmdsmiOdVoltFreqDataT>() - 184usize]; |
| 2360 |
["Alignment of AmdsmiOdVoltFreqDataT"] |
| 2361 |
[::std::mem::align_of::<AmdsmiOdVoltFreqDataT>() - 8usize]; |
| 2362 |
["Offset of field: AmdsmiOdVoltFreqDataT::curr_sclk_range"] |
| 2363 |
[::std::mem::offset_of!(AmdsmiOdVoltFreqDataT, curr_sclk_range) - 0usize]; |
| 2364 |
["Offset of field: AmdsmiOdVoltFreqDataT::curr_mclk_range"] |
| 2365 |
[::std::mem::offset_of!(AmdsmiOdVoltFreqDataT, curr_mclk_range) - 32usize]; |
| 2366 |
["Offset of field: AmdsmiOdVoltFreqDataT::sclk_freq_limits"] |
| 2367 |
[::std::mem::offset_of!(AmdsmiOdVoltFreqDataT, sclk_freq_limits) - 64usize]; |
| 2368 |
["Offset of field: AmdsmiOdVoltFreqDataT::mclk_freq_limits"] |
| 2369 |
[::std::mem::offset_of!(AmdsmiOdVoltFreqDataT, mclk_freq_limits) - 96usize]; |
| 2370 |
["Offset of field: AmdsmiOdVoltFreqDataT::curve"] |
| 2371 |
[::std::mem::offset_of!(AmdsmiOdVoltFreqDataT, curve) - 128usize]; |
| 2372 |
["Offset of field: AmdsmiOdVoltFreqDataT::num_regions"] |
| 2373 |
[::std::mem::offset_of!(AmdsmiOdVoltFreqDataT, num_regions) - 176usize]; |
| 2374 |
}; |
| 2375 |
#[repr(C)] |
| 2376 |
#[derive(Debug, Copy, Clone)] |
| 2377 |
pub struct AmdMetricsTableHeaderT { |
| 2378 |
pub structure_size: u16, |
| 2379 |
pub format_revision: u8, |
| 2380 |
pub content_revision: u8, |
| 2381 |
} |
| 2382 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 2383 |
const _: () = { |
| 2384 |
["Size of AmdMetricsTableHeaderT"][::std::mem::size_of::<AmdMetricsTableHeaderT>() - 4usize]; |
| 2385 |
["Alignment of AmdMetricsTableHeaderT"] |
| 2386 |
[::std::mem::align_of::<AmdMetricsTableHeaderT>() - 2usize]; |
| 2387 |
["Offset of field: AmdMetricsTableHeaderT::structure_size"] |
| 2388 |
[::std::mem::offset_of!(AmdMetricsTableHeaderT, structure_size) - 0usize]; |
| 2389 |
["Offset of field: AmdMetricsTableHeaderT::format_revision"] |
| 2390 |
[::std::mem::offset_of!(AmdMetricsTableHeaderT, format_revision) - 2usize]; |
| 2391 |
["Offset of field: AmdMetricsTableHeaderT::content_revision"] |
| 2392 |
[::std::mem::offset_of!(AmdMetricsTableHeaderT, content_revision) - 3usize]; |
| 2393 |
}; |
| 2394 |
#[repr(C)] |
| 2395 |
#[derive(Debug, Copy, Clone)] |
| 2396 |
pub struct AmdsmiGpuXcpMetricsT { |
| 2397 |
pub gfx_busy_inst: [u32; 8usize], |
| 2398 |
pub jpeg_busy: [u16; 40usize], |
| 2399 |
pub vcn_busy: [u16; 4usize], |
| 2400 |
pub gfx_busy_acc: [u64; 8usize], |
| 2401 |
pub gfx_below_host_limit_acc: [u64; 8usize], |
| 2402 |
pub gfx_below_host_limit_ppt_acc: [u64; 8usize], |
| 2403 |
pub gfx_below_host_limit_thm_acc: [u64; 8usize], |
| 2404 |
pub gfx_low_utilization_acc: [u64; 8usize], |
| 2405 |
pub gfx_below_host_limit_total_acc: [u64; 8usize], |
| 2406 |
} |
| 2407 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 2408 |
const _: () = { |
| 2409 |
["Size of AmdsmiGpuXcpMetricsT"][::std::mem::size_of::<AmdsmiGpuXcpMetricsT>() - 504usize]; |
| 2410 |
["Alignment of AmdsmiGpuXcpMetricsT"][::std::mem::align_of::<AmdsmiGpuXcpMetricsT>() - 8usize]; |
| 2411 |
["Offset of field: AmdsmiGpuXcpMetricsT::gfx_busy_inst"] |
| 2412 |
[::std::mem::offset_of!(AmdsmiGpuXcpMetricsT, gfx_busy_inst) - 0usize]; |
| 2413 |
["Offset of field: AmdsmiGpuXcpMetricsT::jpeg_busy"] |
| 2414 |
[::std::mem::offset_of!(AmdsmiGpuXcpMetricsT, jpeg_busy) - 32usize]; |
| 2415 |
["Offset of field: AmdsmiGpuXcpMetricsT::vcn_busy"] |
| 2416 |
[::std::mem::offset_of!(AmdsmiGpuXcpMetricsT, vcn_busy) - 112usize]; |
| 2417 |
["Offset of field: AmdsmiGpuXcpMetricsT::gfx_busy_acc"] |
| 2418 |
[::std::mem::offset_of!(AmdsmiGpuXcpMetricsT, gfx_busy_acc) - 120usize]; |
| 2419 |
["Offset of field: AmdsmiGpuXcpMetricsT::gfx_below_host_limit_acc"] |
| 2420 |
[::std::mem::offset_of!(AmdsmiGpuXcpMetricsT, gfx_below_host_limit_acc) - 184usize]; |
| 2421 |
["Offset of field: AmdsmiGpuXcpMetricsT::gfx_below_host_limit_ppt_acc"] |
| 2422 |
[::std::mem::offset_of!(AmdsmiGpuXcpMetricsT, gfx_below_host_limit_ppt_acc) - 248usize]; |
| 2423 |
["Offset of field: AmdsmiGpuXcpMetricsT::gfx_below_host_limit_thm_acc"] |
| 2424 |
[::std::mem::offset_of!(AmdsmiGpuXcpMetricsT, gfx_below_host_limit_thm_acc) - 312usize]; |
| 2425 |
["Offset of field: AmdsmiGpuXcpMetricsT::gfx_low_utilization_acc"] |
| 2426 |
[::std::mem::offset_of!(AmdsmiGpuXcpMetricsT, gfx_low_utilization_acc) - 376usize]; |
| 2427 |
["Offset of field: AmdsmiGpuXcpMetricsT::gfx_below_host_limit_total_acc"] |
| 2428 |
[::std::mem::offset_of!(AmdsmiGpuXcpMetricsT, gfx_below_host_limit_total_acc) - 440usize]; |
| 2429 |
}; |
| 2430 |
#[repr(C)] |
| 2431 |
#[derive(Debug, Copy, Clone)] |
| 2432 |
pub struct AmdsmiGpuMetricsT { |
| 2433 |
pub common_header: AmdMetricsTableHeaderT, |
| 2434 |
pub temperature_edge: u16, |
| 2435 |
pub temperature_hotspot: u16, |
| 2436 |
pub temperature_mem: u16, |
| 2437 |
pub temperature_vrgfx: u16, |
| 2438 |
pub temperature_vrsoc: u16, |
| 2439 |
pub temperature_vrmem: u16, |
| 2440 |
pub average_gfx_activity: u16, |
| 2441 |
pub average_umc_activity: u16, |
| 2442 |
pub average_mm_activity: u16, |
| 2443 |
pub average_socket_power: u16, |
| 2444 |
pub energy_accumulator: u64, |
| 2445 |
pub system_clock_counter: u64, |
| 2446 |
pub average_gfxclk_frequency: u16, |
| 2447 |
pub average_socclk_frequency: u16, |
| 2448 |
pub average_uclk_frequency: u16, |
| 2449 |
pub average_vclk0_frequency: u16, |
| 2450 |
pub average_dclk0_frequency: u16, |
| 2451 |
pub average_vclk1_frequency: u16, |
| 2452 |
pub average_dclk1_frequency: u16, |
| 2453 |
pub current_gfxclk: u16, |
| 2454 |
pub current_socclk: u16, |
| 2455 |
pub current_uclk: u16, |
| 2456 |
pub current_vclk0: u16, |
| 2457 |
pub current_dclk0: u16, |
| 2458 |
pub current_vclk1: u16, |
| 2459 |
pub current_dclk1: u16, |
| 2460 |
pub throttle_status: u32, |
| 2461 |
pub current_fan_speed: u16, |
| 2462 |
pub pcie_link_width: u16, |
| 2463 |
pub pcie_link_speed: u16, |
| 2464 |
pub gfx_activity_acc: u32, |
| 2465 |
pub mem_activity_acc: u32, |
| 2466 |
pub temperature_hbm: [u16; 4usize], |
| 2467 |
pub firmware_timestamp: u64, |
| 2468 |
pub voltage_soc: u16, |
| 2469 |
pub voltage_gfx: u16, |
| 2470 |
pub voltage_mem: u16, |
| 2471 |
pub indep_throttle_status: u64, |
| 2472 |
pub current_socket_power: u16, |
| 2473 |
pub vcn_activity: [u16; 4usize], |
| 2474 |
pub gfxclk_lock_status: u32, |
| 2475 |
pub xgmi_link_width: u16, |
| 2476 |
pub xgmi_link_speed: u16, |
| 2477 |
pub pcie_bandwidth_acc: u64, |
| 2478 |
pub pcie_bandwidth_inst: u64, |
| 2479 |
pub pcie_l0_to_recov_count_acc: u64, |
| 2480 |
pub pcie_replay_count_acc: u64, |
| 2481 |
pub pcie_replay_rover_count_acc: u64, |
| 2482 |
pub xgmi_read_data_acc: [u64; 8usize], |
| 2483 |
pub xgmi_write_data_acc: [u64; 8usize], |
| 2484 |
pub current_gfxclks: [u16; 8usize], |
| 2485 |
pub current_socclks: [u16; 4usize], |
| 2486 |
pub current_vclk0s: [u16; 4usize], |
| 2487 |
pub current_dclk0s: [u16; 4usize], |
| 2488 |
pub jpeg_activity: [u16; 32usize], |
| 2489 |
pub pcie_nak_sent_count_acc: u32, |
| 2490 |
pub pcie_nak_rcvd_count_acc: u32, |
| 2491 |
pub accumulation_counter: u64, |
| 2492 |
pub prochot_residency_acc: u64, |
| 2493 |
pub ppt_residency_acc: u64, |
| 2494 |
pub socket_thm_residency_acc: u64, |
| 2495 |
pub vr_thm_residency_acc: u64, |
| 2496 |
pub hbm_thm_residency_acc: u64, |
| 2497 |
pub num_partition: u16, |
| 2498 |
pub xcp_stats: [AmdsmiGpuXcpMetricsT; 8usize], |
| 2499 |
pub pcie_lc_perf_other_end_recovery: u32, |
| 2500 |
pub vram_max_bandwidth: u64, |
| 2501 |
pub xgmi_link_status: [u16; 8usize], |
| 2502 |
} |
| 2503 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 2504 |
const _: () = { |
| 2505 |
["Size of AmdsmiGpuMetricsT"][::std::mem::size_of::<AmdsmiGpuMetricsT>() - 4544usize]; |
| 2506 |
["Alignment of AmdsmiGpuMetricsT"][::std::mem::align_of::<AmdsmiGpuMetricsT>() - 8usize]; |
| 2507 |
["Offset of field: AmdsmiGpuMetricsT::common_header"] |
| 2508 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, common_header) - 0usize]; |
| 2509 |
["Offset of field: AmdsmiGpuMetricsT::temperature_edge"] |
| 2510 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, temperature_edge) - 4usize]; |
| 2511 |
["Offset of field: AmdsmiGpuMetricsT::temperature_hotspot"] |
| 2512 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, temperature_hotspot) - 6usize]; |
| 2513 |
["Offset of field: AmdsmiGpuMetricsT::temperature_mem"] |
| 2514 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, temperature_mem) - 8usize]; |
| 2515 |
["Offset of field: AmdsmiGpuMetricsT::temperature_vrgfx"] |
| 2516 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, temperature_vrgfx) - 10usize]; |
| 2517 |
["Offset of field: AmdsmiGpuMetricsT::temperature_vrsoc"] |
| 2518 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, temperature_vrsoc) - 12usize]; |
| 2519 |
["Offset of field: AmdsmiGpuMetricsT::temperature_vrmem"] |
| 2520 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, temperature_vrmem) - 14usize]; |
| 2521 |
["Offset of field: AmdsmiGpuMetricsT::average_gfx_activity"] |
| 2522 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, average_gfx_activity) - 16usize]; |
| 2523 |
["Offset of field: AmdsmiGpuMetricsT::average_umc_activity"] |
| 2524 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, average_umc_activity) - 18usize]; |
| 2525 |
["Offset of field: AmdsmiGpuMetricsT::average_mm_activity"] |
| 2526 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, average_mm_activity) - 20usize]; |
| 2527 |
["Offset of field: AmdsmiGpuMetricsT::average_socket_power"] |
| 2528 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, average_socket_power) - 22usize]; |
| 2529 |
["Offset of field: AmdsmiGpuMetricsT::energy_accumulator"] |
| 2530 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, energy_accumulator) - 24usize]; |
| 2531 |
["Offset of field: AmdsmiGpuMetricsT::system_clock_counter"] |
| 2532 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, system_clock_counter) - 32usize]; |
| 2533 |
["Offset of field: AmdsmiGpuMetricsT::average_gfxclk_frequency"] |
| 2534 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, average_gfxclk_frequency) - 40usize]; |
| 2535 |
["Offset of field: AmdsmiGpuMetricsT::average_socclk_frequency"] |
| 2536 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, average_socclk_frequency) - 42usize]; |
| 2537 |
["Offset of field: AmdsmiGpuMetricsT::average_uclk_frequency"] |
| 2538 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, average_uclk_frequency) - 44usize]; |
| 2539 |
["Offset of field: AmdsmiGpuMetricsT::average_vclk0_frequency"] |
| 2540 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, average_vclk0_frequency) - 46usize]; |
| 2541 |
["Offset of field: AmdsmiGpuMetricsT::average_dclk0_frequency"] |
| 2542 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, average_dclk0_frequency) - 48usize]; |
| 2543 |
["Offset of field: AmdsmiGpuMetricsT::average_vclk1_frequency"] |
| 2544 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, average_vclk1_frequency) - 50usize]; |
| 2545 |
["Offset of field: AmdsmiGpuMetricsT::average_dclk1_frequency"] |
| 2546 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, average_dclk1_frequency) - 52usize]; |
| 2547 |
["Offset of field: AmdsmiGpuMetricsT::current_gfxclk"] |
| 2548 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, current_gfxclk) - 54usize]; |
| 2549 |
["Offset of field: AmdsmiGpuMetricsT::current_socclk"] |
| 2550 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, current_socclk) - 56usize]; |
| 2551 |
["Offset of field: AmdsmiGpuMetricsT::current_uclk"] |
| 2552 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, current_uclk) - 58usize]; |
| 2553 |
["Offset of field: AmdsmiGpuMetricsT::current_vclk0"] |
| 2554 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, current_vclk0) - 60usize]; |
| 2555 |
["Offset of field: AmdsmiGpuMetricsT::current_dclk0"] |
| 2556 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, current_dclk0) - 62usize]; |
| 2557 |
["Offset of field: AmdsmiGpuMetricsT::current_vclk1"] |
| 2558 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, current_vclk1) - 64usize]; |
| 2559 |
["Offset of field: AmdsmiGpuMetricsT::current_dclk1"] |
| 2560 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, current_dclk1) - 66usize]; |
| 2561 |
["Offset of field: AmdsmiGpuMetricsT::throttle_status"] |
| 2562 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, throttle_status) - 68usize]; |
| 2563 |
["Offset of field: AmdsmiGpuMetricsT::current_fan_speed"] |
| 2564 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, current_fan_speed) - 72usize]; |
| 2565 |
["Offset of field: AmdsmiGpuMetricsT::pcie_link_width"] |
| 2566 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, pcie_link_width) - 74usize]; |
| 2567 |
["Offset of field: AmdsmiGpuMetricsT::pcie_link_speed"] |
| 2568 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, pcie_link_speed) - 76usize]; |
| 2569 |
["Offset of field: AmdsmiGpuMetricsT::gfx_activity_acc"] |
| 2570 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, gfx_activity_acc) - 80usize]; |
| 2571 |
["Offset of field: AmdsmiGpuMetricsT::mem_activity_acc"] |
| 2572 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, mem_activity_acc) - 84usize]; |
| 2573 |
["Offset of field: AmdsmiGpuMetricsT::temperature_hbm"] |
| 2574 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, temperature_hbm) - 88usize]; |
| 2575 |
["Offset of field: AmdsmiGpuMetricsT::firmware_timestamp"] |
| 2576 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, firmware_timestamp) - 96usize]; |
| 2577 |
["Offset of field: AmdsmiGpuMetricsT::voltage_soc"] |
| 2578 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, voltage_soc) - 104usize]; |
| 2579 |
["Offset of field: AmdsmiGpuMetricsT::voltage_gfx"] |
| 2580 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, voltage_gfx) - 106usize]; |
| 2581 |
["Offset of field: AmdsmiGpuMetricsT::voltage_mem"] |
| 2582 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, voltage_mem) - 108usize]; |
| 2583 |
["Offset of field: AmdsmiGpuMetricsT::indep_throttle_status"] |
| 2584 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, indep_throttle_status) - 112usize]; |
| 2585 |
["Offset of field: AmdsmiGpuMetricsT::current_socket_power"] |
| 2586 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, current_socket_power) - 120usize]; |
| 2587 |
["Offset of field: AmdsmiGpuMetricsT::vcn_activity"] |
| 2588 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, vcn_activity) - 122usize]; |
| 2589 |
["Offset of field: AmdsmiGpuMetricsT::gfxclk_lock_status"] |
| 2590 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, gfxclk_lock_status) - 132usize]; |
| 2591 |
["Offset of field: AmdsmiGpuMetricsT::xgmi_link_width"] |
| 2592 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, xgmi_link_width) - 136usize]; |
| 2593 |
["Offset of field: AmdsmiGpuMetricsT::xgmi_link_speed"] |
| 2594 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, xgmi_link_speed) - 138usize]; |
| 2595 |
["Offset of field: AmdsmiGpuMetricsT::pcie_bandwidth_acc"] |
| 2596 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, pcie_bandwidth_acc) - 144usize]; |
| 2597 |
["Offset of field: AmdsmiGpuMetricsT::pcie_bandwidth_inst"] |
| 2598 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, pcie_bandwidth_inst) - 152usize]; |
| 2599 |
["Offset of field: AmdsmiGpuMetricsT::pcie_l0_to_recov_count_acc"] |
| 2600 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, pcie_l0_to_recov_count_acc) - 160usize]; |
| 2601 |
["Offset of field: AmdsmiGpuMetricsT::pcie_replay_count_acc"] |
| 2602 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, pcie_replay_count_acc) - 168usize]; |
| 2603 |
["Offset of field: AmdsmiGpuMetricsT::pcie_replay_rover_count_acc"] |
| 2604 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, pcie_replay_rover_count_acc) - 176usize]; |
| 2605 |
["Offset of field: AmdsmiGpuMetricsT::xgmi_read_data_acc"] |
| 2606 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, xgmi_read_data_acc) - 184usize]; |
| 2607 |
["Offset of field: AmdsmiGpuMetricsT::xgmi_write_data_acc"] |
| 2608 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, xgmi_write_data_acc) - 248usize]; |
| 2609 |
["Offset of field: AmdsmiGpuMetricsT::current_gfxclks"] |
| 2610 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, current_gfxclks) - 312usize]; |
| 2611 |
["Offset of field: AmdsmiGpuMetricsT::current_socclks"] |
| 2612 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, current_socclks) - 328usize]; |
| 2613 |
["Offset of field: AmdsmiGpuMetricsT::current_vclk0s"] |
| 2614 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, current_vclk0s) - 336usize]; |
| 2615 |
["Offset of field: AmdsmiGpuMetricsT::current_dclk0s"] |
| 2616 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, current_dclk0s) - 344usize]; |
| 2617 |
["Offset of field: AmdsmiGpuMetricsT::jpeg_activity"] |
| 2618 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, jpeg_activity) - 352usize]; |
| 2619 |
["Offset of field: AmdsmiGpuMetricsT::pcie_nak_sent_count_acc"] |
| 2620 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, pcie_nak_sent_count_acc) - 416usize]; |
| 2621 |
["Offset of field: AmdsmiGpuMetricsT::pcie_nak_rcvd_count_acc"] |
| 2622 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, pcie_nak_rcvd_count_acc) - 420usize]; |
| 2623 |
["Offset of field: AmdsmiGpuMetricsT::accumulation_counter"] |
| 2624 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, accumulation_counter) - 424usize]; |
| 2625 |
["Offset of field: AmdsmiGpuMetricsT::prochot_residency_acc"] |
| 2626 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, prochot_residency_acc) - 432usize]; |
| 2627 |
["Offset of field: AmdsmiGpuMetricsT::ppt_residency_acc"] |
| 2628 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, ppt_residency_acc) - 440usize]; |
| 2629 |
["Offset of field: AmdsmiGpuMetricsT::socket_thm_residency_acc"] |
| 2630 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, socket_thm_residency_acc) - 448usize]; |
| 2631 |
["Offset of field: AmdsmiGpuMetricsT::vr_thm_residency_acc"] |
| 2632 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, vr_thm_residency_acc) - 456usize]; |
| 2633 |
["Offset of field: AmdsmiGpuMetricsT::hbm_thm_residency_acc"] |
| 2634 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, hbm_thm_residency_acc) - 464usize]; |
| 2635 |
["Offset of field: AmdsmiGpuMetricsT::num_partition"] |
| 2636 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, num_partition) - 472usize]; |
| 2637 |
["Offset of field: AmdsmiGpuMetricsT::xcp_stats"] |
| 2638 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, xcp_stats) - 480usize]; |
| 2639 |
["Offset of field: AmdsmiGpuMetricsT::pcie_lc_perf_other_end_recovery"] |
| 2640 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, pcie_lc_perf_other_end_recovery) - 4512usize]; |
| 2641 |
["Offset of field: AmdsmiGpuMetricsT::vram_max_bandwidth"] |
| 2642 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, vram_max_bandwidth) - 4520usize]; |
| 2643 |
["Offset of field: AmdsmiGpuMetricsT::xgmi_link_status"] |
| 2644 |
[::std::mem::offset_of!(AmdsmiGpuMetricsT, xgmi_link_status) - 4528usize]; |
| 2645 |
}; |
| 2646 |
#[repr(u32)] |
| 2647 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 2648 |
pub enum AmdsmiXgmiLinkStatusTypeT { |
| 2649 |
AmdsmiXgmiLinkDown = 0, |
| 2650 |
AmdsmiXgmiLinkUp = 1, |
| 2651 |
AmdsmiXgmiLinkDisable = 2, |
| 2652 |
} |
| 2653 |
#[repr(C)] |
| 2654 |
#[derive(Debug, Copy, Clone)] |
| 2655 |
pub struct AmdsmiXgmiLinkStatusT { |
| 2656 |
pub total_links: u32, |
| 2657 |
pub status: [AmdsmiXgmiLinkStatusTypeT; 8usize], |
| 2658 |
pub reserved: [u64; 7usize], |
| 2659 |
} |
| 2660 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 2661 |
const _: () = { |
| 2662 |
["Size of AmdsmiXgmiLinkStatusT"][::std::mem::size_of::<AmdsmiXgmiLinkStatusT>() - 96usize]; |
| 2663 |
["Alignment of AmdsmiXgmiLinkStatusT"] |
| 2664 |
[::std::mem::align_of::<AmdsmiXgmiLinkStatusT>() - 8usize]; |
| 2665 |
["Offset of field: AmdsmiXgmiLinkStatusT::total_links"] |
| 2666 |
[::std::mem::offset_of!(AmdsmiXgmiLinkStatusT, total_links) - 0usize]; |
| 2667 |
["Offset of field: AmdsmiXgmiLinkStatusT::status"] |
| 2668 |
[::std::mem::offset_of!(AmdsmiXgmiLinkStatusT, status) - 4usize]; |
| 2669 |
["Offset of field: AmdsmiXgmiLinkStatusT::reserved"] |
| 2670 |
[::std::mem::offset_of!(AmdsmiXgmiLinkStatusT, reserved) - 40usize]; |
| 2671 |
}; |
| 2672 |
#[repr(C)] |
| 2673 |
#[derive(Debug, Copy, Clone)] |
| 2674 |
pub struct AmdsmiNameValueT { |
| 2675 |
pub name: [::std::os::raw::c_char; 256usize], |
| 2676 |
pub value: u64, |
| 2677 |
} |
| 2678 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 2679 |
const _: () = { |
| 2680 |
["Size of AmdsmiNameValueT"][::std::mem::size_of::<AmdsmiNameValueT>() - 264usize]; |
| 2681 |
["Alignment of AmdsmiNameValueT"][::std::mem::align_of::<AmdsmiNameValueT>() - 8usize]; |
| 2682 |
["Offset of field: AmdsmiNameValueT::name"] |
| 2683 |
[::std::mem::offset_of!(AmdsmiNameValueT, name) - 0usize]; |
| 2684 |
["Offset of field: AmdsmiNameValueT::value"] |
| 2685 |
[::std::mem::offset_of!(AmdsmiNameValueT, value) - 256usize]; |
| 2686 |
}; |
| 2687 |
#[repr(u32)] |
| 2688 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 2689 |
pub enum AmdsmiRegTypeT { |
| 2690 |
AmdsmiRegXgmi = 0, |
| 2691 |
AmdsmiRegWafl = 1, |
| 2692 |
AmdsmiRegPcie = 2, |
| 2693 |
AmdsmiRegUsr = 3, |
| 2694 |
AmdsmiRegUsr1 = 4, |
| 2695 |
} |
| 2696 |
#[repr(C)] |
| 2697 |
#[derive(Debug, Copy, Clone)] |
| 2698 |
pub struct AmdsmiRasFeatureT { |
| 2699 |
pub ras_eeprom_version: u32, |
| 2700 |
pub ecc_correction_schema_flag: u32, |
| 2701 |
} |
| 2702 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 2703 |
const _: () = { |
| 2704 |
["Size of AmdsmiRasFeatureT"][::std::mem::size_of::<AmdsmiRasFeatureT>() - 8usize]; |
| 2705 |
["Alignment of AmdsmiRasFeatureT"][::std::mem::align_of::<AmdsmiRasFeatureT>() - 4usize]; |
| 2706 |
["Offset of field: AmdsmiRasFeatureT::ras_eeprom_version"] |
| 2707 |
[::std::mem::offset_of!(AmdsmiRasFeatureT, ras_eeprom_version) - 0usize]; |
| 2708 |
["Offset of field: AmdsmiRasFeatureT::ecc_correction_schema_flag"] |
| 2709 |
[::std::mem::offset_of!(AmdsmiRasFeatureT, ecc_correction_schema_flag) - 4usize]; |
| 2710 |
}; |
| 2711 |
#[repr(C)] |
| 2712 |
#[derive(Debug, Copy, Clone)] |
| 2713 |
pub struct AmdsmiErrorCountT { |
| 2714 |
pub correctable_count: u64, |
| 2715 |
pub uncorrectable_count: u64, |
| 2716 |
pub deferred_count: u64, |
| 2717 |
pub reserved: [u64; 5usize], |
| 2718 |
} |
| 2719 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 2720 |
const _: () = { |
| 2721 |
["Size of AmdsmiErrorCountT"][::std::mem::size_of::<AmdsmiErrorCountT>() - 64usize]; |
| 2722 |
["Alignment of AmdsmiErrorCountT"][::std::mem::align_of::<AmdsmiErrorCountT>() - 8usize]; |
| 2723 |
["Offset of field: AmdsmiErrorCountT::correctable_count"] |
| 2724 |
[::std::mem::offset_of!(AmdsmiErrorCountT, correctable_count) - 0usize]; |
| 2725 |
["Offset of field: AmdsmiErrorCountT::uncorrectable_count"] |
| 2726 |
[::std::mem::offset_of!(AmdsmiErrorCountT, uncorrectable_count) - 8usize]; |
| 2727 |
["Offset of field: AmdsmiErrorCountT::deferred_count"] |
| 2728 |
[::std::mem::offset_of!(AmdsmiErrorCountT, deferred_count) - 16usize]; |
| 2729 |
["Offset of field: AmdsmiErrorCountT::reserved"] |
| 2730 |
[::std::mem::offset_of!(AmdsmiErrorCountT, reserved) - 24usize]; |
| 2731 |
}; |
| 2732 |
#[repr(C)] |
| 2733 |
#[derive(Debug, Copy, Clone)] |
| 2734 |
pub struct AmdsmiProcessInfoT { |
| 2735 |
pub process_id: u32, |
| 2736 |
pub vram_usage: u64, |
| 2737 |
pub sdma_usage: u64, |
| 2738 |
pub cu_occupancy: u32, |
| 2739 |
} |
| 2740 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 2741 |
const _: () = { |
| 2742 |
["Size of AmdsmiProcessInfoT"][::std::mem::size_of::<AmdsmiProcessInfoT>() - 32usize]; |
| 2743 |
["Alignment of AmdsmiProcessInfoT"][::std::mem::align_of::<AmdsmiProcessInfoT>() - 8usize]; |
| 2744 |
["Offset of field: AmdsmiProcessInfoT::process_id"] |
| 2745 |
[::std::mem::offset_of!(AmdsmiProcessInfoT, process_id) - 0usize]; |
| 2746 |
["Offset of field: AmdsmiProcessInfoT::vram_usage"] |
| 2747 |
[::std::mem::offset_of!(AmdsmiProcessInfoT, vram_usage) - 8usize]; |
| 2748 |
["Offset of field: AmdsmiProcessInfoT::sdma_usage"] |
| 2749 |
[::std::mem::offset_of!(AmdsmiProcessInfoT, sdma_usage) - 16usize]; |
| 2750 |
["Offset of field: AmdsmiProcessInfoT::cu_occupancy"] |
| 2751 |
[::std::mem::offset_of!(AmdsmiProcessInfoT, cu_occupancy) - 24usize]; |
| 2752 |
}; |
| 2753 |
#[repr(C)] |
| 2754 |
#[derive(Debug, Copy, Clone)] |
| 2755 |
pub struct AmdsmiTopologyNearestT { |
| 2756 |
pub count: u32, |
| 2757 |
pub processor_list: [AmdsmiProcessorHandle; 256usize], |
| 2758 |
pub reserved: [u64; 14usize], |
| 2759 |
} |
| 2760 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 2761 |
const _: () = { |
| 2762 |
["Size of AmdsmiTopologyNearestT"][::std::mem::size_of::<AmdsmiTopologyNearestT>() - 2168usize]; |
| 2763 |
["Alignment of AmdsmiTopologyNearestT"] |
| 2764 |
[::std::mem::align_of::<AmdsmiTopologyNearestT>() - 8usize]; |
| 2765 |
["Offset of field: AmdsmiTopologyNearestT::count"] |
| 2766 |
[::std::mem::offset_of!(AmdsmiTopologyNearestT, count) - 0usize]; |
| 2767 |
["Offset of field: AmdsmiTopologyNearestT::processor_list"] |
| 2768 |
[::std::mem::offset_of!(AmdsmiTopologyNearestT, processor_list) - 8usize]; |
| 2769 |
["Offset of field: AmdsmiTopologyNearestT::reserved"] |
| 2770 |
[::std::mem::offset_of!(AmdsmiTopologyNearestT, reserved) - 2056usize]; |
| 2771 |
}; |
| 2772 |
#[repr(u32)] |
| 2773 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 2774 |
pub enum AmdsmiVirtualizationModeT { |
| 2775 |
AmdsmiVirtualizationModeUnknown = 0, |
| 2776 |
AmdsmiVirtualizationModeBaremetal = 1, |
| 2777 |
AmdsmiVirtualizationModeHost = 2, |
| 2778 |
AmdsmiVirtualizationModeGuest = 3, |
| 2779 |
AmdsmiVirtualizationModePassthrough = 4, |
| 2780 |
} |
| 2781 |
#[repr(u32)] |
| 2782 |
#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)] |
| 2783 |
pub enum AmdsmiAffinityScopeT { |
| 2784 |
AmdsmiAffinityScopeNode = 0, |
| 2785 |
AmdsmiAffinityScopeSocket = 1, |
| 2786 |
} |
| 2787 |
#[repr(C)] |
| 2788 |
#[derive(Debug, Copy, Clone)] |
| 2789 |
pub struct AmdsmiSockInfoT { |
| 2790 |
pub socket_id: u32, |
| 2791 |
pub cores_per_socket: u32, |
| 2792 |
} |
| 2793 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 2794 |
const _: () = { |
| 2795 |
["Size of AmdsmiSockInfoT"][::std::mem::size_of::<AmdsmiSockInfoT>() - 8usize]; |
| 2796 |
["Alignment of AmdsmiSockInfoT"][::std::mem::align_of::<AmdsmiSockInfoT>() - 4usize]; |
| 2797 |
["Offset of field: AmdsmiSockInfoT::socket_id"] |
| 2798 |
[::std::mem::offset_of!(AmdsmiSockInfoT, socket_id) - 0usize]; |
| 2799 |
["Offset of field: AmdsmiSockInfoT::cores_per_socket"] |
| 2800 |
[::std::mem::offset_of!(AmdsmiSockInfoT, cores_per_socket) - 4usize]; |
| 2801 |
}; |
| 2802 |
extern "C" { |
| 2803 |
pub fn amdsmi_init(init_flags: u64) -> AmdsmiStatusT; |
| 2804 |
} |
| 2805 |
extern "C" { |
| 2806 |
pub fn amdsmi_shut_down() -> AmdsmiStatusT; |
| 2807 |
} |
| 2808 |
extern "C" { |
| 2809 |
pub fn amdsmi_get_socket_handles( |
| 2810 |
socket_count: *mut u32, |
| 2811 |
socket_handles: *mut AmdsmiSocketHandle, |
| 2812 |
) -> AmdsmiStatusT; |
| 2813 |
} |
| 2814 |
extern "C" { |
| 2815 |
pub fn amdsmi_get_socket_info( |
| 2816 |
socket_handle: AmdsmiSocketHandle, |
| 2817 |
len: usize, |
| 2818 |
name: *mut ::std::os::raw::c_char, |
| 2819 |
) -> AmdsmiStatusT; |
| 2820 |
} |
| 2821 |
extern "C" { |
| 2822 |
pub fn amdsmi_get_processor_handles( |
| 2823 |
socket_handle: AmdsmiSocketHandle, |
| 2824 |
processor_count: *mut u32, |
| 2825 |
processor_handles: *mut AmdsmiProcessorHandle, |
| 2826 |
) -> AmdsmiStatusT; |
| 2827 |
} |
| 2828 |
extern "C" { |
| 2829 |
pub fn amdsmi_get_processor_type( |
| 2830 |
processor_handle: AmdsmiProcessorHandle, |
| 2831 |
processor_type: *mut ProcessorTypeT, |
| 2832 |
) -> AmdsmiStatusT; |
| 2833 |
} |
| 2834 |
extern "C" { |
| 2835 |
pub fn amdsmi_get_processor_handle_from_bdf( |
| 2836 |
bdf: AmdsmiBdfT, |
| 2837 |
processor_handle: *mut AmdsmiProcessorHandle, |
| 2838 |
) -> AmdsmiStatusT; |
| 2839 |
} |
| 2840 |
extern "C" { |
| 2841 |
pub fn amdsmi_get_gpu_device_bdf( |
| 2842 |
processor_handle: AmdsmiProcessorHandle, |
| 2843 |
bdf: *mut AmdsmiBdfT, |
| 2844 |
) -> AmdsmiStatusT; |
| 2845 |
} |
| 2846 |
extern "C" { |
| 2847 |
pub fn amdsmi_get_gpu_device_uuid( |
| 2848 |
processor_handle: AmdsmiProcessorHandle, |
| 2849 |
uuid_length: *mut ::std::os::raw::c_uint, |
| 2850 |
uuid: *mut ::std::os::raw::c_char, |
| 2851 |
) -> AmdsmiStatusT; |
| 2852 |
} |
| 2853 |
extern "C" { |
| 2854 |
pub fn amdsmi_get_gpu_enumeration_info( |
| 2855 |
processor_handle: AmdsmiProcessorHandle, |
| 2856 |
info: *mut AmdsmiEnumerationInfoT, |
| 2857 |
) -> AmdsmiStatusT; |
| 2858 |
} |
| 2859 |
extern "C" { |
| 2860 |
pub fn amdsmi_get_cpu_affinity_with_scope( |
| 2861 |
processor_handle: AmdsmiProcessorHandle, |
| 2862 |
cpu_set_size: u32, |
| 2863 |
cpu_set: *mut u64, |
| 2864 |
scope: AmdsmiAffinityScopeT, |
| 2865 |
) -> AmdsmiStatusT; |
| 2866 |
} |
| 2867 |
extern "C" { |
| 2868 |
pub fn amdsmi_get_gpu_virtualization_mode( |
| 2869 |
processor_handle: AmdsmiProcessorHandle, |
| 2870 |
mode: *mut AmdsmiVirtualizationModeT, |
| 2871 |
) -> AmdsmiStatusT; |
| 2872 |
} |
| 2873 |
extern "C" { |
| 2874 |
pub fn amdsmi_get_gpu_id( |
| 2875 |
processor_handle: AmdsmiProcessorHandle, |
| 2876 |
id: *mut u16, |
| 2877 |
) -> AmdsmiStatusT; |
| 2878 |
} |
| 2879 |
extern "C" { |
| 2880 |
pub fn amdsmi_get_gpu_revision( |
| 2881 |
processor_handle: AmdsmiProcessorHandle, |
| 2882 |
revision: *mut u16, |
| 2883 |
) -> AmdsmiStatusT; |
| 2884 |
} |
| 2885 |
extern "C" { |
| 2886 |
pub fn amdsmi_get_gpu_vendor_name( |
| 2887 |
processor_handle: AmdsmiProcessorHandle, |
| 2888 |
name: *mut ::std::os::raw::c_char, |
| 2889 |
len: usize, |
| 2890 |
) -> AmdsmiStatusT; |
| 2891 |
} |
| 2892 |
extern "C" { |
| 2893 |
pub fn amdsmi_get_gpu_vram_vendor( |
| 2894 |
processor_handle: AmdsmiProcessorHandle, |
| 2895 |
brand: *mut ::std::os::raw::c_char, |
| 2896 |
len: u32, |
| 2897 |
) -> AmdsmiStatusT; |
| 2898 |
} |
| 2899 |
extern "C" { |
| 2900 |
pub fn amdsmi_get_gpu_subsystem_id( |
| 2901 |
processor_handle: AmdsmiProcessorHandle, |
| 2902 |
id: *mut u16, |
| 2903 |
) -> AmdsmiStatusT; |
| 2904 |
} |
| 2905 |
extern "C" { |
| 2906 |
pub fn amdsmi_get_gpu_subsystem_name( |
| 2907 |
processor_handle: AmdsmiProcessorHandle, |
| 2908 |
name: *mut ::std::os::raw::c_char, |
| 2909 |
len: usize, |
| 2910 |
) -> AmdsmiStatusT; |
| 2911 |
} |
| 2912 |
extern "C" { |
| 2913 |
pub fn amdsmi_get_gpu_pci_bandwidth( |
| 2914 |
processor_handle: AmdsmiProcessorHandle, |
| 2915 |
bandwidth: *mut AmdsmiPcieBandwidthT, |
| 2916 |
) -> AmdsmiStatusT; |
| 2917 |
} |
| 2918 |
extern "C" { |
| 2919 |
pub fn amdsmi_get_gpu_bdf_id( |
| 2920 |
processor_handle: AmdsmiProcessorHandle, |
| 2921 |
bdfid: *mut u64, |
| 2922 |
) -> AmdsmiStatusT; |
| 2923 |
} |
| 2924 |
extern "C" { |
| 2925 |
pub fn amdsmi_get_gpu_topo_numa_affinity( |
| 2926 |
processor_handle: AmdsmiProcessorHandle, |
| 2927 |
numa_node: *mut i32, |
| 2928 |
) -> AmdsmiStatusT; |
| 2929 |
} |
| 2930 |
extern "C" { |
| 2931 |
pub fn amdsmi_get_gpu_pci_throughput( |
| 2932 |
processor_handle: AmdsmiProcessorHandle, |
| 2933 |
sent: *mut u64, |
| 2934 |
received: *mut u64, |
| 2935 |
max_pkt_sz: *mut u64, |
| 2936 |
) -> AmdsmiStatusT; |
| 2937 |
} |
| 2938 |
extern "C" { |
| 2939 |
pub fn amdsmi_get_gpu_pci_replay_counter( |
| 2940 |
processor_handle: AmdsmiProcessorHandle, |
| 2941 |
counter: *mut u64, |
| 2942 |
) -> AmdsmiStatusT; |
| 2943 |
} |
| 2944 |
extern "C" { |
| 2945 |
pub fn amdsmi_set_gpu_pci_bandwidth( |
| 2946 |
processor_handle: AmdsmiProcessorHandle, |
| 2947 |
bw_bitmask: u64, |
| 2948 |
) -> AmdsmiStatusT; |
| 2949 |
} |
| 2950 |
extern "C" { |
| 2951 |
pub fn amdsmi_get_energy_count( |
| 2952 |
processor_handle: AmdsmiProcessorHandle, |
| 2953 |
energy_accumulator: *mut u64, |
| 2954 |
counter_resolution: *mut f32, |
| 2955 |
timestamp: *mut u64, |
| 2956 |
) -> AmdsmiStatusT; |
| 2957 |
} |
| 2958 |
extern "C" { |
| 2959 |
pub fn amdsmi_set_power_cap( |
| 2960 |
processor_handle: AmdsmiProcessorHandle, |
| 2961 |
sensor_ind: u32, |
| 2962 |
cap: u64, |
| 2963 |
) -> AmdsmiStatusT; |
| 2964 |
} |
| 2965 |
extern "C" { |
| 2966 |
pub fn amdsmi_set_gpu_power_profile( |
| 2967 |
processor_handle: AmdsmiProcessorHandle, |
| 2968 |
reserved: u32, |
| 2969 |
profile: AmdsmiPowerProfilePresetMasksT, |
| 2970 |
) -> AmdsmiStatusT; |
| 2971 |
} |
| 2972 |
extern "C" { |
| 2973 |
pub fn amdsmi_get_cpu_socket_power( |
| 2974 |
processor_handle: AmdsmiProcessorHandle, |
| 2975 |
ppower: *mut u32, |
| 2976 |
) -> AmdsmiStatusT; |
| 2977 |
} |
| 2978 |
extern "C" { |
| 2979 |
pub fn amdsmi_get_cpu_socket_power_cap( |
| 2980 |
processor_handle: AmdsmiProcessorHandle, |
| 2981 |
pcap: *mut u32, |
| 2982 |
) -> AmdsmiStatusT; |
| 2983 |
} |
| 2984 |
extern "C" { |
| 2985 |
pub fn amdsmi_get_cpu_socket_power_cap_max( |
| 2986 |
processor_handle: AmdsmiProcessorHandle, |
| 2987 |
pmax: *mut u32, |
| 2988 |
) -> AmdsmiStatusT; |
| 2989 |
} |
| 2990 |
extern "C" { |
| 2991 |
pub fn amdsmi_get_cpu_pwr_svi_telemetry_all_rails( |
| 2992 |
processor_handle: AmdsmiProcessorHandle, |
| 2993 |
power: *mut u32, |
| 2994 |
) -> AmdsmiStatusT; |
| 2995 |
} |
| 2996 |
extern "C" { |
| 2997 |
pub fn amdsmi_set_cpu_socket_power_cap( |
| 2998 |
processor_handle: AmdsmiProcessorHandle, |
| 2999 |
pcap: u32, |
| 3000 |
) -> AmdsmiStatusT; |
| 3001 |
} |
| 3002 |
extern "C" { |
| 3003 |
pub fn amdsmi_set_cpu_pwr_efficiency_mode( |
| 3004 |
processor_handle: AmdsmiProcessorHandle, |
| 3005 |
mode: u8, |
| 3006 |
) -> AmdsmiStatusT; |
| 3007 |
} |
| 3008 |
extern "C" { |
| 3009 |
pub fn amdsmi_get_gpu_memory_total( |
| 3010 |
processor_handle: AmdsmiProcessorHandle, |
| 3011 |
mem_type: AmdsmiMemoryTypeT, |
| 3012 |
total: *mut u64, |
| 3013 |
) -> AmdsmiStatusT; |
| 3014 |
} |
| 3015 |
extern "C" { |
| 3016 |
pub fn amdsmi_get_gpu_memory_usage( |
| 3017 |
processor_handle: AmdsmiProcessorHandle, |
| 3018 |
mem_type: AmdsmiMemoryTypeT, |
| 3019 |
used: *mut u64, |
| 3020 |
) -> AmdsmiStatusT; |
| 3021 |
} |
| 3022 |
extern "C" { |
| 3023 |
pub fn amdsmi_get_gpu_bad_page_info( |
| 3024 |
processor_handle: AmdsmiProcessorHandle, |
| 3025 |
num_pages: *mut u32, |
| 3026 |
info: *mut AmdsmiRetiredPageRecordT, |
| 3027 |
) -> AmdsmiStatusT; |
| 3028 |
} |
| 3029 |
extern "C" { |
| 3030 |
pub fn amdsmi_get_gpu_bad_page_threshold( |
| 3031 |
processor_handle: AmdsmiProcessorHandle, |
| 3032 |
threshold: *mut u32, |
| 3033 |
) -> AmdsmiStatusT; |
| 3034 |
} |
| 3035 |
extern "C" { |
| 3036 |
pub fn amdsmi_gpu_validate_ras_eeprom(processor_handle: AmdsmiProcessorHandle) |
| 3037 |
-> AmdsmiStatusT; |
| 3038 |
} |
| 3039 |
extern "C" { |
| 3040 |
pub fn amdsmi_get_gpu_ras_feature_info( |
| 3041 |
processor_handle: AmdsmiProcessorHandle, |
| 3042 |
ras_feature: *mut AmdsmiRasFeatureT, |
| 3043 |
) -> AmdsmiStatusT; |
| 3044 |
} |
| 3045 |
extern "C" { |
| 3046 |
pub fn amdsmi_get_gpu_ras_block_features_enabled( |
| 3047 |
processor_handle: AmdsmiProcessorHandle, |
| 3048 |
block: AmdsmiGpuBlockT, |
| 3049 |
state: *mut AmdsmiRasErrStateT, |
| 3050 |
) -> AmdsmiStatusT; |
| 3051 |
} |
| 3052 |
extern "C" { |
| 3053 |
pub fn amdsmi_get_gpu_memory_reserved_pages( |
| 3054 |
processor_handle: AmdsmiProcessorHandle, |
| 3055 |
num_pages: *mut u32, |
| 3056 |
records: *mut AmdsmiRetiredPageRecordT, |
| 3057 |
) -> AmdsmiStatusT; |
| 3058 |
} |
| 3059 |
extern "C" { |
| 3060 |
pub fn amdsmi_get_gpu_fan_rpms( |
| 3061 |
processor_handle: AmdsmiProcessorHandle, |
| 3062 |
sensor_ind: u32, |
| 3063 |
speed: *mut i64, |
| 3064 |
) -> AmdsmiStatusT; |
| 3065 |
} |
| 3066 |
extern "C" { |
| 3067 |
pub fn amdsmi_get_gpu_fan_speed( |
| 3068 |
processor_handle: AmdsmiProcessorHandle, |
| 3069 |
sensor_ind: u32, |
| 3070 |
speed: *mut i64, |
| 3071 |
) -> AmdsmiStatusT; |
| 3072 |
} |
| 3073 |
extern "C" { |
| 3074 |
pub fn amdsmi_get_gpu_fan_speed_max( |
| 3075 |
processor_handle: AmdsmiProcessorHandle, |
| 3076 |
sensor_ind: u32, |
| 3077 |
max_speed: *mut u64, |
| 3078 |
) -> AmdsmiStatusT; |
| 3079 |
} |
| 3080 |
extern "C" { |
| 3081 |
pub fn amdsmi_get_temp_metric( |
| 3082 |
processor_handle: AmdsmiProcessorHandle, |
| 3083 |
sensor_type: AmdsmiTemperatureTypeT, |
| 3084 |
metric: AmdsmiTemperatureMetricT, |
| 3085 |
temperature: *mut i64, |
| 3086 |
) -> AmdsmiStatusT; |
| 3087 |
} |
| 3088 |
extern "C" { |
| 3089 |
pub fn amdsmi_get_gpu_cache_info( |
| 3090 |
processor_handle: AmdsmiProcessorHandle, |
| 3091 |
info: *mut AmdsmiGpuCacheInfoT, |
| 3092 |
) -> AmdsmiStatusT; |
| 3093 |
} |
| 3094 |
extern "C" { |
| 3095 |
pub fn amdsmi_get_gpu_volt_metric( |
| 3096 |
processor_handle: AmdsmiProcessorHandle, |
| 3097 |
sensor_type: AmdsmiVoltageTypeT, |
| 3098 |
metric: AmdsmiVoltageMetricT, |
| 3099 |
voltage: *mut i64, |
| 3100 |
) -> AmdsmiStatusT; |
| 3101 |
} |
| 3102 |
extern "C" { |
| 3103 |
pub fn amdsmi_reset_gpu_fan( |
| 3104 |
processor_handle: AmdsmiProcessorHandle, |
| 3105 |
sensor_ind: u32, |
| 3106 |
) -> AmdsmiStatusT; |
| 3107 |
} |
| 3108 |
extern "C" { |
| 3109 |
pub fn amdsmi_set_gpu_fan_speed( |
| 3110 |
processor_handle: AmdsmiProcessorHandle, |
| 3111 |
sensor_ind: u32, |
| 3112 |
speed: u64, |
| 3113 |
) -> AmdsmiStatusT; |
| 3114 |
} |
| 3115 |
extern "C" { |
| 3116 |
pub fn amdsmi_get_gpu_busy_percent( |
| 3117 |
processor_handle: AmdsmiProcessorHandle, |
| 3118 |
gpu_busy_percent: *mut u32, |
| 3119 |
) -> AmdsmiStatusT; |
| 3120 |
} |
| 3121 |
extern "C" { |
| 3122 |
pub fn amdsmi_get_utilization_count( |
| 3123 |
processor_handle: AmdsmiProcessorHandle, |
| 3124 |
utilization_counters: *mut AmdsmiUtilizationCounterT, |
| 3125 |
count: u32, |
| 3126 |
timestamp: *mut u64, |
| 3127 |
) -> AmdsmiStatusT; |
| 3128 |
} |
| 3129 |
extern "C" { |
| 3130 |
pub fn amdsmi_get_gpu_perf_level( |
| 3131 |
processor_handle: AmdsmiProcessorHandle, |
| 3132 |
perf: *mut AmdsmiDevPerfLevelT, |
| 3133 |
) -> AmdsmiStatusT; |
| 3134 |
} |
| 3135 |
extern "C" { |
| 3136 |
pub fn amdsmi_set_gpu_perf_determinism_mode( |
| 3137 |
processor_handle: AmdsmiProcessorHandle, |
| 3138 |
clkvalue: u64, |
| 3139 |
) -> AmdsmiStatusT; |
| 3140 |
} |
| 3141 |
extern "C" { |
| 3142 |
pub fn amdsmi_get_gpu_overdrive_level( |
| 3143 |
processor_handle: AmdsmiProcessorHandle, |
| 3144 |
od: *mut u32, |
| 3145 |
) -> AmdsmiStatusT; |
| 3146 |
} |
| 3147 |
extern "C" { |
| 3148 |
pub fn amdsmi_get_gpu_mem_overdrive_level( |
| 3149 |
processor_handle: AmdsmiProcessorHandle, |
| 3150 |
od: *mut u32, |
| 3151 |
) -> AmdsmiStatusT; |
| 3152 |
} |
| 3153 |
extern "C" { |
| 3154 |
pub fn amdsmi_get_clk_freq( |
| 3155 |
processor_handle: AmdsmiProcessorHandle, |
| 3156 |
clk_type: AmdsmiClkTypeT, |
| 3157 |
f: *mut AmdsmiFrequenciesT, |
| 3158 |
) -> AmdsmiStatusT; |
| 3159 |
} |
| 3160 |
extern "C" { |
| 3161 |
pub fn amdsmi_reset_gpu(processor_handle: AmdsmiProcessorHandle) -> AmdsmiStatusT; |
| 3162 |
} |
| 3163 |
extern "C" { |
| 3164 |
pub fn amdsmi_get_gpu_od_volt_info( |
| 3165 |
processor_handle: AmdsmiProcessorHandle, |
| 3166 |
odv: *mut AmdsmiOdVoltFreqDataT, |
| 3167 |
) -> AmdsmiStatusT; |
| 3168 |
} |
| 3169 |
extern "C" { |
| 3170 |
pub fn amdsmi_get_gpu_metrics_header_info( |
| 3171 |
processor_handle: AmdsmiProcessorHandle, |
| 3172 |
header_value: *mut AmdMetricsTableHeaderT, |
| 3173 |
) -> AmdsmiStatusT; |
| 3174 |
} |
| 3175 |
extern "C" { |
| 3176 |
pub fn amdsmi_get_gpu_metrics_info( |
| 3177 |
processor_handle: AmdsmiProcessorHandle, |
| 3178 |
pgpu_metrics: *mut AmdsmiGpuMetricsT, |
| 3179 |
) -> AmdsmiStatusT; |
| 3180 |
} |
| 3181 |
extern "C" { |
| 3182 |
pub fn amdsmi_get_gpu_pm_metrics_info( |
| 3183 |
processor_handle: AmdsmiProcessorHandle, |
| 3184 |
pm_metrics: *mut *mut AmdsmiNameValueT, |
| 3185 |
num_of_metrics: *mut u32, |
| 3186 |
) -> AmdsmiStatusT; |
| 3187 |
} |
| 3188 |
extern "C" { |
| 3189 |
pub fn amdsmi_get_gpu_reg_table_info( |
| 3190 |
processor_handle: AmdsmiProcessorHandle, |
| 3191 |
reg_type: AmdsmiRegTypeT, |
| 3192 |
reg_metrics: *mut *mut AmdsmiNameValueT, |
| 3193 |
num_of_metrics: *mut u32, |
| 3194 |
) -> AmdsmiStatusT; |
| 3195 |
} |
| 3196 |
extern "C" { |
| 3197 |
pub fn amdsmi_set_gpu_clk_range( |
| 3198 |
processor_handle: AmdsmiProcessorHandle, |
| 3199 |
minclkvalue: u64, |
| 3200 |
maxclkvalue: u64, |
| 3201 |
clkType: AmdsmiClkTypeT, |
| 3202 |
) -> AmdsmiStatusT; |
| 3203 |
} |
| 3204 |
extern "C" { |
| 3205 |
pub fn amdsmi_set_gpu_clk_limit( |
| 3206 |
processor_handle: AmdsmiProcessorHandle, |
| 3207 |
clk_type: AmdsmiClkTypeT, |
| 3208 |
limit_type: AmdsmiClkLimitTypeT, |
| 3209 |
clk_value: u64, |
| 3210 |
) -> AmdsmiStatusT; |
| 3211 |
} |
| 3212 |
extern "C" { |
| 3213 |
pub fn amdsmi_set_gpu_od_clk_info( |
| 3214 |
processor_handle: AmdsmiProcessorHandle, |
| 3215 |
level: AmdsmiFreqIndT, |
| 3216 |
clkvalue: u64, |
| 3217 |
clkType: AmdsmiClkTypeT, |
| 3218 |
) -> AmdsmiStatusT; |
| 3219 |
} |
| 3220 |
extern "C" { |
| 3221 |
pub fn amdsmi_set_gpu_od_volt_info( |
| 3222 |
processor_handle: AmdsmiProcessorHandle, |
| 3223 |
vpoint: u32, |
| 3224 |
clkvalue: u64, |
| 3225 |
voltvalue: u64, |
| 3226 |
) -> AmdsmiStatusT; |
| 3227 |
} |
| 3228 |
extern "C" { |
| 3229 |
pub fn amdsmi_get_gpu_od_volt_curve_regions( |
| 3230 |
processor_handle: AmdsmiProcessorHandle, |
| 3231 |
num_regions: *mut u32, |
| 3232 |
buffer: *mut AmdsmiFreqVoltRegionT, |
| 3233 |
) -> AmdsmiStatusT; |
| 3234 |
} |
| 3235 |
extern "C" { |
| 3236 |
pub fn amdsmi_get_gpu_power_profile_presets( |
| 3237 |
processor_handle: AmdsmiProcessorHandle, |
| 3238 |
sensor_ind: u32, |
| 3239 |
status: *mut AmdsmiPowerProfileStatusT, |
| 3240 |
) -> AmdsmiStatusT; |
| 3241 |
} |
| 3242 |
extern "C" { |
| 3243 |
pub fn amdsmi_set_gpu_perf_level( |
| 3244 |
processor_handle: AmdsmiProcessorHandle, |
| 3245 |
perf_lvl: AmdsmiDevPerfLevelT, |
| 3246 |
) -> AmdsmiStatusT; |
| 3247 |
} |
| 3248 |
extern "C" { |
| 3249 |
pub fn amdsmi_set_gpu_overdrive_level( |
| 3250 |
processor_handle: AmdsmiProcessorHandle, |
| 3251 |
od: u32, |
| 3252 |
) -> AmdsmiStatusT; |
| 3253 |
} |
| 3254 |
extern "C" { |
| 3255 |
pub fn amdsmi_set_clk_freq( |
| 3256 |
processor_handle: AmdsmiProcessorHandle, |
| 3257 |
clk_type: AmdsmiClkTypeT, |
| 3258 |
freq_bitmask: u64, |
| 3259 |
) -> AmdsmiStatusT; |
| 3260 |
} |
| 3261 |
extern "C" { |
| 3262 |
pub fn amdsmi_get_soc_pstate( |
| 3263 |
processor_handle: AmdsmiProcessorHandle, |
| 3264 |
policy: *mut AmdsmiDpmPolicyT, |
| 3265 |
) -> AmdsmiStatusT; |
| 3266 |
} |
| 3267 |
extern "C" { |
| 3268 |
pub fn amdsmi_set_soc_pstate( |
| 3269 |
processor_handle: AmdsmiProcessorHandle, |
| 3270 |
policy_id: u32, |
| 3271 |
) -> AmdsmiStatusT; |
| 3272 |
} |
| 3273 |
extern "C" { |
| 3274 |
pub fn amdsmi_get_xgmi_plpd( |
| 3275 |
processor_handle: AmdsmiProcessorHandle, |
| 3276 |
xgmi_plpd: *mut AmdsmiDpmPolicyT, |
| 3277 |
) -> AmdsmiStatusT; |
| 3278 |
} |
| 3279 |
extern "C" { |
| 3280 |
pub fn amdsmi_set_xgmi_plpd( |
| 3281 |
processor_handle: AmdsmiProcessorHandle, |
| 3282 |
policy_id: u32, |
| 3283 |
) -> AmdsmiStatusT; |
| 3284 |
} |
| 3285 |
extern "C" { |
| 3286 |
pub fn amdsmi_get_gpu_process_isolation( |
| 3287 |
processor_handle: AmdsmiProcessorHandle, |
| 3288 |
pisolate: *mut u32, |
| 3289 |
) -> AmdsmiStatusT; |
| 3290 |
} |
| 3291 |
extern "C" { |
| 3292 |
pub fn amdsmi_set_gpu_process_isolation( |
| 3293 |
processor_handle: AmdsmiProcessorHandle, |
| 3294 |
pisolate: u32, |
| 3295 |
) -> AmdsmiStatusT; |
| 3296 |
} |
| 3297 |
extern "C" { |
| 3298 |
pub fn amdsmi_clean_gpu_local_data(processor_handle: AmdsmiProcessorHandle) -> AmdsmiStatusT; |
| 3299 |
} |
| 3300 |
extern "C" { |
| 3301 |
pub fn amdsmi_get_lib_version(version: *mut AmdsmiVersionT) -> AmdsmiStatusT; |
| 3302 |
} |
| 3303 |
extern "C" { |
| 3304 |
pub fn amdsmi_get_gpu_ecc_count( |
| 3305 |
processor_handle: AmdsmiProcessorHandle, |
| 3306 |
block: AmdsmiGpuBlockT, |
| 3307 |
ec: *mut AmdsmiErrorCountT, |
| 3308 |
) -> AmdsmiStatusT; |
| 3309 |
} |
| 3310 |
extern "C" { |
| 3311 |
pub fn amdsmi_get_gpu_ecc_enabled( |
| 3312 |
processor_handle: AmdsmiProcessorHandle, |
| 3313 |
enabled_blocks: *mut u64, |
| 3314 |
) -> AmdsmiStatusT; |
| 3315 |
} |
| 3316 |
extern "C" { |
| 3317 |
pub fn amdsmi_get_gpu_total_ecc_count( |
| 3318 |
processor_handle: AmdsmiProcessorHandle, |
| 3319 |
ec: *mut AmdsmiErrorCountT, |
| 3320 |
) -> AmdsmiStatusT; |
| 3321 |
} |
| 3322 |
#[repr(C)] |
| 3323 |
#[derive(Debug, Copy, Clone)] |
| 3324 |
pub struct AmdsmiCperGuidT { |
| 3325 |
pub b: [::std::os::raw::c_uchar; 16usize], |
| 3326 |
} |
| 3327 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 3328 |
const _: () = { |
| 3329 |
["Size of AmdsmiCperGuidT"][::std::mem::size_of::<AmdsmiCperGuidT>() - 16usize]; |
| 3330 |
["Alignment of AmdsmiCperGuidT"][::std::mem::align_of::<AmdsmiCperGuidT>() - 1usize]; |
| 3331 |
["Offset of field: AmdsmiCperGuidT::b"][::std::mem::offset_of!(AmdsmiCperGuidT, b) - 0usize]; |
| 3332 |
}; |
| 3333 |
#[repr(C)] |
| 3334 |
#[derive(Debug, Copy, Clone)] |
| 3335 |
pub struct AmdsmiCperTimestampT { |
| 3336 |
pub seconds: u8, |
| 3337 |
pub minutes: u8, |
| 3338 |
pub hours: u8, |
| 3339 |
pub flag: u8, |
| 3340 |
pub day: u8, |
| 3341 |
pub month: u8, |
| 3342 |
pub year: u8, |
| 3343 |
pub century: u8, |
| 3344 |
} |
| 3345 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 3346 |
const _: () = { |
| 3347 |
["Size of AmdsmiCperTimestampT"][::std::mem::size_of::<AmdsmiCperTimestampT>() - 8usize]; |
| 3348 |
["Alignment of AmdsmiCperTimestampT"][::std::mem::align_of::<AmdsmiCperTimestampT>() - 1usize]; |
| 3349 |
["Offset of field: AmdsmiCperTimestampT::seconds"] |
| 3350 |
[::std::mem::offset_of!(AmdsmiCperTimestampT, seconds) - 0usize]; |
| 3351 |
["Offset of field: AmdsmiCperTimestampT::minutes"] |
| 3352 |
[::std::mem::offset_of!(AmdsmiCperTimestampT, minutes) - 1usize]; |
| 3353 |
["Offset of field: AmdsmiCperTimestampT::hours"] |
| 3354 |
[::std::mem::offset_of!(AmdsmiCperTimestampT, hours) - 2usize]; |
| 3355 |
["Offset of field: AmdsmiCperTimestampT::flag"] |
| 3356 |
[::std::mem::offset_of!(AmdsmiCperTimestampT, flag) - 3usize]; |
| 3357 |
["Offset of field: AmdsmiCperTimestampT::day"] |
| 3358 |
[::std::mem::offset_of!(AmdsmiCperTimestampT, day) - 4usize]; |
| 3359 |
["Offset of field: AmdsmiCperTimestampT::month"] |
| 3360 |
[::std::mem::offset_of!(AmdsmiCperTimestampT, month) - 5usize]; |
| 3361 |
["Offset of field: AmdsmiCperTimestampT::year"] |
| 3362 |
[::std::mem::offset_of!(AmdsmiCperTimestampT, year) - 6usize]; |
| 3363 |
["Offset of field: AmdsmiCperTimestampT::century"] |
| 3364 |
[::std::mem::offset_of!(AmdsmiCperTimestampT, century) - 7usize]; |
| 3365 |
}; |
| 3366 |
#[repr(C, packed)] |
| 3367 |
#[derive(Copy, Clone)] |
| 3368 |
pub union AmdsmiCperValidBitsT { |
| 3369 |
pub valid_bits: AmdsmiCperValidBitsTValidBits, |
| 3370 |
pub valid_mask: u32, |
| 3371 |
} |
| 3372 |
#[repr(C)] |
| 3373 |
#[derive(Debug, Copy, Clone)] |
| 3374 |
pub struct AmdsmiCperValidBitsTValidBits { |
| 3375 |
pub _bitfield_align_1: [u8; 0], |
| 3376 |
pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, |
| 3377 |
} |
| 3378 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 3379 |
const _: () = { |
| 3380 |
["Size of AmdsmiCperValidBitsTValidBits"] |
| 3381 |
[::std::mem::size_of::<AmdsmiCperValidBitsTValidBits>() - 4usize]; |
| 3382 |
["Alignment of AmdsmiCperValidBitsTValidBits"] |
| 3383 |
[::std::mem::align_of::<AmdsmiCperValidBitsTValidBits>() - 1usize]; |
| 3384 |
}; |
| 3385 |
impl AmdsmiCperValidBitsTValidBits { |
| 3386 |
#[inline] |
| 3387 |
pub fn platform_id(&self) -> u32 { |
| 3388 |
unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u32) } |
| 3389 |
} |
| 3390 |
#[inline] |
| 3391 |
pub fn set_platform_id(&mut self, val: u32) { |
| 3392 |
unsafe { |
| 3393 |
let val: u32 = ::std::mem::transmute(val); |
| 3394 |
self._bitfield_1.set(0usize, 1u8, val as u64) |
| 3395 |
} |
| 3396 |
} |
| 3397 |
#[inline] |
| 3398 |
pub fn timestamp(&self) -> u32 { |
| 3399 |
unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u32) } |
| 3400 |
} |
| 3401 |
#[inline] |
| 3402 |
pub fn set_timestamp(&mut self, val: u32) { |
| 3403 |
unsafe { |
| 3404 |
let val: u32 = ::std::mem::transmute(val); |
| 3405 |
self._bitfield_1.set(1usize, 1u8, val as u64) |
| 3406 |
} |
| 3407 |
} |
| 3408 |
#[inline] |
| 3409 |
pub fn partition_id(&self) -> u32 { |
| 3410 |
unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 1u8) as u32) } |
| 3411 |
} |
| 3412 |
#[inline] |
| 3413 |
pub fn set_partition_id(&mut self, val: u32) { |
| 3414 |
unsafe { |
| 3415 |
let val: u32 = ::std::mem::transmute(val); |
| 3416 |
self._bitfield_1.set(2usize, 1u8, val as u64) |
| 3417 |
} |
| 3418 |
} |
| 3419 |
#[inline] |
| 3420 |
pub fn reserved(&self) -> u32 { |
| 3421 |
unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 29u8) as u32) } |
| 3422 |
} |
| 3423 |
#[inline] |
| 3424 |
pub fn set_reserved(&mut self, val: u32) { |
| 3425 |
unsafe { |
| 3426 |
let val: u32 = ::std::mem::transmute(val); |
| 3427 |
self._bitfield_1.set(3usize, 29u8, val as u64) |
| 3428 |
} |
| 3429 |
} |
| 3430 |
#[inline] |
| 3431 |
pub fn new_bitfield_1( |
| 3432 |
platform_id: u32, |
| 3433 |
timestamp: u32, |
| 3434 |
partition_id: u32, |
| 3435 |
reserved: u32, |
| 3436 |
) -> __BindgenBitfieldUnit<[u8; 4usize]> { |
| 3437 |
let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default(); |
| 3438 |
__bindgen_bitfield_unit.set(0usize, 1u8, { |
| 3439 |
let platform_id: u32 = unsafe { ::std::mem::transmute(platform_id) }; |
| 3440 |
platform_id as u64 |
| 3441 |
}); |
| 3442 |
__bindgen_bitfield_unit.set(1usize, 1u8, { |
| 3443 |
let timestamp: u32 = unsafe { ::std::mem::transmute(timestamp) }; |
| 3444 |
timestamp as u64 |
| 3445 |
}); |
| 3446 |
__bindgen_bitfield_unit.set(2usize, 1u8, { |
| 3447 |
let partition_id: u32 = unsafe { ::std::mem::transmute(partition_id) }; |
| 3448 |
partition_id as u64 |
| 3449 |
}); |
| 3450 |
__bindgen_bitfield_unit.set(3usize, 29u8, { |
| 3451 |
let reserved: u32 = unsafe { ::std::mem::transmute(reserved) }; |
| 3452 |
reserved as u64 |
| 3453 |
}); |
| 3454 |
__bindgen_bitfield_unit |
| 3455 |
} |
| 3456 |
} |
| 3457 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 3458 |
const _: () = { |
| 3459 |
["Size of AmdsmiCperValidBitsT"][::std::mem::size_of::<AmdsmiCperValidBitsT>() - 4usize]; |
| 3460 |
["Alignment of AmdsmiCperValidBitsT"][::std::mem::align_of::<AmdsmiCperValidBitsT>() - 1usize]; |
| 3461 |
["Offset of field: AmdsmiCperValidBitsT::valid_bits"] |
| 3462 |
[::std::mem::offset_of!(AmdsmiCperValidBitsT, valid_bits) - 0usize]; |
| 3463 |
["Offset of field: AmdsmiCperValidBitsT::valid_mask"] |
| 3464 |
[::std::mem::offset_of!(AmdsmiCperValidBitsT, valid_mask) - 0usize]; |
| 3465 |
}; |
| 3466 |
#[repr(C, packed)] |
| 3467 |
#[derive(Copy, Clone)] |
| 3468 |
pub struct AmdsmiCperHdrT { |
| 3469 |
pub signature: [::std::os::raw::c_char; 4usize], |
| 3470 |
pub revision: u16, |
| 3471 |
pub signature_end: u32, |
| 3472 |
pub sec_cnt: u16, |
| 3473 |
pub error_severity: AmdsmiCperSevT, |
| 3474 |
pub cper_valid_bits: AmdsmiCperValidBitsT, |
| 3475 |
pub record_length: u32, |
| 3476 |
pub timestamp: AmdsmiCperTimestampT, |
| 3477 |
pub platform_id: [::std::os::raw::c_char; 16usize], |
| 3478 |
pub partition_id: AmdsmiCperGuidT, |
| 3479 |
pub creator_id: [::std::os::raw::c_char; 16usize], |
| 3480 |
pub notify_type: AmdsmiCperGuidT, |
| 3481 |
pub record_id: [::std::os::raw::c_char; 8usize], |
| 3482 |
pub flags: u32, |
| 3483 |
pub persistence_info: u64, |
| 3484 |
pub reserved: [u8; 12usize], |
| 3485 |
} |
| 3486 |
#[allow(clippy::unnecessary_operation, clippy::identity_op)] |
| 3487 |
const _: () = { |
| 3488 |
["Size of AmdsmiCperHdrT"][::std::mem::size_of::<AmdsmiCperHdrT>() - 128usize]; |
| 3489 |
["Alignment of AmdsmiCperHdrT"][::std::mem::align_of::<AmdsmiCperHdrT>() - 1usize]; |
| 3490 |
["Offset of field: AmdsmiCperHdrT::signature"] |
| 3491 |
[::std::mem::offset_of!(AmdsmiCperHdrT, signature) - 0usize]; |
| 3492 |
["Offset of field: AmdsmiCperHdrT::revision"] |
| 3493 |
[::std::mem::offset_of!(AmdsmiCperHdrT, revision) - 4usize]; |
| 3494 |
["Offset of field: AmdsmiCperHdrT::signature_end"] |
| 3495 |
[::std::mem::offset_of!(AmdsmiCperHdrT, signature_end) - 6usize]; |
| 3496 |
["Offset of field: AmdsmiCperHdrT::sec_cnt"] |
| 3497 |
[::std::mem::offset_of!(AmdsmiCperHdrT, sec_cnt) - 10usize]; |
| 3498 |
["Offset of field: AmdsmiCperHdrT::error_severity"] |
| 3499 |
[::std::mem::offset_of!(AmdsmiCperHdrT, error_severity) - 12usize]; |
| 3500 |
["Offset of field: AmdsmiCperHdrT::cper_valid_bits"] |
| 3501 |
[::std::mem::offset_of!(AmdsmiCperHdrT, cper_valid_bits) - 16usize]; |
| 3502 |
["Offset of field: AmdsmiCperHdrT::record_length"] |
| 3503 |
[::std::mem::offset_of!(AmdsmiCperHdrT, record_length) - 20usize]; |
| 3504 |
["Offset of field: AmdsmiCperHdrT::timestamp"] |
| 3505 |
[::std::mem::offset_of!(AmdsmiCperHdrT, timestamp) - 24usize]; |
| 3506 |
["Offset of field: AmdsmiCperHdrT::platform_id"] |
| 3507 |
[::std::mem::offset_of!(AmdsmiCperHdrT, platform_id) - 32usize]; |
| 3508 |
["Offset of field: AmdsmiCperHdrT::partition_id"] |
| 3509 |
[::std::mem::offset_of!(AmdsmiCperHdrT, partition_id) - 48usize]; |
| 3510 |
["Offset of field: AmdsmiCperHdrT::creator_id"] |
| 3511 |
[::std::mem::offset_of!(AmdsmiCperHdrT, creator_id) - 64usize]; |
| 3512 |
["Offset of field: AmdsmiCperHdrT::notify_type"] |
| 3513 |
[::std::mem::offset_of!(AmdsmiCperHdrT, notify_type) - 80usize]; |
| 3514 |
["Offset of field: AmdsmiCperHdrT::record_id"] |
| 3515 |
[::std::mem::offset_of!(AmdsmiCperHdrT, record_id) - 96usize]; |
| 3516 |
["Offset of field: AmdsmiCperHdrT::flags"] |
| 3517 |
[::std::mem::offset_of!(AmdsmiCperHdrT, flags) - 104usize]; |
| 3518 |
["Offset of field: AmdsmiCperHdrT::persistence_info"] |
| 3519 |
[::std::mem::offset_of!(AmdsmiCperHdrT, persistence_info) - 108usize]; |
| 3520 |
["Offset of field: AmdsmiCperHdrT::reserved"] |
| 3521 |
[::std::mem::offset_of!(AmdsmiCperHdrT, reserved) - 116usize]; |
| 3522 |
}; |
| 3523 |
extern "C" { |
| 3524 |
pub fn amdsmi_get_gpu_cper_entries( |
| 3525 |
processor_handle: AmdsmiProcessorHandle, |
| 3526 |
severity_mask: u32, |
| 3527 |
cper_data: *mut ::std::os::raw::c_char, |
| 3528 |
buf_size: *mut u64, |
| 3529 |
cper_hdrs: *mut *mut AmdsmiCperHdrT, |
| 3530 |
entry_count: *mut u64, |
| 3531 |
cursor: *mut u64, |
| 3532 |
) -> AmdsmiStatusT; |
| 3533 |
} |
| 3534 |
extern "C" { |
| 3535 |
pub fn amdsmi_get_afids_from_cper( |
| 3536 |
cper_buffer: *mut ::std::os::raw::c_char, |
| 3537 |
buf_size: u32, |
| 3538 |
afids: *mut u64, |
| 3539 |
num_afids: *mut u32, |
| 3540 |
) -> AmdsmiStatusT; |
| 3541 |
} |
| 3542 |
extern "C" { |
| 3543 |
pub fn amdsmi_get_gpu_ecc_status( |
| 3544 |
processor_handle: AmdsmiProcessorHandle, |
| 3545 |
block: AmdsmiGpuBlockT, |
| 3546 |
state: *mut AmdsmiRasErrStateT, |
| 3547 |
) -> AmdsmiStatusT; |
| 3548 |
} |
| 3549 |
extern "C" { |
| 3550 |
pub fn amdsmi_status_code_to_string( |
| 3551 |
status: AmdsmiStatusT, |
| 3552 |
status_string: *mut *const ::std::os::raw::c_char, |
| 3553 |
) -> AmdsmiStatusT; |
| 3554 |
} |
| 3555 |
extern "C" { |
| 3556 |
pub fn amdsmi_gpu_counter_group_supported( |
| 3557 |
processor_handle: AmdsmiProcessorHandle, |
| 3558 |
group: AmdsmiEventGroupT, |
| 3559 |
) -> AmdsmiStatusT; |
| 3560 |
} |
| 3561 |
extern "C" { |
| 3562 |
pub fn amdsmi_gpu_create_counter( |
| 3563 |
processor_handle: AmdsmiProcessorHandle, |
| 3564 |
type_: AmdsmiEventTypeT, |
| 3565 |
evnt_handle: *mut AmdsmiEventHandleT, |
| 3566 |
) -> AmdsmiStatusT; |
| 3567 |
} |
| 3568 |
extern "C" { |
| 3569 |
pub fn amdsmi_gpu_destroy_counter(evnt_handle: AmdsmiEventHandleT) -> AmdsmiStatusT; |
| 3570 |
} |
| 3571 |
extern "C" { |
| 3572 |
pub fn amdsmi_gpu_control_counter( |
| 3573 |
evt_handle: AmdsmiEventHandleT, |
| 3574 |
cmd: AmdsmiCounterCommandT, |
| 3575 |
cmd_args: *mut ::std::os::raw::c_void, |
| 3576 |
) -> AmdsmiStatusT; |
| 3577 |
} |
| 3578 |
extern "C" { |
| 3579 |
pub fn amdsmi_gpu_read_counter( |
| 3580 |
evt_handle: AmdsmiEventHandleT, |
| 3581 |
value: *mut AmdsmiCounterValueT, |
| 3582 |
) -> AmdsmiStatusT; |
| 3583 |
} |
| 3584 |
extern "C" { |
| 3585 |
pub fn amdsmi_get_gpu_available_counters( |
| 3586 |
processor_handle: AmdsmiProcessorHandle, |
| 3587 |
grp: AmdsmiEventGroupT, |
| 3588 |
available: *mut u32, |
| 3589 |
) -> AmdsmiStatusT; |
| 3590 |
} |
| 3591 |
extern "C" { |
| 3592 |
pub fn amdsmi_get_gpu_compute_process_info( |
| 3593 |
procs: *mut AmdsmiProcessInfoT, |
| 3594 |
num_items: *mut u32, |
| 3595 |
) -> AmdsmiStatusT; |
| 3596 |
} |
| 3597 |
extern "C" { |
| 3598 |
pub fn amdsmi_get_gpu_compute_process_info_by_pid( |
| 3599 |
pid: u32, |
| 3600 |
proc_: *mut AmdsmiProcessInfoT, |
| 3601 |
) -> AmdsmiStatusT; |
| 3602 |
} |
| 3603 |
extern "C" { |
| 3604 |
pub fn amdsmi_get_gpu_compute_process_gpus( |
| 3605 |
pid: u32, |
| 3606 |
dv_indices: *mut u32, |
| 3607 |
num_devices: *mut u32, |
| 3608 |
) -> AmdsmiStatusT; |
| 3609 |
} |
| 3610 |
extern "C" { |
| 3611 |
pub fn amdsmi_gpu_xgmi_error_status( |
| 3612 |
processor_handle: AmdsmiProcessorHandle, |
| 3613 |
status: *mut AmdsmiXgmiStatusT, |
| 3614 |
) -> AmdsmiStatusT; |
| 3615 |
} |
| 3616 |
extern "C" { |
| 3617 |
pub fn amdsmi_reset_gpu_xgmi_error(processor_handle: AmdsmiProcessorHandle) -> AmdsmiStatusT; |
| 3618 |
} |
| 3619 |
extern "C" { |
| 3620 |
pub fn amdsmi_get_xgmi_info( |
| 3621 |
processor_handle: AmdsmiProcessorHandle, |
| 3622 |
info: *mut AmdsmiXgmiInfoT, |
| 3623 |
) -> AmdsmiStatusT; |
| 3624 |
} |
| 3625 |
extern "C" { |
| 3626 |
pub fn amdsmi_get_gpu_xgmi_link_status( |
| 3627 |
processor_handle: AmdsmiProcessorHandle, |
| 3628 |
link_status: *mut AmdsmiXgmiLinkStatusT, |
| 3629 |
) -> AmdsmiStatusT; |
| 3630 |
} |
| 3631 |
extern "C" { |
| 3632 |
pub fn amdsmi_get_link_metrics( |
| 3633 |
processor_handle: AmdsmiProcessorHandle, |
| 3634 |
link_metrics: *mut AmdsmiLinkMetricsT, |
| 3635 |
) -> AmdsmiStatusT; |
| 3636 |
} |
| 3637 |
extern "C" { |
| 3638 |
pub fn amdsmi_topo_get_numa_node_number( |
| 3639 |
processor_handle: AmdsmiProcessorHandle, |
| 3640 |
numa_node: *mut u32, |
| 3641 |
) -> AmdsmiStatusT; |
| 3642 |
} |
| 3643 |
extern "C" { |
| 3644 |
pub fn amdsmi_topo_get_link_weight( |
| 3645 |
processor_handle_src: AmdsmiProcessorHandle, |
| 3646 |
processor_handle_dst: AmdsmiProcessorHandle, |
| 3647 |
weight: *mut u64, |
| 3648 |
) -> AmdsmiStatusT; |
| 3649 |
} |
| 3650 |
extern "C" { |
| 3651 |
pub fn amdsmi_get_minmax_bandwidth_between_processors( |
| 3652 |
processor_handle_src: AmdsmiProcessorHandle, |
| 3653 |
processor_handle_dst: AmdsmiProcessorHandle, |
| 3654 |
min_bandwidth: *mut u64, |
| 3655 |
max_bandwidth: *mut u64, |
| 3656 |
) -> AmdsmiStatusT; |
| 3657 |
} |
| 3658 |
extern "C" { |
| 3659 |
pub fn amdsmi_topo_get_link_type( |
| 3660 |
processor_handle_src: AmdsmiProcessorHandle, |
| 3661 |
processor_handle_dst: AmdsmiProcessorHandle, |
| 3662 |
hops: *mut u64, |
| 3663 |
type_: *mut AmdsmiLinkTypeT, |
| 3664 |
) -> AmdsmiStatusT; |
| 3665 |
} |
| 3666 |
extern "C" { |
| 3667 |
pub fn amdsmi_get_link_topology_nearest( |
| 3668 |
processor_handle: AmdsmiProcessorHandle, |
| 3669 |
link_type: AmdsmiLinkTypeT, |
| 3670 |
topology_nearest_info: *mut AmdsmiTopologyNearestT, |
| 3671 |
) -> AmdsmiStatusT; |
| 3672 |
} |
| 3673 |
extern "C" { |
| 3674 |
pub fn amdsmi_is_P2P_accessible( |
| 3675 |
processor_handle_src: AmdsmiProcessorHandle, |
| 3676 |
processor_handle_dst: AmdsmiProcessorHandle, |
| 3677 |
accessible: *mut bool, |
| 3678 |
) -> AmdsmiStatusT; |
| 3679 |
} |
| 3680 |
extern "C" { |
| 3681 |
pub fn amdsmi_topo_get_p2p_status( |
| 3682 |
processor_handle_src: AmdsmiProcessorHandle, |
| 3683 |
processor_handle_dst: AmdsmiProcessorHandle, |
| 3684 |
type_: *mut AmdsmiLinkTypeT, |
| 3685 |
cap: *mut AmdsmiP2pCapabilityT, |
| 3686 |
) -> AmdsmiStatusT; |
| 3687 |
} |
| 3688 |
extern "C" { |
| 3689 |
pub fn amdsmi_get_gpu_compute_partition( |
| 3690 |
processor_handle: AmdsmiProcessorHandle, |
| 3691 |
compute_partition: *mut ::std::os::raw::c_char, |
| 3692 |
len: u32, |
| 3693 |
) -> AmdsmiStatusT; |
| 3694 |
} |
| 3695 |
extern "C" { |
| 3696 |
pub fn amdsmi_set_gpu_compute_partition( |
| 3697 |
processor_handle: AmdsmiProcessorHandle, |
| 3698 |
compute_partition: AmdsmiComputePartitionTypeT, |
| 3699 |
) -> AmdsmiStatusT; |
| 3700 |
} |
| 3701 |
extern "C" { |
| 3702 |
pub fn amdsmi_get_gpu_memory_partition( |
| 3703 |
processor_handle: AmdsmiProcessorHandle, |
| 3704 |
memory_partition: *mut ::std::os::raw::c_char, |
| 3705 |
len: u32, |
| 3706 |
) -> AmdsmiStatusT; |
| 3707 |
} |
| 3708 |
extern "C" { |
| 3709 |
pub fn amdsmi_set_gpu_memory_partition( |
| 3710 |
processor_handle: AmdsmiProcessorHandle, |
| 3711 |
memory_partition: AmdsmiMemoryPartitionTypeT, |
| 3712 |
) -> AmdsmiStatusT; |
| 3713 |
} |
| 3714 |
extern "C" { |
| 3715 |
pub fn amdsmi_get_gpu_memory_partition_config( |
| 3716 |
processor_handle: AmdsmiProcessorHandle, |
| 3717 |
config: *mut AmdsmiMemoryPartitionConfigT, |
| 3718 |
) -> AmdsmiStatusT; |
| 3719 |
} |
| 3720 |
extern "C" { |
| 3721 |
pub fn amdsmi_set_gpu_memory_partition_mode( |
| 3722 |
processor_handle: AmdsmiProcessorHandle, |
| 3723 |
mode: AmdsmiMemoryPartitionTypeT, |
| 3724 |
) -> AmdsmiStatusT; |
| 3725 |
} |
| 3726 |
extern "C" { |
| 3727 |
pub fn amdsmi_get_gpu_accelerator_partition_profile_config( |
| 3728 |
processor_handle: AmdsmiProcessorHandle, |
| 3729 |
profile_config: *mut AmdsmiAcceleratorPartitionProfileConfigT, |
| 3730 |
) -> AmdsmiStatusT; |
| 3731 |
} |
| 3732 |
extern "C" { |
| 3733 |
pub fn amdsmi_get_gpu_accelerator_partition_profile( |
| 3734 |
processor_handle: AmdsmiProcessorHandle, |
| 3735 |
profile: *mut AmdsmiAcceleratorPartitionProfileT, |
| 3736 |
partition_id: *mut u32, |
| 3737 |
) -> AmdsmiStatusT; |
| 3738 |
} |
| 3739 |
extern "C" { |
| 3740 |
pub fn amdsmi_set_gpu_accelerator_partition_profile( |
| 3741 |
processor_handle: AmdsmiProcessorHandle, |
| 3742 |
profile_index: u32, |
| 3743 |
) -> AmdsmiStatusT; |
| 3744 |
} |
| 3745 |
extern "C" { |
| 3746 |
pub fn amdsmi_init_gpu_event_notification( |
| 3747 |
processor_handle: AmdsmiProcessorHandle, |
| 3748 |
) -> AmdsmiStatusT; |
| 3749 |
} |
| 3750 |
extern "C" { |
| 3751 |
pub fn amdsmi_set_gpu_event_notification_mask( |
| 3752 |
processor_handle: AmdsmiProcessorHandle, |
| 3753 |
mask: u64, |
| 3754 |
) -> AmdsmiStatusT; |
| 3755 |
} |
| 3756 |
extern "C" { |
| 3757 |
pub fn amdsmi_get_gpu_event_notification( |
| 3758 |
timeout_ms: ::std::os::raw::c_int, |
| 3759 |
num_elem: *mut u32, |
| 3760 |
data: *mut AmdsmiEvtNotificationDataT, |
| 3761 |
) -> AmdsmiStatusT; |
| 3762 |
} |
| 3763 |
extern "C" { |
| 3764 |
pub fn amdsmi_stop_gpu_event_notification( |
| 3765 |
processor_handle: AmdsmiProcessorHandle, |
| 3766 |
) -> AmdsmiStatusT; |
| 3767 |
} |
| 3768 |
extern "C" { |
| 3769 |
pub fn amdsmi_get_gpu_driver_info( |
| 3770 |
processor_handle: AmdsmiProcessorHandle, |
| 3771 |
info: *mut AmdsmiDriverInfoT, |
| 3772 |
) -> AmdsmiStatusT; |
| 3773 |
} |
| 3774 |
extern "C" { |
| 3775 |
pub fn amdsmi_get_gpu_asic_info( |
| 3776 |
processor_handle: AmdsmiProcessorHandle, |
| 3777 |
info: *mut AmdsmiAsicInfoT, |
| 3778 |
) -> AmdsmiStatusT; |
| 3779 |
} |
| 3780 |
extern "C" { |
| 3781 |
pub fn amdsmi_get_gpu_kfd_info( |
| 3782 |
processor_handle: AmdsmiProcessorHandle, |
| 3783 |
info: *mut AmdsmiKfdInfoT, |
| 3784 |
) -> AmdsmiStatusT; |
| 3785 |
} |
| 3786 |
extern "C" { |
| 3787 |
pub fn amdsmi_get_gpu_vram_info( |
| 3788 |
processor_handle: AmdsmiProcessorHandle, |
| 3789 |
info: *mut AmdsmiVramInfoT, |
| 3790 |
) -> AmdsmiStatusT; |
| 3791 |
} |
| 3792 |
extern "C" { |
| 3793 |
pub fn amdsmi_get_gpu_board_info( |
| 3794 |
processor_handle: AmdsmiProcessorHandle, |
| 3795 |
info: *mut AmdsmiBoardInfoT, |
| 3796 |
) -> AmdsmiStatusT; |
| 3797 |
} |
| 3798 |
extern "C" { |
| 3799 |
pub fn amdsmi_get_power_cap_info( |
| 3800 |
processor_handle: AmdsmiProcessorHandle, |
| 3801 |
sensor_ind: u32, |
| 3802 |
info: *mut AmdsmiPowerCapInfoT, |
| 3803 |
) -> AmdsmiStatusT; |
| 3804 |
} |
| 3805 |
extern "C" { |
| 3806 |
pub fn amdsmi_get_pcie_info( |
| 3807 |
processor_handle: AmdsmiProcessorHandle, |
| 3808 |
info: *mut AmdsmiPcieInfoT, |
| 3809 |
) -> AmdsmiStatusT; |
| 3810 |
} |
| 3811 |
extern "C" { |
| 3812 |
pub fn amdsmi_get_gpu_xcd_counter( |
| 3813 |
processor_handle: AmdsmiProcessorHandle, |
| 3814 |
xcd_count: *mut u16, |
| 3815 |
) -> AmdsmiStatusT; |
| 3816 |
} |
| 3817 |
extern "C" { |
| 3818 |
pub fn amdsmi_get_fw_info( |
| 3819 |
processor_handle: AmdsmiProcessorHandle, |
| 3820 |
info: *mut AmdsmiFwInfoT, |
| 3821 |
) -> AmdsmiStatusT; |
| 3822 |
} |
| 3823 |
extern "C" { |
| 3824 |
pub fn amdsmi_get_gpu_vbios_info( |
| 3825 |
processor_handle: AmdsmiProcessorHandle, |
| 3826 |
info: *mut AmdsmiVbiosInfoT, |
| 3827 |
) -> AmdsmiStatusT; |
| 3828 |
} |
| 3829 |
extern "C" { |
| 3830 |
pub fn amdsmi_get_gpu_activity( |
| 3831 |
processor_handle: AmdsmiProcessorHandle, |
| 3832 |
info: *mut AmdsmiEngineUsageT, |
| 3833 |
) -> AmdsmiStatusT; |
| 3834 |
} |
| 3835 |
extern "C" { |
| 3836 |
pub fn amdsmi_get_power_info( |
| 3837 |
processor_handle: AmdsmiProcessorHandle, |
| 3838 |
info: *mut AmdsmiPowerInfoT, |
| 3839 |
) -> AmdsmiStatusT; |
| 3840 |
} |
| 3841 |
extern "C" { |
| 3842 |
pub fn amdsmi_is_gpu_power_management_enabled( |
| 3843 |
processor_handle: AmdsmiProcessorHandle, |
| 3844 |
enabled: *mut bool, |
| 3845 |
) -> AmdsmiStatusT; |
| 3846 |
} |
| 3847 |
extern "C" { |
| 3848 |
pub fn amdsmi_get_clock_info( |
| 3849 |
processor_handle: AmdsmiProcessorHandle, |
| 3850 |
clk_type: AmdsmiClkTypeT, |
| 3851 |
info: *mut AmdsmiClkInfoT, |
| 3852 |
) -> AmdsmiStatusT; |
| 3853 |
} |
| 3854 |
extern "C" { |
| 3855 |
pub fn amdsmi_get_gpu_vram_usage( |
| 3856 |
processor_handle: AmdsmiProcessorHandle, |
| 3857 |
info: *mut AmdsmiVramUsageT, |
| 3858 |
) -> AmdsmiStatusT; |
| 3859 |
} |
| 3860 |
extern "C" { |
| 3861 |
pub fn amdsmi_get_violation_status( |
| 3862 |
processor_handle: AmdsmiProcessorHandle, |
| 3863 |
info: *mut AmdsmiViolationStatusT, |
| 3864 |
) -> AmdsmiStatusT; |
| 3865 |
} |
| 3866 |
extern "C" { |
| 3867 |
pub fn amdsmi_get_gpu_process_list( |
| 3868 |
processor_handle: AmdsmiProcessorHandle, |
| 3869 |
max_processes: *mut u32, |
| 3870 |
list: *mut AmdsmiProcInfoT, |
| 3871 |
) -> AmdsmiStatusT; |
| 3872 |
} |
| 3873 |
extern "C" { |
| 3874 |
pub fn amdsmi_gpu_driver_reload() -> AmdsmiStatusT; |
| 3875 |
} |