DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH  v2 0/3] add travis ci support for ppc64le
@ 2020-02-19  1:10 David Wilder
  2020-02-19  1:10 ` [dpdk-dev] [PATCH v2 1/3] eal/linux: select iova-mode va with no-huge option David Wilder
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: David Wilder @ 2020-02-19  1:10 UTC (permalink / raw)
  To: aconole, maicolgabriel, thomas, ferruh.yigit, arybchenko
  Cc: dev, ruifeng.wang, david.marchand, drc, wilder

This patch series adds Travis gcc compilation jobs for ppc64le.
Limitations for ppc64le are similar to arm64 (see commit
31bb45bcfd).

1. Only gcc builds are supported on ppc64le.

2. A container is used, therefor Huge pages are not available.
   Unit tests are not run, a single test (test-null) using the
   no-huge option is run.

V2: Insures iova-mode is VA when --no-huge is selected.
    Removed setting of --iova-mode=VA in test-null.sh.

A Travis build with theses patches can be found here:
https://travis-ci.org/djlwilder/dpdk/builds/652238523

David Wilder (3):
  eal/linux: select iova-mode va with no-huge option
  devtools: allow test-null.sh to run on ppc64le
  ci: add travis ci support for native ppc64le

 .travis.yml                    | 30 ++++++++++++++++++++++++++++++
 devtools/test-null.sh          |  2 +-
 lib/librte_eal/linux/eal/eal.c | 14 ++++++++++++++
 3 files changed, 45 insertions(+), 1 deletion(-)

-- 
2.25.0


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

* [dpdk-dev] [PATCH v2 1/3] eal/linux: select iova-mode va with no-huge option
  2020-02-19  1:10 [dpdk-dev] [PATCH v2 0/3] add travis ci support for ppc64le David Wilder
@ 2020-02-19  1:10 ` David Wilder
  2020-02-19  1:10 ` [dpdk-dev] [PATCH v2 2/3] devtools: allow test-null.sh to run on ppc64le David Wilder
  2020-02-19  1:10 ` [dpdk-dev] [PATCH v2 3/3] ci: add travis ci support for native ppc64le David Wilder
  2 siblings, 0 replies; 7+ messages in thread
From: David Wilder @ 2020-02-19  1:10 UTC (permalink / raw)
  To: aconole, maicolgabriel, thomas, ferruh.yigit, arybchenko
  Cc: dev, ruifeng.wang, david.marchand, drc, wilder

If --no-huge is set and iova-mode has not been specified force VA mode.
If --no-huge and --iova-mode=PA is requested error out as this is
an impossible configuration.

Signed-off-by: David Wilder <dwilder@us.ibm.com>
---
 lib/librte_eal/linux/eal/eal.c | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/lib/librte_eal/linux/eal/eal.c b/lib/librte_eal/linux/eal/eal.c
