From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stephen Hemminger Subject: Re: [PATCH v10 02/13] eal/linux: add rte_epoll_wait/ctl support Date: Tue, 2 Jun 2015 09:21:17 -0700 Message-ID: <20150602092117.3a0b443a@urahara> References: <1432889125-20255-1-git-send-email-cunming.liang@intel.com> <1433228006-24661-1-git-send-email-cunming.liang@intel.com> <1433228006-24661-3-git-send-email-cunming.liang@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Cc: dev@dpdk.org, liang-min.wang@intel.com To: Cunming Liang Return-path: Received: from mx0a-000f0801.pphosted.com (mx0a-000f0801.pphosted.com [67.231.144.122]) by dpdk.org (Postfix) with ESMTP id 87B59BDC2 for ; Tue, 2 Jun 2015 18:21:53 +0200 (CEST) In-Reply-To: <1433228006-24661-3-git-send-email-cunming.liang@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 Tue, 2 Jun 2015 14:53:15 +0800 Cunming Liang wrote: > The patch adds 'rte_epoll_wait' and 'rte_epoll_ctl' for async event wakeup. > It defines 'struct rte_epoll_event' as the event param. > The 'op' uses the same enum as epoll_wait/ctl does. > The epoll event support to carry a raw user data and to register a callback which is exectuted during wakeup. > > Signed-off-by: Cunming Liang Minor polish comments, not blockers. > +static inline int > +eal_init_tls_epfd(void) > +{ > + int pfd = epoll_create(255); > + if (pfd < 0) { Kernel style checker wants blank line after declaration here. / > +int > +rte_epoll_ctl(int epfd, int op, int fd, > + struct rte_epoll_event *event); > + > +/** > + * The function returns the per thread epoll instance. > + * > + * @return > + * epfd the epoll instance refered to. Spell check: 'refered' may be misspelled - perhaps 'referred'? > + */ > +int > +rte_intr_tls_epfd(void);