From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932245AbcISRIk (ORCPT ); Mon, 19 Sep 2016 13:08:40 -0400 Received: from smtprelay2.synopsys.com ([198.182.60.111]:36994 "EHLO smtprelay.synopsys.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932190AbcISRIj (ORCPT ); Mon, 19 Sep 2016 13:08:39 -0400 Subject: Re: [PATCH] ARC: [plat-eznps] add missing atomic_fetch_xxx operations To: Noam Camus References: <1474263280-26203-1-git-send-email-noamca@mellanox.com> CC: "peterz@infradead.org" , "mingo@kernel.org" , "linux-snps-arc@lists.infradead.org" , "linux-kernel@vger.kernel.org" From: Vineet Gupta Message-ID: <78b621bf-2bc4-f4c8-1d13-8fd6fa483ac8@synopsys.com> Date: Mon, 19 Sep 2016 10:08:28 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0 MIME-Version: 1.0 In-Reply-To: <1474263280-26203-1-git-send-email-noamca@mellanox.com> Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-Originating-IP: [10.9.131.247] Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 09/18/2016 10:34 PM, Noam Camus wrote: > From: Noam Camus > > Build brekeage since last changes to generic atomic operations. > Added couple of missing macros which are now mandatory > > Signed-off-by: Noam Camus Added to for-next ! Thx, -Vineet > --- > arch/arc/include/asm/atomic.h | 2 ++ > 1 files changed, 2 insertions(+), 0 deletions(-) > > diff --git a/arch/arc/include/asm/atomic.h b/arch/arc/include/asm/atomic.h > index 4e3c1b6..4f732bf 100644 > --- a/arch/arc/include/asm/atomic.h > +++ b/arch/arc/include/asm/atomic.h > @@ -284,6 +284,7 @@ static inline int atomic_fetch_##op(int i, atomic_t *v) \ > ATOMIC_OPS(add, +=, CTOP_INST_AADD_DI_R2_R2_R3) > #define atomic_sub(i, v) atomic_add(-(i), (v)) > #define atomic_sub_return(i, v) atomic_add_return(-(i), (v)) > +#define atomic_fetch_sub(i, v) atomic_fetch_add(-(i), (v)) > > #undef ATOMIC_OPS > #define ATOMIC_OPS(op, c_op, asm_op) \ > @@ -292,6 +293,7 @@ ATOMIC_OPS(add, +=, CTOP_INST_AADD_DI_R2_R2_R3) > > ATOMIC_OPS(and, &=, CTOP_INST_AAND_DI_R2_R2_R3) > #define atomic_andnot(mask, v) atomic_and(~(mask), (v)) > +#define atomic_fetch_andnot(mask, v) atomic_fetch_and(~(mask), (v)) > ATOMIC_OPS(or, |=, CTOP_INST_AOR_DI_R2_R2_R3) > ATOMIC_OPS(xor, ^=, CTOP_INST_AXOR_DI_R2_R2_R3) >