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] [thread-next>] [day] [month] [year] [list]
Date:   Fri, 21 Aug 2020 08:54:13 +0200
From:   peterz@...radead.org
To:     Marco Elver <elver@...gle.com>
Cc:     Steven Rostedt <rostedt@...dmis.org>, linux-kernel@...r.kernel.org,
        mingo@...nel.org, will@...nel.org, npiggin@...il.com,
        jgross@...e.com, paulmck@...nel.org, rjw@...ysocki.net,
        joel@...lfernandes.org, svens@...ux.ibm.com, tglx@...utronix.de
Subject: Re: [PATCH 0/9] TRACE_IRQFLAGS wreckage

On Thu, Aug 20, 2020 at 07:20:46PM +0200, Marco Elver wrote:
> From 4ec9dd472c978e1eba622fb22bc04e4357f10421 Mon Sep 17 00:00:00 2001
> From: Marco Elver <elver@...gle.com>
> Date: Thu, 20 Aug 2020 19:06:09 +0200
> Subject: [PATCH] sched: Turn inline into __always_inline due to noinstr use
> 
> is_idle_task() may be used from noinstr functions such as
> irqentry_enter(). Since the compiler is free to not inline regular
> inline functions, switch to using __always_inline.
> 
> Signed-off-by: Marco Elver <elver@...gle.com>

Fair enough I suppose; didn't that generate an objtool warning on your
build? (of course that requires PARAVIRT=n, I should get back to fixing
that)

> ---
>  include/linux/sched.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/include/linux/sched.h b/include/linux/sched.h
> index 93ecd930efd3..afe01e232935 100644
> --- a/include/linux/sched.h
> +++ b/include/linux/sched.h
> @@ -1666,7 +1666,7 @@ extern struct task_struct *idle_task(int cpu);
>   *
>   * Return: 1 if @p is an idle task. 0 otherwise.
>   */
> -static inline bool is_idle_task(const struct task_struct *p)
> +static __always_inline bool is_idle_task(const struct task_struct *p)
>  {
>  	return !!(p->flags & PF_IDLE);
>  }
> -- 
> 2.28.0.297.g1956fa8f8d-goog

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