Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/458048/?format=api
{ "id": 458048, "url": "http://patchwork.ozlabs.org/api/patches/458048/?format=api", "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/patch/1428092835-16834-24-git-send-email-jeffrey.t.kirsher@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": "<1428092835-16834-24-git-send-email-jeffrey.t.kirsher@intel.com>", "list_archive_url": null, "date": "2015-04-03T20:27:14", "name": "[net-next,24/25] fm10k: mbx_update_max_size does not drop all oversized messages", "commit_ref": null, "pull_url": null, "state": "accepted", "archived": false, "hash": "987c9986c0f272d45efba5024ec22e7b4cd81af8", "submitter": { "id": 473, "url": "http://patchwork.ozlabs.org/api/people/473/?format=api", "name": "Kirsher, Jeffrey T", "email": "jeffrey.t.kirsher@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/1428092835-16834-24-git-send-email-jeffrey.t.kirsher@intel.com/mbox/", "series": [], "comments": "http://patchwork.ozlabs.org/api/patches/458048/comments/", "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/458048/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<intel-wired-lan-bounces@lists.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" ], "Received": [ "from fraxinus.osuosl.org (fraxinus.osuosl.org [140.211.166.137])\n\tby ozlabs.org (Postfix) with ESMTP id BC02C140187\n\tfor <incoming@patchwork.ozlabs.org>;\n\tSat, 4 Apr 2015 07:27:30 +1100 (AEDT)", "from localhost (localhost [127.0.0.1])\n\tby fraxinus.osuosl.org (Postfix) with ESMTP id F3BD4A40C4;\n\tFri, 3 Apr 2015 20:27:29 +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 2VxQhS-dc96E; Fri, 3 Apr 2015 20:27:29 +0000 (UTC)", "from ash.osuosl.org (ash.osuosl.org [140.211.166.34])\n\tby fraxinus.osuosl.org (Postfix) with ESMTP id B2C52A4065;\n\tFri, 3 Apr 2015 20:27:27 +0000 (UTC)", "from whitealder.osuosl.org (whitealder.osuosl.org\n\t[140.211.166.138])\n\tby ash.osuosl.org (Postfix) with ESMTP id 6EB081C2A8F\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tFri, 3 Apr 2015 20:27:24 +0000 (UTC)", "from localhost (localhost [127.0.0.1])\n\tby whitealder.osuosl.org (Postfix) with ESMTP id 6AA1192130\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tFri, 3 Apr 2015 20:27:24 +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 ljvtk8gDXKII for <intel-wired-lan@lists.osuosl.org>;\n\tFri, 3 Apr 2015 20:27:23 +0000 (UTC)", "from mga09.intel.com (mga09.intel.com [134.134.136.24])\n\tby whitealder.osuosl.org (Postfix) with ESMTP id DB04C92173\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tFri, 3 Apr 2015 20:27:23 +0000 (UTC)", "from fmsmga003.fm.intel.com ([10.253.24.29])\n\tby orsmga102.jf.intel.com with ESMTP; 03 Apr 2015 13:27:23 -0700", "from lwang4-mobl1.amr.corp.intel.com (HELO\n\tjtkirshe-mobl.amr.corp.intel.com) ([10.254.109.203])\n\tby FMSMGA003.fm.intel.com with ESMTP; 03 Apr 2015 13:27:23 -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-ExtLoop1": "1", "X-IronPort-AV": "E=Sophos;i=\"5.11,519,1422950400\"; d=\"scan'208\";a=\"476517960\"", "From": "Jeff Kirsher <jeffrey.t.kirsher@intel.com>", "To": "intel-wired-lan@lists.osuosl.org", "Date": "Fri, 3 Apr 2015 13:27:14 -0700", "Message-Id": "<1428092835-16834-24-git-send-email-jeffrey.t.kirsher@intel.com>", "X-Mailer": "git-send-email 1.9.3", "In-Reply-To": "<1428092835-16834-1-git-send-email-jeffrey.t.kirsher@intel.com>", "References": "<1428092835-16834-1-git-send-email-jeffrey.t.kirsher@intel.com>", "Subject": "[Intel-wired-lan] [net-next 24/25] fm10k: mbx_update_max_size does\n\tnot drop all oversized messages", "X-BeenThere": "intel-wired-lan@lists.osuosl.org", "X-Mailman-Version": "2.1.18-1", "Precedence": "list", "List-Id": "Intel Wired Ethernet Linux Kernel Driver Development\n\t<intel-wired-lan.lists.osuosl.org>", "List-Unsubscribe": "<http://lists.osuosl.org/mailman/options/intel-wired-lan>, \n\t<mailto:intel-wired-lan-request@lists.osuosl.org?subject=unsubscribe>", "List-Archive": "<http://lists.osuosl.org/pipermail/intel-wired-lan/>", "List-Post": "<mailto:intel-wired-lan@lists.osuosl.org>", "List-Help": "<mailto:intel-wired-lan-request@lists.osuosl.org?subject=help>", "List-Subscribe": "<http://lists.osuosl.org/mailman/listinfo/intel-wired-lan>, \n\t<mailto:intel-wired-lan-request@lists.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@lists.osuosl.org", "Sender": "\"Intel-wired-lan\" <intel-wired-lan-bounces@lists.osuosl.org>" }, "content": "When we call update_max_size it does not drop all oversized messages.\nThis is due to the difficulty in performing this operation, since it is\na FIFO which makes updating anything other than head or tail very\ndifficult. To fix this, modify validate_msg_size to ensure that we error\nout later when trying to transmit the message that could be oversized.\nThis will generally be a rare condition, as it requires the FIFO to\ninclude a message larger than the max_size negotiated during mailbox\nconnect. Note that max_size is always smaller than rx.size so it should\nbe safe to use here.\n\nAlso, update the update_max_size function header comment to clearly\nindicate that it does not drop all oversized messages, but only those at\nthe head of the FIFO.\n\nSigned-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>\nSigned-off-by: Jacob Keller <jacob.e.keller@intel.com>\nAcked-by: Matthew Vick <matthew.vick@intel.com>\n---\n drivers/net/ethernet/intel/fm10k/fm10k_mbx.c | 9 ++++++---\n 1 file changed, 6 insertions(+), 3 deletions(-)", "diff": "diff --git a/drivers/net/ethernet/intel/fm10k/fm10k_mbx.c b/drivers/net/ethernet/intel/fm10k/fm10k_mbx.c\nindex 27f8279..1b27383 100644\n--- a/drivers/net/ethernet/intel/fm10k/fm10k_mbx.c\n+++ b/drivers/net/ethernet/intel/fm10k/fm10k_mbx.c\n@@ -327,7 +327,7 @@ static u16 fm10k_mbx_validate_msg_size(struct fm10k_mbx_info *mbx, u16 len)\n \t} while (total_len < len);\n \n \t/* message extends out of pushed section, but fits in FIFO */\n-\tif ((len < total_len) && (msg_len <= mbx->rx.size))\n+\tif ((len < total_len) && (msg_len <= mbx->max_size))\n \t\treturn 0;\n \n \t/* return length of invalid section */\n@@ -1063,8 +1063,11 @@ static void fm10k_mbx_reset_work(struct fm10k_mbx_info *mbx)\n * @mbx: pointer to mailbox\n * @size: new value for max_size\n *\n- * This function will update the max_size value and drop any outgoing messages\n- * from the head of the Tx FIFO that are larger than max_size.\n+ * This function updates the max_size value and drops any outgoing messages\n+ * at the head of the Tx FIFO if they are larger than max_size. It does not\n+ * drop all messages, as this is too difficult to parse and remove them from\n+ * the FIFO. Instead, rely on the checking to ensure that messages larger\n+ * than max_size aren't pushed into the memory buffer.\n **/\n static void fm10k_mbx_update_max_size(struct fm10k_mbx_info *mbx, u16 size)\n {\n", "prefixes": [ "net-next", "24/25" ] }