get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

GET /api/patches/724775/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 724775,
    "url": "http://patchwork.ozlabs.org/api/patches/724775/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/patch/20170206223846.31052-3-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": "<20170206223846.31052-3-jacob.e.keller@intel.com>",
    "list_archive_url": null,
    "date": "2017-02-06T22:38:39",
    "name": "[PART1,02/11] i40e: don't use arrays for (src|dst)_ip",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": false,
    "hash": "512867cf5ddd8771f9a447a50ed0974993319f02",
    "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/20170206223846.31052-3-jacob.e.keller@intel.com/mbox/",
    "series": [],
    "comments": "http://patchwork.ozlabs.org/api/patches/724775/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/724775/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 silver.osuosl.org (smtp3.osuosl.org [140.211.166.136])\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 3vHMp91f9Rz9s1y\n\tfor <incoming@patchwork.ozlabs.org>;\n\tTue,  7 Feb 2017 09:38:57 +1100 (AEDT)",
            "from localhost (localhost [127.0.0.1])\n\tby silver.osuosl.org (Postfix) with ESMTP id B84F030353;\n\tMon,  6 Feb 2017 22:38:55 +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 qynYdk3PXwn8; Mon,  6 Feb 2017 22:38:51 +0000 (UTC)",
            "from ash.osuosl.org (ash.osuosl.org [140.211.166.34])\n\tby silver.osuosl.org (Postfix) with ESMTP id 952F130A53;\n\tMon,  6 Feb 2017 22:38:51 +0000 (UTC)",
            "from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133])\n\tby ash.osuosl.org (Postfix) with ESMTP id C22BB1BFF07\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tMon,  6 Feb 2017 22:38:49 +0000 (UTC)",
            "from localhost (localhost [127.0.0.1])\n\tby hemlock.osuosl.org (Postfix) with ESMTP id BE7A58A351\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tMon,  6 Feb 2017 22:38:49 +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 38jvaFVZpssr for <intel-wired-lan@lists.osuosl.org>;\n\tMon,  6 Feb 2017 22:38:49 +0000 (UTC)",
            "from mga09.intel.com (mga09.intel.com [134.134.136.24])\n\tby hemlock.osuosl.org (Postfix) with ESMTPS id 084A389F62\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tMon,  6 Feb 2017 22:38:49 +0000 (UTC)",
            "from fmsmga006.fm.intel.com ([10.253.24.20])\n\tby orsmga102.jf.intel.com with ESMTP; 06 Feb 2017 14:38:48 -0800",
            "from jekeller-desk.amr.corp.intel.com (HELO\n\tjekeller-desk.jekeller.internal) ([10.166.35.174])\n\tby fmsmga006.fm.intel.com with ESMTP; 06 Feb 2017 14:38:48 -0800"
        ],
        "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.33,342,1477983600\"; d=\"scan'208\";a=\"62577436\"",
        "From": "Jacob Keller <jacob.e.keller@intel.com>",
        "To": "Intel Wired LAN <intel-wired-lan@lists.osuosl.org>",
        "Date": "Mon,  6 Feb 2017 14:38:39 -0800",
        "Message-Id": "<20170206223846.31052-3-jacob.e.keller@intel.com>",
        "X-Mailer": "git-send-email 2.12.0.rc0.151.g8a5726c42288",
        "In-Reply-To": "<20170206223846.31052-1-jacob.e.keller@intel.com>",
        "References": "<20170206223846.31052-1-jacob.e.keller@intel.com>",
        "Subject": "[Intel-wired-lan] [PART1 PATCH 02/11] i40e: don't use arrays for\n\t(src|dst)_ip",
        "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": "The code originally included src_ip and dst_ip with enough space to\nsupport ipv6 filters. However, no actual support for ipv6 filters has\nbeen implemented. Thus, remove the arrays and just use __be32 values.\nShould ipv6 support be added in the future, we can replace these with\na union that has sizes for both values.\n\nSigned-off-by: Jacob Keller <jacob.e.keller@intel.com>\nChange-Id: I1bc04032244a80eb6ebc8a4e6c723a4a665c1dd5\n---\n drivers/net/ethernet/intel/i40e/i40e.h         |  4 ++--\n drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 12 ++++++------\n drivers/net/ethernet/intel/i40e/i40e_txrx.c    | 12 ++++++------\n 3 files changed, 14 insertions(+), 14 deletions(-)",
    "diff": "diff --git a/drivers/net/ethernet/intel/i40e/i40e.h b/drivers/net/ethernet/intel/i40e/i40e.h\nindex 8bb6c5c88fce..e4ac2b782d80 100644\n--- a/drivers/net/ethernet/intel/i40e/i40e.h\n+++ b/drivers/net/ethernet/intel/i40e/i40e.h\n@@ -212,8 +212,8 @@ struct i40e_fdir_filter {\n \tu8 flow_type;\n \tu8 ip4_proto;\n \t/* TX packet view of src and dst */\n-\t__be32 dst_ip[4];\n-\t__be32 src_ip[4];\n+\t__be32 dst_ip;\n+\t__be32 src_ip;\n \t__be16 src_port;\n \t__be16 dst_port;\n \t__be32 sctp_v_tag;\ndiff --git a/drivers/net/ethernet/intel/i40e/i40e_ethtool.c b/drivers/net/ethernet/intel/i40e/i40e_ethtool.c\nindex 4d08f1997f69..9ba3f18f2e8b 100644\n--- a/drivers/net/ethernet/intel/i40e/i40e_ethtool.c\n+++ b/drivers/net/ethernet/intel/i40e/i40e_ethtool.c\n@@ -2368,8 +2368,8 @@ static int i40e_get_ethtool_fdir_entry(struct i40e_pf *pf,\n \t */\n \tfsp->h_u.tcp_ip4_spec.psrc = rule->dst_port;\n \tfsp->h_u.tcp_ip4_spec.pdst = rule->src_port;\n-\tfsp->h_u.tcp_ip4_spec.ip4src = rule->dst_ip[0];\n-\tfsp->h_u.tcp_ip4_spec.ip4dst = rule->src_ip[0];\n+\tfsp->h_u.tcp_ip4_spec.ip4src = rule->dst_ip;\n+\tfsp->h_u.tcp_ip4_spec.ip4dst = rule->src_ip;\n \n \tif (rule->dest_ctl == I40E_FILTER_PROGRAM_DESC_DEST_DROP_PACKET)\n \t\tfsp->ring_cookie = RX_CLS_FLOW_DISC;\n@@ -2592,8 +2592,8 @@ static int i40e_set_rss_hash_opt(struct i40e_pf *pf, struct ethtool_rxnfc *nfc)\n static bool i40e_match_fdir_input_set(struct i40e_fdir_filter *rule,\n \t\t\t\t      struct i40e_fdir_filter *input)\n {\n-\tif ((rule->dst_ip[0] != input->dst_ip[0]) ||\n-\t    (rule->src_ip[0] != input->src_ip[0]) ||\n+\tif ((rule->dst_ip != input->dst_ip) ||\n+\t    (rule->src_ip != input->src_ip) ||\n \t    (rule->dst_port != input->dst_port) ||\n \t    (rule->src_port != input->src_port))\n \t\treturn false;\n@@ -2769,8 +2769,8 @@ static int i40e_add_fdir_ethtool(struct i40e_vsi *vsi,\n \t */\n \tinput->dst_port = fsp->h_u.tcp_ip4_spec.psrc;\n \tinput->src_port = fsp->h_u.tcp_ip4_spec.pdst;\n-\tinput->dst_ip[0] = fsp->h_u.tcp_ip4_spec.ip4src;\n-\tinput->src_ip[0] = fsp->h_u.tcp_ip4_spec.ip4dst;\n+\tinput->dst_ip = fsp->h_u.tcp_ip4_spec.ip4src;\n+\tinput->src_ip = fsp->h_u.tcp_ip4_spec.ip4dst;\n \n \tif (ntohl(fsp->m_ext.data[1])) {\n \t\tvf_id = ntohl(fsp->h_ext.data[1]);\ndiff --git a/drivers/net/ethernet/intel/i40e/i40e_txrx.c b/drivers/net/ethernet/intel/i40e/i40e_txrx.c\nindex 329c8d8e64b1..3b0c9364763e 100644\n--- a/drivers/net/ethernet/intel/i40e/i40e_txrx.c\n+++ b/drivers/net/ethernet/intel/i40e/i40e_txrx.c\n@@ -220,9 +220,9 @@ static int i40e_add_del_fdir_udpv4(struct i40e_vsi *vsi,\n \tudp = (struct udphdr *)(raw_packet + IP_HEADER_OFFSET\n \t      + sizeof(struct iphdr));\n \n-\tip->daddr = fd_data->dst_ip[0];\n+\tip->daddr = fd_data->dst_ip;\n \tudp->dest = fd_data->dst_port;\n-\tip->saddr = fd_data->src_ip[0];\n+\tip->saddr = fd_data->src_ip;\n \tudp->source = fd_data->src_port;\n \n \tfd_data->pctype = I40E_FILTER_PCTYPE_NONF_IPV4_UDP;\n@@ -282,9 +282,9 @@ static int i40e_add_del_fdir_tcpv4(struct i40e_vsi *vsi,\n \ttcp = (struct tcphdr *)(raw_packet + IP_HEADER_OFFSET\n \t      + sizeof(struct iphdr));\n \n-\tip->daddr = fd_data->dst_ip[0];\n+\tip->daddr = fd_data->dst_ip;\n \ttcp->dest = fd_data->dst_port;\n-\tip->saddr = fd_data->src_ip[0];\n+\tip->saddr = fd_data->src_ip;\n \ttcp->source = fd_data->src_port;\n \n \tif (add) {\n@@ -360,8 +360,8 @@ static int i40e_add_del_fdir_ipv4(struct i40e_vsi *vsi,\n \t\tmemcpy(raw_packet, packet, I40E_IP_DUMMY_PACKET_LEN);\n \t\tip = (struct iphdr *)(raw_packet + IP_HEADER_OFFSET);\n \n-\t\tip->saddr = fd_data->src_ip[0];\n-\t\tip->daddr = fd_data->dst_ip[0];\n+\t\tip->saddr = fd_data->src_ip;\n+\t\tip->daddr = fd_data->dst_ip;\n \t\tip->protocol = 0;\n \n \t\tfd_data->pctype = i;\n",
    "prefixes": [
        "PART1",
        "02/11"
    ]
}