test suite reviews and discussions
 help / color / mirror / Atom feed
From: Radoslaw Biernacki <radoslaw.biernacki@linaro.org>
To: dts@dpdk.org, Ayuj.Verma@cavium.com, Nartu.Jogarao@cavium.com
Cc: Herbert Guan <herbert.guan@linaro.org>,
	 Radoslaw Biernacki <radoslaw.biernacki@linaro.org>,
	aczubak@caviumnetworks.com, "Liu, Yong" <yong.liu@intel.com>
Subject: Re: [dts] [PATCH 1/4] framework/crb: Fixing ThunderX ethernet controler detection
Date: Mon, 4 Dec 2017 11:44:53 +0100	[thread overview]
Message-ID: <CAEK-wKmormHu6GJ_b2TyRo_PvkkozwCc9T4VsHEONOdKcaJtYw@mail.gmail.com> (raw)
In-Reply-To: <1512163254-31552-2-git-send-email-radoslaw.biernacki@linaro.org>

[-- Attachment #1: Type: text/plain, Size: 2151 bytes --]

Ayuj and Jogarao you might also be interested to look at this one.

On 1 December 2017 at 22:20, Radoslaw Biernacki <
radoslaw.biernacki@linaro.org> wrote:

> Asking for link speed for ThunderX Ethernet controller is not reliable
> since driver report error when the link is down. In fact we dont need
> to ask for link speed as Ethernet controllers can be easily identified
> by device name from lspci. The mapping will fuhrer filter out the PF
> and VF interfaces which does not have the interface name assigned.
>
> Fixes: 150716d93f5e ("framework crb: Appending only 10G devices for
> cavium")
>
> Signed-off-by: Radoslaw Biernacki <radoslaw.biernacki@linaro.org>
> ---
>  framework/crb.py | 11 ++---------
>  1 file changed, 2 insertions(+), 9 deletions(-)
>
> diff --git a/framework/crb.py b/framework/crb.py
> index dd29a8b..36b1ffe 100644
> --- a/framework/crb.py
> +++ b/framework/crb.py
> @@ -268,20 +268,13 @@ class Crb(object):
>          Look for the NIC's information (PCI Id and card type).
>          """
>          out = self.send_expect(
> -            "lspci -Dnn | grep -i eth", "# ", alt_session=True)
> +            "lspci -Dnn | grep -i 'Ethernet controller'", "# ",
> alt_session=True)
>          rexp = r"([\da-f]{4}:[\da-f]{2}:[\da-f]{2}.\d{1}) .*Eth.*?ernet
> .*?([\da-f]{4}:[\da-f]{4})"
>          pattern = re.compile(rexp)
>          match = pattern.findall(out)
>          self.pci_devices_info = []
>          for i in range(len(match)):
> -            #check if device is cavium and check its linkspeed, append
> only if it is 10G
> -            if "177d:" in match[i][1]:
> -                linkspeed = "10000"
> -                nic_linkspeed = self.send_command("cat
> /sys/bus/pci/devices/%s/net/*/speed" % match[i][0])
> -                if nic_linkspeed == linkspeed:
> -                    self.pci_devices_info.append((match[i][0],
> match[i][1]))
> -            else:
> -                self.pci_devices_info.append((match[i][0], match[i][1]))
> +            self.pci_devices_info.append((match[i][0], match[i][1]))
>
>      def pci_devices_information_uncached_freebsd(self):
>          """
> --
> 2.7.4
>
>

[-- Attachment #2: Type: text/html, Size: 2983 bytes --]

  reply	other threads:[~2017-12-04 10:45 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-12-01 21:20 [dts] [PATCH 0/4] ThunderX DTS initialization phase fixes Radoslaw Biernacki
2017-12-01 21:20 ` [dts] [PATCH 1/4] framework/crb: Fixing ThunderX ethernet controler detection Radoslaw Biernacki
2017-12-04 10:44   ` Radoslaw Biernacki [this message]
     [not found]     ` <CY4PR07MB2920B4D6EB1565292042CC4CF43C0@CY4PR07MB2920.namprd07.prod.outlook.com>
2017-12-04 13:57       ` Radoslaw Biernacki
2017-12-05  1:45         ` Liu, Yong
2017-12-01 21:20 ` [dts] [PATCH 2/4] framework: Fixing unnamed interface detection Radoslaw Biernacki
2017-12-01 21:20 ` [dts] [PATCH 3/4] framework/dut: fixing mixed tab and space python indention Radoslaw Biernacki
2017-12-01 21:20 ` [dts] [PATCH 4/4] framework/dut: Adding exception in case ports_map is empty Radoslaw Biernacki

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=CAEK-wKmormHu6GJ_b2TyRo_PvkkozwCc9T4VsHEONOdKcaJtYw@mail.gmail.com \
    --to=radoslaw.biernacki@linaro.org \
    --cc=Ayuj.Verma@cavium.com \
    --cc=Nartu.Jogarao@cavium.com \
    --cc=aczubak@caviumnetworks.com \
    --cc=dts@dpdk.org \
    --cc=herbert.guan@linaro.org \
    --cc=yong.liu@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).