From patchwork Tue Dec 9 03:42:50 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tetsuya Mukawa X-Patchwork-Id: 1853 Return-Path: X-Original-To: patchwork@dpdk.org Delivered-To: patchwork@dpdk.org Received: from [92.243.14.124] (localhost [IPv6:::1]) by dpdk.org (Postfix) with ESMTP id AE22E80C0; Tue, 9 Dec 2014 04:44:21 +0100 (CET) Received: from mail-pa0-f42.google.com (mail-pa0-f42.google.com [209.85.220.42]) by dpdk.org (Postfix) with ESMTP id 2E61E80B5 for ; Tue, 9 Dec 2014 04:44:20 +0100 (CET) Received: by mail-pa0-f42.google.com with SMTP id et14so6568281pad.1 for ; Mon, 08 Dec 2014 19:44:19 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=PZUILIH8KqZuvtQsPpk8XreuJL3t4byTzZ/DHjoNYdQ=; b=TnGDYcApsi9T7gqk4hpqkG54+0ITyC6Dwfjty/ZolFcmHmQnAlYb8xlpAapFDgZWJL RcYYzk30FDpdB/VW1EFS7CEVYgrPIBG61LNNV/1CdzPyJbDUzxNN4IJ6gnFFBi3AlXRC JOToNDTY6XTcHAizOt6lLUZRupnbxOFQDmvCgtyYLt2GSl8nR3gWhRQNqoh2QNlUbqDj +owxTRmsqRE6b/yjpt+Skn+YUJr5miQk+VC6qgCNADGnTsO37ObBt1/Ip5mIYGuxqkFE DBH+sPrGdY3qqVaFCROCqsdWNQeLMx9zr1VWrXksENPl19WXvf5h1E87lsAWU3ZP6j22 Dybw== X-Gm-Message-State: ALoCoQkM/FZijR+7vyARZ9/hIbkEAORdwqcIehCZlVHRjnz5WwmO+Xp/oDZvq8plxNgXO5pJGpf9 X-Received: by 10.70.43.138 with SMTP id w10mr26652703pdl.50.1418096659568; Mon, 08 Dec 2014 19:44:19 -0800 (PST) Received: from eris.hq.igel.co.jp (napt.igel.co.jp. [219.106.231.132]) by mx.google.com with ESMTPSA id xx2sm2185pab.17.2014.12.08.19.44.17 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 08 Dec 2014 19:44:19 -0800 (PST) From: Tetsuya Mukawa To: dev@dpdk.org Date: Tue, 9 Dec 2014 12:42:50 +0900 Message-Id: <1418096571-27531-28-git-send-email-mukawa@igel.co.jp> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1418096571-27531-1-git-send-email-mukawa@igel.co.jp> References: <1416474399-16851-1-git-send-email-mukawa@igel.co.jp> <1418096571-27531-1-git-send-email-mukawa@igel.co.jp> Cc: nakajima.yoshihiro@lab.ntt.co.jp, menrigh@brocade.com, masutani.hitoshi@lab.ntt.co.jp Subject: [dpdk-dev] [PATCH v2 27/28] eal/pci: Remove rte_eal_dev_attach/detach_pdev() and rte_eal_dev_attach/detach_vdev() X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" These functions are wrapped by rte_eal_dev_attach/detach(). So delete these. Signed-off-by: Tetsuya Mukawa --- lib/librte_eal/common/eal_common_dev.c | 8 +++--- lib/librte_eal/common/include/rte_dev.h | 50 --------------------------------- 2 files changed, 4 insertions(+), 54 deletions(-) diff --git a/lib/librte_eal/common/eal_common_dev.c b/lib/librte_eal/common/eal_common_dev.c index c9d4894..7481fb7 100644 --- a/lib/librte_eal/common/eal_common_dev.c +++ b/lib/librte_eal/common/eal_common_dev.c @@ -174,7 +174,7 @@ rte_eal_dev_find_and_invoke(const char *name, int type) } /* attach the new physical device, then store port_id of the device */ -int +static int rte_eal_dev_attach_pdev(struct rte_pci_addr *addr, uint8_t *port_id) { uint8_t new_port_id; @@ -203,7 +203,7 @@ err: } /* detach the new physical device, then store pci_addr of the device */ -int +static int rte_eal_dev_detach_pdev(uint8_t port_id, struct rte_pci_addr *addr) { struct rte_pci_addr freed_addr; @@ -252,7 +252,7 @@ get_vdev_name(char *vdevargs) } /* attach the new virtual device, then store port_id of the device */ -int +static int rte_eal_dev_attach_vdev(const char *vdevargs, uint8_t *port_id) { char *args; @@ -294,7 +294,7 @@ err0: } /* detach the new virtual device, then store the name of the device */ -int +static int rte_eal_dev_detach_vdev(uint8_t port_id, char *vdevname) { char name[RTE_ETH_NAME_MAX_LEN]; diff --git a/lib/librte_eal/common/include/rte_dev.h b/lib/librte_eal/common/include/rte_dev.h index 1f8f24a..9da518d 100644 --- a/lib/librte_eal/common/include/rte_dev.h +++ b/lib/librte_eal/common/include/rte_dev.h @@ -102,56 +102,6 @@ void rte_eal_driver_unregister(struct rte_driver *driver); #if defined(RTE_LIBRTE_EAL_HOTPLUG) && defined(RTE_LIBRTE_EAL_LINUXAPP) /** - * Attach a new physical device. - * - * @param addr - * A pointer to a pci address structure describing the new - * device to be attached. - * @param port_id - * A pointer to a port identifier actually attached. - * @return - * 0 on success and port_id is filled, negative on error - */ -int rte_eal_dev_attach_pdev(struct rte_pci_addr *addr, uint8_t *port_id); - -/** - * Attach a new virtual device. - * - * @param vdevargs - * A pointer to a strings array describing the new device - * to be attached. - * @param port_id - * A pointer to a port identifier actually attached. - * @return - * 0 on success and port_id is filled, negative on error - */ -int rte_eal_dev_attach_vdev(const char *vdevargs, uint8_t *port_id); - -/** - * Detach a physical device. - * - * @param port_id - * The port identifier of the physical device to detach. - * @param addr - * A pointer to a pci address structure actually detached. - * @return - * 0 on success and addr is filled, negative on error - */ -int rte_eal_dev_detach_pdev(uint8_t port_id, struct rte_pci_addr *addr); - -/** - * Detach a virtual device. - * - * @param port_id - * The port identifier of the virtual device to detach. - * @param addr - * A pointer to a virtual device name actually detached. - * @return - * 0 on success and vdevname is filled, negative on error - */ -int rte_eal_dev_detach_vdev(uint8_t port_id, char *vdevname); - -/** * Attach a new device. * * @param devargs