From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Hunt, David" Subject: Re: [PATCH v6 1/5] mempool: support external handler Date: Wed, 1 Jun 2016 17:29:49 +0100 Message-ID: <574F0D7D.90307@intel.com> References: <1463665501-18325-1-git-send-email-david.hunt@intel.com> <1464797998-76690-1-git-send-email-david.hunt@intel.com> <1464797998-76690-2-git-send-email-david.hunt@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Cc: olivier.matz@6wind.com, viktorin@rehivetech.com, jerin.jacob@caviumnetworks.com To: dev@dpdk.org Return-path: Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by dpdk.org (Postfix) with ESMTP id 582F6697B for ; Wed, 1 Jun 2016 18:29:53 +0200 (CEST) In-Reply-To: <1464797998-76690-2-git-send-email-david.hunt@intel.com> List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On 6/1/2016 5:19 PM, David Hunt wrote: > Until now, the objects stored in a mempool were internally stored in a > ring. This patch introduces the possibility to register external handlers > replacing the ring. > > The default behavior remains unchanged, but calling the new function > rte_mempool_set_handler() right after rte_mempool_create_empty() allows > the user to change the handler that will be used when populating > the mempool. > > v7 changes: > * Moved the flags handling from rte_mempool_create_empty to > rte_mempool_create, as it's only there for backward compatibility > * Various comment additions and cleanup > * Renamed rte_mempool_handler to rte_mempool_ops > * Added a union for *pool and u64 pool_id in struct rte_mempool These v7 changes should me merged with the v6 changes below as this is a v6 patch. Or removed altogether, as they are in the cover letter. > v6 changes: > * split the original patch into a few parts for easier review. > * rename functions with _ext_ to _ops_. > * addressed some review comments > * renamed put and get functions to enqueue and dequeue > * renamed rte_mempool_handler struct to rte_mempool_handler_ops > * changed occurences of rte_mempool_handler_ops to const, as they > contain function pointers (security) > * added some extra comments > > [...]