Documentation
¶
Index ¶
- Constants
- func CalcChecksum(bytes []byte) byte
- func FixChecksum(bytes []byte)
- type AtomAsicProfilingInfoV35
- type AtomAsicProfilingInfoV36
- type AtomCommonTableHeader
- type AtomMasterCommandTable
- type AtomMasterDataTable
- type AtomRomHeader
- type AtomRomPCIInfo
- type AtomSClkEntry
- type AtomSClkTable
- type AtomVRAMInfoV21
- type AtomVRAMInfoV22
- type AtomVRAMInfoV23
- type AtomVRAMModuleV7
- type AtomVRAMModuleV8
- type AtomVRAMModuleV9
- type AtomVRAMTimingEntry
- type AtomVoltageEntry
- type AtomVoltageInfo
- type AtomVoltageTable
- type EFUSE_LINEAR_FUNC_PARAM
Constants ¶
View Source
const ( AtomRomHeaderSizeOffset = 0x02 AtomRomChecksumOffset = 0x21 AtomRomHeaderPointerOffset = 0x48 )
Variables ¶
This section is empty.
Functions ¶
func CalcChecksum ¶
func FixChecksum ¶
func FixChecksum(bytes []byte)
Types ¶
type AtomAsicProfilingInfoV35 ¶
type AtomAsicProfilingInfoV35 struct { Header AtomCommonTableHeader MaxVdd uint32 //Maximum voltage for all parts, in unit of 0.01mv MinVddc uint32 //Minimum voltage for all parts, in unit of 0.01mv LkgEuseIndex uint16 //Efuse Lkg_FT address ( BYTE address ) LkgEfuseBitLSB byte //Efuse Lkg_FT bit shift in 32bit DWORD LkgEfuseLength byte //Efuse Lkg_FT length LkgEncodeLn_MaxDivMin uint32 //value of ln(Max_Lkg_Ft/Min_Lkg_Ft ) in unit of 0.00001 ( unit=100000 ) LkgEncodeMax uint32 //Maximum Lkg_Ft measured value ( or efuse decode value ), in unit of 0.00001 ( unit=100000 ) LkgEncodeMin uint32 //Minimum Lkg_Ft measured value ( or efuse decode value ), in unit of 0.00001 ( unit=100000 ) RoFuse EFUSE_LINEAR_FUNC_PARAM //Efuse RO info: DWORD address, bit shift, length, max/min measure value. in unit of 1. EvvDefaultVddc uint32 //def="EVV_DEFAULT_VDDC" descr="return default VDDC(v) when Efuse not cut" unit="100000"/> EvvNoCalcVddc uint32 //def="EVV_NOCALC_VDDC" descr="return VDDC(v) when Calculation is bad" unit="100000"/> Speed_Model uint32 //def="EVV_SPEED_MODEL" descr="0 = Greek model, 1 = multivariate model" unit="1"/> SM_A0 uint32 //def="EVV_SM_A0" descr="Leakage coeff(Multivariant Mode)." unit="100000"/> SM_A1 uint32 //def="EVV_SM_A1" descr="Leakage/SCLK coeff(Multivariant Mode)." unit="1000000"/> SM_A2 uint32 //def="EVV_SM_A2" descr="Alpha( Greek Mode ) or VDDC/SCLK coeff(Multivariant Mode)." unit="100000"/> SM_A3 uint32 //def="EVV_SM_A3" descr="Beta( Greek Mode ) or SCLK coeff(Multivariant Mode)." unit="100000"/> SM_A4 uint32 //def="EVV_SM_A4" descr="VDDC^2/SCLK coeff(Multivariant Mode)." unit="100000"/> SM_A5 uint32 //def="EVV_SM_A5" descr="VDDC^2 coeff(Multivariant Mode)." unit="100000"/> SM_A6 uint32 //def="EVV_SM_A6" descr="Gamma( Greek Mode ) or VDDC coeff(Multivariant Mode)." unit="100000"/> SM_A7 uint32 //def="EVV_SM_A7" descr="Epsilon( Greek Mode ) or constant(Multivariant Mode)." unit="100000"/> SM_A0_sign byte //def="EVV_SM_A0_SIGN" descr="=0 SM_A0 is postive. =1: SM_A0 is negative" unit="1"/> SM_A1_sign byte //def="EVV_SM_A1_SIGN" descr="=0 SM_A1 is postive. =1: SM_A1 is negative" unit="1"/> SM_A2_sign byte //def="EVV_SM_A2_SIGN" descr="=0 SM_A2 is postive. =1: SM_A2 is negative" unit="1"/> SM_A3_sign byte //def="EVV_SM_A3_SIGN" descr="=0 SM_A3 is postive. =1: SM_A3 is negative" unit="1"/> SM_A4_sign byte //def="EVV_SM_A4_SIGN" descr="=0 SM_A4 is postive. =1: SM_A4 is negative" unit="1"/> SM_A5_sign byte //def="EVV_SM_A5_SIGN" descr="=0 SM_A5 is postive. =1: SM_A5 is negative" unit="1"/> SM_A6_sign byte //def="EVV_SM_A6_SIGN" descr="=0 SM_A6 is postive. =1: SM_A6 is negative" unit="1"/> SM_A7_sign byte //def="EVV_SM_A7_SIGN" descr="=0 SM_A7 is postive. =1: SM_A7 is negative" unit="1"/> Margin_RO_a uint32 //def="EVV_MARGIN_RO_A" descr="A Term to represent RO equation in Ax2+Bx+C, unit=1" Margin_RO_b uint32 //def="EVV_MARGIN_RO_B" descr="B Term to represent RO equation in Ax2+Bx+C, unit=1" Margin_RO_c uint32 //def="EVV_MARGIN_RO_C" descr="C Term to represent RO equation in Ax2+Bx+C, unit=1" Margin_fixed uint32 //def="EVV_MARGIN_FIXED" descr="Fixed MHz to add to SCLK margin, unit=1" unit="1"/> Margin_Fmax_mean uint32 //def="EVV_MARGIN_FMAX_MEAN" descr="Percentage to add for Fmas mean margin unit=10000" unit="10000"/> Margin_plat_mean uint32 //def="EVV_MARGIN_PLAT_MEAN" descr="Percentage to add for platform mean margin unit=10000" unit="10000"/> Margin_Fmax_sigma uint32 //def="EVV_MARGIN_FMAX_SIGMA" descr="Percentage to add for Fmax sigma margin unit=10000" unit="10000"/> Margin_plat_sigma uint32 //def="EVV_MARGIN_PLAT_SIGMA" descr="Percentage to add for platform sigma margin unit=10000" unit="10000"/> Margin_DC_sigma uint32 //def="EVV_MARGIN_DC_SIGMA" descr="Regulator DC tolerance margin (mV) unit=100" unit="100"/> Reserved [1]uint32 }
for Polaris10/Polaris11 speed EVV algorithm
type AtomAsicProfilingInfoV36 ¶
type AtomAsicProfilingInfoV36 struct { Header AtomCommonTableHeader MaxVddc uint32 MinVddc uint32 LkgEuseIndex uint16 LkgEfuseBitLSB byte LkgEfuseLength byte LkgEncodeLn_MaxDivMin uint32 LkgEncodeMax uint32 LkgEncodeMin uint32 RoFuse EFUSE_LINEAR_FUNC_PARAM EvvDefaultVddc uint32 EvvNoCalcVddc uint32 Speed_Model uint32 SM_A0 uint32 SM_A1 uint32 SM_A2 uint32 SM_A3 uint32 SM_A4 uint32 SM_A5 uint32 SM_A6 uint32 SM_A7 uint32 SM_A0_sign byte SM_A1_sign byte SM_A2_sign byte SM_A3_sign byte SM_A4_sign byte SM_A5_sign byte SM_A6_sign byte SM_A7_sign byte Margin_RO_a uint32 Margin_RO_b uint32 Margin_RO_c uint32 Margin_fixed uint32 Margin_Fmax_mean uint32 Margin_plat_mean uint32 Margin_Fmax_sigma uint32 Margin_plat_sigma uint32 Margin_DC_sigma uint32 LoadLineSlop uint32 AVFS_meanNsigma_Acontant0 uint32 AVFS_meanNsigma_Acontant1 uint32 AVFS_meanNsigma_Acontant2 uint32 AVFS_meanNsigma_DC_tol_sigma uint16 AVFS_meanNsigma_Platform_mean uint16 AVFS_meanNsigma_Platform_sigma uint16 GB_VDROOP_TABLE_CKSOFF_a0 uint32 GB_VDROOP_TABLE_CKSOFF_a1 uint32 GB_VDROOP_TABLE_CKSOFF_a2 uint32 GB_VDROOP_TABLE_CKSON_a0 uint32 GB_VDROOP_TABLE_CKSON_a1 uint32 GB_VDROOP_TABLE_CKSON_a2 uint32 AVFSGB_FUSE_TABLE_CKSOFF_m1 uint32 AVFSGB_FUSE_TABLE_CKSOFF_m2 uint16 AVFSGB_FUSE_TABLE_CKSOFF_b uint32 AVFSGB_FUSE_TABLE_CKSON_m1 uint32 AVFSGB_FUSE_TABLE_CKSON_m2 uint16 AVFSGB_FUSE_TABLE_CKSON_b uint32 MaxVoltage_0_25mv uint16 EnableGB_VDROOP_TABLE_CKSOFF byte EnableGB_VDROOP_TABLE_CKSON byte EnableGB_FUSE_TABLE_CKSOFF byte EnableGB_FUSE_TABLE_CKSON byte PSM_Age_ComFactor uint16 EnableApplyAVFS_CKS_OFF_Voltage byte Reserved byte // contains filtered or unexported fields }
for Polars10/11 AVFS parameters
type AtomCommonTableHeader ¶
type AtomMasterCommandTable ¶
type AtomMasterCommandTable struct { Header AtomCommonTableHeader ASICInit uint16 GetDisplaySurfaceSize uint16 ASICRegistersInit uint16 VRAMBlockVenderDetection uint16 DIGxEncoderControl uint16 MemoryControllerInit uint16 EnableCRTCMemReq uint16 MemoryParamAdjt uint16 DVOEncoderControl uint16 GPIOPinControl uint16 SetEngineClock uint16 SetMemoryClock uint16 SetPixelClock uint16 EnableDispPowerGating uint16 ResetMemoryDLL uint16 ResetMemoryDevice uint16 MemoryPLLInit uint16 AdjtDisplayPll uint16 AdjtMemoryController uint16 EnableASICStaticPwrMgt uint16 SetUniphyInstance uint16 DACLoadDetection uint16 LVTMAEncoderControl uint16 HWMiscOperation uint16 DAC1EncoderControl uint16 DAC2EncoderControl uint16 DVOOutputControl uint16 CV1OutputControl uint16 GetConditionalGoldenSetting uint16 TVEncoderControl uint16 PatchMCSetting uint16 MCSEQControl uint16 GfxHarvesting uint16 EnableScaler uint16 BlankCRTC uint16 EnableCRTC uint16 GetPixelClock uint16 EnableVGARender uint16 GetSCLKOverMCLKRatio uint16 SetCRTCTiming uint16 SetCRTCOverScan uint16 SetCRTCReplication uint16 SelectCRTCSource uint16 EnableGraphSurfaces uint16 UpdateCRTCDoubleBufferRegisters uint16 LUTAutoFill uint16 EnableHWIconCursor uint16 GetMemoryClock uint16 GetEngineClock uint16 SetCRTCingDTDTiming uint16 ExternalEncoderControl uint16 LVTMAOutputControl uint16 VRAMBlockDetectionByStrap uint16 MemoryCleanUp uint16 ProcessI2cChannelTransaction uint16 WriteOneByteToHWAssistedI2C uint16 ReadHWAssistedI2CStat uint16 SpeedFanControl uint16 PowerConnectorDetection uint16 MCSynchronization uint16 ComputeMemoryEnginePLL uint16 MemoryRefreshConversion uint16 VRAMGetCurrentInfoBlock uint16 DynamicMemorySettings uint16 MemoryTraining uint16 EnableSpreadSpectrumOnPPLL uint16 TMDSAOutputControl uint16 SetVoltage uint16 DAC1OutputControl uint16 DAC2OutputControl uint16 ComputeMemoryClockParam uint16 ClockSource uint16 MemoryDeviceInit uint16 GetDispObjectInfo uint16 DIG1EncoderControl uint16 DIG2EncoderControl uint16 DIG1TransmitterControl uint16 DIG2TransmitterControl uint16 ProcessAuxChannelTransaction uint16 DPEncoderService uint16 GetVoltageInfo uint16 }
type AtomMasterDataTable ¶
type AtomMasterDataTable struct { Header AtomCommonTableHeader UtilityPipeLine uint16 MultimediaCapabilityInfo uint16 MultimediaConfigInfo uint16 StandardVESATiming uint16 FirmwareInfo uint16 PaletteData uint16 LCDInfo uint16 DIGTransmitterInfo uint16 AnalogTVInfo uint16 SupportedDevicesInfo uint16 GPIOI2CInfo uint16 VRAMageByFirmware uint16 GPIOPinLUT uint16 VESAToInternalModeLUT uint16 ComponentVideoInfo uint16 PowerPlayInfo uint16 CompassionateData uint16 SaveRestoreInfo uint16 PPLLSSInfo uint16 OemInfo uint16 XTMDSInfo uint16 MclkSSInfo uint16 ObjectHeader uint16 IndirectIOAccess uint16 MCInitParameter uint16 ASICVDDCInfo uint16 ASICInternalSSInfo uint16 TVVideoMode uint16 VRAMInfo uint16 MemoryTrainingInfo uint16 IntegratedSystemInfo uint16 ASICProfilingInfo uint16 VoltageObjectInfo uint16 PowerSourceInfo uint16 }
type AtomRomHeader ¶
type AtomRomHeader struct { Header AtomCommonTableHeader FirmWareSignature string `struct:"[4]byte"` BiosRuntimeSegmentAddress uint16 ProtectedModeInfoOffset uint16 ConfigFilenameOffset uint16 CRCBlockOffset uint16 BIOSBootupMessageOffset uint16 Int10Offset uint16 PciBDevInitCode uint16 IoBaseAddress uint16 SubsystemVendorID uint16 SubsystemID uint16 PCIInfoOffset uint16 MasterCommandTableOffset uint16 MasterDataTableOffset uint16 ExtendedFunctionCode byte // contains filtered or unexported fields }
type AtomRomPCIInfo ¶
type AtomSClkEntry ¶
type AtomSClkTable ¶
type AtomSClkTable struct { RevID byte NumEntries byte `struct:"sizeof=Entries"` Entries []AtomSClkEntry }
type AtomVRAMInfoV21 ¶
type AtomVRAMInfoV21 struct { Header AtomCommonTableHeader MemAdjustTblOffset uint16 // offset of ATOM_INIT_REG_BLOCK structure for memory vendor specific MC adjust setting MemClkPatchTblOffset uint16 // offset of ATOM_INIT_REG_BLOCK structure for memory clock specific MC setting PerBytePresetOffset uint16 // offset of ATOM_INIT_REG_BLOCK structure for Per Byte Offset Preset Settings NumOfVRAMModule byte // indicate number of VRAM module MemoryClkPatchTblVer byte // version of memory AC timing register list VramModuleVer byte // indicate ATOM_VRAM_MODUE version VramInfo []AtomVRAMModuleV7 // just for allocation, real number of blocks is in ucNumOfVRAMModule; // contains filtered or unexported fields }
type AtomVRAMInfoV22 ¶
type AtomVRAMInfoV22 struct { Header AtomCommonTableHeader MemAdjustTblOffset uint16 MemClkPatchTblOffset uint16 McAdjustPerTileTblOffset uint16 McPhyInitTableOffset uint16 DramDataRemapTblOffset uint16 NumOfVRAMModule byte MemoryClkPatchTblVer byte VramModuleVer byte McPhyTileNum byte VramInfo []AtomVRAMModuleV8 // contains filtered or unexported fields }
type AtomVRAMInfoV23 ¶
type AtomVRAMInfoV23 struct { Header AtomCommonTableHeader MemAdjustTblOffset uint16 MemClkPatchTblOffset uint16 McAdjustPerTileTblOffset uint16 McPhyInitTableOffset uint16 DramDataRemapTblOffset uint16 TmrsSeqOffset uint16 // offset of HBM tmrs PostUcodeInitOffset uint16 // offset of atom_umc_init_reg_block structure for MC phy init after MC uCode complete umc init VramRsd2 uint16 NumOfVRAMModule byte // indicate number of VRAM module McPhyTileNum byte VramInfo []AtomVRAMModuleV9 // just for allocation, real number of blocks is in ucNumOfVRAMModule; // contains filtered or unexported fields }
type AtomVRAMModuleV7 ¶
type AtomVRAMModuleV7 struct { }
type AtomVRAMModuleV8 ¶
type AtomVRAMModuleV8 struct { ChannelMapCfg uint32 ModuleSize uint16 McRAMCfg uint16 EnableChannels uint16 ExtMemoryID byte MemoryType byte ChannelNum byte ChannelWidth byte Density byte BankCol byte Misc byte VREFI byte MemorySize uint16 McTunningSetID byte RowNum byte EMRS2Value uint16 EMRS3Value uint16 MemoryVenderID byte RefreshRateFactor byte FIFODepth byte CDRBandwidth byte ChannelMapCfg1 uint32 BankMapCfg uint32 MemPNString string `struct:"[20]byte"` // contains filtered or unexported fields }
type AtomVRAMModuleV9 ¶
type AtomVRAMModuleV9 struct { MemorySize uint32 // Total memory size in unit of MB for CONFIG_MEMSIZE zeros EnableChannels uint32 // bit vector, each bit indicate specific channel enable or not MaxMemoryClock uint32 // max memory clock of this memory in unit of 10kHz, =0 means it is not defined MemoryVoltage uint16 // mem_voltage ModuleSize uint16 // Size of atom_vram_module_v9 ExtMemoryID byte // Current memory module ID MemoryType byte // enum of atom_dgpu_vram_type ChannelNum byte // Number of mem. channels supported in this module ChannelWidth byte // CHANNEL_16BIT/CHANNEL_32BIT/CHANNEL_64BIT Density byte // _8Mx32, _16Mx32, _16Mx16, _32Mx16 McTunningSetID byte // MC phy registers set per. VendorRevID byte // [7:4] Revision, [3:0] Vendor code RefreshRateFactor byte // [1:0]=RefreshFactor (00=8ms, 01=16ms, 10=32ms,11=64ms) HBMVendorRevID byte // hbm_ven_rev_id MemPNString string `struct:"[20]byte"` // part number end with '0'. // contains filtered or unexported fields }
type AtomVRAMTimingEntry ¶
type AtomVoltageEntry ¶
type AtomVoltageInfo ¶
type AtomVoltageInfo struct { Header AtomCommonTableHeader VDDCBaseLevel uint16 //In number of 50mv unit NumOfVoltageEntries byte BytesPerVoltageEntry byte VoltageStep byte //Indicating in how many mv increament is one step, 0.5mv unit DefaultVoltageEntry byte VoltageControlI2cLine byte VoltageControlAddress byte VoltageControlOffset byte VoltageEntries []byte // contains filtered or unexported fields }
type AtomVoltageTable ¶
type AtomVoltageTable struct { RevID byte NumEntries byte `struct:"sizeof=Entries"` Entries []AtomVoltageEntry }
type EFUSE_LINEAR_FUNC_PARAM ¶
type EFUSE_LINEAR_FUNC_PARAM struct { EfuseIndex uint16 // Efuse Index in DWORD address, for example Index 911, usEuseIndex=112 EfuseBitLSB byte // Efuse bit LSB in DWORD address, for example Index 911, usEfuseBitLSB= 911-112*8=15 EfuseLength byte // Efuse bits length, EfuseEncodeRang uint32 // Range = Max - Min, bit31 indicate the efuse is negative number EfuseMin uint32 // Min }
Source Files
¶
Click to show internal directories.
Click to hide internal directories.