Skip to contentSkip to conversation

examples/vm_power: fix build

PATCH Applied Ferruh Yigit 4 participants 5 messages Oct 14, 2019 – Oct 23, 2019

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 examples/vm_power: fix build

Fixes 70febdcfd60f ("examples: check status of getting MAC address")

---
Cc: Igor Romanov <[email protected]>
Cc: Andrew Rybchenko <[email protected]>

---
 examples/vm_power_manager/guest_cli/vm_power_cli_guest.c | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)
examples/vm_power_manager/guest_cli/vm_power_cli_guest.c +5 -3
index 77e54401a..fe09b0778 100644
@@ -55,10 +55,10 @@ set_policy_mac(int port, int idx)
 
 	/* Use port MAC address as the vfid */
 	ret = rte_eth_macaddr_get(port, &pfid.addr);
-	if (retval != 0) {
+	if (ret != 0) {
 		printf("Failed to get device (port %u) MAC address: %s\n",
-				port, rte_strerror(-retval));
-		return retval;
+				port, rte_strerror(-ret));
+		return ret;
 	}
 
 	printf("Port %u MAC: %02" PRIx8 ":%02" PRIx8 ":%02" PRIx8 ":"
@@ -108,6 +108,8 @@ set_policy_defaults(struct channel_packet *pkt)
 	pkt->policy_to_use = TIME;
 	pkt->command = PKT_POLICY;
 	strcpy(pkt->vm_name, "ubuntu2");
+
+	return 0;
 }
 
 static void cmd_quit_parsed(__attribute__((unused)) void *parsed_result,
Signature · 1 line
2.21.0
#1 lore raw
Quoted 3 lines · Ferruh Yigit
Fixes 70febdcfd60f ("examples: check status of getting MAC address")

Thanks Ferruh, it is consequences of vm_power_manager excluded from build because of missing libvirt dependency and our inattentiveness when checking build results.

#2 lore raw
Quoted 9 lines · Andrew Rybchenko
Quoted 3 lines · Ferruh Yigit
Fixes 70febdcfd60f ("examples: check status of getting MAC address")

Thanks Ferruh, it is consequences of vm_power_manager excluded from build because of missing libvirt dependency and our inattentiveness when checking build results.

I also missed it because of same reason, validation team caught it :)

Tested-by Acked-by on v1 1/1
#3 lore raw
In reply to Ferruh Yigit
Quoted 10 lines · Ferruh Yigit
Fixes 70febdcfd60f ("examples: check status of getting MAC address")

---
Cc: Igor Romanov <[email protected]>
Cc: Andrew Rybchenko <[email protected]>

---
 examples/vm_power_manager/guest_cli/vm_power_cli_guest.c | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

The guest_cli part of the example app was not being built by the meson builds. I'm now reworking series [1] to include it (a one-line addition is really all that's needed). When added I see these build errors and this patch fixes them.

[1] http://patches.dpdk.org/project/dpdk/list/?series=6864