Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/972311/?format=api
{ "id": 972311, "url": "http://patchwork.ozlabs.org/api/patches/972311/?format=api", "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/patch/20180920104247.69280-1-sebastianx.basierski@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": "<20180920104247.69280-1-sebastianx.basierski@intel.com>", "list_archive_url": null, "date": "2018-09-20T10:42:47", "name": "ixgbe: reset next_to_clean and next_to_use when we reset the head and tail", "commit_ref": null, "pull_url": null, "state": "changes-requested", "archived": false, "hash": "945411edada34aab947f7b902dd0ad9efee22438", "submitter": { "id": 74580, "url": "http://patchwork.ozlabs.org/api/people/74580/?format=api", "name": "Sebastian Basierski", "email": "sebastianx.basierski@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/20180920104247.69280-1-sebastianx.basierski@intel.com/mbox/", "series": [ { "id": 66621, "url": "http://patchwork.ozlabs.org/api/series/66621/?format=api", "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/list/?series=66621", "date": "2018-09-20T10:42:47", "name": "ixgbe: reset next_to_clean and next_to_use when we reset the head and tail", "version": 1, "mbox": "http://patchwork.ozlabs.org/series/66621/mbox/" } ], "comments": "http://patchwork.ozlabs.org/api/patches/972311/comments/", "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/972311/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.136; helo=silver.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 silver.osuosl.org (smtp3.osuosl.org [140.211.166.136])\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 42GCxR1j8Bz9sBj\n\tfor <incoming@patchwork.ozlabs.org>;\n\tThu, 20 Sep 2018 20:43:06 +1000 (AEST)", "from localhost (localhost [127.0.0.1])\n\tby silver.osuosl.org (Postfix) with ESMTP id 5262F3098D;\n\tThu, 20 Sep 2018 10:43:05 +0000 (UTC)", "from silver.osuosl.org ([127.0.0.1])\n\tby localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024)\n\twith ESMTP id pOwMqEzPRDJY; Thu, 20 Sep 2018 10:43:04 +0000 (UTC)", "from ash.osuosl.org (ash.osuosl.org [140.211.166.34])\n\tby silver.osuosl.org (Postfix) with ESMTP id 8325E22BA3;\n\tThu, 20 Sep 2018 10:43:04 +0000 (UTC)", "from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133])\n\tby ash.osuosl.org (Postfix) with ESMTP id E84741C0149\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tThu, 20 Sep 2018 10:43:02 +0000 (UTC)", "from localhost (localhost [127.0.0.1])\n\tby hemlock.osuosl.org (Postfix) with ESMTP id E462288894\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tThu, 20 Sep 2018 10:43:02 +0000 (UTC)", "from hemlock.osuosl.org ([127.0.0.1])\n\tby localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024)\n\twith ESMTP id e1S14nigBHUL for <intel-wired-lan@lists.osuosl.org>;\n\tThu, 20 Sep 2018 10:43:02 +0000 (UTC)", "from mga06.intel.com (mga06.intel.com [134.134.136.31])\n\tby hemlock.osuosl.org (Postfix) with ESMTPS id 1B52B88870\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tThu, 20 Sep 2018 10:43:02 +0000 (UTC)", "from fmsmga006.fm.intel.com ([10.253.24.20])\n\tby orsmga104.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384;\n\t20 Sep 2018 03:43:01 -0700", "from ubuntu.imu.intel.com ([10.217.246.11])\n\tby fmsmga006.fm.intel.com with ESMTP; 20 Sep 2018 03:43:00 -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.53,398,1531810800\"; d=\"scan'208\";a=\"265189620\"", "From": "Sebastian Basierski <sebastianx.basierski@intel.com>", "To": "intel-wired-lan@lists.osuosl.org", "Date": "Thu, 20 Sep 2018 12:42:47 +0200", "Message-Id": "<20180920104247.69280-1-sebastianx.basierski@intel.com>", "X-Mailer": "git-send-email 2.17.1", "Subject": "[Intel-wired-lan] [PATCH] ixgbe: reset next_to_clean and\n\tnext_to_use when we reset the head and tail", "X-BeenThere": "intel-wired-lan@osuosl.org", "X-Mailman-Version": "2.1.24", "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": "Only reset the next_to_clean and next_to_use values when we are resetting\nthe head and tail hardware registers. This way we can avoid having\nmultiple functions doing the reset work and can more easily track the\ncorrelation between the registers and these values.\n\nSigned-off-by: Sebastian Basierski <sebastianx.basierski@intel.com>\n---\n drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 25 +++++++++----------\n 1 file changed, 12 insertions(+), 13 deletions(-)", "diff": "diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c\nindex 27a8546c88b2..0e83f5e8973d 100644\n--- a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c\n+++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c\n@@ -3482,10 +3482,16 @@ void ixgbe_configure_tx_ring(struct ixgbe_adapter *adapter,\n \tIXGBE_WRITE_REG(hw, IXGBE_TDBAH(reg_idx), (tdba >> 32));\n \tIXGBE_WRITE_REG(hw, IXGBE_TDLEN(reg_idx),\n \t\t\tring->count * sizeof(union ixgbe_adv_tx_desc));\n+\n+\t/* reset head and tail pointers */\n \tIXGBE_WRITE_REG(hw, IXGBE_TDH(reg_idx), 0);\n \tIXGBE_WRITE_REG(hw, IXGBE_TDT(reg_idx), 0);\n \tring->tail = adapter->io_addr + IXGBE_TDT(reg_idx);\n \n+\t/* reset ntu and ntc to place SW in sync with hardwdare */\n+\tring->next_to_clean = 0;\n+\tring->next_to_use = 0;\n+\n \t/*\n \t * set WTHRESH to encourage burst writeback, it should not be set\n \t * higher than 1 when:\n@@ -4046,10 +4052,16 @@ void ixgbe_configure_rx_ring(struct ixgbe_adapter *adapter,\n \t/* Force flushing of IXGBE_RDLEN to prevent MDD */\n \tIXGBE_WRITE_FLUSH(hw);\n \n+\t/* reset head and tail pointers */\n \tIXGBE_WRITE_REG(hw, IXGBE_RDH(reg_idx), 0);\n \tIXGBE_WRITE_REG(hw, IXGBE_RDT(reg_idx), 0);\n \tring->tail = adapter->io_addr + IXGBE_RDT(reg_idx);\n \n+\t/* reset ntu and ntc to place SW in sync with hardwdare */\n+\tring->next_to_clean = 0;\n+\tring->next_to_use = 0;\n+\tring->next_to_alloc = 0;\n+\n \tixgbe_configure_srrctl(adapter, ring);\n \tixgbe_configure_rscctl(adapter, ring);\n \n@@ -5238,10 +5250,6 @@ static void ixgbe_clean_rx_ring(struct ixgbe_ring *rx_ring)\n \t\t\trx_buffer = rx_ring->rx_buffer_info;\n \t\t}\n \t}\n-\n-\trx_ring->next_to_alloc = 0;\n-\trx_ring->next_to_clean = 0;\n-\trx_ring->next_to_use = 0;\n }\n \n static int ixgbe_fwd_ring_up(struct ixgbe_adapter *adapter,\n@@ -5933,10 +5941,6 @@ static void ixgbe_clean_tx_ring(struct ixgbe_ring *tx_ring)\n \t/* reset BQL for queue */\n \tif (!ring_is_xdp(tx_ring))\n \t\tnetdev_tx_reset_queue(txring_txq(tx_ring));\n-\n-\t/* reset next_to_use and next_to_clean */\n-\ttx_ring->next_to_use = 0;\n-\ttx_ring->next_to_clean = 0;\n }\n \n /**\n@@ -6369,8 +6373,6 @@ int ixgbe_setup_tx_resources(struct ixgbe_ring *tx_ring)\n \tif (!tx_ring->desc)\n \t\tgoto err;\n \n-\ttx_ring->next_to_use = 0;\n-\ttx_ring->next_to_clean = 0;\n \treturn 0;\n \n err:\n@@ -6463,9 +6465,6 @@ int ixgbe_setup_rx_resources(struct ixgbe_adapter *adapter,\n \tif (!rx_ring->desc)\n \t\tgoto err;\n \n-\trx_ring->next_to_clean = 0;\n-\trx_ring->next_to_use = 0;\n-\n \t/* XDP RX-queue info */\n \tif (xdp_rxq_info_reg(&rx_ring->xdp_rxq, adapter->netdev,\n \t\t\t rx_ring->queue_index) < 0)\n", "prefixes": [] }