1 /* SPDX-License-Identifier: BSD-3-Clause
2 * Copyright(c) 2010-2014 Intel Corporation
17 #include <rte_lcore.h>
18 #include <rte_power.h>
19 #include <rte_debug.h>
21 #include "vm_power_cli_guest.h"
24 sig_handler(int signo)
26 printf("Received signal %d, exiting...\n", signo);
29 RTE_LCORE_FOREACH(lcore_id) {
30 rte_power_exit(lcore_id);
36 main(int argc, char **argv)
41 ret = rte_eal_init(argc, argv);
43 rte_panic("Cannot init EAL\n");
45 signal(SIGINT, sig_handler);
46 signal(SIGTERM, sig_handler);
48 rte_power_set_env(PM_ENV_KVM_VM);
49 RTE_LCORE_FOREACH(lcore_id) {
50 rte_power_init(lcore_id);