[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20151125091349.GW17308@twins.programming.kicks-ass.net>
Date: Wed, 25 Nov 2015 10:13:49 +0100
From: Peter Zijlstra <peterz@...radead.org>
To: Frederic Weisbecker <fweisbec@...il.com>
Cc: Chris Metcalf <cmetcalf@...hip.com>,
LKML <linux-kernel@...r.kernel.org>,
Thomas Gleixner <tglx@...utronix.de>,
Luiz Capitulino <lcapitulino@...hat.com>,
Christoph Lameter <cl@...ux.com>,
Ingo Molnar <mingo@...nel.org>,
Viresh Kumar <viresh.kumar@...aro.org>,
Rik van Riel <riel@...hat.com>
Subject: Re: [PATCH 1/7] atomic: Export fetch_or()
On Tue, Nov 24, 2015 at 10:19:52PM +0100, Frederic Weisbecker wrote:
> Also note that or_return() means that you first do OR and then return the new value.
Yes, that's useless. OR is an irreversible operator, which means
or_return() looses data. You can never say if a bit included in the
mask was set before.
You really must have fetch_or().
--
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