From: christian.ehrhardt@canonical.com
To: Raja Zidane <rzidane@nvidia.com>
Cc: Omar Awaysa <omara@nvidia.com>, dpdk stable <stable@dpdk.org>
Subject: patch 'examples/link_status_interrupt: fix stats refresh rate' has been queued to stable release 19.11.13
Date: Tue, 12 Jul 2022 09:45:21 +0200 [thread overview]
Message-ID: <20220712074522.3704914-1-christian.ehrhardt@canonical.com> (raw)
Hi,
FYI, your patch has been queued to stable release 19.11.13
Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 07/14/22. 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/cpaelzer/dpdk-stable-queue
This queued commit can be viewed at:
https://github.com/cpaelzer/dpdk-stable-queue/commit/44bd653285d4ee919052ec5cffc15ba3f2dc2fe1
Thanks.
Christian Ehrhardt <christian.ehrhardt@canonical.com>
---
From 44bd653285d4ee919052ec5cffc15ba3f2dc2fe1 Mon Sep 17 00:00:00 2001
From: Raja Zidane <rzidane@nvidia.com>
Date: Thu, 7 Jul 2022 08:22:34 +0000
Subject: [PATCH] examples/link_status_interrupt: fix stats refresh rate
[ upstream commit 14d460b888c290e16c00cff4ae809d14fe799aec ]
TIMER_MILLISECOND is defined as the number of CPU cycles per millisecond.
The current definition is correct only for cores with frequency of 2GHz.
Use DPDK API to get CPU frequency, and to define timer period.
Fixes: af75078fece3 ("first public release")
Signed-off-by: Raja Zidane <rzidane@nvidia.com>
Signed-off-by: Omar Awaysa <omara@nvidia.com>
---
examples/link_status_interrupt/main.c | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/examples/link_status_interrupt/main.c b/examples/link_status_interrupt/main.c
index 26595bb47a..174888eaae 100644
--- a/examples/link_status_interrupt/main.c
+++ b/examples/link_status_interrupt/main.c
@@ -99,9 +99,10 @@ struct lsi_port_statistics {
struct lsi_port_statistics port_statistics[RTE_MAX_ETHPORTS];
/* A tsc-based timer responsible for triggering statistics printout */
-#define TIMER_MILLISECOND 2000000ULL /* around 1ms at 2 Ghz */
+#define TIMER_MILLISECOND (rte_get_timer_hz() / 1000)
#define MAX_TIMER_PERIOD 86400 /* 1 day max */
-static int64_t timer_period = 10 * TIMER_MILLISECOND * 1000; /* default period is 10 seconds */
+#define DEFAULT_TIMER_PERIOD 10UL /* default period is 10 seconds */
+static int64_t timer_period;
/* Print out statistics on packets dropped */
static void
@@ -368,6 +369,8 @@ lsi_parse_args(int argc, char **argv)
{NULL, 0, 0, 0}
};
+ timer_period = DEFAULT_TIMER_PERIOD * TIMER_MILLISECOND * 1000;
+
argvopt = argv;
while ((opt = getopt_long(argc, argvopt, "p:q:T:",
--
2.37.0
---
Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- - 2022-07-12 09:44:11.717895611 +0200
+++ 0001-examples-link_status_interrupt-fix-stats-refresh-rat.patch 2022-07-12 09:44:11.676834710 +0200
@@ -1 +1 @@
-From 14d460b888c290e16c00cff4ae809d14fe799aec Mon Sep 17 00:00:00 2001
+From 44bd653285d4ee919052ec5cffc15ba3f2dc2fe1 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 14d460b888c290e16c00cff4ae809d14fe799aec ]
+
@@ -12 +13,0 @@
-Cc: stable@dpdk.org
@@ -21 +22 @@
-index 551f0524da..9699e14ce6 100644
+index 26595bb47a..174888eaae 100644
@@ -24 +25 @@
-@@ -101,9 +101,10 @@ struct lsi_port_statistics {
+@@ -99,9 +99,10 @@ struct lsi_port_statistics {
@@ -37 +38 @@
-@@ -370,6 +371,8 @@ lsi_parse_args(int argc, char **argv)
+@@ -368,6 +369,8 @@ lsi_parse_args(int argc, char **argv)
next reply other threads:[~2022-07-12 7:45 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-07-12 7:45 christian.ehrhardt [this message]
2022-07-12 7:45 ` patch 'vdpa/ifc/base: fix null pointer dereference' " christian.ehrhardt
2022-07-12 7:47 ` Pei, Andy
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=20220712074522.3704914-1-christian.ehrhardt@canonical.com \
--to=christian.ehrhardt@canonical.com \
--cc=omara@nvidia.com \
--cc=rzidane@nvidia.com \
--cc=stable@dpdk.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).