Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

s390/dasd: Remove PRINTK_HEADER and KMSG_COMPONENT definitions

PRINTK_HEADER was mainly used to prefix log messages with the module
name. Most components don't use this definition anymore. Either because
there are no log messages being generated anymore, or pr_*() were
replaced by dev_*(), which contains device and component information
already.

PRINTK_HEADER is also dropped in the function
dasd_3990_erp_handle_match_erp() in dasd_3990_erp.c from a panic() call
as panic() already provides all relevant information.

KMSG_COMPONENT was mainly used to identify a component in a long gone
kernel message catalog feature.

Remove both definition since they're either not used or alternatives
make the code slightly shorter and more readable.

Signed-off-by: Jan Höppner <hoeppner@linux.ibm.com>
Reviewed-by: Stefan Haberland <sth@linux.ibm.com>
Signed-off-by: Stefan Haberland <sth@linux.ibm.com>
Link: https://lore.kernel.org/r/20240208164248.540985-9-sth@linux.ibm.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>

authored by

Jan Höppner and committed by
Jens Axboe
c6c6c69d 4ba6366d

+1 -55
-3
drivers/s390/block/dasd.c
··· 30 30 #include <asm/itcw.h> 31 31 #include <asm/diag.h> 32 32 33 - /* This is ugly... */ 34 - #define PRINTK_HEADER "dasd:" 35 - 36 33 #include "dasd_int.h" 37 34 /* 38 35 * SECTION: Constant definitions to be used within this file
+1 -6
drivers/s390/block/dasd_3990_erp.c
··· 7 7 * 8 8 */ 9 9 10 - #define KMSG_COMPONENT "dasd-eckd" 11 - 12 10 #include <linux/timer.h> 13 11 #include <asm/idals.h> 14 - 15 - #define PRINTK_HEADER "dasd_erp(3990): " 16 12 17 13 #include "dasd_int.h" 18 14 #include "dasd_eckd.h" ··· 2696 2700 while (erp_done != erp) { 2697 2701 2698 2702 if (erp_done == NULL) /* end of chain reached */ 2699 - panic(PRINTK_HEADER "Programming error in ERP! The " 2700 - "original request was lost\n"); 2703 + panic("Programming error in ERP! The original request was lost\n"); 2701 2704 2702 2705 /* remove the request from the device queue */ 2703 2706 list_del(&erp_done->blocklist);
-8
drivers/s390/block/dasd_alias.c
··· 6 6 * Author(s): Stefan Weinhuber <wein@de.ibm.com> 7 7 */ 8 8 9 - #define KMSG_COMPONENT "dasd-eckd" 10 - 11 9 #include <linux/list.h> 12 10 #include <linux/slab.h> 13 11 #include <asm/ebcdic.h> 14 12 #include "dasd_int.h" 15 13 #include "dasd_eckd.h" 16 - 17 - #ifdef PRINTK_HEADER 18 - #undef PRINTK_HEADER 19 - #endif /* PRINTK_HEADER */ 20 - #define PRINTK_HEADER "dasd(eckd):" 21 - 22 14 23 15 /* 24 16 * General concept of alias management:
-4
drivers/s390/block/dasd_devmap.c
··· 13 13 * 14 14 */ 15 15 16 - #define KMSG_COMPONENT "dasd" 17 - 18 16 #include <linux/ctype.h> 19 17 #include <linux/init.h> 20 18 #include <linux/module.h> ··· 22 24 #include <linux/uaccess.h> 23 25 #include <asm/ipl.h> 24 26 25 - /* This is ugly... */ 26 - #define PRINTK_HEADER "dasd_devmap:" 27 27 #define DASD_MAX_PARAMS 256 28 28 29 29 #include "dasd_int.h"
-4
drivers/s390/block/dasd_diag.c
··· 8 8 * 9 9 */ 10 10 11 - #define KMSG_COMPONENT "dasd" 12 - 13 11 #include <linux/kernel_stat.h> 14 12 #include <linux/stddef.h> 15 13 #include <linux/kernel.h> ··· 28 30 29 31 #include "dasd_int.h" 30 32 #include "dasd_diag.h" 31 - 32 - #define PRINTK_HEADER "dasd(diag):" 33 33 34 34 MODULE_LICENSE("GPL"); 35 35
-2
drivers/s390/block/dasd_eckd.c
··· 10 10 * Author.........: Nigel Hislop <hislop_nigel@emc.com> 11 11 */ 12 12 13 - #define KMSG_COMPONENT "dasd-eckd" 14 - 15 13 #include <linux/stddef.h> 16 14 #include <linux/kernel.h> 17 15 #include <linux/slab.h>
-7
drivers/s390/block/dasd_eer.c
··· 7 7 * Author(s): Stefan Weinhuber <wein@de.ibm.com> 8 8 */ 9 9 10 - #define KMSG_COMPONENT "dasd-eckd" 11 - 12 10 #include <linux/init.h> 13 11 #include <linux/fs.h> 14 12 #include <linux/kernel.h> ··· 25 27 26 28 #include "dasd_int.h" 27 29 #include "dasd_eckd.h" 28 - 29 - #ifdef PRINTK_HEADER 30 - #undef PRINTK_HEADER 31 - #endif /* PRINTK_HEADER */ 32 - #define PRINTK_HEADER "dasd(eer):" 33 30 34 31 /* 35 32 * SECTION: the internal buffer
-5
drivers/s390/block/dasd_erp.c
··· 9 9 * 10 10 */ 11 11 12 - #define KMSG_COMPONENT "dasd" 13 - 14 12 #include <linux/ctype.h> 15 13 #include <linux/init.h> 16 14 17 15 #include <asm/debug.h> 18 16 #include <asm/ebcdic.h> 19 17 #include <linux/uaccess.h> 20 - 21 - /* This is ugly... */ 22 - #define PRINTK_HEADER "dasd_erp:" 23 18 24 19 #include "dasd_int.h" 25 20
-5
drivers/s390/block/dasd_genhd.c
··· 11 11 * 12 12 */ 13 13 14 - #define KMSG_COMPONENT "dasd" 15 - 16 14 #include <linux/interrupt.h> 17 15 #include <linux/major.h> 18 16 #include <linux/fs.h> 19 17 #include <linux/blkpg.h> 20 18 21 19 #include <linux/uaccess.h> 22 - 23 - /* This is ugly... */ 24 - #define PRINTK_HEADER "dasd_gendisk:" 25 20 26 21 #include "dasd_int.h" 27 22
-6
drivers/s390/block/dasd_ioctl.c
··· 10 10 * i/o controls for the dasd driver. 11 11 */ 12 12 13 - #define KMSG_COMPONENT "dasd" 14 - 15 13 #include <linux/interrupt.h> 16 14 #include <linux/compat.h> 17 15 #include <linux/major.h> ··· 22 24 #include <linux/uaccess.h> 23 25 #include <linux/dasd_mod.h> 24 26 25 - /* This is ugly... */ 26 - #define PRINTK_HEADER "dasd_ioctl:" 27 - 28 27 #include "dasd_int.h" 29 - 30 28 31 29 static int 32 30 dasd_ioctl_api_version(void __user *argp)
-5
drivers/s390/block/dasd_proc.c
··· 11 11 * 12 12 */ 13 13 14 - #define KMSG_COMPONENT "dasd" 15 - 16 14 #include <linux/ctype.h> 17 15 #include <linux/slab.h> 18 16 #include <linux/string.h> ··· 20 22 21 23 #include <asm/debug.h> 22 24 #include <linux/uaccess.h> 23 - 24 - /* This is ugly... */ 25 - #define PRINTK_HEADER "dasd_proc:" 26 25 27 26 #include "dasd_int.h" 28 27