Xe GT Frequency Management¶
This component is responsible for the raw GT frequency management, including the sysfs API.
Underneath, Xe enables GuC SLPC automated frequency management. GuC is then allowed to request PCODE any frequency between the Minimum and the Maximum selected by this component. Furthermore, it is important to highlight that PCODE is the ultimate decision maker of the actual running frequency, based on thermal and other running conditions.
Xe’s Freq provides a sysfs API for frequency management under
<device>/tile#/gt#/freq0/ directory.
Read-only attributes:
act_freq: The actual resolved frequency decided by PCODE.cur_freq: The current one requested by GuC PC to the PCODE.rpn_freq: The Render Performance (RP) N level, which is the minimal one.rpa_freq: The Render Performance (RP) A level, which is the achievable one.Calculated by PCODE at runtime based on multiple running conditions
rpe_freq: The Render Performance (RP) E level, which is the efficient one.Calculated by PCODE at runtime based on multiple running conditions
rp0_freq: The Render Performance (RP) 0 level, which is the maximum one.
Read-write attributes:
min_freq: Min frequency request.max_freq: Max frequency request.If max <= min, then freq_min becomes a fixed frequency request.
The GT frequency may be throttled by hardware/firmware for various reasons
that are provided through attributes under the freq0/throttle/ directory.
Their availability depend on the platform and some may not be visible if that
reason is not available.
The reasons attribute can be used by sysadmin to monitor all possible
reasons for throttling and report them. It’s preferred over monitoring
status and then reading the reason from individual attributes since that
is racy. If there’s no throttling happening, “none” is returned.
The following attributes are available on Crescent Island platform:
status: Overall throttle status (0: no throttling, 1: throttling)reasons: Array of reasons causing throttling separated by spacereason_pl1: package PL1reason_pl2: package PL2reason_pl4: package PL4reason_prochot: prochotreason_soc_thermal: SoC thermalreason_mem_thermal: Memory thermalreason_vr_thermal: VR thermalreason_iccmax: ICCMAXreason_ratl: RATL thermal algorithmreason_soc_avg_thermal: SoC average tempreason_fastvmode: VR is hitting FastVModereason_psys_pl1: PSYS PL1reason_psys_pl2: PSYS PL2reason_p0_freq: P0 frequencyreason_psys_crit: PSYS critical
Other platforms support the following reasons:
status: Overall throttle status (0: no throttling, 1: throttling)reasons: Array of reasons causing throttling separated by spacereason_pl1: package PL1reason_pl2: package PL2reason_pl4: package PL4, Iccmax etc.reason_thermal: thermalreason_prochot: prochotreason_ratl: RATL hermal algorithmreason_vr_thermalert: VR THERMALERTreason_vr_tdc: VR TDC
Internal API¶
-
int xe_gt_freq_init(struct xe_gt *gt)¶
Initialize Xe Freq component
Parameters
struct xe_gt *gtXe GT object
Description
It needs to be initialized after GT Sysfs and GuC PC components are ready.
Return
Returns error value for failure and 0 for success.