All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/5] Introduce powerpc64 LE architecture support
@ 2020-01-18 19:41 Khem Raj
  2020-01-18 19:41 ` [PATCH 1/5] classes, conf, lib: Add support for powerpc64le Khem Raj
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: Khem Raj @ 2020-01-18 19:41 UTC (permalink / raw)
  To: openembedded-core

This patchset adds base support for building ppc64 in Litte-Endian mode,
the linux-yocto changes and qemu related changes will make it buildable
target out of box, but that is not yet made available

The following changes since commit ecbf203e34484731dcb6acc5e75df79cb86e55dc:

  sstatesig: Improve debug output if getpwuid() fails (2020-01-16 22:33:09 +0000)

are available in the Git repository at:

  git://git.yoctoproject.org/poky-contrib kraj/ppc64le
  http://git.yoctoproject.org/cgit.cgi/poky-contrib/log/?h=kraj/ppc64le

Khem Raj (5):
  classes,conf,lib: Add support for powerpc64le
  gcc: Enable 32bit powerpcle at multi-arch for powerpc64le
  openssl: Add powerpc64 LE support
  tcf-agent: Add LCL_STOP_SERVICES for powerpc64 LE
  ghostscript: Add powerpc64 LE specific objarch.h

 meta/classes/libc-package.bbclass             |  1 +
 meta/classes/meson.bbclass                    |  2 +-
 meta/conf/bitbake.conf                        |  1 +
 meta/lib/oe/elf.py                            |  2 +
 meta/lib/oe/package_manager.py                |  1 +
 .../openssl/openssl_1.1.1d.bb                 |  3 ++
 meta/recipes-devtools/gcc/gcc-common.inc      |  1 +
 .../tcf-agent/tcf-agent_git.bb                |  1 +
 .../ghostscript/powerpc64le/objarch.h         | 40 +++++++++++++++++++
 9 files changed, 51 insertions(+), 1 deletion(-)
 create mode 100644 meta/recipes-extended/ghostscript/ghostscript/powerpc64le/objarch.h

-- 
2.25.0



^ permalink raw reply	[flat|nested] 6+ messages in thread

* [PATCH 1/5] classes, conf, lib: Add support for powerpc64le
  2020-01-18 19:41 [PATCH 0/5] Introduce powerpc64 LE architecture support Khem Raj
@ 2020-01-18 19:41 ` Khem Raj
  2020-01-18 19:41 ` [PATCH 2/5] gcc: Enable 32bit powerpcle at multi-arch " Khem Raj
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: Khem Raj @ 2020-01-18 19:41 UTC (permalink / raw)
  To: openembedded-core

LE is default for modern powerpc64, power8+

PowerPC64 Little Endian Linux ABI specifies Power8 as the minimum ISA.
The basic ABI can run on earlier versions of the 64 bit PowerPC ISA,
but it was helpful to define a new, minimum instruction set for Linux
distribution releases during the switch to Little Endian.

Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
 meta/classes/libc-package.bbclass | 1 +
 meta/classes/meson.bbclass        | 2 +-
 meta/conf/bitbake.conf            | 1 +
 meta/lib/oe/elf.py                | 2 ++
 meta/lib/oe/package_manager.py    | 1 +
 5 files changed, 6 insertions(+), 1 deletion(-)

diff --git a/meta/classes/libc-package.bbclass b/meta/classes/libc-package.bbclass
index de816bcec1..de3b4250c7 100644
--- a/meta/classes/libc-package.bbclass
+++ b/meta/classes/libc-package.bbclass
@@ -248,6 +248,7 @@ python package_do_split_gconvs () {
                 "sh4":     " --uint32-align=4 --big-endian ",    \
                 "powerpc": " --uint32-align=4 --big-endian ",    \
                 "powerpc64": " --uint32-align=4 --big-endian ",  \
+                "powerpc64le": " --uint32-align=4 --little-endian ",  \
                 "mips":    " --uint32-align=4 --big-endian ",    \
                 "mipsisa32r6":    " --uint32-align=4 --big-endian ",    \
                 "mips64":  " --uint32-align=4 --big-endian ",    \
diff --git a/meta/classes/meson.bbclass b/meta/classes/meson.bbclass
index 71f9de1a57..1ef34a999c 100644
--- a/meta/classes/meson.bbclass
+++ b/meta/classes/meson.bbclass
@@ -45,7 +45,7 @@ def meson_cpu_family(var, d):
     arch = d.getVar(var)
     if arch == 'powerpc':
         return 'ppc'
-    elif arch == 'powerpc64':
+    elif arch == 'powerpc64' or arch == 'powerpc64le':
         return 'ppc64'
     elif arch == 'armeb':
         return 'arm'
diff --git a/meta/conf/bitbake.conf b/meta/conf/bitbake.conf
index 62b5466b71..3bbe42c2c0 100644
--- a/meta/conf/bitbake.conf
+++ b/meta/conf/bitbake.conf
@@ -11,6 +11,7 @@ baselib = "${BASELIB}"
 baselib[vardepvalue] = "${baselib}"
 BASELIB = "lib"
 BASELIB_powerpc64 = "lib64"
+BASELIB_powerpc64le = "lib64"
 
 # Path prefixes
 export base_prefix = ""
diff --git a/meta/lib/oe/elf.py b/meta/lib/oe/elf.py
index 2562cea1dd..43c962c697 100644
--- a/meta/lib/oe/elf.py
+++ b/meta/lib/oe/elf.py
@@ -34,6 +34,7 @@ def machine_dict(d):
                         "armeb":      (40,    97,    0,          False,         32),
                         "powerpc":    (20,     0,    0,          False,         32),
                         "powerpc64":  (21,     0,    0,          False,         64),
+                        "powerpc64le":  (21,     0,    0,          True,         64),
                         "i386":       ( 3,     0,    0,          True,          32),
                         "i486":       ( 3,     0,    0,          True,          32),
                         "i586":       ( 3,     0,    0,          True,          32),
@@ -68,6 +69,7 @@ def machine_dict(d):
                         "armeb":      (  40,    97,    0,          False,         32),
                         "powerpc":    (  20,     0,    0,          False,         32),
                         "powerpc64":  (  21,     0,    0,          False,         64),
+                        "powerpc64le":  (21,     0,    0,          True,         64),
                         "i386":       (   3,     0,    0,          True,          32),
                         "i486":       (   3,     0,    0,          True,          32),
                         "i586":       (   3,     0,    0,          True,          32),
diff --git a/meta/lib/oe/package_manager.py b/meta/lib/oe/package_manager.py
index e15e3c4a31..e96c28b46d 100644
--- a/meta/lib/oe/package_manager.py
+++ b/meta/lib/oe/package_manager.py
@@ -107,6 +107,7 @@ def generate_locale_archive(d, rootfs, target_arch, localedir):
         "sh4": ["--uint32-align=4", "--big-endian"],
         "powerpc": ["--uint32-align=4", "--big-endian"],
         "powerpc64": ["--uint32-align=4", "--big-endian"],
+        "powerpc64le": ["--uint32-align=4", "--little-endian"],
         "mips": ["--uint32-align=4", "--big-endian"],
         "mipsisa32r6": ["--uint32-align=4", "--big-endian"],
         "mips64": ["--uint32-align=4", "--big-endian"],
-- 
2.25.0



^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH 2/5] gcc: Enable 32bit powerpcle at multi-arch for powerpc64le
  2020-01-18 19:41 [PATCH 0/5] Introduce powerpc64 LE architecture support Khem Raj
  2020-01-18 19:41 ` [PATCH 1/5] classes, conf, lib: Add support for powerpc64le Khem Raj
