OSDN Git Service

drm/amd/pm: Clean up errors in aldebaran_ppt.c
authorRan Sun <sunran001@208suo.com>
Tue, 1 Aug 2023 02:00:52 +0000 (02:00 +0000)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 9 Aug 2023 13:40:08 +0000 (09:40 -0400)
Fix the following errors reported by checkpatch:

ERROR: that open brace { should be on the previous line
ERROR: space required after that ',' (ctx:VxV)
ERROR: spaces required around that '=' (ctx:VxW)
ERROR: else should follow close brace '}'

Signed-off-by: Ran Sun <sunran001@208suo.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/pm/swsmu/smu13/aldebaran_ppt.c

index ce50ef4..8f26123 100644 (file)
@@ -94,8 +94,7 @@
  */
 #define SUPPORT_BAD_CHANNEL_INFO_MSG_VERSION 0x00443300
 
-static const struct smu_temperature_range smu13_thermal_policy[] =
-{
+static const struct smu_temperature_range smu13_thermal_policy[] = {
        {-273150,  99000, 99000, -273150, 99000, 99000, -273150, 99000, 99000},
        { 120000, 120000, 120000, 120000, 120000, 120000, 120000, 120000, 120000},
 };
@@ -196,7 +195,7 @@ static const struct cmn2asic_mapping aldebaran_feature_mask_map[SMU_FEATURE_COUN
        ALDEBARAN_FEA_MAP(SMU_FEATURE_FW_CTF_BIT,                               FEATURE_FW_CTF_BIT),
        ALDEBARAN_FEA_MAP(SMU_FEATURE_THERMAL_BIT,                              FEATURE_THERMAL_BIT),
        ALDEBARAN_FEA_MAP(SMU_FEATURE_OUT_OF_BAND_MONITOR_BIT,  FEATURE_OUT_OF_BAND_MONITOR_BIT),
-       ALDEBARAN_FEA_MAP(SMU_FEATURE_XGMI_PER_LINK_PWR_DWN_BIT,FEATURE_XGMI_PER_LINK_PWR_DWN),
+       ALDEBARAN_FEA_MAP(SMU_FEATURE_XGMI_PER_LINK_PWR_DWN_BIT, FEATURE_XGMI_PER_LINK_PWR_DWN),
        ALDEBARAN_FEA_MAP(SMU_FEATURE_DF_CSTATE_BIT,                    FEATURE_DF_CSTATE),
 };
 
@@ -580,7 +579,7 @@ static int aldebaran_get_smu_metrics_data(struct smu_context *smu,
                                          MetricsMember_t member,
                                          uint32_t *value)
 {
-       struct smu_table_context *smu_table= &smu->smu_table;
+       struct smu_table_context *smu_table = &smu->smu_table;
        SmuMetrics_t *metrics = (SmuMetrics_t *)smu_table->metrics_table;
        int ret = 0;
 
@@ -1906,8 +1905,7 @@ static int aldebaran_mode1_reset(struct smu_context *smu)
        smu_cmn_get_smc_version(smu, NULL, &smu_version);
        if (smu_version < 0x00440700) {
                ret = smu_cmn_send_smc_msg(smu, SMU_MSG_Mode1Reset, NULL);
-       }
-       else {
+       } else {
                /* fatal error triggered by ras, PMFW supports the flag
                   from 68.44.0 */
                if ((smu_version >= 0x00442c00) && ras &&
@@ -2116,7 +2114,7 @@ static const struct pptable_funcs aldebaran_ppt_funcs = {
        .register_irq_handler = smu_v13_0_register_irq_handler,
        .set_azalia_d3_pme = smu_v13_0_set_azalia_d3_pme,
        .get_max_sustainable_clocks_by_dc = smu_v13_0_get_max_sustainable_clocks_by_dc,
-       .baco_is_support= aldebaran_is_baco_supported,
+       .baco_is_support = aldebaran_is_baco_supported,
        .get_dpm_ultimate_freq = smu_v13_0_get_dpm_ultimate_freq,
        .set_soft_freq_limited_range = aldebaran_set_soft_freq_limited_range,
        .od_edit_dpm_table = aldebaran_usr_edit_dpm_table,