From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Monjalon Subject: Re: [PATCH v4 4/5] eal: add per rx queue interrupt handling based on VFIO Date: Mon, 23 Feb 2015 14:28:08 +0100 Message-ID: <3509738.2W4po8ncMD@xps13> References: <1424353698-29837-1-git-send-email-danny.zhou@intel.com> <6417495.deEVoxQ023@xps13> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7Bit Cc: dev-VfR2kkLFssw@public.gmane.org To: "Zhou, Danny" Return-path: In-Reply-To: List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces-VfR2kkLFssw@public.gmane.org Sender: "dev" 2015-02-23 11:47, Zhou, Danny: > From: Thomas Monjalon [mailto:thomas.monjalon-pdR9zngts4EAvxtiuMwx3w@public.gmane.org] > > 2015-02-19 21:48, Zhou Danny: > > > --- a/lib/librte_eal/linuxapp/eal/Makefile > > > +++ b/lib/librte_eal/linuxapp/eal/Makefile > > > @@ -43,6 +43,7 @@ CFLAGS += -I$(SRCDIR)/include > > > CFLAGS += -I$(RTE_SDK)/lib/librte_eal/common > > > CFLAGS += -I$(RTE_SDK)/lib/librte_eal/common/include > > > CFLAGS += -I$(RTE_SDK)/lib/librte_ring > > > +CFLAGS += -I$(RTE_SDK)/lib/librte_mbuf > > > CFLAGS += -I$(RTE_SDK)/lib/librte_mempool > > > CFLAGS += -I$(RTE_SDK)/lib/librte_malloc > > > CFLAGS += -I$(RTE_SDK)/lib/librte_ether > > > > Why do we need mbuf in EAL? > > The file eal_interrupts.c includes rte_ethdev.h which defines structure rte_eth_devices that > eal needs to use in order to get per-port intr_handle. The rte_ethdev.h includes the rte_mbuf.h > so the Makefile is updated here. I see. You are breaking layer isolation by introducing ethdev in EAL. The cause seems to be: + struct rte_intr_handle intr_handle = + rte_eth_devices[port_id].pci_dev->intr_handle; Maybe that pci_dev should be a parameter of the function.