[dpdk-stable] patch 'examples/power: fix ack for enable/disable turbo' has been queued to stable release 19.11.1

luca.boccassi at gmail.com luca.boccassi at gmail.com
Mon Feb 17 18:44:58 CET 2020


Hi,

FYI, your patch has been queued to stable release 19.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 02/19/20. 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.

Thanks.

Luca Boccassi

---
>From 40aaf22e968754c863e9a129fa77578364b16906 Mon Sep 17 00:00:00 2001
From: David Hunt <david.hunt at intel.com>
Date: Tue, 11 Feb 2020 10:50:08 +0000
Subject: [PATCH] examples/power: fix ack for enable/disable turbo

[ upstream commit 1e3ec03d8ac118eaf5ef76036c0a24c598589add ]

When a VM sends a command through virtio-serial to enable/disable
turbo, it is successfully enabled or disabled, yet the response to the
VM is NACK. This is because all the library frequency change APIs return
1 for success (change in frequency), 0 for success (no change in
frequency) and -1 for failure. However the turbo enable/disable APIs just
return 0 for success and -1 for failure.

Fix the handling of the return code to treat ">= 0" as success, and
send an ACK. Only send NACK when < 0 (failure).

Fixes: 0de94bcac7fc ("examples/vm_power: send confirmation cmd to guest")

Signed-off-by: David Hunt <david.hunt at intel.com>
Acked-by: Lei Yao <lei.a.yao at intel.com>
---
 examples/vm_power_manager/channel_monitor.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/examples/vm_power_manager/channel_monitor.c b/examples/vm_power_manager/channel_monitor.c
index 090c2a98b0..1d00a6cf6c 100644
--- a/examples/vm_power_manager/channel_monitor.c
+++ b/examples/vm_power_manager/channel_monitor.c
@@ -868,7 +868,7 @@ process_request(struct channel_packet *pkt, struct channel_info *chan_info)
 		if (valid_unit) {
 			ret = send_ack_for_received_cmd(pkt,
 					chan_info,
-					scale_res > 0 ?
+					scale_res >= 0 ?
 						CPU_POWER_CMD_ACK :
 						CPU_POWER_CMD_NACK);
 			if (ret < 0)
-- 
2.20.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2020-02-17 17:00:15.527336179 +0000
+++ 0006-examples-power-fix-ack-for-enable-disable-turbo.patch	2020-02-17 17:00:15.271949945 +0000
@@ -1,8 +1,10 @@
-From 1e3ec03d8ac118eaf5ef76036c0a24c598589add Mon Sep 17 00:00:00 2001
+From 40aaf22e968754c863e9a129fa77578364b16906 Mon Sep 17 00:00:00 2001
 From: David Hunt <david.hunt at intel.com>
 Date: Tue, 11 Feb 2020 10:50:08 +0000
 Subject: [PATCH] examples/power: fix ack for enable/disable turbo
 
+[ upstream commit 1e3ec03d8ac118eaf5ef76036c0a24c598589add ]
+
 When a VM sends a command through virtio-serial to enable/disable
 turbo, it is successfully enabled or disabled, yet the response to the
 VM is NACK. This is because all the library frequency change APIs return
@@ -14,7 +16,6 @@
 send an ACK. Only send NACK when < 0 (failure).
 
 Fixes: 0de94bcac7fc ("examples/vm_power: send confirmation cmd to guest")
-Cc: stable at dpdk.org
 
 Signed-off-by: David Hunt <david.hunt at intel.com>
 Acked-by: Lei Yao <lei.a.yao at intel.com>


More information about the stable mailing list