get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 726,
    "url": "http://patches.dpdk.org/api/patches/726/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/1412757811-10625-1-git-send-email-david.marchand@6wind.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": "<1412757811-10625-1-git-send-email-david.marchand@6wind.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/1412757811-10625-1-git-send-email-david.marchand@6wind.com",
    "date": "2014-10-08T08:43:31",
    "name": "[dpdk-dev] eal/bsd: fix core detection",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "1483c728d08f4f81085bae6088e3d4236a9eb42f",
    "submitter": {
        "id": 3,
        "url": "http://patches.dpdk.org/api/people/3/?format=api",
        "name": "David Marchand",
        "email": "david.marchand@6wind.com"
    },
    "delegate": null,
    "mbox": "http://patches.dpdk.org/project/dpdk/patch/1412757811-10625-1-git-send-email-david.marchand@6wind.com/mbox/",
    "series": [],
    "comments": "http://patches.dpdk.org/api/patches/726/comments/",
    "check": "pending",
    "checks": "http://patches.dpdk.org/api/patches/726/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 8BB9168B8;\n\tWed,  8 Oct 2014 10:36:25 +0200 (CEST)",
            "from mail-wi0-f169.google.com (mail-wi0-f169.google.com\n\t[209.85.212.169]) by dpdk.org (Postfix) with ESMTP id 122F75918\n\tfor <dev@dpdk.org>; Wed,  8 Oct 2014 10:36:22 +0200 (CEST)",
            "by mail-wi0-f169.google.com with SMTP id cc10so11691706wib.0\n\tfor <dev@dpdk.org>; Wed, 08 Oct 2014 01:43:38 -0700 (PDT)",
            "from alcyon.dev.6wind.com (guy78-3-82-239-227-177.fbx.proxad.net.\n\t[82.239.227.177]) by mx.google.com with ESMTPSA id\n\tlu10sm10885233wjb.13.2014.10.08.01.43.37 for <multiple recipients>\n\t(version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);\n\tWed, 08 Oct 2014 01:43:37 -0700 (PDT)"
        ],
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20130820;\n\th=x-gm-message-state:from:to:cc:subject:date:message-id;\n\tbh=YzLXAW34Cd2OWOgL3fBonNV3VC5+lwLzE0/ZgnI9ui0=;\n\tb=l9Yk0BHa6bMAW+JRwTLH3bLHLTQVRzrE/QmOLugBM+4EBV51DZIfWSmaA/h1w7Kguv\n\tYD3OH7Jmqv4Hi1z6Ct7Cm+MTK9WnVrZDPXvJp3kJn05A+u8xUddYV1TIygs0sJ7I30X5\n\txIiO/spsMex4giFKbCATcna7PgCVTNPdXFlsJRhWoYpv8cs5P8Etj/BMv7ur9yGvDZq6\n\tADWTJmQKOyYyTrZ9l23stsxiQbahy3vComcZCZz/Ton0Qfw4dJr3VV0N2reuUXw1jNxb\n\tcwn4xRcSUmP8kSX8XyrpfiHVW+7t9sgUCw/grfVNIolB62UKCxZYpbzz13xVb1NbsH7A\n\t2SLQ==",
        "X-Gm-Message-State": "ALoCoQngPcZtIxs1dQ2VVMUs33Wp7Y+rqIoMjuo4VeaVPnh/6VBUqlIiA/I0OUvhbwII8ChF/sBD",
        "X-Received": "by 10.194.143.69 with SMTP id sc5mr10478306wjb.49.1412757818310; \n\tWed, 08 Oct 2014 01:43:38 -0700 (PDT)",
        "From": "David Marchand <david.marchand@6wind.com>",
        "To": "dev@dpdk.org",
        "Date": "Wed,  8 Oct 2014 10:43:31 +0200",
        "Message-Id": "<1412757811-10625-1-git-send-email-david.marchand@6wind.com>",
        "X-Mailer": "git-send-email 1.7.10.4",
        "Subject": "[dpdk-dev] [PATCH] eal/bsd: fix core detection",
        "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": "Following \"options parsing\" patchset (commit d7cb626f and 489a9d6c), core\ndetection is not working correctly on bsd.\n\n./x86_64-native-bsdapp-gcc/app/test -c f -n 4 -- -i\n[...]\nEAL: lcore 0 unavailable\nEAL: invalid coremask\n\nAlign bsd to linux:\n- commit f563a372 \"eal: fix recording of detected/enabled logical cores\"\n- commit 4f04db8b \"eal: check coremask against detected lcores\"\n\nReported-by: Zhan, Zhaochen <zhaochen.zhan@intel.com>\nSigned-off-by: David Marchand <david.marchand@6wind.com>\n---\n lib/librte_eal/bsdapp/eal/eal.c       |    6 +++---\n lib/librte_eal/bsdapp/eal/eal_lcore.c |   15 +++++++++------\n 2 files changed, 12 insertions(+), 9 deletions(-)",
    "diff": "diff --git a/lib/librte_eal/bsdapp/eal/eal.c b/lib/librte_eal/bsdapp/eal/eal.c\nindex c40a59a..ca99cb9 100644\n--- a/lib/librte_eal/bsdapp/eal/eal.c\n+++ b/lib/librte_eal/bsdapp/eal/eal.c\n@@ -517,6 +517,9 @@ rte_eal_init(int argc, char **argv)\n \tif (rte_eal_log_early_init() < 0)\n \t\trte_panic(\"Cannot init early logs\\n\");\n \n+\tif (rte_eal_cpu_init() < 0)\n+\t\trte_panic(\"Cannot detect lcores\\n\");\n+\n \tfctret = eal_parse_args(argc, argv);\n \tif (fctret < 0)\n \t\texit(1);\n@@ -551,9 +554,6 @@ rte_eal_init(int argc, char **argv)\n \n \trte_config_init();\n \n-\tif (rte_eal_cpu_init() < 0)\n-\t\trte_panic(\"Cannot detect lcores\\n\");\n-\n \tif (rte_eal_memory_init() < 0)\n \t\trte_panic(\"Cannot init memory\\n\");\n \ndiff --git a/lib/librte_eal/bsdapp/eal/eal_lcore.c b/lib/librte_eal/bsdapp/eal/eal_lcore.c\nindex 43a5c01..5b52eba 100644\n--- a/lib/librte_eal/bsdapp/eal/eal_lcore.c\n+++ b/lib/librte_eal/bsdapp/eal/eal_lcore.c\n@@ -71,16 +71,18 @@ rte_eal_cpu_init(void)\n \tunsigned count = 0;\n \n \tconst unsigned ncpus = get_ncpus();\n-\n-\t/* disable lcores that were not detected */\n-\tRTE_LCORE_FOREACH(lcore_id) {\n-\n+\t/*\n+\t * Parse the maximum set of logical cores, detect the subset of running\n+\t * ones and enable them by default.\n+\t */\n+\tfor (lcore_id = 0; lcore_id < RTE_MAX_LCORE; lcore_id++) {\n \t\tlcore_config[lcore_id].detected = (lcore_id < ncpus);\n \t\tif (lcore_config[lcore_id].detected == 0) {\n \t\t\tconfig->lcore_role[lcore_id] = ROLE_OFF;\n \t\t\tcontinue;\n \t\t}\n-\t\tcount++;\n+\t\t/* By default, each detected core is enabled */\n+\t\tconfig->lcore_role[lcore_id] = ROLE_RTE;\n \t\tlcore_config[lcore_id].core_id = cpu_core_id(lcore_id);\n \t\tlcore_config[lcore_id].socket_id = cpu_socket_id(lcore_id);\n \t\tif (lcore_config[lcore_id].socket_id >= RTE_MAX_NUMA_NODES)\n@@ -93,8 +95,9 @@ rte_eal_cpu_init(void)\n #endif\n \t\tRTE_LOG(DEBUG, EAL, \"Detected lcore %u\\n\",\n \t\t\t\tlcore_id);\n+\t\tcount ++;\n \t}\n-\n+\t/* Set the count of enabled logical cores of the EAL configuration */\n \tconfig->lcore_count = count;\n \tRTE_LOG(DEBUG, EAL, \"Support maximum %u logical core(s) by configuration.\\n\",\n \t\tRTE_MAX_LCORE);\n",
    "prefixes": [
        "dpdk-dev"
    ]
}