@ 2020-01-18 19:41 ` Khem Raj
  2020-01-18 19:41 ` [PATCH 3/5] openssl: Add powerpc64 LE support Khem Raj
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: Khem Raj @ 2020-01-18 19:41 UTC (permalink / raw)
  To: openembedded-core

Even though we do not expect any legacy ( 32bit ) for LE, linux-yocto
does enable the compat code, so enable 32bit support to get that going

Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
 meta/recipes-devtools/gcc/gcc-common.inc | 1 +
 1 file changed, 1 insertion(+)

diff --git a/meta/recipes-devtools/gcc/gcc-common.inc b/meta/recipes-devtools/gcc/gcc-common.inc
index 44cba287f3..3dcfdf835f 100644
--- a/meta/recipes-devtools/gcc/gcc-common.inc
+++ b/meta/recipes-devtools/gcc/gcc-common.inc
@@ -47,6 +47,7 @@ def get_gcc_multiarch_setting(bb, d):
         "i586":    "--enable-targets=all",
         "i686":    "--enable-targets=all",
         "powerpc": "--enable-targets=powerpc64",
+        "powerpc64le": "--enable-targets=powerpcle",
         "mips":    "--enable-targets=all",
         "sparc":   "--enable-targets=all",
     }
-- 
2.25.0



