[v17,2/8] net/bnxt: fix aarch32 build

Message ID 1619095749-7948-3-git-send-email-juraj.linkes@pantheon.tech (mailing list archive)
State Superseded, archived
Delegated to: Thomas Monjalon
Headers
Series aarch64 -> aarch32 cross compilation support |

Checks

Context Check Description
ci/checkpatch success coding style OK

Commit Message

Juraj Linkeš April 22, 2021, 12:49 p.m. UTC
  From: Ruifeng Wang <ruifeng.wang@arm.com>

NEON vector path of the PMD needs aarch64 support. But it was
enabled for aarch32 build as well because aarch32 build had
cpu_family set to aarch64. So build for aarch32 will fail due
to unsupported intrinsics.

Fix aarch32 build by updating meson file to exclude NEON vector
implementation for aarch32.

Fixes: 398358341419 ("net/bnxt: support NEON")
Cc: lance.richardson@broadcom.com
Cc: stable@dpdk.org

Signed-off-by: Ruifeng Wang <ruifeng.wang@arm.com>
Reviewed-by: Lance Richardson <lance.richardson@broadcom.com>
---
 drivers/net/bnxt/meson.build | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
  

Comments

Ajit Khaparde April 22, 2021, 6:50 p.m. UTC | #1
On Thu, Apr 22, 2021 at 5:49 AM Juraj Linkeš <juraj.linkes@pantheon.tech> wrote:
>
> From: Ruifeng Wang <ruifeng.wang@arm.com>
>
> NEON vector path of the PMD needs aarch64 support. But it was
> enabled for aarch32 build as well because aarch32 build had
> cpu_family set to aarch64. So build for aarch32 will fail due
> to unsupported intrinsics.
>
> Fix aarch32 build by updating meson file to exclude NEON vector
> implementation for aarch32.
>
> Fixes: 398358341419 ("net/bnxt: support NEON")
> Cc: lance.richardson@broadcom.com
> Cc: stable@dpdk.org
>
> Signed-off-by: Ruifeng Wang <ruifeng.wang@arm.com>
> Reviewed-by: Lance Richardson <lance.richardson@broadcom.com>
Acked-by: Ajit Khaparde <ajit.khaparde@broadcom.com>


> ---
>  drivers/net/bnxt/meson.build | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/net/bnxt/meson.build b/drivers/net/bnxt/meson.build
> index 117c753489..5a72989915 100644
> --- a/drivers/net/bnxt/meson.build
> +++ b/drivers/net/bnxt/meson.build
> @@ -82,6 +82,6 @@ sources = files(
>
>  if arch_subdir == 'x86'
>      sources += files('bnxt_rxtx_vec_sse.c')
> -elif arch_subdir == 'arm' and host_machine.cpu_family().startswith('aarch64')
> +elif arch_subdir == 'arm' and dpdk_conf.get('RTE_ARCH_64')
>      sources += files('bnxt_rxtx_vec_neon.c')
>  endif
> --
> 2.20.1
>
  

Patch

diff --git a/drivers/net/bnxt/meson.build b/drivers/net/bnxt/meson.build
index 117c753489..5a72989915 100644
--- a/drivers/net/bnxt/meson.build
+++ b/drivers/net/bnxt/meson.build
@@ -82,6 +82,6 @@  sources = files(
 
 if arch_subdir == 'x86'
     sources += files('bnxt_rxtx_vec_sse.c')
-elif arch_subdir == 'arm' and host_machine.cpu_family().startswith('aarch64')
+elif arch_subdir == 'arm' and dpdk_conf.get('RTE_ARCH_64')
     sources += files('bnxt_rxtx_vec_neon.c')
 endif