From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by dpdk.org (Postfix) with ESMTP id 079BC4C74 for ; Fri, 14 Dec 2018 13:20:09 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by fmsmga104.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 14 Dec 2018 04:20:09 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.56,352,1539673200"; d="scan'208";a="303824342" Received: from aburakov-mobl1.ger.corp.intel.com (HELO [10.251.85.142]) ([10.251.85.142]) by fmsmga005.fm.intel.com with ESMTP; 14 Dec 2018 04:20:08 -0800 To: Liang Ma , david.hunt@intel.com Cc: dev@dpdk.org References: <1542972781-6149-1-git-send-email-liang.j.ma@intel.com> <1544786028-10138-1-git-send-email-liang.j.ma@intel.com> From: "Burakov, Anatoly" Message-ID: Date: Fri, 14 Dec 2018 12:20:07 +0000 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.3.3 MIME-Version: 1.0 In-Reply-To: <1544786028-10138-1-git-send-email-liang.j.ma@intel.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit Subject: Re: [dpdk-dev] [PATCH v2] libs/power: add p-state driver compatibility X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Dec 2018 12:20:10 -0000 On 14-Dec-18 11:13 AM, Liang Ma wrote: > Previously, in order to use the power library, it was necessary > for the user to disable the intel_pstate driver by adding > “intel_pstate=disable” to the kernel command line for the system, > which causes the acpi_cpufreq driver to be loaded in its place. > > This patch adds the ability for the power library use the intel-pstate > driver. > > It adds a new suite of functions behind the current power library API, > and will seamlessly set up the user facing API function pointers to > the relevant functions depending on whether the system is running with > acpi_cpufreq kernel driver, intel_pstate kernel driver or in a guest, > using kvm. The library API and ABI is unchanged. > > Signed-off-by: Liang Ma > --- > sources = files('rte_power.c', 'power_acpi_cpufreq.c', > 'power_kvm_vm.c', 'guest_channel.c', > - 'rte_power_empty_poll.c') > + 'rte_power_empty_poll.c', > + 'power_pstate_cpufreq.c') > headers = files('rte_power.h','rte_power_empty_poll.h') > -deps += ['timer'] > diff --git a/lib/librte_power/power_pstate_cpufreq.c b/lib/librte_power/power_pstate_cpufreq.c > new file mode 100644 > index 0000000..1711484 > --- /dev/null > +++ b/lib/librte_power/power_pstate_cpufreq.c > @@ -0,0 +1,770 @@ > +/* SPDX-License-Identifier: BSD-3-Clause > + * Copyright(c) 2010-2018 Intel Corporation Like i said in comments to previous revision, copyright date here is wrong - you're creating a new file. This file wasn't created in 2010. It should just say "2018". Other than that, LGTM Reviewed-by: Anatoly Burakov -- Thanks, Anatoly