From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Monjalon Subject: Re: [PATCH v2] ethdev: allow all ports event registration Date: Fri, 29 Dec 2017 12:45:12 +0100 Message-ID: <6214136.ixGVTiWP3P@xps> References: <1512028170-18637-1-git-send-email-matan@mellanox.com> <1512402221-17630-1-git-send-email-matan@mellanox.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7Bit Cc: dev@dpdk.org To: Matan Azrad Return-path: Received: from out2-smtp.messagingengine.com (out2-smtp.messagingengine.com [66.111.4.26]) by dpdk.org (Postfix) with ESMTP id 17C92160 for ; Fri, 29 Dec 2017 12:45:26 +0100 (CET) In-Reply-To: <1512402221-17630-1-git-send-email-matan@mellanox.com> List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Hi Matan, Please find some review details below. As this patch is needed for the notification of new ports, I will re-send them in a patchset, with the minor modifications described below. 04/12/2017 16:43, Matan Azrad: > --- a/lib/librte_ether/rte_ethdev.c > +++ b/lib/librte_ether/rte_ethdev.c > +RTE_INIT(eth_dev_init_cb_lists); [...] > +static void > +eth_dev_init_cb_lists(void) RTE_INIT macro can be used in function definition without prior declaration. This function should be moved just before the callback register/unregister functions. > @@ -2827,37 +2837,59 @@ > + uint32_t next_port; > + uint32_t last_port; A port id should be uint16_t. > --- a/lib/librte_ether/rte_ethdev.h > +++ b/lib/librte_ether/rte_ethdev.h > /** > - * Register a callback function for specific port id. > + * Register a callback function for port id event. [...] > - * Unregister a callback function for specific port id. > + * Unregister a callback function for port id event. "port event" would be more appropriate than "port id event".