index 9530ee55f..d3a0a1731 100644
--- a/lib/librte_eal/linux/eal/eal.c
+++ b/lib/librte_eal/linux/eal/eal.c
@@ -1062,9 +1062,16 @@ rte_eal_init(int argc, char **argv)
 
 	/* if no EAL option "--iova-mode=<pa|va>", use bus IOVA scheme */
 	if (internal_config.iova_mode == RTE_IOVA_DC) {
+
 		/* autodetect the IOVA mapping mode */
 		enum rte_iova_mode iova_mode = rte_bus_get_iommu_class();
 
+		if (iova_mode == RTE_IOVA_PA && !rte_eal_has_hugepages()) {
+			iova_mode = RTE_IOVA_VA;
+			RTE_LOG(WARNING, EAL, "Some buses want 'PA' but forcing 'VA' because --no-huge is requested.\n");
+			RTE_LOG(WARNING, EAL, "Not all buses may be able to initialize.\n");
+		}
+
 		if (iova_mode == RTE_IOVA_DC) {
 			RTE_LOG(DEBUG, EAL, "Buses did not request a specific IOVA mode.\n");
 
@@ -1111,6 +1118,13 @@ rte_eal_init(int argc, char **argv)
 			internal_config.iova_mode;
 	}
 
+	if (rte_eal_iova_mode() == RTE_IOVA_PA &&
+	    rte_eal_has_hugepages() == 0) {
+		rte_eal_init_alert("Cannot use IOVA as 'PA' with --no-huge");
+		rte_errno = EINVAL;
+		return -1;
+	}
+
 	if (rte_eal_iova_mode() == RTE_IOVA_PA && !phys_addrs) {
 		rte_eal_init_alert("Cannot use IOVA as 'PA' since physical addresses are not available");
 		rte_errno = EINVAL;
-- 
2.25.0


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

* [dpdk-dev] [PATCH v2 2/3] devtools: allow test-null.sh to run on ppc64le
  2020-02-19  1:10 [dpdk-dev] [PATCH v2 0/3] add travis ci support for ppc64le David Wilder
  2020-02-19  1:10 ` [dpdk-dev] [PATCH v2 1/3] eal/linux: select iova-mode va with no-huge option David Wilder
@ 2020-02-19  1:10 ` David Wilder
  2020-02-19  1:10 ` [dpdk-dev] [PATCH v2 3/3] ci: add travis ci support for native ppc64le David Wilder
  2 siblings, 0 replies; 7+ messages in thread
From: David Wilder @ 2020-02-19  1:10 UTC (permalink / raw)
  To: aconole, maicolgabriel, thomas, ferruh.yigit, arybchenko
  Cc: dev, ruifeng.wang, david.marchand, drc, wilder

Memory requirements are larger for ppc64le
due to a higher RTE_MAX_LCORE value.

Signed-off-by: David Wilder <dwilder@us.ibm.com>
Reviewed-by: David Christensen <drc@linux.vnet.ibm.com>
---
 devtools/test-null.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/devtools/test-null.sh b/devtools/test-null.sh
index 548de8113..b7defe1fd 100755
--- a/devtools/test-null.sh
+++ b/devtools/test-null.sh
@@ -27,6 +27,6 @@ else
 fi
 
 (sleep 1 && echo stop) |
-$testpmd -c $coremask --no-huge -m 20 \
+$testpmd -c $coremask --no-huge -m 30 \
 	$libs -w 0:0.0 --vdev net_null1 --vdev net_null2 $eal_options -- \
 	--no-mlockall --total-num-mbufs=2048 $testpmd_options -ia
-- 
2.25.0


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

* [dpdk-dev] [PATCH v2 3/3] ci: add travis ci support for native ppc64le
  2020-02-19  1:10 [dpdk-dev] [PATCH v2 0/3] add travis ci support for ppc64le David Wilder
  2020-02-19  1:10 ` [dpdk-dev] [PATCH v2 1/3] eal/linux: select iova-mode va with no-huge option David Wilder
  2020-02-19  1:10 ` [dpdk-dev] [PATCH v2 2/3] devtools: allow test-null.sh to run on ppc64le David Wilder
@ 2020-02-19  1:10 ` David Wilder
  2020-02-19  7:55   ` Thomas Monjalon
  2020-02-19 13:46   ` David Marchand
  2 siblings, 2 replies; 7+ messages in thread
From: David Wilder @ 2020-02-19  1:10 UTC (permalink / raw)
  To: aconole, maicolgabriel, thomas, ferruh.yigit, arybchenko
  Cc: dev, ruifeng.wang, david.marchand, drc, wilder

This change follows the example of aarch64 Travis support
by adding support for ppc64le gcc builds.  Limitations for
ppc64le are the same as aarch64 as described in commit
31bb45bcfd.

Signed-off-by: David Wilder <dwilder@us.ibm.com>
Reviewed-by: David Christensen <drc@linux.vnet.ibm.com>
---
 .travis.yml | 30 ++++++++++++++++++++++++++++++
 1 file changed, 30 insertions(+)

diff --git a/.travis.yml b/.travis.yml
index 1d43f16ae..c15bf4f07 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -153,5 +153,35 @@ matrix:
         packages:
           - *extra_packages
           - *libabigail_build_packages
+  - env: DEF_LIB="static"
+    arch: ppc64le
+    compiler: gcc
+    addons:
+      apt:
+        packages:
+          - *required_packages
+  - env: DEF_LIB="shared"
+    arch: ppc64le
+    compiler: gcc
+    addons:
+      apt:
+        packages:
+          - *required_packages
+  - env: DEF_LIB="shared" OPTS="-Denable_kmods=false" BUILD_DOCS=1
+    arch: ppc64le
+    compiler: gcc
+    addons:
+      apt:
+        packages:
+          - *required_packages
+          - *doc_packages
+  - env: DEF_LIB="shared" EXTRA_PACKAGES=1 ABI_CHECKS=1
+    arch: ppc64le
+    compiler: gcc
+    addons:
+      apt:
+        packages:
+          - *extra_packages
+          - *libabigail_build_packages
 
 script: ./.ci/${TRAVIS_OS_NAME}-build.sh
-- 
2.25.0


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

* Re: [dpdk-dev] [PATCH v2 3/3] ci: add travis ci support for native ppc64le
  2020-02-19  1:10 ` [dpdk-dev] [PATCH v2 3/3] ci: add travis ci support for native ppc64le David Wilder
@ 2020-02-19  7:55   ` Thomas Monjalon
  2020-02-19 13:46   ` David Marchand
  1 sibling, 0 replies; 7+ messages in thread
From: Thomas Monjalon @ 2020-02-19  7:55 UTC (permalink / raw)
  To: David Wilder
  Cc: aconole, maicolgabriel, ferruh.yigit, arybchenko, dev,
	ruifeng.wang, david.marchand, drc

19/02/2020 02:10, David Wilder:
> This change follows the example of aarch64 Travis support
> by adding support for ppc64le gcc builds.  Limitations for
> ppc64le are the same as aarch64 as described in commit
> 31bb45bcfd.
> 
> Signed-off-by: David Wilder <dwilder@us.ibm.com>
> Reviewed-by: David Christensen <drc@linux.vnet.ibm.com>
> ---
> --- a/.travis.yml
> +++ b/.travis.yml
> +  - env: DEF_LIB="static"
> +    arch: ppc64le
> +    compiler: gcc
> +    addons:
> +      apt:
> +        packages:
> +          - *required_packages
> +  - env: DEF_LIB="shared"
> +    arch: ppc64le
> +    compiler: gcc
> +    addons:
> +      apt:
> +        packages:
> +          - *required_packages
> +  - env: DEF_LIB="shared" OPTS="-Denable_kmods=false" BUILD_DOCS=1

kmods are already disabled by default.

> +    arch: ppc64le
> +    compiler: gcc
> +    addons:
> +      apt:
> +        packages:
> +          - *required_packages
> +          - *doc_packages

Why testing without EXTRA_PACKAGES?

> +  - env: DEF_LIB="shared" EXTRA_PACKAGES=1 ABI_CHECKS=1
> +    arch: ppc64le
> +    compiler: gcc
> +    addons:
> +      apt:
> +        packages:
> +          - *extra_packages
> +          - *libabigail_build_packages




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

* Re: [dpdk-dev] [PATCH v2 3/3] ci: add travis ci support for native ppc64le
  2020-02-19  1:10 ` [dpdk-dev] [PATCH v2 3/3] ci: add travis ci support for native ppc64le David Wilder
  2020-02-19  7:55   ` Thomas Monjalon
@ 2020-02-19 13:46   ` David Marchand
  2020-02-19 20:32     ` dwilder
  1 sibling, 1 reply; 7+ messages in thread
From: David Marchand @ 2020-02-19 13:46 UTC (permalink / raw)
  To: David Wilder
  Cc: Aaron Conole, Michael Santana, Thomas Monjalon, Yigit, Ferruh,
	Andrew Rybchenko, dev, Ruifeng Wang (Arm Technology China),
	David Christensen, David Wilder

On Wed, Feb 19, 2020 at 2:10 AM David Wilder <dwilder@us.ibm.com> wrote:
>
> This change follows the example of aarch64 Travis support
> by adding support for ppc64le gcc builds.  Limitations for
> ppc64le are the same as aarch64 as described in commit
> 31bb45bcfd.

checkpatch did not catch it because of the \n (?).
When referring to other commits, please use the format 'commit <12+
chars of sha1> ("<title line>")'.


>
> Signed-off-by: David Wilder <dwilder@us.ibm.com>
> Reviewed-by: David Christensen <drc@linux.vnet.ibm.com>

I can see no clang compilation.
Is it unsupported? forgotten? unwanted?


> ---
>  .travis.yml | 30 ++++++++++++++++++++++++++++++
>  1 file changed, 30 insertions(+)
>
> diff --git a/.travis.yml b/.travis.yml
> index 1d43f16ae..c15bf4f07 100644
> --- a/.travis.yml
> +++ b/.travis.yml
> @@ -153,5 +153,35 @@ matrix:
>          packages:
>            - *extra_packages
>            - *libabigail_build_packages
> +  - env: DEF_LIB="static"
> +    arch: ppc64le
> +    compiler: gcc
> +    addons:
> +      apt:
> +        packages:
> +          - *required_packages

Copy/pasting this part is useless.
The addons: global node would make all jobs use this required_packages
as a default.
I have a patch cleaning this for arm.


> +  - env: DEF_LIB="shared"
> +    arch: ppc64le
> +    compiler: gcc
> +    addons:
> +      apt:
> +        packages:
> +          - *required_packages
> +  - env: DEF_LIB="shared" OPTS="-Denable_kmods=false" BUILD_DOCS=1
> +    arch: ppc64le
> +    compiler: gcc
> +    addons:
> +      apt:
> +        packages:
> +          - *required_packages
> +          - *doc_packages
> +  - env: DEF_LIB="shared" EXTRA_PACKAGES=1 ABI_CHECKS=1
> +    arch: ppc64le
> +    compiler: gcc
> +    addons:
> +      apt:
> +        packages:
> +          - *extra_packages
> +          - *libabigail_build_packages
>
>  script: ./.ci/${TRAVIS_OS_NAME}-build.sh
> --
> 2.25.0
>


-- 
David Marchand


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

* Re: [dpdk-dev] [PATCH v2 3/3] ci: add travis ci support for native ppc64le
  2020-02-19 13:46   ` David Marchand
@ 2020-02-19 20:32     ` dwilder
  0 siblings, 0 replies; 7+ messages in thread
From: dwilder @ 2020-02-19 20:32 UTC (permalink / raw)
  To: David Marchand
  Cc: Aaron Conole, Michael Santana, Thomas Monjalon, Yigit, Ferruh,
	Andrew Rybchenko, dev, Ruifeng Wang (Arm Technology China),
	David Christensen, David Wilder

On 2020-02-19 05:46, David Marchand wrote:
> On Wed, Feb 19, 2020 at 2:10 AM David Wilder <dwilder@us.ibm.com> 
> wrote:
>> 
>> This change follows the example of aarch64 Travis support
>> by adding support for ppc64le gcc builds.  Limitations for
>> ppc64le are the same as aarch64 as described in commit
>> 31bb45bcfd.
> 
> checkpatch did not catch it because of the \n (?).
> When referring to other commits, please use the format 'commit <12+
> chars of sha1> ("<title line>")'.
> 

Ok

> 
>> 
>> Signed-off-by: David Wilder <dwilder@us.ibm.com>
>> Reviewed-by: David Christensen <drc@linux.vnet.ibm.com>
> 
> I can see no clang compilation.
> Is it unsupported? forgotten? unwanted?
> 

Unsupported for now (issues with altivec).

> 
>> ---
>>  .travis.yml | 30 ++++++++++++++++++++++++++++++
>>  1 file changed, 30 insertions(+)
>> 
>> diff --git a/.travis.yml b/.travis.yml
>> index 1d43f16ae..c15bf4f07 100644
>> --- a/.travis.yml
>> +++ b/.travis.yml
>> @@ -153,5 +153,35 @@ matrix:
>>          packages:
>>            - *extra_packages
>>            - *libabigail_build_packages
>> +  - env: DEF_LIB="static"
>> +    arch: ppc64le
>> +    compiler: gcc
>> +    addons:
>> +      apt:
>> +        packages:
>> +          - *required_packages
> 
> Copy/pasting this part is useless.
> The addons: global node would make all jobs use this required_packages
> as a default.
> I have a patch cleaning this for arm.

I see your cleanup patch now.  I will refactor the ppc support on top 
and let you know if I have issues.

Thanks for the review.

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

end of thread, other threads:[~2020-02-19 20:32 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-02-19  1:10 [dpdk-dev] [PATCH v2 0/3] add travis ci support for ppc64le David Wilder
2020-02-19  1:10 ` [dpdk-dev] [PATCH v2 1/3] eal/linux: select iova-mode va with no-huge option David Wilder
2020-02-19  1:10 ` [dpdk-dev] [PATCH v2 2/3] devtools: allow test-null.sh to run on ppc64le David Wilder
2020-02-19  1:10 ` [dpdk-dev] [PATCH v2 3/3] ci: add travis ci support for native ppc64le David Wilder
2020-02-19  7:55   ` Thomas Monjalon
2020-02-19 13:46   ` David Marchand
2020-02-19 20:32     ` dwilder

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).