lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CALY79ryLY=xB7V_2vVi7rafxudOkhr4misKLU5uVEvCAJB7zuw@mail.gmail.com>
Date: Mon, 13 Jan 2025 11:57:53 +0000
From: Oxana Kharitonova <oxana@...udflare.com>
To: Andrew Morton <akpm@...ux-foundation.org>
Cc: brauner@...nel.org, bsegall@...gle.com, dietmar.eggemann@....com, 
	jack@...e.cz, juri.lelli@...hat.com, mgorman@...e.de, mingo@...hat.com, 
	peterz@...radead.org, rostedt@...dmis.org, vincent.guittot@...aro.org, 
	viro@...iv.linux.org.uk, vschneid@...hat.com, kernel-team@...udflare.com, 
	linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH resend] hung_task: add task->flags, blocked by coredump to log

On Sat, Jan 11, 2025 at 3:54 AM Andrew Morton <akpm@...ux-foundation.org> wrote:
>
> I added the below fix.
>

Thank you for taking care of the patch and adding the fix!

>
> From: Andrew Morton <akpm@...ux-foundation.org>
> Subject: hung_task-add-task-flags-blocked-by-coredump-to-log-fix
> Date: Fri Jan 10 07:51:53 PM PST 2025
>
> fix printk control string
>
> In file included from ./include/asm-generic/bug.h:22,
>                  from ./arch/x86/include/asm/bug.h:99,
>                  from ./include/linux/bug.h:5,
>                  from ./arch/x86/include/asm/paravirt.h:19,
>                  from ./arch/x86/include/asm/irqflags.h:80,
>                  from ./include/linux/irqflags.h:18,
>                  from ./include/linux/spinlock.h:59,
>                  from ./include/linux/wait.h:9,
>                  from ./include/linux/wait_bit.h:8,
>                  from ./include/linux/fs.h:6,
>                  from ./include/linux/highmem.h:5,
>                  from kernel/sched/core.c:10:
> kernel/sched/core.c: In function 'sched_show_task':
> ./include/linux/kern_levels.h:5:25: error: format '%lx' expects argument of type 'long unsigned int', but argument 6 has type 'unsigned int' [-Werror=format=]
>     5 | #define KERN_SOH        "\001"          /* ASCII Start Of Header */
>       |                         ^~~~~~
> ./include/linux/printk.h:473:25: note: in definition of macro 'printk_index_wrap'
>   473 |                 _p_func(_fmt, ##__VA_ARGS__);                           \
>       |                         ^~~~
> ./include/linux/printk.h:586:9: note: in expansion of macro 'printk'
>   586 |         printk(KERN_CONT fmt, ##__VA_ARGS__)
>       |         ^~~~~~
> ./include/linux/kern_levels.h:24:25: note: in expansion of macro 'KERN_SOH'
>    24 | #define KERN_CONT       KERN_SOH "c"
>       |                         ^~~~~~~~
> ./include/linux/printk.h:586:16: note: in expansion of macro 'KERN_CONT'
>   586 |         printk(KERN_CONT fmt, ##__VA_ARGS__)
>       |                ^~~~~~~~~
> kernel/sched/core.c:7704:9: note: in expansion of macro 'pr_cont'
>  7704 |         pr_cont(" stack:%-5lu pid:%-5d tgid:%-5d ppid:%-6d task_flags:0x%08lx flags:0x%08lx\n",
>       |         ^~~~~~~
> cc1: all warnings being treated as errors
>
> Cc: Al Viro <viro@...iv.linux.org.uk>
> Cc: Ben Segall <bsegall@...gle.com>
> Cc: Christian Brauner <brauner@...nel.org>
> Cc: Dietmar Eggemann <dietmar.eggemann@....com>
> Cc: Ingo Molnar <mingo@...hat.com>
> Cc: Jan Kara <jack@...e.cz>
> Cc: Juri Lelli <juri.lelli@...hat.com>
> Cc: Mel Gorman <mgorman@...e.de>
> Cc: Oxana Kharitonova <oxana@...udflare.com>
> Cc: Peter Zijlstra (Intel) <peterz@...radead.org>
> Cc: Steven Rostedt <rostedt@...dmis.org>
> Cc: Valentin Schneider <vschneid@...hat.com>
> Cc: Vincent Guittot <vincent.guittot@...aro.org>
> Signed-off-by: Andrew Morton <akpm@...ux-foundation.org>
> ---
>
>  kernel/sched/core.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> --- a/kernel/sched/core.c~hung_task-add-task-flags-blocked-by-coredump-to-log-fix
> +++ a/kernel/sched/core.c
> @@ -7701,7 +7701,7 @@ void sched_show_task(struct task_struct
>         if (pid_alive(p))
>                 ppid = task_pid_nr(rcu_dereference(p->real_parent));
>         rcu_read_unlock();
> -       pr_cont(" stack:%-5lu pid:%-5d tgid:%-5d ppid:%-6d task_flags:0x%08lx flags:0x%08lx\n",
> +       pr_cont(" stack:%-5lu pid:%-5d tgid:%-5d ppid:%-6d task_flags:0x%04x flags:0x%08lx\n",
>                 free, task_pid_nr(p), task_tgid_nr(p),
>                 ppid, p->flags, read_task_thread_flags(p));
>
> _
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