All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ddr: altera: use KBUILD_BASENAME instead of __FILE__
@ 2021-09-14  3:20 Marek Vasut
  2021-09-23  1:55 ` Chee, Tien Fong
  0 siblings, 1 reply; 2+ messages in thread
From: Marek Vasut @ 2021-09-14  3:20 UTC (permalink / raw)
  To: u-boot; +Cc: Marek Vasut, Siew Chin Lim, Simon Goldschmidt, Tien Fong Chee

The KBUILD_BASENAME contains just the name of the compiled module,
in this case 'sequencer', rather than a full path to the compiled
file. Use it to prevent pulling the full path into the U-Boot binary,
which is useless and annoying.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Siew Chin Lim <elly.siew.chin.lim@intel.com>
Cc: Simon Goldschmidt <simon.k.r.goldschmidt@gmail.com>
Cc: Tien Fong Chee <tien.fong.chee@intel.com>
---
 drivers/ddr/altera/sequencer.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/ddr/altera/sequencer.c b/drivers/ddr/altera/sequencer.c
index 6b9b2e90943..8a016f0628f 100644
--- a/drivers/ddr/altera/sequencer.c
+++ b/drivers/ddr/altera/sequencer.c
@@ -3714,7 +3714,7 @@ static void debug_mem_calibrate(struct socfpga_sdrseq *seq, int pass)
 	u32 debug_info;
 
 	if (pass) {
-		debug("%s: CALIBRATION PASSED\n", __FILE__);
+		debug(KBUILD_BASENAME ": CALIBRATION PASSED\n");
 
 		seq->gbl.fom_in /= 2;
 		seq->gbl.fom_out /= 2;
@@ -3733,7 +3733,7 @@ static void debug_mem_calibrate(struct socfpga_sdrseq *seq, int pass)
 		writel(debug_info, &phy_mgr_cfg->cal_debug_info);
 		writel(PHY_MGR_CAL_SUCCESS, &phy_mgr_cfg->cal_status);
 	} else {
-		debug("%s: CALIBRATION FAILED\n", __FILE__);
+		debug(KBUILD_BASENAME ": CALIBRATION FAILED\n");
 
 		debug_info = seq->gbl.error_stage;
 		debug_info |= seq->gbl.error_substage << 8;
@@ -3750,7 +3750,7 @@ static void debug_mem_calibrate(struct socfpga_sdrseq *seq, int pass)
 		writel(debug_info, &sdr_reg_file->failing_stage);
 	}
 
-	debug("%s: Calibration complete\n", __FILE__);
+	debug(KBUILD_BASENAME ": Calibration complete\n");
 }
 
 /**
@@ -3934,7 +3934,7 @@ int sdram_calibration_full(struct socfpga_sdr *sdr)
 
 	initialize_tracking(&seq);
 
-	debug("%s: Preparing to start memory calibration\n", __FILE__);
+	debug(KBUILD_BASENAME ": Preparing to start memory calibration\n");
 
 	debug("%s:%d\n", __func__, __LINE__);
 	debug_cond(DLEVEL >= 1,
-- 
2.33.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* RE: [PATCH] ddr: altera: use KBUILD_BASENAME instead of __FILE__
  2021-09-14  3:20 [PATCH] ddr: altera: use KBUILD_BASENAME instead of __FILE__ Marek Vasut
@ 2021-09-23  1:55 ` Chee, Tien Fong
  0 siblings, 0 replies; 2+ messages in thread
From: Chee, Tien Fong @ 2021-09-23  1:55 UTC (permalink / raw)
  To: Marek Vasut, u-boot; +Cc: Lim, Elly Siew Chin, Simon Goldschmidt

> -----Original Message-----
> From: Marek Vasut <marex@denx.de>
> Sent: Tuesday, 14 September, 2021 11:20 AM
> To: u-boot@lists.denx.de
> Cc: Marek Vasut <marex@denx.de>; Lim, Elly Siew Chin
> <elly.siew.chin.lim@intel.com>; Simon Goldschmidt
> <simon.k.r.goldschmidt@gmail.com>; Chee, Tien Fong
> <tien.fong.chee@intel.com>
> Subject: [PATCH] ddr: altera: use KBUILD_BASENAME instead of __FILE__
> 
> The KBUILD_BASENAME contains just the name of the compiled module, in this
> case 'sequencer', rather than a full path to the compiled file. Use it to prevent
> pulling the full path into the U-Boot binary, which is useless and annoying.
> 
> Signed-off-by: Marek Vasut <marex@denx.de>
> Cc: Siew Chin Lim <elly.siew.chin.lim@intel.com>
> Cc: Simon Goldschmidt <simon.k.r.goldschmidt@gmail.com>
> Cc: Tien Fong Chee <tien.fong.chee@intel.com>
> ---
>  drivers/ddr/altera/sequencer.c | 8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)
> 

Reviewed-by: Tien Fong Chee <tien.fong.chee@intel.com>

Regards,
TF

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-09-23  1:56 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-14  3:20 [PATCH] ddr: altera: use KBUILD_BASENAME instead of __FILE__ Marek Vasut
2021-09-23  1:55 ` Chee, Tien Fong

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.