--- initial
+++ final
@@ -1,70 +1,70 @@
 static int vega10_hwmgr_backend_init(struct pp_hwmgr *hwmgr) {
   int result = 0;
   struct vega10_hwmgr *data;
   uint32_t config_telemetry = 0;
   struct pp_atomfwctrl_voltage_table vol_table;
   struct cgs_system_info sys_info = {0};
   data = kzalloc(sizeof(struct vega10_hwmgr), GFP_KERNEL);
   if (data == NULL) return -ENOMEM;
   hwmgr->backend = data;
   vega10_set_default_registry_data(hwmgr);
   data->disable_dpm_mask = 0xff;
   data->workload_mask = 0xff;
   /* need to set voltage control types before EVV patching */
   data->vddc_control = VEGA10_VOLTAGE_CONTROL_NONE;
   data->mvdd_control = VEGA10_VOLTAGE_CONTROL_NONE;
   data->vddci_control = VEGA10_VOLTAGE_CONTROL_NONE;
   /* VDDCR_SOC */
   if (pp_atomfwctrl_is_voltage_controlled_by_gpio_v4(hwmgr, VOLTAGE_TYPE_VDDC, VOLTAGE_OBJ_SVID2)) {
     if (!pp_atomfwctrl_get_voltage_table_v4(hwmgr, VOLTAGE_TYPE_VDDC, VOLTAGE_OBJ_SVID2, &vol_table)) {
       config_telemetry = ((vol_table.telemetry_slope << 8) & 0xff00) | (vol_table.telemetry_offset & 0xff);
       data->vddc_control = VEGA10_VOLTAGE_CONTROL_BY_SVID2;
     }
   } else {
     kfree(hwmgr->backend);
     hwmgr->backend = NULL;
     PP_ASSERT_WITH_CODE(false, "VDDCR_SOC is not SVID2!", return -1);
   }
   /* MVDDC */
   if (pp_atomfwctrl_is_voltage_controlled_by_gpio_v4(hwmgr, VOLTAGE_TYPE_MVDDC, VOLTAGE_OBJ_SVID2)) {
     if (!pp_atomfwctrl_get_voltage_table_v4(hwmgr, VOLTAGE_TYPE_MVDDC, VOLTAGE_OBJ_SVID2, &vol_table)) {
       config_telemetry |= ((vol_table.telemetry_slope << 24) & 0xff000000) | ((vol_table.telemetry_offset << 16) & 0xff0000);
       data->mvdd_control = VEGA10_VOLTAGE_CONTROL_BY_SVID2;
     }
   }
   /* VDDCI_MEM */
-  if (phm_cap_enabled(hwmgr->platform_descriptor.platformCaps, PHM_PlatformCaps_ControlVDDCI)) {
+  if (PP_CAP(PHM_PlatformCaps_ControlVDDCI)) {
     if (pp_atomfwctrl_is_voltage_controlled_by_gpio_v4(hwmgr, VOLTAGE_TYPE_VDDCI, VOLTAGE_OBJ_GPIO_LUT)) data->vddci_control = VEGA10_VOLTAGE_CONTROL_BY_GPIO;
   }
   data->config_telemetry = config_telemetry;
   vega10_set_features_platform_caps(hwmgr);
   vega10_init_dpm_defaults(hwmgr);
 #ifdef PPLIB_VEGA10_EVV_SUPPORT
   /* Get leakage voltage based on leakage ID. */
   PP_ASSERT_WITH_CODE(!vega10_get_evv_voltages(hwmgr), "Get EVV Voltage Failed.  Abort Driver loading!", return -1);
 #endif
   /* Patch our voltage dependency table with actual leakage voltage
    * We need to perform leakage translation before it's used by other functions
    */
   vega10_complete_dependency_tables(hwmgr);
   /* Parse pptable data read from VBIOS */
   vega10_set_private_data_based_on_pptable(hwmgr);
   data->is_tlu_enabled = false;
   hwmgr->platform_descriptor.hardwareActivityPerformanceLevels = VEGA10_MAX_HARDWARE_POWERLEVELS;
   hwmgr->platform_descriptor.hardwarePerformanceLevels = 2;
   hwmgr->platform_descriptor.minimumClocksReductionPercentage = 50;
   hwmgr->platform_descriptor.vbiosInterruptId = 0x20000400; /* IRQ_SOURCE1_SW_INT */
   /* The true clock step depends on the frequency, typically 4.5 or 9 MHz. Here we use 5. */
   hwmgr->platform_descriptor.clockStep.engineClock = 500;
   hwmgr->platform_descriptor.clockStep.memoryClock = 500;
   sys_info.size = sizeof(struct cgs_system_info);
   sys_info.info_id = CGS_SYSTEM_INFO_GFX_CU_INFO;
   result = cgs_query_system_info(hwmgr->device, &sys_info);
   data->total_active_cus = sys_info.value;
   /* Setup default Overdrive Fan control settings */
   data->odn_fan_table.target_fan_speed = hwmgr->thermal_controller.advanceFanControlParameters.usMaxFanRPM;
   data->odn_fan_table.target_temperature = hwmgr->thermal_controller.advanceFanControlParameters.ucTargetTemperature;
   data->odn_fan_table.min_performance_clock = hwmgr->thermal_controller.advanceFanControlParameters.ulMinFanSCLKAcousticLimit;
   data->odn_fan_table.min_fan_limit = hwmgr->thermal_controller.advanceFanControlParameters.usFanPWMMinLimit * hwmgr->thermal_controller.fanInfo.ulMaxRPM / 100;
   return result;
 }<sep>@@
expression hwmgr,e;
@@
- phm_cap_enabled(hwmgr->platform_descriptor.platformCaps,e)
+ PP_CAP(e)