From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <dev-bounces@dpdk.org>
Received: from dpdk.org (dpdk.org [92.243.14.124])
	by inbox.dpdk.org (Postfix) with ESMTP id 34AADA09EA;
	Wed,  9 Dec 2020 14:02:00 +0100 (CET)
Received: from [92.243.14.124] (localhost [127.0.0.1])
	by dpdk.org (Postfix) with ESMTP id C8F93C9D4;
	Wed,  9 Dec 2020 13:59:54 +0100 (CET)
Received: from lb.pantheon.sk (lb.pantheon.sk [46.229.239.20])
 by dpdk.org (Postfix) with ESMTP id 3AA7EC968
 for <dev@dpdk.org>; Wed,  9 Dec 2020 13:59:45 +0100 (CET)
Received: from localhost (localhost [127.0.0.1])
 by lb.pantheon.sk (Postfix) with ESMTP id 8F89ABD2B8;
 Wed,  9 Dec 2020 13:59:44 +0100 (CET)
X-Virus-Scanned: amavisd-new at siecit.sk
Received: from lb.pantheon.sk ([127.0.0.1])
 by localhost (lb.pantheon.sk [127.0.0.1]) (amavisd-new, port 10024)
 with ESMTP id S8BfiuJhVHKl; Wed,  9 Dec 2020 13:59:43 +0100 (CET)
Received: from service-node1.lab.pantheon.local (unknown [46.229.239.141])
 by lb.pantheon.sk (Postfix) with ESMTP id 81782BC036;
 Wed,  9 Dec 2020 13:59:41 +0100 (CET)
From: =?UTF-8?q?Juraj=20Linke=C5=A1?= <juraj.linkes@pantheon.tech>
To: thomas@monjalon.net, bruce.richardson@intel.com, aconole@redhat.com,
 maicolgabriel@hotmail.com
Cc: dev@dpdk.org,
	juraj.linkes@pantheon.tech,
	Phil Yang <phil.yang@arm.com>
Date: Wed,  9 Dec 2020 13:59:31 +0100
Message-Id: <1607518771-7564-8-git-send-email-juraj.linkes@pantheon.tech>
X-Mailer: git-send-email 2.7.4
In-Reply-To: <1607518771-7564-1-git-send-email-juraj.linkes@pantheon.tech>
References: <1600244472-29696-1-git-send-email-juraj.linkes@pantheon.tech>
 <1607518771-7564-1-git-send-email-juraj.linkes@pantheon.tech>
Subject: [dpdk-dev] [PATCH v11 7/7] doc: add aarch32 build guidance
X-BeenThere: dev@dpdk.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: DPDK patches and discussions <dev.dpdk.org>
List-Unsubscribe: <https://mails.dpdk.org/options/dev>,
 <mailto:dev-request@dpdk.org?subject=unsubscribe>
List-Archive: <http://mails.dpdk.org/archives/dev/>
List-Post: <mailto:dev@dpdk.org>
List-Help: <mailto:dev-request@dpdk.org?subject=help>
List-Subscribe: <https://mails.dpdk.org/listinfo/dev>,
 <mailto:dev-request@dpdk.org?subject=subscribe>
Errors-To: dev-bounces@dpdk.org
Sender: "dev" <dev-bounces@dpdk.org>

From: Phil Yang <phil.yang@arm.com>

Add cross-compiling guidance for 32-bit aarch32 DPDK on aarch64 host.

Signed-off-by: Phil Yang <phil.yang@arm.com>
Acked-by: Ruifeng Wang <ruifeng.wang@arm.com>
---
 .../linux_gsg/cross_build_dpdk_for_arm64.rst  | 34 +++++++++++++------
 1 file changed, 24 insertions(+), 10 deletions(-)

diff --git a/doc/guides/linux_gsg/cross_build_dpdk_for_arm64.rst b/doc/guides/linux_gsg/cross_build_dpdk_for_arm64.rst
index 8a1d0e88b..1f2ff751d 100644
--- a/doc/guides/linux_gsg/cross_build_dpdk_for_arm64.rst
+++ b/doc/guides/linux_gsg/cross_build_dpdk_for_arm64.rst
@@ -1,15 +1,16 @@
 ..  SPDX-License-Identifier: BSD-3-Clause
     Copyright(c) 2018 ARM Corporation.
 
-Cross compile DPDK for ARM64
-============================
-This chapter describes how to cross compile DPDK for ARM64 from x86 build hosts.
+Cross compile DPDK for aarch64 and aarch32
+==========================================
+This chapter describes how to cross compile DPDK for aarch64 from x86 build hosts and compile
+32-bit aarch32 DPDK from aarch64 build hosts.
 
 .. note::
 
-   Whilst it is recommended to natively build DPDK on ARM64 (just
-   like with x86), it is also possible to cross-build DPDK for ARM64. An
-   ARM64 cross compile GNU toolchain is used for this.
+   Whilst it is recommended to natively build DPDK on aarch64 (just
+   like with x86), it is also possible to cross-build DPDK for aarch64.
+   An aarch64 cross compile GNU toolchain is used for this.
 
 Obtain the cross tool chain
 ---------------------------
@@ -88,14 +89,27 @@ To install it in Ubuntu::
 
    sudo apt-get install pkg-config-aarch64-linux-gnu
 
-To cross-compile DPDK on a desired target machine we can use the following
-command::
+.. note::
+
+    Some aarch64 platforms support EL0 aarch32 mode, which means the 32-bit aarch32 applications
+    can run on aarch64. The armhf architecture toolchain ``gcc-arm-linux-gnueabihf`` is required
+    for aarch32 on aarch64. To install it in Ubuntu::
+
+       sudo dpkg --add-architecture armhf
+       sudo apt-get update
+       sudo apt-get install -y gcc-arm-linux-gnueabihf libc6:armhf binutils
+
+To cross-compile DPDK on a desired target machine use the following command::
 
 	meson cross-build --cross-file <target_machine_configuration>
 	ninja -C cross-build
 
-For example if the target machine is arm64 we can use the following
-command::
+For example if the target machine is aarch64 use the following command::
 
 	meson arm64-build --cross-file config/arm/arm64_armv8_linux_gcc
 	ninja -C arm64-build
+
+If the target machine is aarch32 use the following command::
+
+	meson arm32-build --cross-file config/arm/arm32_armv8a_linux_gcc
+	ninja -C arm32-build
-- 
2.20.1