Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp1984055imm; Thu, 24 May 2018 04:02:32 -0700 (PDT) X-Google-Smtp-Source: AB8JxZruwHdh/qvz3cXw4wwWYBa0KrR79y7hmkvmKm1QzpxWYeQY5HOzwE1scdQnpQbkhpYfJmAa X-Received: by 2002:a62:d508:: with SMTP id d8-v6mr6657579pfg.234.1527159752042; Thu, 24 May 2018 04:02:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1527159752; cv=none; d=google.com; s=arc-20160816; b=p67DtXEnj4QtPwRN1NMQnvQql7rLFPTvQ1xvC+OFGrB+n+iA9w5DcnwqrpfZXysgR2 BjBZN3sMu26aT3n+d52KYry6tRHkGRPDT2zJLmuemiKS/9Fdp2NIzqhrw5snD6Qg1wk4 Xzzt+MD2e2xbJKDkmOt4Osnv3nclCsp8SZ6Y4fUWuhO3ym71nRvgCfcS8KggKp3WLqgx EvK4EnhlRku5HK6/wvNcAciFuKiJgc0T5S6Ff2ADyiBcKXRMgvJ4i0iO+f7+jnvRrHsE IYX9Nc1MelWGWTiBB5mRH/LUjw86mU88vFNkfRmog2uHNSyAs/Q71ov+UpegZPpTgV2Z KJ7g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:arc-authentication-results; bh=KPoO3xkmTJNlaTbhFQlzQWdV0d+0c5MF04CUiFuVFTI=; b=YmPGieWwBVhoZsQhOnL+9Nal1nBJ+s7eR/EvCy5aYr6KPuJCPpbpjegpcTljzKXHs7 p4D0/fz8RullCGt/NE7UKoCaPnuAgBNT1sQddjKnYoMyL9ZLg+NNua5B2J96YVmMILYX dXBKuZyj2fRdGnqeqON0+6S+sGRYima0KiDJIc/uR26obZWOSIiiUpawvsvEB9o7/9QN 9kb4JGo4ue6wLZPOA8z+xPnDWD21i2vJgP0SRqpS7JjIQUF55/ne84rtWD0Ve0JyU9vl lFDMEOsPPtoBfgHnRmYzTWQbj+mjRdc2ov6Gsp5XUJbS9QILwjLmrFrtJ235d6m6i6NO ECxA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m26-v6si21555668pfk.56.2018.05.24.04.01.55; Thu, 24 May 2018 04:02:32 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1032756AbeEXK7c (ORCPT + 99 others); Thu, 24 May 2018 06:59:32 -0400 Received: from foss.arm.com ([217.140.101.70]:40932 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1030295AbeEXK7T (ORCPT ); Thu, 24 May 2018 06:59:19 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 8FE8F165D; Thu, 24 May 2018 03:59:19 -0700 (PDT) Received: from edgewater-inn.cambridge.arm.com (usa-sjc-imap-foss1.foss.arm.com [10.72.51.249]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 608393F762; Thu, 24 May 2018 03:59:19 -0700 (PDT) Received: by edgewater-inn.cambridge.arm.com (Postfix, from userid 1000) id 6133C1AE372C; Thu, 24 May 2018 11:59:47 +0100 (BST) From: Will Deacon To: linux-kernel@vger.kernel.org Cc: peterz@infradead.org, mingo@kernel.org, linux-arm-kernel@lists.infradead.org, yamada.masahiro@socionext.com, Will Deacon Subject: [PATCH 2/9] m68k: Don't use asm-generic/bitops/lock.h Date: Thu, 24 May 2018 11:59:39 +0100 Message-Id: <1527159586-8578-3-git-send-email-will.deacon@arm.com> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1527159586-8578-1-git-send-email-will.deacon@arm.com> References: <1527159586-8578-1-git-send-email-will.deacon@arm.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org asm-generic/bitops/lock.h is shortly going to be built on top of the atomic_long_* API, which introduces a nasty circular dependency for m68k where linux/atomic.h pulls in linux/bitops.h via: linux/atomic.h asm/atomic.h linux/irqflags.h asm/irqflags.h linux/preempt.h asm/preempt.h asm-generic/preempt.h linux/thread_info.h asm/thread_info.h asm/page.h asm-generic/getorder.h linux/log2.h linux/bitops.h Since m68k isn't SMP and doesn't support ACQUIRE/RELEASE barriers, we can just define the lock bitops in terms of the atomic bitops in the asm/bitops.h header. Acked-by: Geert Uytterhoeven Signed-off-by: Will Deacon --- arch/m68k/include/asm/bitops.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/arch/m68k/include/asm/bitops.h b/arch/m68k/include/asm/bitops.h index 93b47b1f6fb4..18193419f97d 100644 --- a/arch/m68k/include/asm/bitops.h +++ b/arch/m68k/include/asm/bitops.h @@ -515,12 +515,16 @@ static inline int __fls(int x) #endif +/* Simple test-and-set bit locks */ +#define test_and_set_bit_lock test_and_set_bit +#define clear_bit_unlock clear_bit +#define __clear_bit_unlock clear_bit_unlock + #include #include #include #include #include -#include #endif /* __KERNEL__ */ #endif /* _M68K_BITOPS_H */ -- 2.1.4