From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Monjalon Subject: Re: [PATCH v14 12/13] eal/pci: Add rte_eal_dev_attach/detach() functions Date: Wed, 25 Feb 2015 12:21:29 +0100 Message-ID: <2987764.cYYQsyCFG8@xps13> References: <1424060073-23484-2-git-send-email-mukawa@igel.co.jp> <1424837093-5661-1-git-send-email-mukawa@igel.co.jp> <1424837093-5661-13-git-send-email-mukawa@igel.co.jp> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7Bit Cc: dev-VfR2kkLFssw@public.gmane.org To: Tetsuya Mukawa Return-path: In-Reply-To: <1424837093-5661-13-git-send-email-mukawa-AlSX/UN32fvPDbFq/vQRIQ@public.gmane.org> 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-25 13:04, Tetsuya Mukawa: > --- a/lib/librte_eal/common/eal_common_dev.c > +++ b/lib/librte_eal/common/eal_common_dev.c > @@ -32,10 +32,13 @@ > * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. > */ > > +#include > +#include > #include > #include > #include > > +#include > #include > #include No, you must not include ethdev in EAL. The ethdev layer is by design on top of EAL. Maxime already asked why you did it. He was implicitly asking to remove it. You said that you are calling ethdev_is_detachable() but you should call a function eal_is_detachable() or something like that. The detachable state must be only device-related, i.e. in EAL. The ethdev API is only a wrapper (with port id) in such case. > --- a/lib/librte_eal/linuxapp/eal/Makefile > +++ b/lib/librte_eal/linuxapp/eal/Makefile > @@ -45,6 +45,7 @@ CFLAGS += -I$(RTE_SDK)/lib/librte_eal/common/include > CFLAGS += -I$(RTE_SDK)/lib/librte_ring > CFLAGS += -I$(RTE_SDK)/lib/librte_mempool > CFLAGS += -I$(RTE_SDK)/lib/librte_malloc > +CFLAGS += -I$(RTE_SDK)/lib/librte_mbuf By removing ethdev dependency, you can remove this ugly mbuf dependency. Thanks Tetsuya