From patchwork Tue Dec 27 21:28:50 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sam Ravnborg X-Patchwork-Id: 133367 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 8C1C8B6FE8 for ; Wed, 28 Dec 2011 08:28:52 +1100 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751340Ab1L0V2v (ORCPT ); Tue, 27 Dec 2011 16:28:51 -0500 Received: from smtp.snhosting.dk ([87.238.248.203]:43416 "EHLO smtp.domainteam.dk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751342Ab1L0V2v (ORCPT ); Tue, 27 Dec 2011 16:28:51 -0500 Received: from merkur.ravnborg.org (x1-6-c4-3d-c7-28-70-1a.k498.webspeed.dk [83.89.83.41]) by smtp.domainteam.dk (Postfix) with ESMTPA id 6256EF189F; Tue, 27 Dec 2011 22:28:50 +0100 (CET) Date: Tue, 27 Dec 2011 22:28:50 +0100 From: Sam Ravnborg To: "David S. Miller" , sparclinux Subject: [PATCH] sparc32: support atomic64_t Message-ID: <20111227212850.GA8174@merkur.ravnborg.org> MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.18 (2008-05-17) Sender: sparclinux-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: sparclinux@vger.kernel.org From 8d3ccd703b99564b119a6ddb4127c31f8f2fece3 Mon Sep 17 00:00:00 2001 From: Sam Ravnborg Date: Tue, 27 Dec 2011 21:46:53 +0100 Subject: [PATCH] sparc32: support atomic64_t There is no-one that really require atomic64_t support on sparc32. But several drivers fails to build without proper atomic64 support. And for an allyesconfig build for sparc32 this is annoying. Include the generic atomic64_t support for sparc32. This has a text footprint cost: $size vmlinux (before atomic64_t support) text data bss dec hex filename 3578860 134260 108781 3821901 3a514d vmlinux $size vmlinux (after atomic64_t support) text data bss dec hex filename 3579892 130684 108781 3819357 3a475d vmlinux text increase (3579892 - 3578860) = 1032 bytes data decreases - but I fail to explain why! I have rebuild twice to check my numbers. Signed-off-by: Sam Ravnborg --- Note: This is only build tested because my faithful SPARCclassic is non-functional atm :-( Sam arch/sparc/Kconfig | 1 + arch/sparc/include/asm/atomic_32.h | 2 ++ 2 files changed, 3 insertions(+), 0 deletions(-) diff --git a/arch/sparc/Kconfig b/arch/sparc/Kconfig index f92602e..27060b2 100644 --- a/arch/sparc/Kconfig +++ b/arch/sparc/Kconfig @@ -31,6 +31,7 @@ config SPARC config SPARC32 def_bool !64BIT + select GENERIC_ATOMIC64 config SPARC64 def_bool 64BIT diff --git a/arch/sparc/include/asm/atomic_32.h b/arch/sparc/include/asm/atomic_32.h index 03fd0c5..9dd0a76 100644 --- a/arch/sparc/include/asm/atomic_32.h +++ b/arch/sparc/include/asm/atomic_32.h @@ -13,6 +13,8 @@ #include +#include + #include #define ATOMIC_INIT(i) { (i) }