From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from out1-smtp.messagingengine.com (out1-smtp.messagingengine.com [66.111.4.25]) by dpdk.org (Postfix) with ESMTP id 1B6A91B2E8 for ; Fri, 19 Jan 2018 02:14:30 +0100 (CET) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id B02BC20C71; Thu, 18 Jan 2018 20:14:29 -0500 (EST) Received: from frontend1 ([10.202.2.160]) by compute1.internal (MEProxy); Thu, 18 Jan 2018 20:14:29 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=mesmtp; bh=u6zmOVmiqUgx6UVhJTePf+Yynq pzKmmL4GWuaniUmbI=; b=Df056+hV0dhniq4uTGOrqq3HQY+fB2PQWv/LA+mhsR k2wuuoWRP6bAQxl0cV4a0RJkMesXOD/RYIeiL2UZpN1vUNpfPdHITI16bRYljlTm GyTdafLFl4jFafRkY2IOrjy3xtkkC3Pt5gRAxEJSY3nPCNYtWTDVjJAs3H5uXPXy U= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; bh=u6zmOV miqUgx6UVhJTePf+YynqpzKmmL4GWuaniUmbI=; b=EpwI8ZHLVlToF7IQrOvr/9 WYOB8Rwy9h9vOzms4JEFRcaA0ffbCIW46fzxnlyf8REG2Nm2JjdlYS5q4aCkWbq9 9s3RWRA/+xOU2ZxkBraP6+EEUjnilwqnNzuuF8FKm5s8XnVhJX65pVGNw0D/yAQc 6wG/nKe+/cKyFGxo7D7gH6ZoeOXFPmzB3Y2iDM5ABb461o/LMqTEowf0Cj+zbarB CT4HwHcBS9PpLgMGx9N1vBD+urT+N0+US+Ekg6RsixjsryIiX3dMATHPhjEwL2do 7J82q1wz3ItqyA3vZ/ZNKsdlXHHzYuiuaxxc+T9gkX+HwDMRX+PDlwqFQPxKMtXA == X-ME-Sender: Received: from xps.localnet (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA id 590EA7E13A; Thu, 18 Jan 2018 20:14:29 -0500 (EST) From: Thomas Monjalon To: Jeff Guo Cc: dev@dpdk.org, stephen@networkplumber.org, bruce.richardson@intel.com, ferruh.yigit@intel.com, gaetan.rivet@6wind.com, konstantin.ananyev@intel.com, jblunck@infradead.org, shreyansh.jain@nxp.com, jingjing.wu@intel.com, helin.zhang@intel.com, motih@mellanox.com Date: Fri, 19 Jan 2018 02:13:55 +0100 Message-ID: <3568576.lheXnZb7QM@xps> In-Reply-To: <1516248723-16985-1-git-send-email-jia.guo@intel.com> References: <1516013331-18939-3-git-send-email-jia.guo@intel.com> <1516248723-16985-1-git-send-email-jia.guo@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Subject: Re: [dpdk-dev] [PATCH V12 1/3] eal: add uevent monitor api and callback func 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, 19 Jan 2018 01:14:30 -0000 18/01/2018 05:12, Jeff Guo: > + * It registers the callback for the specific device. > + * Multiple callbacks cal be registered at the same time. > + * > + * @param device_name > + * The device name, that is the param name of the struct rte_device, Why not using rte_device pointer? > + * null value means for all devices. I don't see any management of NULL value. On the contrary, I see + if (device_name == NULL) + return -EINVAL; > + * @param cb_fn > + * callback address. > + * @param cb_arg > + * address of parameter for callback. > + * > + * @return > + * - On success, zero. > + * - On failure, a negative value. > + */ > +int rte_dev_callback_register(char *device_name, rte_dev_event_cb_fn cb_fn, > + void *cb_arg); > +