patches for DPDK stable branches
 help / color / mirror / Atom feed
From: Kevin Traynor <ktraynor@redhat.com>
To: Robin Jarry <robin.jarry@6wind.com>
Cc: Stephen Hemminger <stephen@networkplumber.org>,
	dpdk stable <stable@dpdk.org>
Subject: [dpdk-stable] patch 'usertools: fix telemetry client with python 3' has been queued to LTS release 18.11.6
Date: Tue, 10 Dec 2019 14:59:20 +0000	[thread overview]
Message-ID: <20191210145937.32755-46-ktraynor@redhat.com> (raw)
In-Reply-To: <20191210145937.32755-1-ktraynor@redhat.com>

Hi,

FYI, your patch has been queued to LTS release 18.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 12/16/19. So please
shout if anyone has objections.

Also note that after the patch there's a diff of the upstream commit vs the
patch applied to the branch. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/kevintraynor/dpdk-stable-queue

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable-queue/commit/66742b2c696789ef642042d035284bf1fc4f3a26

Thanks.

Kevin.

---
From 66742b2c696789ef642042d035284bf1fc4f3a26 Mon Sep 17 00:00:00 2001
From: Robin Jarry <robin.jarry@6wind.com>
Date: Thu, 17 Oct 2019 19:32:12 +0200
Subject: [PATCH] usertools: fix telemetry client with python 3

[ upstream commit fe35622659edc678992aea389beb152105051e7f ]

When running the dpdk-telemetry-client.py with python 3, we get the
following syntax errors:

  File "usertools/dpdk-telemetry-client.py", line 70
      print "\nResponse: \n", str(data)
                           ^
  SyntaxError: invalid syntax

  File "usertools/dpdk-telemetry-client.py", line 93
      print "\nResponse: \n", str(data)
                           ^
  SyntaxError: invalid syntax

  File "usertools/dpdk-telemetry-client.py", line 111
      file_path = sys.argv[1]
                            ^
  TabError: inconsistent use of tabs and spaces in indentation

Import print_function from __future__ and add parentheses where missing.
Also, use spaces for indentation everywhere.

Fixes: d1b94da4a4e0 ("usertools: add client script for telemetry")
Fixes: 53f293c9a783 ("usertools: replace unsafe input function")
Fixes: 4080e46c8078 ("telemetry: support global metrics")

Signed-off-by: Robin Jarry <robin.jarry@6wind.com>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
---
 usertools/dpdk-telemetry-client.py | 12 +++++++-----
 1 file changed, 7 insertions(+), 5 deletions(-)

diff --git a/usertools/dpdk-telemetry-client.py b/usertools/dpdk-telemetry-client.py
index e0587022c..1c61a2a28 100644
--- a/usertools/dpdk-telemetry-client.py
+++ b/usertools/dpdk-telemetry-client.py
@@ -2,4 +2,6 @@
 # Copyright(c) 2018 Intel Corporation
 
+from __future__ import print_function
+
 import socket
 import os
@@ -15,7 +17,7 @@ DEFAULT_FP = "/var/run/dpdk/default_client"
 
 try:
-	raw_input  # Python 2
+    raw_input  # Python 2
 except NameError:
-	raw_input = input  # Python 3
+    raw_input = input  # Python 3
 
 class Socket:
@@ -73,5 +75,5 @@ class Client:
         self.socket.client_fd.send(METRICS_REQ)
         data = self.socket.client_fd.recv(BUFFER_SIZE)
-        print "\nResponse: \n", str(data)
+        print("\nResponse: \n", str(data))
 
     def repeatedlyRequestMetrics(self, sleep_time): # Recursively requests metrics for given client
@@ -112,8 +114,8 @@ if __name__ == "__main__":
     file_path = ""
     if (len(sys.argv) == 2):
-	file_path = sys.argv[1]
+        file_path = sys.argv[1]
     else:
         print("Warning - No filepath passed, using default (" + DEFAULT_FP + ").")
-	file_path = DEFAULT_FP
+        file_path = DEFAULT_FP
     client = Client()
     client.getFilepath(file_path)
