From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from out4-smtp.messagingengine.com (out4-smtp.messagingengine.com [66.111.4.28]) by dpdk.org (Postfix) with ESMTP id 7871A7CD8 for ; Thu, 4 May 2017 17:46:44 +0200 (CEST) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 0EE4620AE3; Thu, 4 May 2017 11:46:44 -0400 (EDT) Received: from frontend1 ([10.202.2.160]) by compute1.internal (MEProxy); Thu, 04 May 2017 11:46:44 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= date:from:message-id:subject:to:x-me-sender:x-me-sender :x-sasl-enc:x-sasl-enc; s=mesmtp; bh=4uCUhaz+Y5kyb0DloS35pkSoOhW OcJsy4CT+AM40B0o=; b=ZkRMregqXh6rl4Tr+2lK6FmiAYohfK2HgRjtmGKcpHf PIJatcNZ/2Jwces2HfsUt2Mc2itKDv5wV1uZlmg8j2XLvzTodc+QHfQYlh7XVxQf KDefR81U1kdpQxpwoT1T/HDiaV2fZDHirv9SZ0/xnh5jBbN0BDvJvT3kjemEMv1o = DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=date:from:message-id:subject:to :x-me-sender:x-me-sender:x-sasl-enc:x-sasl-enc; s=fm1; bh=4uCUha z+Y5kyb0DloS35pkSoOhWOcJsy4CT+AM40B0o=; b=cFkmSMgeaj0d+GRpzk9tBH kWuytRP0So+OaiUUoPVTmU0eA4bCPeTVXEGQFX7hsXvINdonwf9aD/jsgT3JLTwD 5WOd7m4TxVIldAmy3yN0JMHFJc6trRs6RYRLRj66vozbP28tWuFqSAb3IqxyxHR8 YREg0FXkm4/SuilhyTPbb+7NG2vogDH2bxtEyDC/4Qqb0is2I5WB0IItyrzUIKxK 4bQ6qvkONXOsBeHTmiaNnhuue6qaEF9dgg/Vexynaoa9ArW5zAIlBCMjZaqQrT1r FRhf8imyJSpZ+m0f5TiPB0e86jfEYrxYp7DbwNn26zXjLDdI+IkGULqZoScfUImA == X-ME-Sender: X-Sasl-enc: Z+Zmsysc0pkFpq3Vrq2fssbbR/Bo1FNycic1OHv990M2 1493912803 Received: from xps.monjalon.net (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA id 90F287E2E2 for ; Thu, 4 May 2017 11:46:43 -0400 (EDT) From: Thomas Monjalon To: dev@dpdk.org Date: Thu, 4 May 2017 17:46:20 +0200 Message-Id: <20170504154620.29243-1-thomas@monjalon.net> X-Mailer: git-send-email 2.12.2 Subject: [dpdk-dev] [PATCH] eal: remove forward declaration of generic driver 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: Thu, 04 May 2017 15:46:44 -0000 We can just move rte_driver definition before rte_device (which depends on rte_driver). Signed-off-by: Thomas Monjalon --- lib/librte_eal/common/include/rte_dev.h | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) diff --git a/lib/librte_eal/common/include/rte_dev.h b/lib/librte_eal/common/include/rte_dev.h index b63d0540d..759059889 100644 --- a/lib/librte_eal/common/include/rte_dev.h +++ b/lib/librte_eal/common/include/rte_dev.h @@ -123,8 +123,14 @@ struct rte_mem_resource { void *addr; /**< Virtual address, NULL when not mapped. */ }; -/* Forward declaration */ -struct rte_driver; +/** + * A structure describing a device driver. + */ +struct rte_driver { + TAILQ_ENTRY(rte_driver) next; /**< Next in list. */ + const char *name; /**< Driver name. */ + const char *alias; /**< Driver alias. */ +}; /** * A structure describing a generic device. @@ -138,15 +144,6 @@ struct rte_device { }; /** - * A structure describing a device driver. - */ -struct rte_driver { - TAILQ_ENTRY(rte_driver) next; /**< Next in list. */ - const char *name; /**< Driver name. */ - const char *alias; /**< Driver alias. */ -}; - -/** * Initialize a driver specified by name. * * @param name -- 2.12.2