^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH 3/5] openssl: Add powerpc64 LE support
  2020-01-18 19:41 [PATCH 0/5] Introduce powerpc64 LE architecture support Khem Raj
  2020-01-18 19:41 ` [PATCH 1/5] classes, conf, lib: Add support for powerpc64le Khem Raj
  2020-01-18 19:41 ` [PATCH 2/5] gcc: Enable 32bit powerpcle at multi-arch " Khem Raj
@ 2020-01-18 19:41 ` Khem Raj
  2020-01-18 19:41 ` [PATCH 4/5] tcf-agent: Add LCL_STOP_SERVICES for powerpc64 LE Khem Raj
  2020-01-18 19:41 ` [PATCH 5/5] ghostscript: Add powerpc64 LE specific objarch.h Khem Raj
  4 siblings, 0 replies; 6+ messages in thread
From: Khem Raj @ 2020-01-18 19:41 UTC (permalink / raw)
  To: openembedded-core

Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
 meta/recipes-connectivity/openssl/openssl_1.1.1d.bb | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/meta/recipes-connectivity/openssl/openssl_1.1.1d.bb b/meta/recipes-connectivity/openssl/openssl_1.1.1d.bb
index 458ae7daf4..7fd0f9a269 100644
--- a/meta/recipes-connectivity/openssl/openssl_1.1.1d.bb
+++ b/meta/recipes-connectivity/openssl/openssl_1.1.1d.bb
@@ -102,6 +102,9 @@ do_configure () {
 	linux-powerpc64)
 		target=linux-ppc64
 		;;
+	linux-powerpc64le)
+		target=linux-ppc64le
+		;;
 	linux-riscv32)
 		target=linux-generic32
 		;;
-- 
2.25.0



^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH 4/5] tcf-agent: Add LCL_STOP_SERVICES for powerpc64 LE
  2020-01-18 19:41 [PATCH 0/5] Introduce powerpc64 LE architecture support Khem Raj
                   ` (2 preceding siblings ...)
  2020-01-18 19:41 ` [PATCH 3/5] openssl: Add powerpc64 LE support Khem Raj
@ 2020-01-18 19:41 ` Khem Raj
  2020-01-18 19:41 ` [PATCH 5/5] ghostscript: Add powerpc64 LE specific objarch.h Khem Raj
  4 siblings, 0 replies; 6+ messages in thread
From: Khem Raj @ 2020-01-18 19:41 UTC (permalink / raw)
  To: openembedded-core

This is same as PPC64 BE

Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
 meta/recipes-devtools/tcf-agent/tcf-agent_git.bb | 1 +
 1 file changed, 1 insertion(+)

diff --git a/meta/recipes-devtools/tcf-agent/tcf-agent_git.bb b/meta/recipes-devtools/tcf-agent/tcf-agent_git.bb
index b4bd4ca63c..e0a07a9375 100644
--- a/meta/recipes-devtools/tcf-agent/tcf-agent_git.bb
+++ b/meta/recipes-devtools/tcf-agent/tcf-agent_git.bb
@@ -46,6 +46,7 @@ CFLAGS_append_mips = " ${LCL_STOP_SERVICES}"
 CFLAGS_append_mips64 = " ${LCL_STOP_SERVICES}"
 CFLAGS_append_libc-musl = " ${LCL_STOP_SERVICES}"
 CFLAGS_append_powerpc64 = " ${LCL_STOP_SERVICES}"
+CFLAGS_append_powerpc64le = " ${LCL_STOP_SERVICES}"
 CFLAGS_append_riscv64 = " ${LCL_STOP_SERVICES}"
 
 do_install() {
-- 
2.25.0



^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH 5/5] ghostscript: Add powerpc64 LE specific objarch.h
  2020-01-18 19:41 [PATCH 0/5] Introduce powerpc64 LE architecture support Khem Raj
                   ` (3 preceding siblings ...)
  2020-01-18 19:41 ` [PATCH 4/5] tcf-agent: Add LCL_STOP_SERVICES for powerpc64 LE Khem Raj
@ 2020-01-18 19:41 ` Khem Raj
  4 siblings, 0 replies; 6+ messages in thread
