[v2] usertools/telemetry: fix unused parameter

Message ID 20230523143855.218984-1-samina.arshad@intel.com (mailing list archive)
State Superseded, archived
Delegated to: akhil goyal
Headers
Series [v2] usertools/telemetry: fix unused parameter |

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/loongarch-compilation success Compilation OK
ci/loongarch-unit-testing success Unit Testing PASS
ci/iol-mellanox-Performance success Performance Testing PASS
ci/iol-abi-testing success Testing PASS
ci/iol-x86_64-compile-testing success Testing PASS
ci/iol-intel-Performance success Performance Testing PASS
ci/iol-broadcom-Performance success Performance Testing PASS
ci/iol-intel-Functional success Functional Testing PASS
ci/iol-broadcom-Functional success Functional Testing PASS
ci/iol-aarch64-unit-testing success Testing PASS
ci/iol-testing success Testing PASS
ci/iol-x86_64-unit-testing success Testing PASS
ci/iol-unit-testing success Testing PASS
ci/iol-aarch64-compile-testing success Testing PASS
ci/Intel-compilation success Compilation OK
ci/intel-Testing success Testing PASS
ci/intel-Functional success Functional PASS

Commit Message

Samina Arshad May 23, 2023, 2:38 p.m. UTC
  This bug fix ensures that the runtime socket path is generated
correctly, based on the user-specified file_prefix value,
resolving the issue that occurred in the previous implementation.

Fixes: a15fc792cfb6 ("usertools/telemetry: add file prefix argument")
Cc: lihuisong@huawei.com
Cc: stable@dpdk.org

Signed-off-by: Samina Arshad <samina.arshad@intel.com>
---
v2:
Made changes for previous commit to be efficient. Removed
"args" from "args.file_prefix".
---
---
 usertools/dpdk-telemetry-client.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
  

Comments

Ciara Power May 25, 2023, 1:34 p.m. UTC | #1
Hi Samina,

> -----Original Message-----
> From: Arshad, Samina <samina.arshad@intel.com>
> Sent: Tuesday 23 May 2023 15:39
> To: y
> Cc: Power, Ciara <ciara.power@intel.com>; dev@dpdk.org; Kearney, Tadhg
> <tadhg.kearney@intel.com>; stable@dpdk.org; Arshad, Samina
> <samina.arshad@intel.com>; lihuisong@huawei.com
> Subject: [PATCH v2] usertools/telemetry: fix unused parameter
> 
> This bug fix ensures that the runtime socket path is generated correctly, based
> on the user-specified file_prefix value, resolving the issue that occurred in the
> previous implementation.
> 
> Fixes: a15fc792cfb6 ("usertools/telemetry: add file prefix argument")
> Cc: lihuisong@huawei.com
> Cc: stable@dpdk.org

No need for cc stable here because the bad commit was only introduced in 23.03 release.
That means we don't need the fix to be backported to 21.11 or 22.11, as the bug didn't exist in those releases.

+1 for code changes though,

Acked-by: Ciara Power <ciara.power@intel.com>

> 
> Signed-off-by: Samina Arshad <samina.arshad@intel.com>
> ---
> v2:
> Made changes for previous commit to be efficient. Removed "args" from
> "args.file_prefix".
<snip>
  
Thomas Monjalon June 1, 2023, 2:42 p.m. UTC | #2
25/05/2023 15:34, Power, Ciara:
> From: Arshad, Samina <samina.arshad@intel.com>
> > Fixes: a15fc792cfb6 ("usertools/telemetry: add file prefix argument")
> > Cc: lihuisong@huawei.com
> > Cc: stable@dpdk.org
> 
> No need for cc stable here because the bad commit was only introduced in 23.03 release.
> That means we don't need the fix to be backported to 21.11 or 22.11, as the bug didn't exist in those releases.

We need to Cc: stable as long as the bug is in a different release.
It will not trigger a backport for upstream releases,
but it could help someone maintaining 23.03 for a specific purpose.
  
Ciara Power June 1, 2023, 2:52 p.m. UTC | #3
> -----Original Message-----
> From: Thomas Monjalon <thomas@monjalon.net>
> Sent: Thursday 1 June 2023 15:42
> To: Arshad, Samina <samina.arshad@intel.com>; Power, Ciara
> <ciara.power@intel.com>
> Cc: dev@dpdk.org; Kearney, Tadhg <tadhg.kearney@intel.com>;
> stable@dpdk.org; lihuisong@huawei.com; Dooley, Brian
> <brian.dooley@intel.com>
> Subject: Re: [PATCH v2] usertools/telemetry: fix unused parameter
> 
> 25/05/2023 15:34, Power, Ciara:
> > From: Arshad, Samina <samina.arshad@intel.com>
> > > Fixes: a15fc792cfb6 ("usertools/telemetry: add file prefix
> > > argument")
> > > Cc: lihuisong@huawei.com
> > > Cc: stable@dpdk.org
> >
> > No need for cc stable here because the bad commit was only introduced in
> 23.03 release.
> > That means we don't need the fix to be backported to 21.11 or 22.11, as the
> bug didn't exist in those releases.
> 
> We need to Cc: stable as long as the bug is in a different release.
> It will not trigger a backport for upstream releases, but it could help someone
> maintaining 23.03 for a specific purpose.
> 

Ah - didn't realise that. Noted, thanks Thomas!
  

Patch

diff --git a/usertools/dpdk-telemetry-client.py b/usertools/dpdk-telemetry-client.py
index d6718ca5b0..e3bb1c9ee0 100755
--- a/usertools/dpdk-telemetry-client.py
+++ b/usertools/dpdk-telemetry-client.py
@@ -55,8 +55,8 @@  def getFilepath(self, file_path):
         # Gets arguments from Command-Line and assigns to instance of client
         self.file_path = file_path
 
-    def setRunpath(self, file_path):
-        self.run_path = os.path.join(get_dpdk_runtime_dir(args.file_prefix),
+    def setRunpath(self, file_prefix):
+        self.run_path = os.path.join(get_dpdk_runtime_dir(file_prefix),
                                      RUNTIME_SOCKET_NAME)
 
     def register(self):