X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=examples%2Fvm_power_manager%2Fpower_manager.h;h=d35f8cbe01f89982b16fa20fc3542fba7173eb94;hb=0a65bf8d4124866678f3ddb816d36aae66f791eb;hp=e81a60ae54ca62719b1747c6a3fc2d84d05940c5;hpb=751227a08d92c36bc69a1d25416b223c50fd278a;p=dpdk.git diff --git a/examples/vm_power_manager/power_manager.h b/examples/vm_power_manager/power_manager.h index e81a60ae54..d35f8cbe01 100644 --- a/examples/vm_power_manager/power_manager.h +++ b/examples/vm_power_manager/power_manager.h @@ -8,18 +8,30 @@ #ifdef __cplusplus extern "C" { #endif + +#define FREQ_WINDOW_SIZE 32 + +enum { + FREQ_UNKNOWN, + FREQ_MIN, + FREQ_MAX +}; + struct core_details { uint64_t last_branches; uint64_t last_branch_misses; uint16_t global_enabled_cpus; uint16_t oob_enabled; int msr_fd; + uint16_t freq_directions[FREQ_WINDOW_SIZE]; + uint16_t freq_window_idx; + uint16_t freq_state; + float branch_ratio_threshold; }; struct core_info { uint16_t core_count; struct core_details *cd; - float branch_ratio_threshold; }; #define BRANCH_RATIO_THRESHOLD 0.1