test suite reviews and discussions
 help / color / mirror / Atom feed
* [dts] [PATCH V1] tests/unit_tests_lpm: fix lpm set hugepage failed
@ 2017-08-31  9:47 lu,peipei
  2017-09-01  1:47 ` Liu, Yong
  0 siblings, 1 reply; 2+ messages in thread
From: lu,peipei @ 2017-08-31  9:47 UTC (permalink / raw)
  To: dts; +Cc: lu,peipei

Now all servers hugepage size were set 1G by default,the source codes were not must.

Signed-off-by: lu,peipei <peipeix.lu@intel.com>
---
 tests/TestSuite_unit_tests_lpm.py | 12 ------------
 1 file changed, 12 deletions(-)

diff --git a/tests/TestSuite_unit_tests_lpm.py b/tests/TestSuite_unit_tests_lpm.py
index e8149ff..792be40 100644
--- a/tests/TestSuite_unit_tests_lpm.py
+++ b/tests/TestSuite_unit_tests_lpm.py
@@ -81,21 +81,9 @@ class TestUnitTestsLpmIpv6(TestCase):
         """
         [arch, machine, env, toolchain] = self.target.split('-')
         self.verify(arch in ["x86_64", "arm64"], "lpm6 request huge memory")
-        if env == 'bsdapp':
-            pass
-        else:
-            hugepage_ori = self.dut.get_total_huge_pages()
-            self.dut.set_huge_pages(4096)
-            hugepage_num = self.dut.get_total_huge_pages()
-            self.verify(hugepage_num >= 4096, "failed to request huge memory")
-
         self.dut.send_expect("./%s/app/test -n 1 -c f" % self.target, "R.*T.*E.*>.*>", 60)
         out = self.dut.send_expect("lpm6_autotest", "RTE>>", 3600)
         self.dut.send_expect("quit", "# ")
-        if env == 'bsdapp':
-            pass
-        else:
-            self.dut.set_huge_pages(hugepage_ori)
         self.verify("Test OK" in out, "Test failed")
 
     def tear_down(self):
-- 
1.9.3

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

* Re: [dts] [PATCH V1] tests/unit_tests_lpm: fix lpm set hugepage failed
  2017-08-31  9:47 [dts] [PATCH V1] tests/unit_tests_lpm: fix lpm set hugepage failed lu,peipei
@ 2017-09-01  1:47 ` Liu, Yong
  0 siblings, 0 replies; 2+ messages in thread
From: Liu, Yong @ 2017-09-01  1:47 UTC (permalink / raw)
  To: Lu, PeipeiX, dts; +Cc: Lu, PeipeiX

Peipei,
We can assume that every host have the same setting as yours. 
There're two options here, one is like original version, just allocate enough hugepage for this case.
The second option is that check the number of hugepages, raise one error if not enough. 


Thanks,
Marvin

> -----Original Message-----
> From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of lu,peipei
> Sent: Thursday, August 31, 2017 5:47 PM
> To: dts@dpdk.org
> Cc: Lu, PeipeiX <peipeix.lu@intel.com>
> Subject: [dts] [PATCH V1] tests/unit_tests_lpm: fix lpm set hugepage
> failed
> 
> Now all servers hugepage size were set 1G by default,the source codes were
> not must.
> 
> Signed-off-by: lu,peipei <peipeix.lu@intel.com>
> ---
>  tests/TestSuite_unit_tests_lpm.py | 12 ------------
>  1 file changed, 12 deletions(-)
> 
> diff --git a/tests/TestSuite_unit_tests_lpm.py
> b/tests/TestSuite_unit_tests_lpm.py
> index e8149ff..792be40 100644
> --- a/tests/TestSuite_unit_tests_lpm.py
> +++ b/tests/TestSuite_unit_tests_lpm.py
> @@ -81,21 +81,9 @@ class TestUnitTestsLpmIpv6(TestCase):
>          """
>          [arch, machine, env, toolchain] = self.target.split('-')
>          self.verify(arch in ["x86_64", "arm64"], "lpm6 request huge
> memory")
> -        if env == 'bsdapp':
> -            pass
> -        else:
> -            hugepage_ori = self.dut.get_total_huge_pages()
> -            self.dut.set_huge_pages(4096)
> -            hugepage_num = self.dut.get_total_huge_pages()
> -            self.verify(hugepage_num >= 4096, "failed to request huge
> memory")
> -
>          self.dut.send_expect("./%s/app/test -n 1 -c f" % self.target,
> "R.*T.*E.*>.*>", 60)
>          out = self.dut.send_expect("lpm6_autotest", "RTE>>", 3600)
>          self.dut.send_expect("quit", "# ")
> -        if env == 'bsdapp':
> -            pass
> -        else:
> -            self.dut.set_huge_pages(hugepage_ori)
>          self.verify("Test OK" in out, "Test failed")
> 
>      def tear_down(self):
> --
> 1.9.3

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

end of thread, other threads:[~2017-09-01  1:47 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-08-31  9:47 [dts] [PATCH V1] tests/unit_tests_lpm: fix lpm set hugepage failed lu,peipei
2017-09-01  1:47 ` Liu, Yong

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).