From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from out2-smtp.messagingengine.com (out2-smtp.messagingengine.com [66.111.4.26]) by dpdk.org (Postfix) with ESMTP id 1384D1094 for ; Wed, 5 Jul 2017 01:45:11 +0200 (CEST) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id A370C20B35; Tue, 4 Jul 2017 19:45:10 -0400 (EDT) Received: from frontend2 ([10.202.2.161]) by compute1.internal (MEProxy); Tue, 04 Jul 2017 19:45:10 -0400 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:x-sasl-enc; s=mesmtp; bh=uvlaRS1TuvwWlON baxFIMdnGuwpTS8XCRxmSOpx2tsU=; b=LmCv97B2sor2c34zDdLQ+ul0OdfyQmZ noE84dxq7gSSjOE28c3jPsrMC59ChP+Ct/57nCtccvVNotNWVJ71Zz9kQnAu+p/3 GD3gZNdVpdp5iyqzx+2AAn0OOcGV6s0+DOzDL4Mo/+MoOn8s9GIsf3f32D4ZDtkf HyF1eVxcvCNs= 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:x-sasl-enc; s= fm1; bh=uvlaRS1TuvwWlONbaxFIMdnGuwpTS8XCRxmSOpx2tsU=; b=bABQDyKl CcBKFdsqMG7v52oTbj0Abbv6sR47k2pFXedzXrOGud1EYbT3Z0y8vJLNGAY1Cevl ISTTOrZv9Fj1aOBg0/U4MTriBqrxr7/cAT4Zzw6oAN36JKYxkW3g0valtFzDbsjz naRqTy+GwvErMoFmnikcoWo+LGH+5qhxGeKfYGgdhPNQFuEgHrl3vw+MH4Q/nE5E yGBnh+hMRrgms3mdSJph3TK2IO3kf+z0Cae18brSYHIOfPFVDkxLg2NO7Nrcv/eZ ah+6/6O73VnnY1qo2DUmc+nGOnHShnnesjnMPLwDXESuamBcXbybtuwDFRzAdz+H k+zeWizvXBD7Tw== X-ME-Sender: X-Sasl-enc: Wc0cqaLrnt1H2z1Aw/VJ+AuNzhRAU6iH3QQU35gpvQbR 1499211910 Received: from xps.localnet (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA id 5908B24253; Tue, 4 Jul 2017 19:45:10 -0400 (EDT) From: Thomas Monjalon To: Jeff Guo Cc: dev@dpdk.org, helin.zhang@intel.com, jingjing.wu@intel.com Date: Wed, 05 Jul 2017 01:45:09 +0200 Message-ID: <1643564.1KfnGSoeuV@xps> In-Reply-To: <1498648044-57541-1-git-send-email-jia.guo@intel.com> References: <1495986280-26207-1-git-send-email-jia.guo@intel.com> <1498648044-57541-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 v2 1/2] eal: add uevent api for hot plug 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: Tue, 04 Jul 2017 23:45:11 -0000 Hi, This is an interesting step for hotplug in DPDK. 28/06/2017 13:07, Jeff Guo: > + netlink_fd = socket(PF_NETLINK, SOCK_DGRAM, NETLINK_KOBJECT_UEVENT); It is monitoring the whole system... > +int > +rte_uevent_get(int fd, struct rte_uevent *uevent) > +{ > + int ret; > + char buf[RTE_UEVENT_MSG_LEN]; > + > + memset(uevent, 0, sizeof(struct rte_uevent)); > + memset(buf, 0, RTE_UEVENT_MSG_LEN); > + > + ret = recv(fd, buf, RTE_UEVENT_MSG_LEN - 1, MSG_DONTWAIT); ... and it is read from this function called by one driver. It cannot work without a global dispatch. It must be a global mechanism, probably a service core. The question is also to know whether it should be a mandatory service in DPDK or an optional helper?