Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/55480/?format=api
http://patches.dpdk.org/api/patches/55480/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/patch/1561635235-22238-6-git-send-email-david.marchand@redhat.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": "<1561635235-22238-6-git-send-email-david.marchand@redhat.com>", "list_archive_url": "https://inbox.dpdk.org/dev/1561635235-22238-6-git-send-email-david.marchand@redhat.com", "date": "2019-06-27T11:33:51", "name": "[5/9] buildtools: detect discrepancies for experimental symbols", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": true, "hash": "ec58bc19a82dc69f2db5908337914f6d76d99137", "submitter": { "id": 1173, "url": "http://patches.dpdk.org/api/people/1173/?format=api", "name": "David Marchand", "email": "david.marchand@redhat.com" }, "delegate": { "id": 1, "url": "http://patches.dpdk.org/api/users/1/?format=api", "username": "tmonjalo", "first_name": "Thomas", "last_name": "Monjalon", "email": "thomas@monjalon.net" }, "mbox": "http://patches.dpdk.org/project/dpdk/patch/1561635235-22238-6-git-send-email-david.marchand@redhat.com/mbox/", "series": [ { "id": 5197, "url": "http://patches.dpdk.org/api/series/5197/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=5197", "date": "2019-06-27T11:33:47", "name": "experimental tags fixes", "version": 1, "mbox": "http://patches.dpdk.org/series/5197/mbox/" } ], "comments": "http://patches.dpdk.org/api/patches/55480/comments/", "check": "success", "checks": "http://patches.dpdk.org/api/patches/55480/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 [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id 4B8DA44C3;\n\tThu, 27 Jun 2019 13:34:37 +0200 (CEST)", "from mx1.redhat.com (mx1.redhat.com [209.132.183.28])\n\tby dpdk.org (Postfix) with ESMTP id F266D4C93\n\tfor <dev@dpdk.org>; Thu, 27 Jun 2019 13:34:32 +0200 (CEST)", "from smtp.corp.redhat.com\n\t(int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23])\n\t(using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits))\n\t(No client certificate requested)\n\tby mx1.redhat.com (Postfix) with ESMTPS id 4F3FB87620;\n\tThu, 27 Jun 2019 11:34:30 +0000 (UTC)", "from dmarchan.remote.csb (ovpn-204-76.brq.redhat.com\n\t[10.40.204.76])\n\tby smtp.corp.redhat.com (Postfix) with ESMTP id 0D6761974B;\n\tThu, 27 Jun 2019 11:34:28 +0000 (UTC)" ], "From": "David Marchand <david.marchand@redhat.com>", "To": "dev@dpdk.org", "Cc": "nhorman@tuxdriver.com,\n\taconole@redhat.com,\n\tthomas@monjalon.net", "Date": "Thu, 27 Jun 2019 13:33:51 +0200", "Message-Id": "<1561635235-22238-6-git-send-email-david.marchand@redhat.com>", "In-Reply-To": "<1561635235-22238-1-git-send-email-david.marchand@redhat.com>", "References": "<1561635235-22238-1-git-send-email-david.marchand@redhat.com>", "X-Scanned-By": "MIMEDefang 2.84 on 10.5.11.23", "X-Greylist": "Sender IP whitelisted, not delayed by milter-greylist-4.5.16\n\t(mx1.redhat.com [10.5.110.26]); Thu, 27 Jun 2019 11:34:32 +0000 (UTC)", "Subject": "[dpdk-dev] [PATCH 5/9] buildtools: detect discrepancies for\n\texperimental symbols", "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\t<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\t<mailto:dev-request@dpdk.org?subject=subscribe>", "Errors-To": "dev-bounces@dpdk.org", "Sender": "\"dev\" <dev-bounces@dpdk.org>" }, "content": "When promoting those symbols as stable, there is no check to ensure that\nthe final result is consistent.\n\nAdd a little script to get the symbols per section from the library map\nfiles.\nValidate that all experimental symbols in object files are referenced by\nlibrary map files.\n\nSigned-off-by: David Marchand <david.marchand@redhat.com>\n---\n buildtools/check-experimental-syms.sh | 29 +++++++++++----\n buildtools/map-list-symbol.sh | 70 +++++++++++++++++++++++++++++++++++\n 2 files changed, 92 insertions(+), 7 deletions(-)\n create mode 100755 buildtools/map-list-symbol.sh", "diff": "diff --git a/buildtools/check-experimental-syms.sh b/buildtools/check-experimental-syms.sh\nindex 7d1f3a5..653756e 100755\n--- a/buildtools/check-experimental-syms.sh\n+++ b/buildtools/check-experimental-syms.sh\n@@ -5,6 +5,8 @@\n MAPFILE=$1\n OBJFILE=$2\n \n+LIST_SYMBOL=$RTE_SDK/buildtools/map-list-symbol.sh\n+\n # added check for \"make -C test/\" usage\n if [ ! -e $MAPFILE ] || [ ! -f $OBJFILE ]\n then\n@@ -16,12 +18,9 @@ then\n \texit 0\n fi\n \n-for i in `awk 'BEGIN {found=0}\n-\t\t/.*EXPERIMENTAL.*/ {found=1}\n-\t\t/.*}.*;/ {found=0}\n-\t\t/.*;/ {if (found == 1) print $1}' $MAPFILE`\n+ret=0\n+for SYM in `$LIST_SYMBOL -S EXPERIMENTAL $MAPFILE`\n do\n-\tSYM=`echo $i | sed -e\"s/;//\"`\n \tobjdump -t $OBJFILE | grep -q \"\\.text.*$SYM$\"\n \tIN_TEXT=$?\n \tobjdump -t $OBJFILE | grep -q \"\\.text\\.experimental.*$SYM$\"\n@@ -33,8 +32,24 @@ do\n \t\tbut is listed in version map\n \t\tPlease add __rte_experimental to the definition of $SYM\n \t\tEND_OF_MESSAGE\n-\t\texit 1\n+\t\tret=1\n \tfi\n done\n-exit 0\n \n+for SYM in `objdump -t $OBJFILE |awk '{\n+\tif ($2 != \"l\" && $4 == \".text.experimental\") {\n+\t\tprint $NF\n+\t}\n+}'`\n+do\n+\t$LIST_SYMBOL -S EXPERIMENTAL -s $SYM -q $MAPFILE || {\n+\t\tcat >&2 <<- END_OF_MESSAGE\n+\t\t$SYM is flagged as experimental\n+\t\tbut is not listed in version map\n+\t\tPlease add $SYM to the version map\n+\t\tEND_OF_MESSAGE\n+\t\tret=1\n+\t}\n+done\n+\n+exit $ret\ndiff --git a/buildtools/map-list-symbol.sh b/buildtools/map-list-symbol.sh\nnew file mode 100755\nindex 0000000..5509b4a\n--- /dev/null\n+++ b/buildtools/map-list-symbol.sh\n@@ -0,0 +1,70 @@\n+#!/bin/sh\n+# SPDX-License-Identifier: BSD-3-Clause\n+# Copyright(c) 2018 David Marchand <david.marchand@redhat.com>\n+\n+section=all\n+symbol=all\n+quiet=\n+\n+while getopts 'S:s:q' name; do\n+\tcase $name in\n+\tS)\n+\t\t[ $section = 'all' ] || {\n+\t\t\techo 'Cannot list in multiple sections'\n+\t\t\texit 1\n+\t\t}\n+\t\tsection=$OPTARG\n+\t;;\n+\ts)\n+\t\t[ $symbol = 'all' ] || {\n+\t\t\techo 'Cannot list multiple symbols'\n+\t\t\texit 1\n+\t\t}\n+\t\tsymbol=$OPTARG\n+\t;;\n+\tq)\n+\t\tquiet='y'\n+\t;;\n+\t?)\n+\t\techo 'usage: $0 [-S section] [-s symbol] [-q]'\n+\t\texit 1\n+\t;;\n+\tesac\n+done\n+\n+shift $(($OPTIND - 1))\n+\n+for file in $@; do\n+\tcat \"$file\" |awk '\n+\tBEGIN {\n+\t\tcurrent_section = \"\";\n+\t\tif (\"'$section'\" == \"all\" && \"'$symbol'\" == \"all\") {\n+\t\t\tret = 0;\n+\t\t} else {\n+\t\t\tret = 1;\n+\t\t}\n+\t}\n+\t/^.*{/ {\n+\t\tif (\"'$section'\" == \"all\" || $1 == \"'$section'\") {\n+\t\t\tcurrent_section = $1;\n+\t\t}\n+\t}\n+\t/.*}/ { current_section = \"\"; }\n+\t/^[^}].*[^:*];/ {\n+\t\tif (current_section != \"\") {\n+\t\t\tgsub(\";\",\"\");\n+\t\t\tif (\"'$symbol'\" == \"all\" || $1 == \"'$symbol'\") {\n+\t\t\t\tret = 0;\n+\t\t\t\tif (\"'$quiet'\" == \"\") {\n+\t\t\t\t\tprint \"'$file' \"current_section\" \"$1;\n+\t\t\t\t}\n+\t\t\t\tif (\"'$symbol'\" != \"all\") {\n+\t\t\t\t\texit 0;\n+\t\t\t\t}\n+\t\t\t}\n+\t\t}\n+\t}\n+\tEND {\n+\t\texit ret;\n+\t}'\n+done\n", "prefixes": [ "5/9" ] }{ "id": 55480, "url": "