Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/691071/?format=api
{ "id": 691071, "url": "http://patchwork.ozlabs.org/api/patches/691071/?format=api", "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/patch/20161103230941.27152-1-jacob.e.keller@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": "<20161103230941.27152-1-jacob.e.keller@intel.com>", "list_archive_url": null, "date": "2016-11-03T23:09:41", "name": "fm10k: Limit dma sync of RX buffers to actual packet size", "commit_ref": null, "pull_url": null, "state": "accepted", "archived": false, "hash": "038ecdc26263027f91c35f321dc6db33fe61f3b5", "submitter": { "id": 9784, "url": "http://patchwork.ozlabs.org/api/people/9784/?format=api", "name": "Jacob Keller", "email": "jacob.e.keller@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/20161103230941.27152-1-jacob.e.keller@intel.com/mbox/", "series": [], "comments": "http://patchwork.ozlabs.org/api/patches/691071/comments/", "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/691071/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 hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133])\n\t(using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits))\n\t(No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPS id 3t90zb4200z9t2N\n\tfor <incoming@patchwork.ozlabs.org>;\n\tFri, 4 Nov 2016 10:09:47 +1100 (AEDT)", "from localhost (localhost [127.0.0.1])\n\tby hemlock.osuosl.org (Postfix) with ESMTP id BFB3095CB7;\n\tThu, 3 Nov 2016 23:09:45 +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 TbaTxvPBX42z; Thu, 3 Nov 2016 23:09:45 +0000 (UTC)", "from ash.osuosl.org (ash.osuosl.org [140.211.166.34])\n\tby hemlock.osuosl.org (Postfix) with ESMTP id 5EBFF95A62;\n\tThu, 3 Nov 2016 23:09:45 +0000 (UTC)", "from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133])\n\tby ash.osuosl.org (Postfix) with ESMTP id 5AB2E1C2278\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tThu, 3 Nov 2016 23:09:44 +0000 (UTC)", "from localhost (localhost [127.0.0.1])\n\tby hemlock.osuosl.org (Postfix) with ESMTP id 55C2495B9A\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tThu, 3 Nov 2016 23:09:44 +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 MXlzKMMVQmKt for <intel-wired-lan@lists.osuosl.org>;\n\tThu, 3 Nov 2016 23:09:43 +0000 (UTC)", "from mga01.intel.com (mga01.intel.com [192.55.52.88])\n\tby hemlock.osuosl.org (Postfix) with ESMTPS id 2A110953A6\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tThu, 3 Nov 2016 23:09:43 +0000 (UTC)", "from fmsmga001.fm.intel.com ([10.253.24.23])\n\tby fmsmga101.fm.intel.com with ESMTP; 03 Nov 2016 16:09:43 -0700", "from jekeller-desk.amr.corp.intel.com (HELO\n\tjekeller-desk.jekeller.internal) ([134.134.3.116])\n\tby fmsmga001.fm.intel.com with ESMTP; 03 Nov 2016 16:09:42 -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.31,440,1473145200\"; d=\"scan'208\";\n\ta=\"1063657021\"", "From": "Jacob Keller <jacob.e.keller@intel.com>", "To": "Intel Wired LAN <intel-wired-lan@lists.osuosl.org>", "Date": "Thu, 3 Nov 2016 16:09:41 -0700", "Message-Id": "<20161103230941.27152-1-jacob.e.keller@intel.com>", "X-Mailer": "git-send-email 2.10.1.777.gd068e6b", "Subject": "[Intel-wired-lan] [PATCH] fm10k: Limit dma sync of RX buffers to\n\tactual packet size", "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": "From: \"Peterson, Scott D\" <scott.d.peterson@intel.com>\n\nOn packet RX, we perform a dma sync for cpu before passing the\npacket up. Here we limit that sync to the actual length of the\nincoming packet, rather than always syncing the entire buffer.\n\nTesting Hints:\nVerify traffic is still passed correctly with the same or better\nperformance as before this patch\n\nSigned-off-by: Scott Peterson <scott.d.peterson@intel.com>\nSigned-off-by: Jacob Keller <jacob.e.keller@intel.com>\n---\n drivers/net/ethernet/intel/fm10k/fm10k_main.c | 8 +++++---\n 1 file changed, 5 insertions(+), 3 deletions(-)", "diff": "diff --git a/drivers/net/ethernet/intel/fm10k/fm10k_main.c b/drivers/net/ethernet/intel/fm10k/fm10k_main.c\nindex 509514d3ce6c..8f90c6db53ff 100644\n--- a/drivers/net/ethernet/intel/fm10k/fm10k_main.c\n+++ b/drivers/net/ethernet/intel/fm10k/fm10k_main.c\n@@ -251,6 +251,7 @@ static bool fm10k_can_reuse_rx_page(struct fm10k_rx_buffer *rx_buffer,\n /**\n * fm10k_add_rx_frag - Add contents of Rx buffer to sk_buff\n * @rx_buffer: buffer containing page to add\n+ * @size: packet size from rx_desc\n * @rx_desc: descriptor containing length of buffer written by hardware\n * @skb: sk_buff to place the data into\n *\n@@ -263,12 +264,12 @@ static bool fm10k_can_reuse_rx_page(struct fm10k_rx_buffer *rx_buffer,\n * true if the buffer can be reused by the interface.\n **/\n static bool fm10k_add_rx_frag(struct fm10k_rx_buffer *rx_buffer,\n+\t\t\t unsigned int size,\n \t\t\t union fm10k_rx_desc *rx_desc,\n \t\t\t struct sk_buff *skb)\n {\n \tstruct page *page = rx_buffer->page;\n \tunsigned char *va = page_address(page) + rx_buffer->page_offset;\n-\tunsigned int size = le16_to_cpu(rx_desc->w.length);\n #if (PAGE_SIZE < 8192)\n \tunsigned int truesize = FM10K_RX_BUFSZ;\n #else\n@@ -314,6 +315,7 @@ static struct sk_buff *fm10k_fetch_rx_buffer(struct fm10k_ring *rx_ring,\n \t\t\t\t\t union fm10k_rx_desc *rx_desc,\n \t\t\t\t\t struct sk_buff *skb)\n {\n+\tunsigned int size = le16_to_cpu(rx_desc->w.length);\n \tstruct fm10k_rx_buffer *rx_buffer;\n \tstruct page *page;\n \n@@ -350,11 +352,11 @@ static struct sk_buff *fm10k_fetch_rx_buffer(struct fm10k_ring *rx_ring,\n \tdma_sync_single_range_for_cpu(rx_ring->dev,\n \t\t\t\t rx_buffer->dma,\n \t\t\t\t rx_buffer->page_offset,\n-\t\t\t\t FM10K_RX_BUFSZ,\n+\t\t\t\t size,\n \t\t\t\t DMA_FROM_DEVICE);\n \n \t/* pull page into skb */\n-\tif (fm10k_add_rx_frag(rx_buffer, rx_desc, skb)) {\n+\tif (fm10k_add_rx_frag(rx_buffer, size, rx_desc, skb)) {\n \t\t/* hand second half of page back to the ring */\n \t\tfm10k_reuse_rx_page(rx_ring, rx_buffer);\n \t} else {\n", "prefixes": [] }