]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
scsi: mvsas: Don't emit __LINE__ in debug messages
authorUwe Kleine-König (The Capable Hub) <u.kleine-koenig@baylibre.com>
Mon, 27 Apr 2026 17:45:46 +0000 (19:45 +0200)
committerMartin K. Petersen <martin.petersen@oracle.com>
Fri, 15 May 2026 02:04:50 +0000 (22:04 -0400)
__LINE__ changes quite easily for cleanup commits. So when checking if a
cleanup patch introduces changes to the resulting binary each usage of
__LINE__ is source of annoyance.

So instead of __FILE__ and __LINE__ emit __func__ to give at least some
more indication about where the messages originates from than __FILE__
alone; with that and the actual message the situation should be clear
enough.

While at it reduce duplication by implementing mv_dprintk() using
mv_printk().

Signed-off-by: Uwe Kleine-König (The Capable Hub) <u.kleine-koenig@baylibre.com>
Link: https://patch.msgid.link/20260427174545.2014499-2-u.kleine-koenig@baylibre.com
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/mvsas/mv_sas.h

index 09ce3f2241f2406c4956f01aa71faf7c677059a4..7521f969aa87da33beab60f9a0ff82095abab17f 100644 (file)
 #define MVS_ID_NOT_MAPPED      0x7f
 #define WIDE_PORT_MAX_PHY              4
 #define mv_printk(fmt, arg ...)        \
-       printk(KERN_DEBUG"%s %d:" fmt, __FILE__, __LINE__, ## arg)
+       printk(KERN_DEBUG "%s: " fmt, __func__, ## arg)
 #ifdef MV_DEBUG
-#define mv_dprintk(format, arg...)     \
-       printk(KERN_DEBUG"%s %d:" format, __FILE__, __LINE__, ## arg)
+#define mv_dprintk(fmt, arg...)        \
+       mv_printk(fmt, ## arg)
 #else
 #define mv_dprintk(format, arg...) no_printk(format, ## arg)
 #endif