From: "Tu, Lijuan" <lijuan.tu@intel.com>
To: "Zhu, WenhuiX" <wenhuix.zhu@intel.com>, "dts@dpdk.org" <dts@dpdk.org>
Cc: "Zhu, WenhuiX" <wenhuix.zhu@intel.com>
Subject: Re: [dts] [PATCH V1] tests/kni:set kni virtual interface carrier up automatically
Date: Mon, 5 Nov 2018 02:06:58 +0000 [thread overview]
Message-ID: <8CE3E05A3F976642AAB0F4675D0AD20E0B9B6703@SHSMSX101.ccr.corp.intel.com> (raw)
In-Reply-To: <1541139344-21101-1-git-send-email-wenhuix.zhu@intel.com>
> -----Original Message-----
> From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of zhuwenhui
> Sent: Friday, November 2, 2018 2:16 PM
> To: dts@dpdk.org
> Cc: Zhu, WenhuiX <wenhuix.zhu@intel.com>
> Subject: [dts] [PATCH V1] tests/kni:set kni virtual interface carrier up
> automatically
>
> kni interface carrier status is "off"by default, which is equivalent of cable not
> plugged in in physical device,so start kni sample application with -m
> parameter, set kni virtual interface carrier up automatically
[Lijuan] The description is not align with dpdk documentation. "-m" means enable link monitoring, and the link status will be updated to match the physical NIC port's state.
>
> Signed-off-by: zhuwenhui <wenhuix.zhu@intel.com>
> ---
> tests/TestSuite_kni.py | 20 +++++++++++++-------
> 1 file changed, 13 insertions(+), 7 deletions(-)
>
> diff --git a/tests/TestSuite_kni.py b/tests/TestSuite_kni.py index
> 5f81def..7655266 100644
> --- a/tests/TestSuite_kni.py
> +++ b/tests/TestSuite_kni.py
> @@ -277,7 +277,7 @@ class TestKni(TestCase):
> """
> pass
>
> - def start_kni(self, lo_mode=None, kthread_mode=None):
> + def start_kni(self, lo_mode=None, kthread_mode=None, status=True):
> """
> Insert the igb_uio and rte_kni modules with passed parameters
> and launch
> kni application.
> @@ -306,11 +306,17 @@ class TestKni(TestCase):
> self.config['rx_cores'] + self.config['tx_cores'] +
> self.config['kernel_cores'])
>
> config_param = self.build_config_param()
> -
> - out_kni = self.dut.send_expect(
> - './examples/kni/build/app/kni -c %s -n %d -- -P -p %s %s &' %
> - (core_mask, self.dut.get_memory_channels(), port_mask,
> config_param),
> - "Link Up", 20)
> +
> + if status is not True:
> + out_kni = self.dut.send_expect(
> + './examples/kni/build/app/kni -c %s -n %d -- -P -p %s %s
> -m &' %
> + (core_mask, self.dut.get_memory_channels(),
> port_mask, config_param),
> + "Link Up", 20)
> + else:
> + out_kni = self.dut.send_expect(
> + './examples/kni/build/app/kni -c %s -n %d -- -P -p %s %s
> &' %
> + (core_mask, self.dut.get_memory_channels(),
> port_mask, config_param),
> + "Link Up", 20)
>
> time.sleep(5)
> if kthread_mode == 'single':
> @@ -525,7 +531,7 @@ class TestKni(TestCase):
> # Ports and cores configuration set in set_up_all function
> # Setup IP address on virtual interfaces and tester ports
> self.dut.kill_all()
> - self.start_kni()
> + self.start_kni(status=False)
> for port in self.config['ports']:
> virtual_interface = self.virtual_interface_name(port)
>
> --
> 2.17.2
prev parent reply other threads:[~2018-11-05 2:07 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-11-02 6:15 zhuwenhui
2018-11-05 2:06 ` Tu, Lijuan [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=8CE3E05A3F976642AAB0F4675D0AD20E0B9B6703@SHSMSX101.ccr.corp.intel.com \
--to=lijuan.tu@intel.com \
--cc=dts@dpdk.org \
--cc=wenhuix.zhu@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).