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:	Tue, 30 Aug 2011 12:30:36 -0700
From:	Joe Perches <joe@...ches.com>
To:	Richard Kuo <rkuo@...eaurora.org>
Cc:	linux-kernel@...r.kernel.org, linux-hexagon@...r.kernel.org
Subject: Re: [patch v2 21/35] Hexagon: Add SMP support

On Tue, 2011-08-30 at 14:07 -0500, Richard Kuo wrote:
> plain text document attachment (smp.diff)
> Signed-off-by: Richard Kuo <rkuo@...eaurora.org>
[]
> +static inline void __handle_ipi(unsigned long *ops, struct ipi_data *ipi,
> +				int cpu)
> +{
> +	do {
> +		unsigned long msg = msg = ffz(~*ops);

Really?  That's unlikely to be the right code.
Maybe just one msg?

> +
> +		*ops &= ~(1 << msg);
> +
> +		switch (msg) {
> +		case IPI_TIMER:
> +			ipi_timer();
> +			break;
> +		case IPI_CALL_FUNC:
> +		{

> +			struct smp_call_struct *data =
> +				smp_call_function_data;
> +			void (*func) (void *info) =
> +				data->func;

No need to wrap either of these.

> +			void *info = data->info;
> +			int wait = data->wait;
> +
> +			smp_mb();
> +			cpumask_clear_cpu(cpu, &data->pending);
> +
> +			(*func)(info);
> +
> +			smp_mb();
> +			if (wait)
> +				cpumask_clear_cpu(cpu,
> +					&data->unfinished);

or here.


--
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