All of lore.kernel.org
 help / color / mirror / Atom feed
From: Michael Neuling <mikey@neuling.org>
To: Michael Neuling <mikey@neuling.org>,
	Paul Mackerras <paulus@samba.org>,
	Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: linuxppc-dev@ozlabs.org, Milton Miller <miltonm@bga.com>
Subject: [PATCH 2/2] powerpc: Move VSX load/stores into ppc-opcode.h
Date: Wed, 29 Apr 2009 17:20:40 +1000	[thread overview]
Message-ID: <20090429072040.A3C761222D@localhost.localdomain> (raw)
In-Reply-To: <1240989640.548113.69052602556.qpush@pale>

Move VSX load/stores into ppc-opcode.h

Signed-off-by: Michael Neuling <mikey@neuling.org>
---

 arch/powerpc/include/asm/ppc-opcode.h |    9 +++++++++
 arch/powerpc/include/asm/ppc_asm.h    |   10 ----------
 2 files changed, 9 insertions(+), 10 deletions(-)

Index: linux-2.6-ozlabs/arch/powerpc/include/asm/ppc-opcode.h
===================================================================
--- linux-2.6-ozlabs.orig/arch/powerpc/include/asm/ppc-opcode.h
+++ linux-2.6-ozlabs/arch/powerpc/include/asm/ppc-opcode.h
@@ -49,6 +49,7 @@
 /* macros to insert fields into opcodes */
 #define __PPC_RA(a)	(((a) & 0x1f) << 16)
 #define __PPC_RB(b)	(((b) & 0x1f) << 11)
+#define __PPC_XS(s)	((((s) & 0x1f) << 21) | (((s) & 0x20) >> 5))
 #define __PPC_T_TLB(t)	(((t) & 0x3) << 21)
 #define __PPC_WC(w)	(((w) & 0x3) << 21)
 
@@ -70,4 +71,12 @@
 #define PPC_WAIT(w)		stringify_in_c(.long PPC_INST_WAIT | \
 					__PPC_WC(w))
 
+/*
+ * Define what the VSX XX1 form instructions will look like, then add
+ * the 128 bit load store instructions based on that.
+ */
+#define VSX_XX1(s, a, b)	(__PPC_XS(s) | __PPC_RA(a) | __PPC_RB(b))
+#define STXVD2X(s, a, b)	.long (0x7c000798 | VSX_XX1((s), (a), (b)))
+#define LXVD2X(s, a, b)		.long (0x7c000698 | VSX_XX1((s), (a), (b)))
+
 #endif /* _ASM_POWERPC_PPC_OPCODE_H */
Index: linux-2.6-ozlabs/arch/powerpc/include/asm/ppc_asm.h
===================================================================
--- linux-2.6-ozlabs.orig/arch/powerpc/include/asm/ppc_asm.h
+++ linux-2.6-ozlabs/arch/powerpc/include/asm/ppc_asm.h
@@ -75,16 +75,6 @@ END_FTR_SECTION_IFCLR(CPU_FTR_PURR);				
 				REST_10GPRS(22, base)
 #endif
 
