]> www.infradead.org Git - users/dwmw2/linux.git/commitdiff
s390/boot: Make boot_printk() return int
authorVasily Gorbik <gor@linux.ibm.com>
Wed, 20 Nov 2024 19:36:46 +0000 (20:36 +0100)
committerAlexander Gordeev <agordeev@linux.ibm.com>
Sun, 26 Jan 2025 16:24:01 +0000 (17:24 +0100)
Modify boot_printk() to return int, aligning it with printk().

Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
Acked-by: Heiko Carstens <hca@linux.ibm.com>
Signed-off-by: Alexander Gordeev <agordeev@linux.ibm.com>
arch/s390/boot/boot.h
arch/s390/boot/printk.c

index 80e86387bee55c2ee0723cceea2b7bc0093edd4b..dbfba6822d6fdcf9b2457e3f5841ff53fef5fdd6 100644 (file)
@@ -72,7 +72,7 @@ void print_pgm_check_info(void);
 unsigned long randomize_within_range(unsigned long size, unsigned long align,
                                     unsigned long min, unsigned long max);
 void setup_vmem(unsigned long kernel_start, unsigned long kernel_end, unsigned long asce_limit);
-void __printf(1, 2) boot_printk(const char *fmt, ...);
+int __printf(1, 2) boot_printk(const char *fmt, ...);
 void print_stacktrace(unsigned long sp);
 void error(char *m);
 int get_random(unsigned long limit, unsigned long *value);
index e49a9be6d555ec37d52d783b2bf047c074ceab58..311fb45c097c5ec9471708981077fbc440a1f2a9 100644 (file)
@@ -174,7 +174,7 @@ static void boot_console_earlyprintk(const char *buf)
         (lenmod == 'z') ? va_arg(args, typemod long) :                 \
                           va_arg(args, typemod int))
 
-void boot_printk(const char *fmt, ...)
+int boot_printk(const char *fmt, ...)
 {
        char buf[1024] = { 0 };
        char *end = buf + sizeof(buf) - 1; /* make sure buf is 0 terminated */
@@ -248,4 +248,5 @@ out:
                boot_rb_add(buf, len);
                boot_console_earlyprintk(buf);
        }
+       return len;
 }