Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/986039/?format=api
{ "id": 986039, "url": "http://patchwork.ozlabs.org/api/patches/986039/?format=api", "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/patch/20181018153709.32664-7-anirudh.venkataramanan@intel.com/", "project": { "id": 46, "url": "http://patchwork.ozlabs.org/api/projects/46/?format=api", "name": "Intel Wired Ethernet development", "link_name": "intel-wired-lan", "list_id": "intel-wired-lan.osuosl.org", "list_email": "intel-wired-lan@osuosl.org", "web_url": "", "scm_url": "", "webscm_url": "", "list_archive_url": "", "list_archive_url_format": "", "commit_url_format": "" }, "msgid": "<20181018153709.32664-7-anirudh.venkataramanan@intel.com>", "list_archive_url": null, "date": "2018-10-18T15:37:08", "name": "[6/7] ice: Allocate VF interrupts and set queue map", "commit_ref": null, "pull_url": null, "state": "accepted", "archived": false, "hash": "6aba691e2478e8e6ed2acd4ddb60b1d927c0df39", "submitter": { "id": 73601, "url": "http://patchwork.ozlabs.org/api/people/73601/?format=api", "name": "Anirudh Venkataramanan", "email": "anirudh.venkataramanan@intel.com" }, "delegate": { "id": 68, "url": "http://patchwork.ozlabs.org/api/users/68/?format=api", "username": "jtkirshe", "first_name": "Jeff", "last_name": "Kirsher", "email": "jeffrey.t.kirsher@intel.com" }, "mbox": "http://patchwork.ozlabs.org/project/intel-wired-lan/patch/20181018153709.32664-7-anirudh.venkataramanan@intel.com/mbox/", "series": [ { "id": 71486, "url": "http://patchwork.ozlabs.org/api/series/71486/?format=api", "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/list/?series=71486", "date": "2018-10-18T15:37:02", "name": "[1/7] ice: Make ice_msix_clean_rings static", "version": 1, "mbox": "http://patchwork.ozlabs.org/series/71486/mbox/" } ], "comments": "http://patchwork.ozlabs.org/api/patches/986039/comments/", "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/986039/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<intel-wired-lan-bounces@osuosl.org>", "X-Original-To": [ "incoming@patchwork.ozlabs.org", "intel-wired-lan@lists.osuosl.org" ], "Delivered-To": [ "patchwork-incoming@bilbo.ozlabs.org", "intel-wired-lan@lists.osuosl.org" ], "Authentication-Results": [ "ozlabs.org;\n\tspf=pass (mailfrom) smtp.mailfrom=osuosl.org\n\t(client-ip=140.211.166.137; helo=fraxinus.osuosl.org;\n\tenvelope-from=intel-wired-lan-bounces@osuosl.org;\n\treceiver=<UNKNOWN>)", "ozlabs.org;\n\tdmarc=fail (p=none dis=none) header.from=intel.com" ], "Received": [ "from fraxinus.osuosl.org (smtp4.osuosl.org [140.211.166.137])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256\n\tbits)) (No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPS id 42bY7z3vDNz9sCm\n\tfor <incoming@patchwork.ozlabs.org>;\n\tFri, 19 Oct 2018 02:37:19 +1100 (AEDT)", "from localhost (localhost [127.0.0.1])\n\tby fraxinus.osuosl.org (Postfix) with ESMTP id 3216586DD7;\n\tThu, 18 Oct 2018 15:37:18 +0000 (UTC)", "from fraxinus.osuosl.org ([127.0.0.1])\n\tby localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024)\n\twith ESMTP id PDuLhMunDrux; Thu, 18 Oct 2018 15:37:17 +0000 (UTC)", "from ash.osuosl.org (ash.osuosl.org [140.211.166.34])\n\tby fraxinus.osuosl.org (Postfix) with ESMTP id EAFAA86DE4;\n\tThu, 18 Oct 2018 15:37:16 +0000 (UTC)", "from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138])\n\tby ash.osuosl.org (Postfix) with ESMTP id 283BC1BF3E5\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tThu, 18 Oct 2018 15:37:12 +0000 (UTC)", "from localhost (localhost [127.0.0.1])\n\tby whitealder.osuosl.org (Postfix) with ESMTP id 2567287D5A\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tThu, 18 Oct 2018 15:37:12 +0000 (UTC)", "from whitealder.osuosl.org ([127.0.0.1])\n\tby localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024)\n\twith ESMTP id 5wk6VH7TfxXi for <intel-wired-lan@lists.osuosl.org>;\n\tThu, 18 Oct 2018 15:37:10 +0000 (UTC)", "from mga07.intel.com (mga07.intel.com [134.134.136.100])\n\tby whitealder.osuosl.org (Postfix) with ESMTPS id 5FDC087D6B\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tThu, 18 Oct 2018 15:37:10 +0000 (UTC)", "from orsmga007.jf.intel.com ([10.7.209.58])\n\tby orsmga105.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384;\n\t18 Oct 2018 08:37:09 -0700", "from shasta.jf.intel.com ([10.166.241.11])\n\tby orsmga007.jf.intel.com with ESMTP; 18 Oct 2018 08:37:09 -0700" ], "X-Virus-Scanned": [ "amavisd-new at osuosl.org", "amavisd-new at osuosl.org" ], "X-Greylist": "domain auto-whitelisted by SQLgrey-1.7.6", "X-Amp-Result": "SKIPPED(no attachment in message)", "X-Amp-File-Uploaded": "False", "X-ExtLoop1": "1", "X-IronPort-AV": "E=Sophos;i=\"5.54,396,1534834800\"; d=\"scan'208\";a=\"82246054\"", "From": "Anirudh Venkataramanan <anirudh.venkataramanan@intel.com>", "To": "intel-wired-lan@lists.osuosl.org", "Date": "Thu, 18 Oct 2018 08:37:08 -0700", "Message-Id": "<20181018153709.32664-7-anirudh.venkataramanan@intel.com>", "X-Mailer": "git-send-email 2.14.3", "In-Reply-To": "<20181018153709.32664-1-anirudh.venkataramanan@intel.com>", "References": "<20181018153709.32664-1-anirudh.venkataramanan@intel.com>", "Subject": "[Intel-wired-lan] [PATCH 6/7] ice: Allocate VF interrupts and set\n\tqueue map", "X-BeenThere": "intel-wired-lan@osuosl.org", "X-Mailman-Version": "2.1.29", "Precedence": "list", "List-Id": "Intel Wired Ethernet Linux Kernel Driver Development\n\t<intel-wired-lan.osuosl.org>", "List-Unsubscribe": "<https://lists.osuosl.org/mailman/options/intel-wired-lan>, \n\t<mailto:intel-wired-lan-request@osuosl.org?subject=unsubscribe>", "List-Archive": "<http://lists.osuosl.org/pipermail/intel-wired-lan/>", "List-Post": "<mailto:intel-wired-lan@osuosl.org>", "List-Help": "<mailto:intel-wired-lan-request@osuosl.org?subject=help>", "List-Subscribe": "<https://lists.osuosl.org/mailman/listinfo/intel-wired-lan>, \n\t<mailto:intel-wired-lan-request@osuosl.org?subject=subscribe>", "MIME-Version": "1.0", "Content-Type": "text/plain; charset=\"us-ascii\"", "Content-Transfer-Encoding": "7bit", "Errors-To": "intel-wired-lan-bounces@osuosl.org", "Sender": "\"Intel-wired-lan\" <intel-wired-lan-bounces@osuosl.org>" }, "content": "Allocate VF interrupts using VPINT_ALLOC_PCI. Multiple interrupts are\nspecified as a range from \"first\" to \"last\".\n\nAlso, according to the spec, the queue mapping for a VF needs to be set\nin both contig and scatter queue modes. So make this change as well.\n\nSigned-off-by: Anirudh Venkataramanan <anirudh.venkataramanan@intel.com>\n---\n drivers/net/ethernet/intel/ice/ice_hw_autogen.h | 6 ++++++\n drivers/net/ethernet/intel/ice/ice_virtchnl_pf.c | 15 +++++++++++----\n 2 files changed, 17 insertions(+), 4 deletions(-)", "diff": "diff --git a/drivers/net/ethernet/intel/ice/ice_hw_autogen.h b/drivers/net/ethernet/intel/ice/ice_hw_autogen.h\nindex 228afcad6fc3..5fdea6ec7675 100644\n--- a/drivers/net/ethernet/intel/ice/ice_hw_autogen.h\n+++ b/drivers/net/ethernet/intel/ice/ice_hw_autogen.h\n@@ -157,6 +157,12 @@\n #define VPINT_ALLOC_LAST_S\t\t\t12\n #define VPINT_ALLOC_LAST_M\t\t\tICE_M(0x7FF, 12)\n #define VPINT_ALLOC_VALID_M\t\t\tBIT(31)\n+#define VPINT_ALLOC_PCI(_VF)\t\t\t(0x0009D000 + ((_VF) * 4))\n+#define VPINT_ALLOC_PCI_FIRST_S\t\t\t0\n+#define VPINT_ALLOC_PCI_FIRST_M\t\t\tICE_M(0x7FF, 0)\n+#define VPINT_ALLOC_PCI_LAST_S\t\t\t12\n+#define VPINT_ALLOC_PCI_LAST_M\t\t\tICE_M(0x7FF, 12)\n+#define VPINT_ALLOC_PCI_VALID_M\t\t\tBIT(31)\n #define GLLAN_RCTL_0\t\t\t\t0x002941F8\n #define QRX_CONTEXT(_i, _QRX)\t\t\t(0x00280000 + ((_i) * 8192 + (_QRX) * 4))\n #define QRX_CTRL(_QRX)\t\t\t\t(0x00120000 + ((_QRX) * 4))\ndiff --git a/drivers/net/ethernet/intel/ice/ice_virtchnl_pf.c b/drivers/net/ethernet/intel/ice/ice_virtchnl_pf.c\nindex c25e486706f3..45f10f8f01dc 100644\n--- a/drivers/net/ethernet/intel/ice/ice_virtchnl_pf.c\n+++ b/drivers/net/ethernet/intel/ice/ice_virtchnl_pf.c\n@@ -173,6 +173,7 @@ static void ice_dis_vf_mappings(struct ice_vf *vf)\n \tvsi = pf->vsi[vf->lan_vsi_idx];\n \n \twr32(hw, VPINT_ALLOC(vf->vf_id), 0);\n+\twr32(hw, VPINT_ALLOC_PCI(vf->vf_id), 0);\n \n \tfirst = vf->first_vector_idx;\n \tlast = first + pf->num_vf_msix - 1;\n@@ -519,6 +520,10 @@ static void ice_ena_vf_mappings(struct ice_vf *vf)\n \t VPINT_ALLOC_VALID_M);\n \twr32(hw, VPINT_ALLOC(vf->vf_id), reg);\n \n+\treg = (((first << VPINT_ALLOC_PCI_FIRST_S) & VPINT_ALLOC_PCI_FIRST_M) |\n+\t ((last << VPINT_ALLOC_PCI_LAST_S) & VPINT_ALLOC_PCI_LAST_M) |\n+\t VPINT_ALLOC_PCI_VALID_M);\n+\twr32(hw, VPINT_ALLOC_PCI(vf->vf_id), reg);\n \t/* map the interrupts to its functions */\n \tfor (v = first; v <= last; v++) {\n \t\treg = (((abs_vf_id << GLINT_VECT2FUNC_VF_NUM_S) &\n@@ -528,10 +533,11 @@ static void ice_ena_vf_mappings(struct ice_vf *vf)\n \t\twr32(hw, GLINT_VECT2FUNC(v), reg);\n \t}\n \n+\t/* set regardless of mapping mode */\n+\twr32(hw, VPLAN_TXQ_MAPENA(vf->vf_id), VPLAN_TXQ_MAPENA_TX_ENA_M);\n+\n \t/* VF Tx queues allocation */\n \tif (vsi->tx_mapping_mode == ICE_VSI_MAP_CONTIG) {\n-\t\twr32(hw, VPLAN_TXQ_MAPENA(vf->vf_id),\n-\t\t VPLAN_TXQ_MAPENA_TX_ENA_M);\n \t\t/* set the VF PF Tx queue range\n \t\t * VFNUMQ value should be set to (number of queues - 1). A value\n \t\t * of 0 means 1 queue and a value of 255 means 256 queues\n@@ -546,10 +552,11 @@ static void ice_ena_vf_mappings(struct ice_vf *vf)\n \t\t\t\"Scattered mode for VF Tx queues is not yet implemented\\n\");\n \t}\n \n+\t/* set regardless of mapping mode */\n+\twr32(hw, VPLAN_RXQ_MAPENA(vf->vf_id), VPLAN_RXQ_MAPENA_RX_ENA_M);\n+\n \t/* VF Rx queues allocation */\n \tif (vsi->rx_mapping_mode == ICE_VSI_MAP_CONTIG) {\n-\t\twr32(hw, VPLAN_RXQ_MAPENA(vf->vf_id),\n-\t\t VPLAN_RXQ_MAPENA_RX_ENA_M);\n \t\t/* set the VF PF Rx queue range\n \t\t * VFNUMQ value should be set to (number of queues - 1). A value\n \t\t * of 0 means 1 queue and a value of 255 means 256 queues\n", "prefixes": [ "6/7" ] }