Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/118343/?format=api
http://patches.dpdk.org/api/patches/118343/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/patch/1666073977-175484-6-git-send-email-andy.pei@intel.com/", "project": { "id": 1, "url": "http://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": "<1666073977-175484-6-git-send-email-andy.pei@intel.com>", "list_archive_url": "https://inbox.dpdk.org/dev/1666073977-175484-6-git-send-email-andy.pei@intel.com", "date": "2022-10-18T06:19:30", "name": "[v7,05/12] vdpa/ifc: only configure enabled queue", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": true, "hash": "63fbf8ebca131393e4dd2478c11e7ac08fe730c1", "submitter": { "id": 1185, "url": "http://patches.dpdk.org/api/people/1185/?format=api", "name": "Pei, Andy", "email": "andy.pei@intel.com" }, "delegate": { "id": 2642, "url": "http://patches.dpdk.org/api/users/2642/?format=api", "username": "mcoquelin", "first_name": "Maxime", "last_name": "Coquelin", "email": "maxime.coquelin@redhat.com" }, "mbox": "http://patches.dpdk.org/project/dpdk/patch/1666073977-175484-6-git-send-email-andy.pei@intel.com/mbox/", "series": [ { "id": 25271, "url": "http://patches.dpdk.org/api/series/25271/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=25271", "date": "2022-10-18T06:19:25", "name": "vdpa/ifc: add multi queue support", "version": 7, "mbox": "http://patches.dpdk.org/series/25271/mbox/" } ], "comments": "http://patches.dpdk.org/api/patches/118343/comments/", "check": "success", "checks": "http://patches.dpdk.org/api/patches/118343/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<dev-bounces@dpdk.org>", "X-Original-To": "patchwork@inbox.dpdk.org", "Delivered-To": "patchwork@inbox.dpdk.org", "Received": [ "from mails.dpdk.org (mails.dpdk.org [217.70.189.124])\n\tby inbox.dpdk.org (Postfix) with ESMTP id EBA2DA0560;\n\tTue, 18 Oct 2022 08:23:54 +0200 (CEST)", "from [217.70.189.124] (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id 3E9C4427EA;\n\tTue, 18 Oct 2022 08:23:45 +0200 (CEST)", "from mga12.intel.com (mga12.intel.com [192.55.52.136])\n by mails.dpdk.org (Postfix) with ESMTP id 0E7694161A\n for <dev@dpdk.org>; Tue, 18 Oct 2022 08:23:43 +0200 (CEST)", "from orsmga008.jf.intel.com ([10.7.209.65])\n by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 17 Oct 2022 23:23:40 -0700", "from dpdk-dipei.sh.intel.com ([10.67.110.251])\n by orsmga008.jf.intel.com with ESMTP; 17 Oct 2022 23:23:38 -0700" ], "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/simple;\n d=intel.com; i=@intel.com; q=dns/txt; s=Intel;\n t=1666074224; x=1697610224;\n h=from:to:cc:subject:date:message-id:in-reply-to: references;\n bh=u6gMBbApdXSB3Ld3Jjg3QEGS4spcCcxNroeYHYyn54Q=;\n b=Jz4m3nqnDKYlKkbk/4SRERcrwVqgmG99SBKkYHIbGwzJVjIWdtpgPm66\n UmLNOqQC64WcpjyAF6bTN8aDH+aK2sEEJaq84Bu7Cyw3bjrY7YsvKbQeS\n SxRmfLeMh4x5QkIVZaSwVo6MfwgbqFSsSO/iD5NdUstEuts9PB/+Rwuxe\n GTxR0otXuAFZL/0bNHBPmSddboOqkgbdyw2DIsVqqQJD7RmA0fC4NSSW5\n gHcxb8OrpAVOF/Mlusvj5urQJDyimoMo7mkYE0vojU3Gak1ft+ANg72vg\n tySx/+Ge2QFoLqJGIZHnHAUP9Se490pmQnZnGS++Ml+S5PyY0jReuZunu Q==;", "X-IronPort-AV": [ "E=McAfee;i=\"6500,9779,10503\"; a=\"285732765\"", "E=Sophos;i=\"5.95,193,1661842800\"; d=\"scan'208\";a=\"285732765\"", "E=McAfee;i=\"6500,9779,10503\"; a=\"659655841\"", "E=Sophos;i=\"5.95,193,1661842800\"; d=\"scan'208\";a=\"659655841\"" ], "X-ExtLoop1": "1", "From": "Andy Pei <andy.pei@intel.com>", "To": "dev@dpdk.org", "Cc": "chenbo.xia@intel.com, rosen.xu@intel.com, wei.huang@intel.com,\n gang.cao@intel.com, maxime.coquelin@redhat.com", "Subject": "[PATCH v7 05/12] vdpa/ifc: only configure enabled queue", "Date": "Tue, 18 Oct 2022 14:19:30 +0800", "Message-Id": "<1666073977-175484-6-git-send-email-andy.pei@intel.com>", "X-Mailer": "git-send-email 1.8.3.1", "In-Reply-To": "<1666073977-175484-1-git-send-email-andy.pei@intel.com>", "References": "<1661229305-240952-2-git-send-email-andy.pei@intel.com>\n <1666073977-175484-1-git-send-email-andy.pei@intel.com>", "X-BeenThere": "dev@dpdk.org", "X-Mailman-Version": "2.1.29", "Precedence": "list", "List-Id": "DPDK patches and discussions <dev.dpdk.org>", "List-Unsubscribe": "<https://mails.dpdk.org/options/dev>,\n <mailto:dev-request@dpdk.org?subject=unsubscribe>", "List-Archive": "<http://mails.dpdk.org/archives/dev/>", "List-Post": "<mailto:dev@dpdk.org>", "List-Help": "<mailto:dev-request@dpdk.org?subject=help>", "List-Subscribe": "<https://mails.dpdk.org/listinfo/dev>,\n <mailto:dev-request@dpdk.org?subject=subscribe>", "Errors-To": "dev-bounces@dpdk.org" }, "content": "When configuring the hardware queue, we only configure queues which\nhave been enabled by vhost.\n\nSigned-off-by: Andy Pei <andy.pei@intel.com>\nSigned-off-by: Huang Wei <wei.huang@intel.com>\nReviewed-by: Chenbo Xia <chenbo.xia@intel.com>\n---\n drivers/vdpa/ifc/base/ifcvf.c | 3 +++\n drivers/vdpa/ifc/ifcvf_vdpa.c | 16 ++++++++++++++--\n 2 files changed, 17 insertions(+), 2 deletions(-)", "diff": "diff --git a/drivers/vdpa/ifc/base/ifcvf.c b/drivers/vdpa/ifc/base/ifcvf.c\nindex b377126..30bb8cb 100644\n--- a/drivers/vdpa/ifc/base/ifcvf.c\n+++ b/drivers/vdpa/ifc/base/ifcvf.c\n@@ -252,6 +252,9 @@\n \n \tifcvf_enable_mq(hw);\n \tfor (i = 0; i < hw->nr_vring; i++) {\n+\t\tif (!hw->vring[i].enable)\n+\t\t\tcontinue;\n+\n \t\tIFCVF_WRITE_REG16(i, &cfg->queue_select);\n \t\tio_write64_twopart(hw->vring[i].desc, &cfg->queue_desc_lo,\n \t\t\t\t&cfg->queue_desc_hi);\ndiff --git a/drivers/vdpa/ifc/ifcvf_vdpa.c b/drivers/vdpa/ifc/ifcvf_vdpa.c\nindex 5a24204..0c3407a 100644\n--- a/drivers/vdpa/ifc/ifcvf_vdpa.c\n+++ b/drivers/vdpa/ifc/ifcvf_vdpa.c\n@@ -284,6 +284,8 @@ struct rte_vdpa_dev_info {\n \trte_vhost_get_negotiated_features(vid, &hw->req_features);\n \n \tfor (i = 0; i < nr_vring; i++) {\n+\t\tif (!hw->vring[i].enable)\n+\t\t\tcontinue;\n \t\trte_vhost_get_vhost_vring(vid, i, &vq);\n \t\tgpa = hva_to_gpa(vid, (uint64_t)(uintptr_t)vq.desc);\n \t\tif (gpa == 0) {\n@@ -499,6 +501,8 @@ struct rte_vdpa_dev_info {\n \n \tvring.kickfd = -1;\n \tfor (qid = 0; qid < q_num; qid++) {\n+\t\tif (!hw->vring[qid].enable)\n+\t\t\tcontinue;\n \t\tev.events = EPOLLIN | EPOLLPRI;\n \t\trte_vhost_get_vhost_vring(internal->vid, qid, &vring);\n \t\tev.data.u64 = qid | (uint64_t)vring.kickfd << 32;\n@@ -1058,6 +1062,8 @@ struct rte_vdpa_dev_info {\n \tstruct rte_vdpa_device *vdev;\n \tstruct internal_list *list;\n \tstruct ifcvf_internal *internal;\n+\tstruct ifcvf_hw *hw;\n+\tuint16_t i;\n \n \tvdev = rte_vhost_get_vdpa_device(vid);\n \tlist = find_internal_resource_by_vdev(vdev);\n@@ -1071,11 +1077,17 @@ struct rte_vdpa_dev_info {\n \trte_atomic32_set(&internal->dev_attached, 1);\n \tupdate_datapath(internal);\n \n-\tif (rte_vhost_host_notifier_ctrl(vid, RTE_VHOST_QUEUE_ALL, true) != 0)\n-\t\tDRV_LOG(NOTICE, \"vDPA (%s): software relay is used.\",\n+\thw = &internal->hw;\n+\tfor (i = 0; i < hw->nr_vring; i++) {\n+\t\tif (!hw->vring[i].enable)\n+\t\t\tcontinue;\n+\t\tif (rte_vhost_host_notifier_ctrl(vid, i, true) != 0)\n+\t\t\tDRV_LOG(NOTICE, \"vDPA (%s): software relay is used.\",\n \t\t\t\tvdev->device->name);\n+\t}\n \n \tinternal->configured = 1;\n+\tDRV_LOG(INFO, \"vDPA device %s is configured\", vdev->device->name);\n \treturn 0;\n }\n \n", "prefixes": [ "v7", "05/12" ] }{ "id": 118343, "url": "