From: Khem Raj @ 2020-01-18 19:41 UTC (permalink / raw)
  To: openembedded-core

Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
 .../ghostscript/powerpc64le/objarch.h         | 40 +++++++++++++++++++
 1 file changed, 40 insertions(+)
 create mode 100644 meta/recipes-extended/ghostscript/ghostscript/powerpc64le/objarch.h

diff --git a/meta/recipes-extended/ghostscript/ghostscript/powerpc64le/objarch.h b/meta/recipes-extended/ghostscript/ghostscript/powerpc64le/objarch.h
new file mode 100644
index 0000000000..a05de29def
--- /dev/null
+++ b/meta/recipes-extended/ghostscript/ghostscript/powerpc64le/objarch.h
@@ -0,0 +1,40 @@
+/* Parameters derived from machine and compiler architecture. */
+/* This file is generated mechanically by genarch.c. */
+
+	 /* ---------------- Scalar alignments ---------------- */
+
+#define ARCH_ALIGN_SHORT_MOD 2
+#define ARCH_ALIGN_INT_MOD 4
+#define ARCH_ALIGN_LONG_MOD 8
+#define ARCH_ALIGN_PTR_MOD 8
+#define ARCH_ALIGN_FLOAT_MOD 4
+#define ARCH_ALIGN_DOUBLE_MOD 8
+
+	 /* ---------------- Scalar sizes ---------------- */
+
+#define ARCH_LOG2_SIZEOF_CHAR 0
+#define ARCH_LOG2_SIZEOF_SHORT 1
+#define ARCH_LOG2_SIZEOF_INT 2
+#define ARCH_LOG2_SIZEOF_LONG 3
+#define ARCH_LOG2_SIZEOF_LONG_LONG 3
+#define ARCH_SIZEOF_GX_COLOR_INDEX 8
+#define ARCH_SIZEOF_PTR 8
+#define ARCH_SIZEOF_FLOAT 4
+#define ARCH_SIZEOF_DOUBLE 8
+#define ARCH_FLOAT_MANTISSA_BITS 24
+#define ARCH_DOUBLE_MANTISSA_BITS 53
+
+	 /* ---------------- Unsigned max values ---------------- */
+
+#define ARCH_MAX_UCHAR ((unsigned char)0xff + (unsigned char)0)
+#define ARCH_MAX_USHORT ((unsigned short)0xffff + (unsigned short)0)
+#define ARCH_MAX_UINT ((unsigned int)~0 + (unsigned int)0)
+#define ARCH_MAX_ULONG ((unsigned long)~0L + (unsigned long)0)
+
+	 /* ---------------- Miscellaneous ---------------- */
+
+#define ARCH_IS_BIG_ENDIAN 0
+#define ARCH_PTRS_ARE_SIGNED 0
+#define ARCH_FLOATS_ARE_IEEE 1
+#define ARCH_ARITH_RSHIFT 2
+#define ARCH_DIV_NEG_POS_TRUNCATES 1
-- 
2.25.0



^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2020-01-18 19:41 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-01-18 19:41 [PATCH 0/5] Introduce powerpc64 LE architecture support Khem Raj
2020-01-18 19:41 ` [PATCH 1/5] classes, conf, lib: Add support for powerpc64le Khem Raj
2020-01-18 19:41 ` [PATCH 2/5] gcc: Enable 32bit powerpcle at multi-arch " Khem Raj
2020-01-18 19:41 ` [PATCH 3/5] openssl: Add powerpc64 LE support Khem Raj
2020-01-18 19:41 ` [PATCH 4/5] tcf-agent: Add LCL_STOP_SERVICES for powerpc64 LE Khem Raj
2020-01-18 19:41 ` [PATCH 5/5] ghostscript: Add powerpc64 LE specific objarch.h Khem Raj

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.