get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 13190,
    "url": "http://patchwork.dpdk.org/api/patches/13190/?format=api",
    "web_url": "http://patchwork.dpdk.org/project/dpdk/patch/1464922755-2888-1-git-send-email-beilei.xing@intel.com/",
    "project": {
        "id": 1,
        "url": "http://patchwork.dpdk.org/api/projects/1/?format=api",
        "name": "DPDK",
        "link_name": "dpdk",
        "list_id": "dev.dpdk.org",
        "list_email": "dev@dpdk.org",
        "web_url": "http://core.dpdk.org",
        "scm_url": "git://dpdk.org/dpdk",
        "webscm_url": "http://git.dpdk.org/dpdk",
        "list_archive_url": "https://inbox.dpdk.org/dev",
        "list_archive_url_format": "https://inbox.dpdk.org/dev/{}",
        "commit_url_format": ""
    },
    "msgid": "<1464922755-2888-1-git-send-email-beilei.xing@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/1464922755-2888-1-git-send-email-beilei.xing@intel.com",
    "date": "2016-06-03T02:59:15",
    "name": "[dpdk-dev,v2] e1000: configure VLAN TPID",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "141f26ccbaf2b484423836c9b6346f48912eeb6e",
    "submitter": {
        "id": 410,
        "url": "http://patchwork.dpdk.org/api/people/410/?format=api",
        "name": "Xing, Beilei",
        "email": "beilei.xing@intel.com"
    },
    "delegate": {
        "id": 10,
        "url": "http://patchwork.dpdk.org/api/users/10/?format=api",
        "username": "bruce",
        "first_name": "Bruce",
        "last_name": "Richardson",
        "email": "bruce.richardson@intel.com"
    },
    "mbox": "http://patchwork.dpdk.org/project/dpdk/patch/1464922755-2888-1-git-send-email-beilei.xing@intel.com/mbox/",
    "series": [],
    "comments": "http://patchwork.dpdk.org/api/patches/13190/comments/",
    "check": "pending",
    "checks": "http://patchwork.dpdk.org/api/patches/13190/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<dev-bounces@dpdk.org>",
        "X-Original-To": "patchwork@dpdk.org",
        "Delivered-To": "patchwork@dpdk.org",
        "Received": [
            "from [92.243.14.124] (localhost [IPv6:::1])\n\tby dpdk.org (Postfix) with ESMTP id 5929A5A9F;\n\tFri,  3 Jun 2016 04:59:25 +0200 (CEST)",
            "from mga02.intel.com (mga02.intel.com [134.134.136.20])\n\tby dpdk.org (Postfix) with ESMTP id 158255A93\n\tfor <dev@dpdk.org>; Fri,  3 Jun 2016 04:59:22 +0200 (CEST)",
            "from fmsmga001.fm.intel.com ([10.253.24.23])\n\tby orsmga101.jf.intel.com with ESMTP; 02 Jun 2016 19:59:22 -0700",
            "from shvmail01.sh.intel.com ([10.239.29.42])\n\tby fmsmga001.fm.intel.com with ESMTP; 02 Jun 2016 19:59:21 -0700",
            "from shecgisg004.sh.intel.com (shecgisg004.sh.intel.com\n\t[10.239.29.89])\n\tby shvmail01.sh.intel.com with ESMTP id u532xJwl028117;\n\tFri, 3 Jun 2016 10:59:19 +0800",
            "from shecgisg004.sh.intel.com (localhost [127.0.0.1])\n\tby shecgisg004.sh.intel.com (8.13.6/8.13.6/SuSE Linux 0.8) with ESMTP\n\tid u532xGlZ002923; Fri, 3 Jun 2016 10:59:18 +0800",
            "(from beileixi@localhost)\n\tby shecgisg004.sh.intel.com (8.13.6/8.13.6/Submit) id u532xGs0002919; \n\tFri, 3 Jun 2016 10:59:16 +0800"
        ],
        "X-ExtLoop1": "1",
        "X-IronPort-AV": "E=Sophos;i=\"5.26,409,1459839600\"; d=\"scan'208\";a=\"979925348\"",
        "From": "Beilei Xing <beilei.xing@intel.com>",
        "To": "wenzhuo.lu@intel.com",
        "Cc": "dev@dpdk.org, Beilei Xing <beilei.xing@intel.com>",
        "Date": "Fri,  3 Jun 2016 10:59:15 +0800",
        "Message-Id": "<1464922755-2888-1-git-send-email-beilei.xing@intel.com>",
        "X-Mailer": "git-send-email 1.7.4.1",
        "In-Reply-To": "<1461228948-18820-1-git-send-email-beilei.xing@intel.com>",
        "References": "<1461228948-18820-1-git-send-email-beilei.xing@intel.com>",
        "Subject": "[dpdk-dev] [PATCH v2] e1000: configure VLAN TPID",
        "X-BeenThere": "dev@dpdk.org",
        "X-Mailman-Version": "2.1.15",
        "Precedence": "list",
        "List-Id": "patches and discussions about DPDK <dev.dpdk.org>",
        "List-Unsubscribe": "<http://dpdk.org/ml/options/dev>,\n\t<mailto:dev-request@dpdk.org?subject=unsubscribe>",
        "List-Archive": "<http://dpdk.org/ml/archives/dev/>",
        "List-Post": "<mailto:dev@dpdk.org>",
        "List-Help": "<mailto:dev-request@dpdk.org?subject=help>",
        "List-Subscribe": "<http://dpdk.org/ml/listinfo/dev>,\n\t<mailto:dev-request@dpdk.org?subject=subscribe>",
        "Errors-To": "dev-bounces@dpdk.org",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>"
    },
    "content": "This patch enables configuring the ether types of both inner and\nouter VLANs. Note that outer TPID of single VLAN and inner TPID of\ndouble VLAN are read only.\n\nSigned-off-by: Beilei Xing <beilei.xing@intel.com>\n---\nv2 changes:\n Modify return value. Cause inner tpid is not supported by single vlan,\n return -ENOTSUP.\n Add return value. If want to set inner TPID of double vlan or set outer\n tpid of single vlan, return -ENOTSUP.\n    \n drivers/net/e1000/igb_ethdev.c | 38 +++++++++++++++++++++++++++++++++++---\n 1 file changed, 35 insertions(+), 3 deletions(-)",
    "diff": "diff --git a/drivers/net/e1000/igb_ethdev.c b/drivers/net/e1000/igb_ethdev.c\nindex f0921ee..5d37e2c 100644\n--- a/drivers/net/e1000/igb_ethdev.c\n+++ b/drivers/net/e1000/igb_ethdev.c\n@@ -86,6 +86,14 @@\n #define E1000_INCVALUE_82576         (16 << IGB_82576_TSYNC_SHIFT)\n #define E1000_TSAUXC_DISABLE_SYSTIME 0x80000000\n \n+/* CTRL_EXT bit mask*/\n+#define E1000_CTRL_EXT_EXT_VLAN      (1 << 26)\n+\n+/* VLAN Ether Type bit mask */\n+#define E1000_VET_VET_EXT            0xFFFF0000\n+\n+#define E1000_VET_VET_EXT_SHIFT      16\n+\n static int  eth_igb_configure(struct rte_eth_dev *dev);\n static int  eth_igb_start(struct rte_eth_dev *dev);\n static void eth_igb_stop(struct rte_eth_dev *dev);\n@@ -2237,13 +2245,37 @@ eth_igb_vlan_tpid_set(struct rte_eth_dev *dev,\n {\n \tstruct e1000_hw *hw =\n \t\tE1000_DEV_PRIVATE_TO_HW(dev->data->dev_private);\n-\tuint32_t reg = ETHER_TYPE_VLAN;\n+\tuint32_t reg;\n+\tuint32_t qinq;\n \tint ret = 0;\n \n+\tqinq = E1000_READ_REG(hw, E1000_CTRL_EXT);\n+\tqinq &= E1000_CTRL_EXT_EXT_VLAN;\n+\n \tswitch (vlan_type) {\n \tcase ETH_VLAN_TYPE_INNER:\n-\t\treg |= (tpid << 16);\n-\t\tE1000_WRITE_REG(hw, E1000_VET, reg);\n+\t\tif (qinq) {\n+\t\t\tret = -ENOTSUP;\n+\t\t\tPMD_DRV_LOG(WARNING,\n+\t\t\t\t    \"Inner vlan ether type is read-only\\n\");\n+\t\t} else {\n+\t\t\tret = -ENOTSUP;\n+\t\t\tPMD_DRV_LOG(ERR, \"Inner type is not supported\"\n+\t\t\t\t    \" by single vlan\\n\");\n+\t\t}\n+\t\tbreak;\n+\tcase ETH_VLAN_TYPE_OUTER:\n+\t\tif (qinq) {\n+\t\t\treg = E1000_READ_REG(hw, E1000_VET);\n+\t\t\treg = (reg & (~E1000_VET_VET_EXT)) |\n+\t\t\t\t((uint32_t)tpid << E1000_VET_VET_EXT_SHIFT);\n+\t\t\tE1000_WRITE_REG(hw, E1000_VET, reg);\n+\t\t} else {\n+\t\t\tret = -ENOTSUP;\n+\t\t\tPMD_DRV_LOG(WARNING,\n+\t\t\t\t    \"Single vlan ether type is read-only\\n\");\n+\t\t}\n+\n \t\tbreak;\n \tdefault:\n \t\tret = -EINVAL;\n",
    "prefixes": [
        "dpdk-dev",
        "v2"
    ]
}