-/*
- * Define what the VSX XX1 form instructions will look like, then add
- * the 128 bit load store instructions based on that.
- */
-#define VSX_XX1(xs, ra, rb)	(((xs) & 0x1f) << 21 | ((ra) << 16) |  \
-				 ((rb) << 11) | (((xs) >> 5)))
-
-#define STXVD2X(xs, ra, rb)	.long (0x7c000798 | VSX_XX1((xs), (ra), (rb)))
-#define LXVD2X(xs, ra, rb)	.long (0x7c000698 | VSX_XX1((xs), (ra), (rb)))
-
 #define SAVE_2GPRS(n, base)	SAVE_GPR(n, base); SAVE_GPR(n+1, base)
 #define SAVE_4GPRS(n, base)	SAVE_2GPRS(n, base); SAVE_2GPRS(n+2, base)
 #define SAVE_8GPRS(n, base)	SAVE_4GPRS(n, base); SAVE_4GPRS(n+4, base)

  reply	other threads:[~2009-04-29  7:20 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-04-24  6:24 [PATCH 0/2] powerpc: tlbie implementation PowerPC 2.06 Michael Neuling
2009-04-24  6:24 ` [PATCH 2/2] powerpc: Add 2.06 tlbie mnemonics Michael Neuling
2009-04-27  1:20   ` Benjamin Herrenschmidt
2009-04-27 19:30   ` Kumar Gala
2009-04-27 19:31   ` Kumar Gala
2009-04-27 19:46     ` Kumar Gala
2009-04-28  5:03       ` [PATCH 0/2] powerpc: tlbie implementation for PowerPC ISA 2.06 Michael Neuling
2009-04-28  5:03         ` [PATCH 1/2] powerpc: Enable MMU feature sections for inline asm Michael Neuling
2009-04-28  5:03         ` [PATCH 2/2] powerpc: Add 2.06 tlbie mnemonics Michael Neuling
2009-04-28 12:05           ` Kumar Gala
2009-04-28 12:40             ` Michael Neuling
2009-04-28 12:45             ` [PATCH 0/2] powerpc: tlbie implementation for PowerPC ISA 2.06 Michael Neuling
2009-04-28 12:45               ` [PATCH 1/2] powerpc: Enable MMU feature sections for inline asm Michael Neuling
2009-04-28 12:45               ` [PATCH 2/2] powerpc: Add 2.06 tlbie mnemonics Michael Neuling
2009-04-28 13:21                 ` Kumar Gala
2009-04-29  0:16                   ` Michael Neuling
2009-04-29  0:26                   ` [PATCH 0/2] powerpc: tlbie implementation for PowerPC ISA 2.06 Michael Neuling
2009-04-29  0:26                     ` [PATCH 1/2] powerpc: Enable MMU feature sections for inline asm Michael Neuling
2009-04-29  0:52                       ` Michael Ellerman
2009-04-29  7:20                         ` [PATCH 0/2] powerpc: Cleanup code in ppc-opcode.h Michael Neuling
2009-04-29  7:20                           ` Michael Neuling [this message]
2009-04-29 12:38                             ` [PATCH 2/2] powerpc: Move VSX load/stores into ppc-opcode.h Kumar Gala
2009-04-30  0:24                               ` Michael Neuling
2009-04-30  6:58                                 ` [PATCH 0/4] powerpc: tlbie implementation for PowerPC ISA 2.06 and cleanups for ppc-opcode.h Michael Neuling
2009-04-30  6:58                                   ` [PATCH 1/4] powerpc: Cleanup macros in ppc-opcode.h Michael Neuling
2009-04-30 11:27                                     ` Kumar Gala
2009-04-30  6:58                                   ` [PATCH 4/4] powerpc: Add 2.06 tlbie mnemonics Michael Neuling
2009-04-30  6:58                                   ` [PATCH 2/4] powerpc: Move VSX load/stores into ppc-opcode.h Michael Neuling
2009-04-30 11:28                                     ` Kumar Gala
2009-04-30  6:58                                   ` [PATCH 3/4] powerpc: Enable MMU feature sections for inline asm Michael Neuling
2009-04-29  7:20                           ` [PATCH 1/2] powerpc: Cleanup macros in ppc-opcode.h Michael Neuling
2009-04-29  7:27                           ` [PATCH 0/2] powerpc: tlbie implementation for PowerPC ISA 2.06 Michael Neuling
2009-04-29  7:27                             ` [PATCH 1/2] powerpc: Enable MMU feature sections for inline asm Michael Neuling
2009-04-29  7:27                             ` [PATCH 2/2] powerpc: Add 2.06 tlbie mnemonics Michael Neuling
2009-04-29  0:26                     ` Michael Neuling
2009-04-24  6:24 ` [PATCH 1/2] powerpc: Enable CPU feature sections for inline asm Michael Neuling

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20090429072040.A3C761222D@localhost.localdomain \
    --to=mikey@neuling.org \
    --cc=benh@kernel.crashing.org \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=miltonm@bga.com \
    --cc=paulus@samba.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.