get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 71726,
    "url": "http://patchwork.dpdk.org/api/patches/71726/?format=api",
    "web_url": "http://patchwork.dpdk.org/project/dpdk/patch/20200618135049.489773-3-bruce.richardson@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": "<20200618135049.489773-3-bruce.richardson@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20200618135049.489773-3-bruce.richardson@intel.com",
    "date": "2020-06-18T13:50:47",
    "name": "[2/4] eal: only load shared libs from driver plugin directory",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "a28c1a110f1488a83566ba8943c8a55d71f6d18b",
    "submitter": {
        "id": 20,
        "url": "http://patchwork.dpdk.org/api/people/20/?format=api",
        "name": "Bruce Richardson",
        "email": "bruce.richardson@intel.com"
    },
    "delegate": null,
    "mbox": "http://patchwork.dpdk.org/project/dpdk/patch/20200618135049.489773-3-bruce.richardson@intel.com/mbox/",
    "series": [
        {
            "id": 10501,
            "url": "http://patchwork.dpdk.org/api/series/10501/?format=api",
            "web_url": "http://patchwork.dpdk.org/project/dpdk/list/?series=10501",
            "date": "2020-06-18T13:50:45",
            "name": "improve runtime loading of shared drivers",
            "version": 1,
            "mbox": "http://patchwork.dpdk.org/series/10501/mbox/"
        }
    ],
    "comments": "http://patchwork.dpdk.org/api/patches/71726/comments/",
    "check": "fail",
    "checks": "http://patchwork.dpdk.org/api/patches/71726/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<dev-bounces@dpdk.org>",
        "X-Original-To": "patchwork@inbox.dpdk.org",
        "Delivered-To": "patchwork@inbox.dpdk.org",
        "Received": [
            "from dpdk.org (dpdk.org [92.243.14.124])\n\tby inbox.dpdk.org (Postfix) with ESMTP id A9721A04A5;\n\tThu, 18 Jun 2020 15:51:20 +0200 (CEST)",
            "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id 46CB11BF5F;\n\tThu, 18 Jun 2020 15:51:08 +0200 (CEST)",
            "from mga06.intel.com (mga06.intel.com [134.134.136.31])\n by dpdk.org (Postfix) with ESMTP id 492131BF5B\n for <dev@dpdk.org>; Thu, 18 Jun 2020 15:51:07 +0200 (CEST)",
            "from fmsmga006.fm.intel.com ([10.253.24.20])\n by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 18 Jun 2020 06:51:06 -0700",
            "from silpixa00399126.ir.intel.com ([10.237.222.84])\n by fmsmga006.fm.intel.com with ESMTP; 18 Jun 2020 06:51:05 -0700"
        ],
        "IronPort-SDR": [
            "\n kp7Of3MHoiEqXEcVRzJ33GnIMe+S140QfGNWrOkirQ67a0PEZCkB5PFKsYFbHTSMq76tHR/B3F\n Gu9p99NvlAXQ==",
            "\n wH6MZE5fWatvSI9ZtMOxuivBVFLimsAIHPRIlzQUG0g0UEc399VuU9Xjui40lF+i9S1E9lupGs\n qlKWWcUQh2TA=="
        ],
        "X-IronPort-AV": [
            "E=McAfee;i=\"6000,8403,9655\"; a=\"204065794\"",
            "E=Sophos;i=\"5.73,526,1583222400\"; d=\"scan'208\";a=\"204065794\"",
            "E=Sophos;i=\"5.73,526,1583222400\"; d=\"scan'208\";a=\"477200701\""
        ],
        "X-Amp-Result": "SKIPPED(no attachment in message)",
        "X-Amp-File-Uploaded": "False",
        "X-ExtLoop1": "1",
        "From": "Bruce Richardson <bruce.richardson@intel.com>",
        "To": "dev@dpdk.org",
        "Cc": "thomas@monjalon.net, david.marchand@redhat.com,\n Bruce Richardson <bruce.richardson@intel.com>",
        "Date": "Thu, 18 Jun 2020 14:50:47 +0100",
        "Message-Id": "<20200618135049.489773-3-bruce.richardson@intel.com>",
        "X-Mailer": "git-send-email 2.25.1",
        "In-Reply-To": "<20200618135049.489773-1-bruce.richardson@intel.com>",
        "References": "<20200618135049.489773-1-bruce.richardson@intel.com>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Subject": "[dpdk-dev] [PATCH 2/4] eal: only load shared libs from driver\n\tplugin directory",
        "X-BeenThere": "dev@dpdk.org",
        "X-Mailman-Version": "2.1.15",
        "Precedence": "list",
        "List-Id": "DPDK patches and discussions <dev.dpdk.org>",
        "List-Unsubscribe": "<https://mails.dpdk.org/options/dev>,\n <mailto:dev-request@dpdk.org?subject=unsubscribe>",
        "List-Archive": "<http://mails.dpdk.org/archives/dev/>",
        "List-Post": "<mailto:dev@dpdk.org>",
        "List-Help": "<mailto:dev-request@dpdk.org?subject=help>",
        "List-Subscribe": "<https://mails.dpdk.org/listinfo/dev>,\n <mailto:dev-request@dpdk.org?subject=subscribe>",
        "Errors-To": "dev-bounces@dpdk.org",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>"
    },
    "content": "When we pass a \"-d\" flag to EAL pointing to a directory, we attempt to load\nall files in that directory as driver plugins, irrespective of file type.\nThis procludes using e.g. the build/drivers directory, as a driver source\nsince it contains static libs and other files as well as the shared\nobjects.\n\nBy filtering out any files whose filename does not end in \".so\", we can\nimprove usability by allowing other non-driver files to be present in the\ndriver directory.\n\nSigned-off-by: Bruce Richardson <bruce.richardson@intel.com>\n---\n lib/librte_eal/common/eal_common_options.c | 6 ++++++\n 1 file changed, 6 insertions(+)",
    "diff": "diff --git a/lib/librte_eal/common/eal_common_options.c b/lib/librte_eal/common/eal_common_options.c\nindex 6fbe9b5db..7aef6df4c 100644\n--- a/lib/librte_eal/common/eal_common_options.c\n+++ b/lib/librte_eal/common/eal_common_options.c\n@@ -347,9 +347,15 @@ eal_plugindir_init(const char *path)\n \n \twhile ((dent = readdir(d)) != NULL) {\n \t\tstruct stat sb;\n+\t\tint nlen = strnlen(dent->d_name, sizeof(dent->d_name));\n+\n+\t\t/* check if name ends in .so */\n+\t\tif (strcmp(&dent->d_name[nlen - 3], \".so\") != 0)\n+\t\t\tcontinue;\n \n \t\tsnprintf(sopath, sizeof(sopath), \"%s/%s\", path, dent->d_name);\n \n+\t\t/* if a regular file, add to list to load */\n \t\tif (!(stat(sopath, &sb) == 0 && S_ISREG(sb.st_mode)))\n \t\t\tcontinue;\n \n",
    "prefixes": [
        "2/4"
    ]
}