Re: [PATCH 2/4] drm: amd: Fix line continuation formats

2017-11-17 Thread Alex Deucher
On Thu, Nov 16, 2017 at 10:50 AM, Joe Perches  wrote:
> On Thu, 2017-11-16 at 10:38 -0500, Harry Wentland wrote:
>> On 2017-11-16 10:27 AM, Joe Perches wrote:
>> > Line continuations with excess spacing causes unexpected output.
> []
>> > @@ -872,9 +870,8 @@ static bool perform_clock_recovery_sequence(
>> > if (retry_count >= LINK_TRAINING_MAX_CR_RETRY) {
>> > ASSERT(0);
>> > dm_logger_write(link->ctx->logger, LOG_ERROR,
>> > -   "%s: Link Training Error, could not \
>> > -get CR after %d tries. \
>> > -   Possibly voltage swing issue", __func__,
>> > +   "%s: Link Training Error, could not get CR after %d 
>> > tries. Possibly voltage swing issue",
>>
>> Would probably be good to add a '\n' here as well but that's not the main 
>> intention of this patch.
>
> About 1/4 of the dm_logger_write calls are missing
> newlines and I think it should be a separate patch.
>
> I encourage you to fix them one day.
>
>> Reviewed-by: Harry Wentland 
>
> cheers, Joe

Applied.  Thanks!

Alex
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx


[PATCH 2/4] drm: amd: Fix line continuation formats

2017-11-16 Thread Joe Perches
Line continuations with excess spacing causes unexpected output.

Miscellanea:

o Added missing '\n' to a few of the coalesced pr_ formats

Signed-off-by: Joe Perches 
---
 drivers/gpu/drm/amd/display/dc/core/dc_link_dp.c   | 11 -
 .../amd/powerplay/hwmgr/process_pptables_v1_0.c|  6 ++---
 drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c | 27 --
 drivers/gpu/drm/amd/powerplay/smumgr/ci_smumgr.c   |  6 ++---
 .../gpu/drm/amd/powerplay/smumgr/iceland_smumgr.c  |  9 +++-
 .../gpu/drm/amd/powerplay/smumgr/vega10_smumgr.c   |  6 ++---
 6 files changed, 22 insertions(+), 43 deletions(-)

diff --git a/drivers/gpu/drm/amd/display/dc/core/dc_link_dp.c 
b/drivers/gpu/drm/amd/display/dc/core/dc_link_dp.c
index ced42484dcfc..6743786afcce 100644
--- a/drivers/gpu/drm/amd/display/dc/core/dc_link_dp.c
+++ b/drivers/gpu/drm/amd/display/dc/core/dc_link_dp.c
@@ -220,8 +220,7 @@ static void dpcd_set_lt_pattern_and_lane_settings(
size_in_bytes);
 
dm_logger_write(link->ctx->logger, LOG_HW_LINK_TRAINING,
-   "%s:\n %x VS set = %x  PE set = %x \
-   max VS Reached = %x  max PE Reached = %x\n",
+   "%s:\n %x VS set = %x  PE set = %x max VS Reached = %x  max PE 
Reached = %x\n",
__func__,
DP_TRAINING_LANE0_SET,
dpcd_lane[0].bits.VOLTAGE_SWING_SET,
@@ -558,8 +557,7 @@ static void dpcd_set_lane_settings(
*/
 
dm_logger_write(link->ctx->logger, LOG_HW_LINK_TRAINING,
-   "%s\n %x VS set = %x  PE set = %x \
-   max VS Reached = %x  max PE Reached = %x\n",
+   "%s\n %x VS set = %x  PE set = %x max VS Reached = %x  max PE 
Reached = %x\n",
__func__,
DP_TRAINING_LANE0_SET,
dpcd_lane[0].bits.VOLTAGE_SWING_SET,
@@ -872,9 +870,8 @@ static bool perform_clock_recovery_sequence(
if (retry_count >= LINK_TRAINING_MAX_CR_RETRY) {
ASSERT(0);
dm_logger_write(link->ctx->logger, LOG_ERROR,
-   "%s: Link Training Error, could not \
-get CR after %d tries. \
-   Possibly voltage swing issue", __func__,
+   "%s: Link Training Error, could not get CR after %d 
tries. Possibly voltage swing issue",
+   __func__,
LINK_TRAINING_MAX_CR_RETRY);
 
}
diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/process_pptables_v1_0.c 
b/drivers/gpu/drm/amd/powerplay/hwmgr/process_pptables_v1_0.c
index d1af1483c69b..813f827e4270 100644
--- a/drivers/gpu/drm/amd/powerplay/hwmgr/process_pptables_v1_0.c
+++ b/drivers/gpu/drm/amd/powerplay/hwmgr/process_pptables_v1_0.c
@@ -523,8 +523,7 @@ static int get_pcie_table(
if ((uint32_t)atom_pcie_table->ucNumEntries <= pcie_count)
pcie_count = (uint32_t)atom_pcie_table->ucNumEntries;
else
-   pr_err("Number of Pcie Entries exceed the number of 
SCLK Dpm Levels! \
-   Disregarding the excess entries... \n");
+   pr_err("Number of Pcie Entries exceed the number of 
SCLK Dpm Levels! Disregarding the excess entries...\n");
 
pcie_table->count = pcie_count;
for (i = 0; i < pcie_count; i++) {
@@ -563,8 +562,7 @@ static int get_pcie_table(
if ((uint32_t)atom_pcie_table->ucNumEntries <= pcie_count)
pcie_count = (uint32_t)atom_pcie_table->ucNumEntries;
else
-   pr_err("Number of Pcie Entries exceed the number of 
SCLK Dpm Levels! \
-   Disregarding the excess entries... \n");
+   pr_err("Number of Pcie Entries exceed the number of 
SCLK Dpm Levels! Disregarding the excess entries...\n");
 
pcie_table->count = pcie_count;
 
diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c 
b/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c
index 4f79c21f27ed..9599fe0ba779 100644
--- a/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c
+++ b/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c
@@ -546,8 +546,7 @@ static void vega10_patch_with_vdd_leakage(struct pp_hwmgr 
*hwmgr,
}
 
if (*voltage > ATOM_VIRTUAL_VOLTAGE_ID0)
-   pr_info("Voltage value looks like a Leakage ID \
-   but it's not patched\n");
+   pr_info("Voltage value looks like a Leakage ID but it's not 
patched\n");
 }
 
 /**
@@ -701,18 +700,14 @@ static int 
vega10_set_private_data_based_on_pptable(struct pp_hwmgr *hwmgr)
table_info->vdd_dep_on_mclk;
 
PP_ASSERT_WITH_CODE(allowed_sclk_vdd_table,
-   "VDD dependency on SCLK table is missing. \
-   This table is mandatory", return -EINVAL);
+   "VDD dependency on SCLK table is missing. This 

Re: [PATCH 2/4] drm: amd: Fix line continuation formats

2017-11-16 Thread Joe Perches
On Thu, 2017-11-16 at 10:38 -0500, Harry Wentland wrote:
> On 2017-11-16 10:27 AM, Joe Perches wrote:
> > Line continuations with excess spacing causes unexpected output.
[]
> > @@ -872,9 +870,8 @@ static bool perform_clock_recovery_sequence(
> > if (retry_count >= LINK_TRAINING_MAX_CR_RETRY) {
> > ASSERT(0);
> > dm_logger_write(link->ctx->logger, LOG_ERROR,
> > -   "%s: Link Training Error, could not \
> > -get CR after %d tries. \
> > -   Possibly voltage swing issue", __func__,
> > +   "%s: Link Training Error, could not get CR after %d 
> > tries. Possibly voltage swing issue",
> 
> Would probably be good to add a '\n' here as well but that's not the main 
> intention of this patch.

About 1/4 of the dm_logger_write calls are missing
newlines and I think it should be a separate patch.

I encourage you to fix them one day.

> Reviewed-by: Harry Wentland 

cheers, Joe
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx