From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 7C545A04B5 for ; Wed, 13 Jan 2021 12:14:26 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 73761140D1E; Wed, 13 Jan 2021 12:14:26 +0100 (CET) Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by mails.dpdk.org (Postfix) with ESMTP id 25CE5140CFC; Wed, 13 Jan 2021 12:14:23 +0100 (CET) IronPort-SDR: z4CypcNUYdoyk5X5q3rqf4jrqXxxgZjwAs4A3Pab9Y0dvjIVTqxafvC616ZLEqRcw/foyI5TAC VuTdEWxOJPLA== X-IronPort-AV: E=McAfee;i="6000,8403,9862"; a="174681246" X-IronPort-AV: E=Sophos;i="5.79,344,1602572400"; d="scan'208";a="174681246" Received: from orsmga008.jf.intel.com ([10.7.209.65]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2021 03:14:19 -0800 IronPort-SDR: uPrrQzgQj6aeUiAE4ycTpwaU22HPI4Ceqx1+zOH2wunHQODv22nJFXnxPHxwvKx6h3I+PleGzF PKddMcCd1aEA== X-IronPort-AV: E=Sophos;i="5.79,344,1602572400"; d="scan'208";a="381806248" Received: from dhunt5-mobl5.ger.corp.intel.com (HELO [10.213.220.13]) ([10.213.220.13]) by orsmga008-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2021 03:14:18 -0800 To: "Burakov, Anatoly" , dev@dpdk.org Cc: stable@dpdk.org References: <20201217113656.28884-1-david.hunt@intel.com> <20210108143048.23755-1-david.hunt@intel.com> <2a4c607c-8919-7572-0646-c9627e6cbe48@intel.com> From: David Hunt Message-ID: Date: Wed, 13 Jan 2021 11:14:16 +0000 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.5.1 MIME-Version: 1.0 In-Reply-To: <2a4c607c-8919-7572-0646-c9627e6cbe48@intel.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-GB Subject: Re: [dpdk-stable] [dpdk-dev] [PATCH 0/6] power: fix make build for power apps X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" Hi Anatoly, On 13/1/2021 11:08 AM, Burakov, Anatoly wrote: > On 08-Jan-21 2:30 PM, David Hunt wrote: >> The power example applications that uses the virtio-serial method of >> communication cannot currently be built with make, and can only be built >> using meson/ninja. >> >> The guest channel message definitions and functions in guest_channel.h >> are needed by applications and need to be made public. >> >> This worked pre-20.11, but now with all the meson/ninja changes, making >> these apps externally no longer works. To fix, we need to move the >> header >> file with the API definitions for the channel commands public, and >> rename >> the functions accordingly. >> >> The main change is to rename channel_commands.h to >> rte_power_guest_channel.h so that it gets picked up by the installer and >> copied to /usr/local/include. Other changes include renaming #defines to >> have RTE_ at the beginning instead of CPU_. Finally we refactor the code >> to work with those changes. >> >> --- >> v2 changes >>    - re-worked from monolithic patch to a 6 patch patchset for easier >> review >> >> [PATCH v2 1/6] power: create guest channel public header file >> [PATCH v2 2/6] power: make channel msg functions public >> [PATCH v2 3/6] power: rename public structs >> [PATCH v2 4/6] power: rename defines >> [PATCH v2 5/6] power: add new header file to export list >> [PATCH v2 6/6] power: clean up includes >> > > Just a general question: wouldn't it be better to move this stuff > entirely into sample app and not bother with keeping it in the > library? There is precedent - ethtool app has a "library" and an > "application" part, i think you should be able to move it out of the > library and into the sample app entirely without too much trouble, as > code looks to be fairly self-contained. > Agreed, that's a great idea. I could have a common lib under examples/vm_power_manager, then two apps, vm_power_manager and guest_cli. That would keep everything nicely local, and not expose the channel API publicly. The only reason we were making it public was to allow "make" to work, so that's not a good enought reason, tbh. I'll throw a prototype together today. Thanks, Dave.