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]
Message-ID: <20140210144609.GX25953@redhat.com>
Date:	Mon, 10 Feb 2014 09:46:09 -0500
From:	Don Zickus <dzickus@...hat.com>
To:	Frederic Weisbecker <fweisbec@...il.com>
Cc:	LKML <linux-kernel@...r.kernel.org>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Christoph Hellwig <hch@...radead.org>,
	Ingo Molnar <mingo@...nel.org>, Jan Kara <jack@...e.cz>,
	Jens Axboe <jens.axboe@...cle.com>,
	Michal Hocko <mhocko@...e.cz>,
	"Srivatsa S. Bhat" <srivatsa.bhat@...ux.vnet.ibm.com>
Subject: Re: [PATCH 09/11] watchdog: Simplify a little the IPI call

On Sat, Feb 08, 2014 at 05:18:38PM +0100, Frederic Weisbecker wrote:
> In order to remotely restart the watchdog hrtimer, update_timers()
> allocates a csd on the stack and pass it to __smp_call_function_single().
> 
> There is no partcular need, however, for a specific csd here. Lets
> simplify that a little by calling smp_call_function_single()
> which can already take care of the csd allocation by itself.

Sounds simple enough.

Acked-by: Don Zickus <dzickus@...hat.com>

> 
> Cc: Andrew Morton <akpm@...ux-foundation.org>
> Cc: Christoph Hellwig <hch@...radead.org>
> Cc: Don Zickus <dzickus@...hat.com>
> Cc: Ingo Molnar <mingo@...nel.org>
> Cc: Jan Kara <jack@...e.cz>
> Cc: Jens Axboe <jens.axboe@...cle.com>
> Cc: Michal Hocko <mhocko@...e.cz>
> Cc: Srivatsa S. Bhat <srivatsa.bhat@...ux.vnet.ibm.com>
> Signed-off-by: Frederic Weisbecker <fweisbec@...il.com>
> ---
>  kernel/watchdog.c | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/kernel/watchdog.c b/kernel/watchdog.c
> index 4431610..01c6f97 100644
> --- a/kernel/watchdog.c
> +++ b/kernel/watchdog.c
> @@ -505,7 +505,6 @@ static void restart_watchdog_hrtimer(void *info)
>  
>  static void update_timers(int cpu)
>  {
> -	struct call_single_data data = {.func = restart_watchdog_hrtimer};
>  	/*
>  	 * Make sure that perf event counter will adopt to a new
>  	 * sampling period. Updating the sampling period directly would
> @@ -515,7 +514,7 @@ static void update_timers(int cpu)
>  	 * might be late already so we have to restart the timer as well.
>  	 */
>  	watchdog_nmi_disable(cpu);
> -	__smp_call_function_single(cpu, &data, 1);
> +	smp_call_function_single(cpu, restart_watchdog_hrtimer, NULL, 1);
>  	watchdog_nmi_enable(cpu);
>  }
>  
> -- 
> 1.8.3.1
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