Patchwork Add architecture files for AArch64 architecture.

login
register
mail settings
Submitter Marcin Juszkiewicz
Date March 14, 2013, 5:41 p.m.
Message ID <1363282893-19390-1-git-send-email-marcin.juszkiewicz@linaro.org>
Download mbox | patch
Permalink /patch/46183/
State New
Headers show

Comments

Marcin Juszkiewicz - March 14, 2013, 5:41 p.m.
Signed-off-by: Marcin Juszkiewicz <marcin.juszkiewicz@linaro.org>
---
 meta/conf/machine/include/aarch64/README           |  9 +++++++++
 meta/conf/machine/include/aarch64/arch-aarch64.inc | 16 ++++++++++++++++
 2 files changed, 25 insertions(+)
 create mode 100644 meta/conf/machine/include/aarch64/README
 create mode 100644 meta/conf/machine/include/aarch64/arch-aarch64.inc
Mark Hatle - March 14, 2013, 6:04 p.m.
On 3/14/13 12:41 PM, Marcin Juszkiewicz wrote:
> Signed-off-by: Marcin Juszkiewicz <marcin.juszkiewicz@linaro.org>
> ---
>   meta/conf/machine/include/aarch64/README           |  9 +++++++++
>   meta/conf/machine/include/aarch64/arch-aarch64.inc | 16 ++++++++++++++++
>   2 files changed, 25 insertions(+)
>   create mode 100644 meta/conf/machine/include/aarch64/README
>   create mode 100644 meta/conf/machine/include/aarch64/arch-aarch64.inc
>
> diff --git a/meta/conf/machine/include/aarch64/README b/meta/conf/machine/include/aarch64/README
> new file mode 100644
> index 0000000..59c8710
> --- /dev/null
> +++ b/meta/conf/machine/include/aarch64/README
> @@ -0,0 +1,9 @@
> +2013-03-14 - Marcin Juszkiewicz <marcin.juszkiewicz@linaro.org>
> + - Initial Revision
> +
> +Currently only little endian is defined for AArch64.
> +
> +AArch64 is 64-bit ARM architecture.
> +
> +Also known as ARMv8 (instruction set) or ARM64 (name in Linux kernel and
> +architecture name in Debian and derived).
> diff --git a/meta/conf/machine/include/aarch64/arch-aarch64.inc b/meta/conf/machine/include/aarch64/arch-aarch64.inc
> new file mode 100644
> index 0000000..5177d7f
> --- /dev/null
> +++ b/meta/conf/machine/include/aarch64/arch-aarch64.inc
> @@ -0,0 +1,16 @@
> +DEFAULTTUNE ?= "aarch64"
> +
> +ARMPKGARCH ?= "aarch64"
> +
> +TUNEVALID[aarch64] = "Enable instructions for aarch64"
> +TUNECONFLICTS[aarch64] = ""
> +MACHINEOVERRIDES .= "${@bb.utils.contains("TUNE_FEATURES", "aarch64", ":aarch64", "" ,d)}"
> +
> +# Little Endian base configs
> +AVAILTUNES += "aarch64"
> +TUNE_FEATURES_tune-aarch64 ?= "aarch64"
> +
> +TUNE_ARCH = "aarch64"
> +TUNE_PKGARCH = "aarch64"
> +
> +PACKAGE_EXTRA_ARCHS += "aarch64"
>

I'm not completely familiar with aarch64.  So a couple of questions.  The first 
is is it supposed to allow a multilib configuration?  I.e. being able to run 
both 32-bit "arm/thumb" code & aarch64 code on the same machine?  If so, a 
"BASE_LIB_tune-aarch64" should be defined with the right value.

Second are there expected to be tuned variants for the aarch64, i.e. 
processor/core tunings that need to get embedded into the package arch.  if so 
the definition of the TUNE_ARCH and TUNE_PKGARCH should probably be based on the 
tune_feature...  (This may simply not be necessary though as this is a new 
architecture that will expand and grow...)

My suggestion then, to help with future growth is:

DEFAULTTUNE ?= "aarch64"

ARMPKGARCH ?= "aarch64"

TUNEVALID[aarch64] = "Enable instructions for aarch64"
TUNECONFLICTS[aarch64] = ""
MACHINEOVERRIDES .= "${@bb.utils.contains("TUNE_FEATURES", "aarch64", 
":aarch64", "" ,d)}"

# Little Endian base configs
AVAILTUNES += "aarch64"
TUNE_FEATURES_tune-aarch64 ?= "aarch64"
BASE_LIB_tune-aarch64 = "lib64" <-- guess on my part
TUNE_ARCH_tune-aarch64 = "aarch64"
TUNE_PKGARCH_tune-aarch64 = "aarch64"
PACKAGE_EXTRA_ARCHS_tune-aarch64 += "aarch64"

Patch

diff --git a/meta/conf/machine/include/aarch64/README b/meta/conf/machine/include/aarch64/README
new file mode 100644
index 0000000..59c8710
--- /dev/null
+++ b/meta/conf/machine/include/aarch64/README
@@ -0,0 +1,9 @@ 
+2013-03-14 - Marcin Juszkiewicz <marcin.juszkiewicz@linaro.org>
+ - Initial Revision
+
+Currently only little endian is defined for AArch64.
+
+AArch64 is 64-bit ARM architecture.
+
+Also known as ARMv8 (instruction set) or ARM64 (name in Linux kernel and
+architecture name in Debian and derived).
diff --git a/meta/conf/machine/include/aarch64/arch-aarch64.inc b/meta/conf/machine/include/aarch64/arch-aarch64.inc
new file mode 100644
index 0000000..5177d7f
--- /dev/null
+++ b/meta/conf/machine/include/aarch64/arch-aarch64.inc
@@ -0,0 +1,16 @@ 
+DEFAULTTUNE ?= "aarch64"
+
+ARMPKGARCH ?= "aarch64"
+
+TUNEVALID[aarch64] = "Enable instructions for aarch64"
+TUNECONFLICTS[aarch64] = ""
+MACHINEOVERRIDES .= "${@bb.utils.contains("TUNE_FEATURES", "aarch64", ":aarch64", "" ,d)}"
+
+# Little Endian base configs
+AVAILTUNES += "aarch64"
+TUNE_FEATURES_tune-aarch64 ?= "aarch64"
+
+TUNE_ARCH = "aarch64"
+TUNE_PKGARCH = "aarch64"
+
+PACKAGE_EXTRA_ARCHS += "aarch64"