-- 
2.21.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-12-10 14:49:42.153148203 +0000
+++ 0046-usertools-fix-telemetry-client-with-python-3.patch	2019-12-10 14:49:39.077457301 +0000
@@ -1 +1 @@
-From fe35622659edc678992aea389beb152105051e7f Mon Sep 17 00:00:00 2001
+From 66742b2c696789ef642042d035284bf1fc4f3a26 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit fe35622659edc678992aea389beb152105051e7f ]
+
@@ -30 +31,0 @@
-Cc: stable@dpdk.org
@@ -35,2 +36,2 @@
- usertools/dpdk-telemetry-client.py | 14 ++++++++------
- 1 file changed, 8 insertions(+), 6 deletions(-)
+ usertools/dpdk-telemetry-client.py | 12 +++++++-----
+ 1 file changed, 7 insertions(+), 5 deletions(-)
@@ -39 +40 @@
-index 60fe97af7..e06d6306c 100755
+index e0587022c..1c61a2a28 100644
@@ -42 +43 @@
-@@ -3,4 +3,6 @@
+@@ -2,4 +2,6 @@
@@ -49 +50 @@
-@@ -17,7 +19,7 @@ DEFAULT_FP = "/var/run/dpdk/default_client"
+@@ -15,7 +17,7 @@ DEFAULT_FP = "/var/run/dpdk/default_client"
@@ -59 +60 @@
-@@ -75,5 +77,5 @@ class Client:
+@@ -73,5 +75,5 @@ class Client:
@@ -66,8 +67 @@
-@@ -89,5 +91,5 @@ class Client:
-         self.socket.client_fd.send(GLOBAL_METRICS_REQ)
-         data = self.socket.client_fd.recv(BUFFER_SIZE)
--        print "\nResponse: \n", str(data)
-+        print("\nResponse: \n", str(data))
- 
-     def interactiveMenu(self, sleep_time): # Creates Interactive menu within the script
-@@ -122,8 +124,8 @@ if __name__ == "__main__":
+@@ -112,8 +114,8 @@ if __name__ == "__main__":


  parent reply	other threads:[~2019-12-10 15:01 UTC|newest]

Thread overview: 63+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-12-10 14:58 [dpdk-stable] patch 'app/testpmd: fix CRC strip command' " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'net/i40e: fix integer overflow' " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'vhost: translate incoming log address to GPA' " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'vhost: fix virtqueue not accessible' " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'vhost: prevent zero copy mode if IOMMU is on' " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'net/i40e: fix address of first segment' " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'net/ixgbe: " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'doc: fix a common typo in NIC guides' " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'app/testpmd: fix help for loop topology option' " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'net/mlx4: remove dependency on libmnl in meson' " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'net/axgbe: fix double unlock' " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'net/af_packet: improve Tx statistics accuracy' " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'net/enetc: fix BD ring alignment' " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'bus/fslmc: fix global variable multiple definitions' " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'net/igb: " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'crypto/null: " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'crypto/virtio: " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'compress/octeontx: " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'test: " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'reciprocal: fix off-by-one with 32-bit divisor' " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'vfio: fix truncated BAR offset for 32-bit' " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'ethdev: fix include of ethernet header file' " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'net/bnxt: fix mbuf free when clearing Tx queue' " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'net/i40e: fix exception with multi-driver' " Kevin Traynor
2019-12-10 14:58 ` [dpdk-stable] patch 'net/ixgbe: fix zeroing of RSS config' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'net/e1000: " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'net/virtio: reject deferred Rx start' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'net/virtio: reject deferred Tx " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'net/virtio: reject unsupported Rx multi-queue modes' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'net/virtio: reject unsupported Tx " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'vhost: fix IPv4 checksum' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'net/mlx: fix debug build with icc' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'app/testpmd: fix Tx checksum when TSO enabled' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'net/bnxt: fix ping with MTU change' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'net/bnxt: fix setting max RSS contexts' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'net/bnxt: fix writing MTU to FW' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'net/bnxt: expose some missing counters in port stats' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'net/bonding: use non deprecated PCI API' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'vhost: fix build on RHEL 7.6 for Power' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'app/procinfo: use strlcpy for copying string' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'examples/vm_power: fix type of cmdline token in cli' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'examples/l3fwd-power: fix Rx interrupt disabling' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'power: fix socket indicator value' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'examples/vm_power: fix build without i40e' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'usertools: fix pmdinfo with python 3 and pyelftools>=0.24' " Kevin Traynor
2019-12-10 14:59 ` Kevin Traynor [this message]
2019-12-10 14:59 ` [dpdk-stable] patch 'doc: fix description of links to EAL options pages' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'common/dpaax: fallback to check separate memory node for VM' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'doc: fix description of versioning macros' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'eventdev: fix possible use of uninitialized var' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'common/cpt: fix possible null dereference' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'compress/octeontx: remove commented out code' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'event/opdl: " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'net/bnxt: " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'mk: fix build on arm64' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'crypto/dpaa2_sec: fix length retrieved from hardware' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'examples/ipsec-secgw: fix GCM IV length' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'examples/ipsec-secgw: fix SHA256-HMAC digest " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'crypto/openssl: use local copy for session contexts' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'net/fm10k: fix mbuf free in vector Rx' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'net/igb: fix PHY status if PHY reset is not blocked' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'net/bonding: fix port ID check' " Kevin Traynor
2019-12-10 14:59 ` [dpdk-stable] patch 'port: fix pcap support with meson' " Kevin Traynor

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=20191210145937.32755-46-ktraynor@redhat.com \
    --to=ktraynor@redhat.com \
    --cc=robin.jarry@6wind.com \
    --cc=stable@dpdk.org \
    --cc=stephen@networkplumber.org \
    /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).