From patchwork Mon Jun 25 23:33:20 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Neuling X-Patchwork-Id: 167279 X-Patchwork-Delegate: benh@kernel.crashing.org Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from ozlabs.org (localhost [IPv6:::1]) by ozlabs.org (Postfix) with ESMTP id 186CAB7018 for ; Tue, 26 Jun 2012 09:51:44 +1000 (EST) Received: by ozlabs.org (Postfix) id 3D3D91007E1; Tue, 26 Jun 2012 09:33:21 +1000 (EST) Delivered-To: linuxppc-dev@ozlabs.org Received: from localhost.localdomain (localhost [127.0.0.1]) by ozlabs.org (Postfix) with ESMTP id 02FCF1007DE; Tue, 26 Jun 2012 09:33:21 +1000 (EST) Received: by localhost.localdomain (Postfix, from userid 1000) id B2E4AD43685; Tue, 26 Jun 2012 09:33:20 +1000 (EST) To: Benjamin Herrenschmidt , Paul Mackerras , Michael Ellerman From: Michael Neuling Date: Tue, 26 Jun 2012 09:33:20 +1000 Subject: [PATCH 13/18] powerpc: introduce new ___PPC_RA/B/S/T macros In-Reply-To: <1340667187.357853.615199632713.qpush@ale> Message-Id: <20120625233320.B2E4AD43685@localhost.localdomain> Cc: mikey@neuling.org, matt@ozlabs.org, linuxppc-dev@ozlabs.org, schwab@linux-m68k.org, Anton Blanchard , Olof Johannsson X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.15rc1 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Sender: "Linuxppc-dev" These are currently the same as __PPC_RA/B/S/T but we'll wrap them soon. Signed-off-by: Michael Neuling --- arch/powerpc/include/asm/ppc-opcode.h | 4 ++++ 1 file changed, 4 insertions(+) Index: b/arch/powerpc/include/asm/ppc-opcode.h =================================================================== --- a/arch/powerpc/include/asm/ppc-opcode.h +++ b/arch/powerpc/include/asm/ppc-opcode.h @@ -144,6 +144,10 @@ #define PPC_INST_STBCIX 0x7c0007aa /* macros to insert fields into opcodes */ +#define ___PPC_RA(a) (((a) & 0x1f) << 16) +#define ___PPC_RB(b) (((b) & 0x1f) << 11) +#define ___PPC_RS(s) (((s) & 0x1f) << 21) +#define ___PPC_RT(t) ___PPC_RS(t) #define __PPC_RA(a) (((a) & 0x1f) << 16) #define __PPC_RB(b) (((b) & 0x1f) << 11) #define __PPC_RS(s) (((s) & 0x1f) << 21)