Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/1108/?format=api
https://patches.dpdk.org/api/patches/1108/?format=api", "web_url": "https://patches.dpdk.org/project/dpdk/patch/1415072748-31937-23-git-send-email-mukawa@igel.co.jp/", "project": { "id": 1, "url": "https://patches.dpdk.org/api/projects/1/?format=api", "name": "DPDK", "link_name": "dpdk", "list_id": "dev.dpdk.org", "list_email": "dev@dpdk.org", "web_url": "http://core.dpdk.org", "scm_url": "git://dpdk.org/dpdk", "webscm_url": "http://git.dpdk.org/dpdk", "list_archive_url": "https://inbox.dpdk.org/dev", "list_archive_url_format": "https://inbox.dpdk.org/dev/{}", "commit_url_format": "" }, "msgid": "<1415072748-31937-23-git-send-email-mukawa@igel.co.jp>", "list_archive_url": "https://inbox.dpdk.org/dev/1415072748-31937-23-git-send-email-mukawa@igel.co.jp", "date": "2014-11-04T03:45:42", "name": "[dpdk-dev,RFC,v2,22/28] eal/pci: Add pci_close_all_drivers", "commit_ref": null, "pull_url": null, "state": "rfc", "archived": true, "hash": "2e77ae1417b44c28d8ee5ff306a84c92a13e02d6", "submitter": { "id": 64, "url": "https://patches.dpdk.org/api/people/64/?format=api", "name": "Tetsuya Mukawa", "email": "mukawa@igel.co.jp" }, "delegate": null, "mbox": "https://patches.dpdk.org/project/dpdk/patch/1415072748-31937-23-git-send-email-mukawa@igel.co.jp/mbox/", "series": [], "comments": "https://patches.dpdk.org/api/patches/1108/comments/", "check": "pending", "checks": "https://patches.dpdk.org/api/patches/1108/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<dev-bounces@dpdk.org>", "X-Original-To": "patchwork@dpdk.org", "Delivered-To": "patchwork@dpdk.org", "Received": [ "from [92.243.14.124] (localhost [IPv6:::1])\n\tby dpdk.org (Postfix) with ESMTP id 7E5067FD1;\n\tTue, 4 Nov 2014 04:37:45 +0100 (CET)", "from mail-pd0-f177.google.com (mail-pd0-f177.google.com\n\t[209.85.192.177]) by dpdk.org (Postfix) with ESMTP id 2EDA87FD1\n\tfor <dev@dpdk.org>; Tue, 4 Nov 2014 04:37:43 +0100 (CET)", "by mail-pd0-f177.google.com with SMTP id v10so12766508pde.36\n\tfor <dev@dpdk.org>; Mon, 03 Nov 2014 19:46:59 -0800 (PST)", "from localhost.localdomain (napt.igel.co.jp. [219.106.231.132])\n\tby mx.google.com with ESMTPSA id\n\tjc3sm18430580pbb.49.2014.11.03.19.46.57 for <multiple recipients>\n\t(version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128);\n\tMon, 03 Nov 2014 19:46:58 -0800 (PST)" ], "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20130820;\n\th=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to\n\t:references;\n\tbh=hA6bSmbxm9B08auQh8GTFs3c150rFa8zSrBqtMhW9gs=;\n\tb=EH1lDDZpH+yq8VVT4ZZsps+tY9HNSAwL7Jt3NuRYwF2lQ/TL9/gVjJiFlMm1L2zptZ\n\tjx2QcpYQz4iUfjnzDuzQIc6/C8+KvVb92LjDJn5N/dv1hnsYHufm0mb3MCKrgkwYSsfO\n\t7fDrERJvKV8IhIQYF3hW6WTZOah1iKAhms1CovozNUtPAE3/uyE33A6wwy6I9hrg5Y3r\n\tqnkT7S5T8kdR+CCM2P1AnMSdzzbrK5kL/CoauUaF/ziyAkbarN+FQum6XRxgRXhfKcOU\n\tJL1sjbT+L7qoyNRMBfShYj/9uMWm2HXU7lntJxbdnFpI+9tOfc4XpmwwSPWs20Ut/p4K\n\tNaOw==", "X-Gm-Message-State": "ALoCoQkiyOfwA47eYv6bT1sZhz8/k0j5pSOY1kYO2s1nQoTKAlM7mUhwowPvr5PiKRf+8tZSMY10", "X-Received": "by 10.67.30.34 with SMTP id kb2mr46386071pad.97.1415072819407;\n\tMon, 03 Nov 2014 19:46:59 -0800 (PST)", "From": "Tetsuya Mukawa <mukawa@igel.co.jp>", "To": "dev@dpdk.org", "Date": "Tue, 4 Nov 2014 12:45:42 +0900", "Message-Id": "<1415072748-31937-23-git-send-email-mukawa@igel.co.jp>", "X-Mailer": "git-send-email 1.9.1", "In-Reply-To": "<1415072748-31937-1-git-send-email-mukawa@igel.co.jp>", "References": "<1414572576-21371-1-git-send-email-mukawa@igel.co.jp>\n\t<1415072748-31937-1-git-send-email-mukawa@igel.co.jp>", "Cc": "nakajima.yoshihiro@lab.ntt.co.jp, masutani.hitoshi@lab.ntt.co.jp", "Subject": "[dpdk-dev] [RFC PATCH v2 22/28] eal/pci: Add pci_close_all_drivers", "X-BeenThere": "dev@dpdk.org", "X-Mailman-Version": "2.1.15", "Precedence": "list", "List-Id": "patches and discussions about DPDK <dev.dpdk.org>", "List-Unsubscribe": "<http://dpdk.org/ml/options/dev>,\n\t<mailto:dev-request@dpdk.org?subject=unsubscribe>", "List-Archive": "<http://dpdk.org/ml/archives/dev/>", "List-Post": "<mailto:dev@dpdk.org>", "List-Help": "<mailto:dev-request@dpdk.org?subject=help>", "List-Subscribe": "<http://dpdk.org/ml/listinfo/dev>,\n\t<mailto:dev-request@dpdk.org?subject=subscribe>", "Errors-To": "dev-bounces@dpdk.org", "Sender": "\"dev\" <dev-bounces@dpdk.org>" }, "content": "The function tries to find a driver for the specified device, and then\nclose the driver.\n\nSigned-off-by: Tetsuya Mukawa <mukawa@igel.co.jp>\n---\n lib/librte_eal/common/eal_common_pci.c | 19 +++++++++++++++++++\n 1 file changed, 19 insertions(+)", "diff": "diff --git a/lib/librte_eal/common/eal_common_pci.c b/lib/librte_eal/common/eal_common_pci.c\nindex 1e3efea..b404ee0 100644\n--- a/lib/librte_eal/common/eal_common_pci.c\n+++ b/lib/librte_eal/common/eal_common_pci.c\n@@ -100,6 +100,7 @@ static struct rte_devargs *pci_devargs_lookup(struct rte_pci_device *dev)\n }\n \n #define INVOKE_PROBE\t(0)\n+#define INVOKE_CLOSE\t(1)\n \n static int\n pci_invoke_all_drivers(struct rte_pci_device *dev, int type)\n@@ -112,6 +113,11 @@ pci_invoke_all_drivers(struct rte_pci_device *dev, int type)\n \t\tcase INVOKE_PROBE:\n \t\t\trc = rte_eal_pci_probe_one_driver(dr, dev);\n \t\t\tbreak;\n+#if defined(RTE_LIBRTE_EAL_HOTPLUG) && defined(RTE_LIBRTE_EAL_LINUXAPP)\n+\t\tcase INVOKE_CLOSE:\n+\t\t\trc = rte_eal_pci_close_one_driver(dr, dev);\n+\t\t\tbreak;\n+#endif\n \t\t}\n \t\tif (rc < 0)\n \t\t\t/* negative value is an error */\n@@ -135,6 +141,19 @@ pci_probe_all_drivers(struct rte_pci_device *dev)\n \treturn pci_invoke_all_drivers(dev, INVOKE_PROBE);\n }\n \n+#if defined(RTE_LIBRTE_EAL_HOTPLUG) && defined(RTE_LIBRTE_EAL_LINUXAPP)\n+/*\n+ * If vendor/device ID match, call the devclose() function of all\n+ * registered driver for the given device. Return -1 if initialization\n+ * failed, return 1 if no driver is found for this device.\n+ */\n+static int\n+pci_close_all_drivers(struct rte_pci_device *dev)\n+{\n+\treturn pci_invoke_all_drivers(dev, INVOKE_CLOSE);\n+}\n+#endif /* RTE_LIBRTE_EAL_HOTPLUG & RTE_LIBRTE_EAL_LINUXAPP */\n+\n /*\n * Scan the content of the PCI bus, and call the devinit() function for\n * all registered drivers that have a matching entry in its id_table\n", "prefixes": [ "dpdk-dev", "RFC", "v2", "22/28" ] }{ "id": 1108, "url": "