get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 3772,
    "url": "http://patches.dpdk.org/api/patches/3772/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/1425040393-31201-1-git-send-email-nhorman@tuxdriver.com/",
    "project": {
        "id": 1,
        "url": "http://patches.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": "<1425040393-31201-1-git-send-email-nhorman@tuxdriver.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/1425040393-31201-1-git-send-email-nhorman@tuxdriver.com",
    "date": "2015-02-27T12:33:13",
    "name": "[dpdk-dev,v3] eal: Clean up export of per_lcore__socket_id",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "e08840cac0977ab985712b762610a70749589147",
    "submitter": {
        "id": 32,
        "url": "http://patches.dpdk.org/api/people/32/?format=api",
        "name": "Neil Horman",
        "email": "nhorman@tuxdriver.com"
    },
    "delegate": null,
    "mbox": "http://patches.dpdk.org/project/dpdk/patch/1425040393-31201-1-git-send-email-nhorman@tuxdriver.com/mbox/",
    "series": [],
    "comments": "http://patches.dpdk.org/api/patches/3772/comments/",
    "check": "pending",
    "checks": "http://patches.dpdk.org/api/patches/3772/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 15DE0376E;\n\tFri, 27 Feb 2015 13:33:27 +0100 (CET)",
            "from smtp.tuxdriver.com (charlotte.tuxdriver.com [70.61.120.58])\n\tby dpdk.org (Postfix) with ESMTP id B246E3208\n\tfor <dev@dpdk.org>; Fri, 27 Feb 2015 13:33:25 +0100 (CET)",
            "from hmsreliant.think-freely.org\n\t([2001:470:8:a08:7aac:c0ff:fec2:933b] helo=localhost)\n\tby smtp.tuxdriver.com with esmtpsa (TLSv1:AES128-SHA:128) (Exim 4.63)\n\t(envelope-from <nhorman@tuxdriver.com>)\n\tid 1YRK6Y-0007AA-Ss; Fri, 27 Feb 2015 07:33:24 -0500"
        ],
        "From": "Neil Horman <nhorman@tuxdriver.com>",
        "To": "dev@dpdk.org",
        "Date": "Fri, 27 Feb 2015 07:33:13 -0500",
        "Message-Id": "<1425040393-31201-1-git-send-email-nhorman@tuxdriver.com>",
        "X-Mailer": "git-send-email 2.1.0",
        "In-Reply-To": "<1424874849-8973-1-git-send-email-nhorman@tuxdriver.com>",
        "References": "<1424874849-8973-1-git-send-email-nhorman@tuxdriver.com>",
        "X-Spam-Score": "-2.9 (--)",
        "X-Spam-Status": "No",
        "Subject": "[dpdk-dev] [PATCH v3] eal: Clean up export of per_lcore__socket_id",
        "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": "Theres no need to export this variable.  Its set and queried from an API call\nthat doesn't exist in the hot path.  Instead just export the rte_socket_id\nsymbol and make the variable private to protect it from type changes.  We should\ndo this with the other exported variables too, but I think its too late in the\nrelease cycle to do that.\n\ntested using distributor_autotest (which uses rte_socket_id), successfully.\nOnly tested on linux, as I don't currently have a bsd system spun up, but the\nchanges are symmetric, and should be fine\n\nSigned-off-by: Neil Horman <nhorman@tuxdriver.com>\n\n---\nChange Notes:\n\nv2) Moved rte_socket_id to be a common function\n\nv3) replaced some previously removed spaces\n---\n lib/librte_eal/bsdapp/eal/rte_eal_version.map   | 2 +-\n lib/librte_eal/common/eal_common_thread.c       | 7 +++++++\n lib/librte_eal/common/include/rte_lcore.h       | 7 +------\n lib/librte_eal/linuxapp/eal/rte_eal_version.map | 2 +-\n 4 files changed, 10 insertions(+), 8 deletions(-)",
    "diff": "diff --git a/lib/librte_eal/bsdapp/eal/rte_eal_version.map b/lib/librte_eal/bsdapp/eal/rte_eal_version.map\nindex 17515a9..d83524d 100644\n--- a/lib/librte_eal/bsdapp/eal/rte_eal_version.map\n+++ b/lib/librte_eal/bsdapp/eal/rte_eal_version.map\n@@ -10,7 +10,6 @@ DPDK_2.0 {\n \tpci_driver_list;\n \tper_lcore__lcore_id;\n \tper_lcore__rte_errno;\n-\tper_lcore__socket_id;\n \trte_cpu_check_supported;\n \trte_cpu_get_flag_enabled;\n \trte_cycles_vmware_tsc_map;\n@@ -82,6 +81,7 @@ DPDK_2.0 {\n \trte_set_log_level;\n \trte_set_log_type;\n \trte_snprintf;\n+\trte_socket_id;\n \trte_strerror;\n \trte_strsplit;\n \trte_sys_gettid;\ndiff --git a/lib/librte_eal/common/eal_common_thread.c b/lib/librte_eal/common/eal_common_thread.c\nindex f4d9892..2405e93 100644\n--- a/lib/librte_eal/common/eal_common_thread.c\n+++ b/lib/librte_eal/common/eal_common_thread.c\n@@ -46,6 +46,13 @@\n \n #include \"eal_thread.h\"\n \n+RTE_DECLARE_PER_LCORE(unsigned , _socket_id);\n+\n+unsigned rte_socket_id(void)\n+{\n+\treturn RTE_PER_LCORE(_socket_id);\n+}\n+\n int eal_cpuset_socket_id(rte_cpuset_t *cpusetp)\n {\n \tunsigned cpu = 0;\ndiff --git a/lib/librte_eal/common/include/rte_lcore.h b/lib/librte_eal/common/include/rte_lcore.h\nindex 20a58eb..e03264e 100644\n--- a/lib/librte_eal/common/include/rte_lcore.h\n+++ b/lib/librte_eal/common/include/rte_lcore.h\n@@ -81,7 +81,6 @@ struct lcore_config {\n extern struct lcore_config lcore_config[RTE_MAX_LCORE];\n \n RTE_DECLARE_PER_LCORE(unsigned, _lcore_id);  /**< Per thread \"lcore id\". */\n-RTE_DECLARE_PER_LCORE(unsigned, _socket_id); /**< Per thread \"socket id\". */\n RTE_DECLARE_PER_LCORE(rte_cpuset_t, _cpuset); /**< Per thread \"cpuset\". */\n \n /**\n@@ -145,11 +144,7 @@ rte_lcore_index(int lcore_id)\n  * @return\n  *   the ID of current lcoreid's physical socket\n  */\n-static inline unsigned\n-rte_socket_id(void)\n-{\n-\treturn RTE_PER_LCORE(_socket_id);\n-}\n+unsigned rte_socket_id(void);\n \n /**\n  * Get the ID of the physical socket of the specified lcore\ndiff --git a/lib/librte_eal/linuxapp/eal/rte_eal_version.map b/lib/librte_eal/linuxapp/eal/rte_eal_version.map\nindex 17515a9..d83524d 100644\n--- a/lib/librte_eal/linuxapp/eal/rte_eal_version.map\n+++ b/lib/librte_eal/linuxapp/eal/rte_eal_version.map\n@@ -10,7 +10,6 @@ DPDK_2.0 {\n \tpci_driver_list;\n \tper_lcore__lcore_id;\n \tper_lcore__rte_errno;\n-\tper_lcore__socket_id;\n \trte_cpu_check_supported;\n \trte_cpu_get_flag_enabled;\n \trte_cycles_vmware_tsc_map;\n@@ -82,6 +81,7 @@ DPDK_2.0 {\n \trte_set_log_level;\n \trte_set_log_type;\n \trte_snprintf;\n+\trte_socket_id;\n \trte_strerror;\n \trte_strsplit;\n \trte_sys_gettid;\n",
    "prefixes": [
        "dpdk-dev",
        "v3"
    ]
}