[{"id":1759878,"web_url":"http://patchwork.ozlabs.org/comment/1759878/","msgid":"<e0d6d6ee-95aa-0661-379f-76f0d8f4a9c5@canonical.com>","list_archive_url":null,"date":"2017-08-30T05:38:09","subject":"ACK: [PATCH] acpica: fwts_acpica: fix linker issues on Fedora (LP:\n\t#1712572)","submitter":{"id":10593,"url":"http://patchwork.ozlabs.org/api/people/10593/","name":"Alex Hung","email":"alex.hung@canonical.com"},"content":"On 2017-08-29 08:04 AM, Colin King wrote:\n> From: Colin Ian King <colin.king@canonical.com>\n> \n> When building for ppcC64el on Fedora we get linker issues with\n> undefined symbols. It seems that while this is not an issue on\n> Debian systems, the linker seems to require these sysbols to be\n> defined even if we don't actually use them. Make these functions\n> void no-ops that throw warnings if they are used.  This has been\n> tested on Fedora 25 and also Ubuntu and is able to build and\n> pass the regression tests.\n> \n> Signed-off-by: Colin Ian King <colin.king@canonical.com>\n> ---\n>   src/acpica/fwts_acpica.c | 36 ++++++++++++++++++++++++++++++++++++\n>   1 file changed, 36 insertions(+)\n> \n> diff --git a/src/acpica/fwts_acpica.c b/src/acpica/fwts_acpica.c\n> index b85e18d6..b0cefe73 100644\n> --- a/src/acpica/fwts_acpica.c\n> +++ b/src/acpica/fwts_acpica.c\n> @@ -1326,4 +1326,40 @@ fwts_list *fwts_acpica_get_object_names(int type)\n>   \treturn list;\n>   }\n>   \n> +#else\n> +\n> +static void __void_func(const char *funcname)\n> +{\n> +\tfprintf(stderr, \"fwts ACPICA library: unexpected call to %s()\\n\", funcname);\n> +\texit(EXIT_FAILURE);\n> +}\n> +\n> +#define VOID_FUNC(name) void name(void) { __void_func(#name); }\n> +\n> +/*\n> + *  With ACPI disabled, these functions should never\n> + *  be called. We should defined this otherwise we will\n> + *  get linker errors with some autotools/linker combos\n> + */\n> +VOID_FUNC(AcpiGbl_IgnoreErrors)\n> +VOID_FUNC(AcpiGbl_RegionFillValue)\n> +\n> +VOID_FUNC(AcpiOsCreateSemaphore)\n> +VOID_FUNC(AcpiOsDeleteSemaphore)\n> +VOID_FUNC(AcpiOsExecute)\n> +VOID_FUNC(AcpiOsGetRootPointer)\n> +VOID_FUNC(AcpiOsPrintf)\n> +VOID_FUNC(AcpiOsReadPciConfiguration)\n> +VOID_FUNC(AcpiOsReadPort)\n> +VOID_FUNC(AcpiOsSignal)\n> +VOID_FUNC(AcpiOsSignalSemaphore)\n> +VOID_FUNC(AcpiOsSleep)\n> +VOID_FUNC(AcpiOsVprintf)\n> +VOID_FUNC(AcpiOsWaitSemaphore)\n> +\n> +VOID_FUNC(AeTableOverride)\n> +\n> +VOID_FUNC(MpSaveGpioInfo)\n> +VOID_FUNC(MpSaveSerialInfo)\n> +\n>   #endif\n> \n\nAcked-by: Alex Hung <alex.hung@canonical.com>","headers":{"Return-Path":"<fwts-devel-bounces@lists.ubuntu.com>","X-Original-To":"incoming@patchwork.ozlabs.org","Delivered-To":"patchwork-incoming@bilbo.ozlabs.org","Authentication-Results":"ozlabs.org;\n\tspf=none (mailfrom) smtp.mailfrom=lists.ubuntu.com\n\t(client-ip=91.189.94.19; helo=huckleberry.canonical.com;\n\tenvelope-from=fwts-devel-bounces@lists.ubuntu.com;\n\treceiver=<UNKNOWN>)","Received":["from huckleberry.canonical.com (huckleberry.canonical.com\n\t[91.189.94.19])\n\tby ozlabs.org (Postfix) with ESMTP id 3xhvS63d6Yz9s7c;\n\tWed, 30 Aug 2017 15:38:29 +1000 (AEST)","from localhost ([127.0.0.1] helo=huckleberry.canonical.com)\n\tby huckleberry.canonical.com with esmtp (Exim 4.76)\n\t(envelope-from <fwts-devel-bounces@lists.ubuntu.com>)\n\tid 1dmvhq-0005AX-BM; Wed, 30 Aug 2017 05:38:26 +0000","from youngberry.canonical.com ([91.189.89.112])\n\tby huckleberry.canonical.com with esmtps\n\t(TLS1.0:RSA_AES_256_CBC_SHA1:32)\n\t(Exim 4.76) (envelope-from <alex.hung@canonical.com>)\n\tid 1dmvhk-00059m-2x\n\tfor fwts-devel@lists.ubuntu.com; Wed, 30 Aug 2017 05:38:20 +0000","from mail-pf0-f197.google.com ([209.85.192.197])\n\tby youngberry.canonical.com with esmtps\n\t(TLS1.0:RSA_AES_128_CBC_SHA1:16)\n\t(Exim 4.76) (envelope-from <alex.hung@canonical.com>)\n\tid 1dmvhj-0004KI-MS\n\tfor fwts-devel@lists.ubuntu.com; Wed, 30 Aug 2017 05:38:19 +0000","by mail-pf0-f197.google.com with SMTP id k3so10043160pfc.1\n\tfor <fwts-devel@lists.ubuntu.com>;\n\tTue, 29 Aug 2017 22:38:19 -0700 (PDT)","from [192.168.1.125] ([207.102.104.225])\n\tby smtp.gmail.com with ESMTPSA id\n\tv14sm7587284pgq.89.2017.08.29.22.38.17\n\tfor <fwts-devel@lists.ubuntu.com>\n\t(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);\n\tTue, 29 Aug 2017 22:38:17 -0700 (PDT)"],"X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:subject:to:references:from:message-id:date\n\t:user-agent:mime-version:in-reply-to:content-language\n\t:content-transfer-encoding;\n\tbh=eqlpZg7KhItNSR8V9n08RKkarXevNKk0fpUjgnjO/3Q=;\n\tb=L308bTFT6FDgg3JzMlJe6zriB4azpTwPOBw3o5WMjXnLzL9tZaHH6etfdrb+BhlGIS\n\tAfsTAo/H1l85LxMeyKMDXjHUKdVJpKzAiujW4yIIixwwvBoDi1FHP93KPh+UEuSuVCw3\n\tY0054+69uuLvB8QIOXIpnbJHzh/a6c7lh1hP3wcmUlodQs2xFixnp12nXjyfZ28kQsQI\n\tbyO7Kxjz05jpO+09okIu9PusZwERFrdC0k7Bl+fjHgsMiY2syCXgQD0lt4aCZvrokjcg\n\tYHfe5TkdjXYBtsED7C8KiYmoXmIMEXRk4CfQXsgRDfa6R5BSonF2T5tX85sRNeNWPfze\n\t4w3g==","X-Gm-Message-State":"AHYfb5i3/+NM7cecB9CCywkF2N0yanumnHCkIqVYzhF4qKjVy552y/7f\n\tj97ZLcl/xedzOP24vjmg3bZxX/2UlykVryJwXOI768lj2iFW9KcjXP/kBk9nqgb4hTz/AHrlF6o\n\tHQyFkyuK6JJwvwPYzHiNQbAxSLr1vA6Y=","X-Received":["by 10.84.224.142 with SMTP id s14mr485642plj.323.1504071498208; \n\tTue, 29 Aug 2017 22:38:18 -0700 (PDT)","by 10.84.224.142 with SMTP id s14mr485631plj.323.1504071497948; \n\tTue, 29 Aug 2017 22:38:17 -0700 (PDT)"],"Subject":"ACK: [PATCH] acpica: fwts_acpica: fix linker issues on Fedora (LP:\n\t#1712572)","To":"fwts-devel@lists.ubuntu.com","References":"<20170829150426.5935-1-colin.king@canonical.com>","From":"Alex Hung <alex.hung@canonical.com>","Message-ID":"<e0d6d6ee-95aa-0661-379f-76f0d8f4a9c5@canonical.com>","Date":"Tue, 29 Aug 2017 22:38:09 -0700","User-Agent":"Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101\n\tThunderbird/52.2.1","MIME-Version":"1.0","In-Reply-To":"<20170829150426.5935-1-colin.king@canonical.com>","Content-Language":"en-US","X-BeenThere":"fwts-devel@lists.ubuntu.com","X-Mailman-Version":"2.1.14","Precedence":"list","List-Id":"Firmware Test Suite Development <fwts-devel.lists.ubuntu.com>","List-Unsubscribe":"<https://lists.ubuntu.com/mailman/options/fwts-devel>,\n\t<mailto:fwts-devel-request@lists.ubuntu.com?subject=unsubscribe>","List-Archive":"<https://lists.ubuntu.com/archives/fwts-devel>","List-Post":"<mailto:fwts-devel@lists.ubuntu.com>","List-Help":"<mailto:fwts-devel-request@lists.ubuntu.com?subject=help>","List-Subscribe":"<https://lists.ubuntu.com/mailman/listinfo/fwts-devel>,\n\t<mailto:fwts-devel-request@lists.ubuntu.com?subject=subscribe>","Content-Transfer-Encoding":"7bit","Content-Type":"text/plain; charset=\"us-ascii\"; Format=\"flowed\"","Errors-To":"fwts-devel-bounces@lists.ubuntu.com","Sender":"fwts-devel-bounces@lists.ubuntu.com"}},{"id":1759883,"web_url":"http://patchwork.ozlabs.org/comment/1759883/","msgid":"<07058a3c-bea6-1416-c9f5-c408ccf9700a@canonical.com>","list_archive_url":null,"date":"2017-08-30T05:41:37","subject":"ACK: [PATCH] acpica: fwts_acpica: fix linker issues on Fedora (LP:\n\t#1712572)","submitter":{"id":14061,"url":"http://patchwork.ozlabs.org/api/people/14061/","name":"Ivan Hu","email":"ivan.hu@canonical.com"},"content":"On 08/29/2017 11:04 PM, Colin King wrote:\n> From: Colin Ian King <colin.king@canonical.com>\n> \n> When building for ppcC64el on Fedora we get linker issues with\n> undefined symbols. It seems that while this is not an issue on\n> Debian systems, the linker seems to require these sysbols to be\n> defined even if we don't actually use them. Make these functions\n> void no-ops that throw warnings if they are used.  This has been\n> tested on Fedora 25 and also Ubuntu and is able to build and\n> pass the regression tests.\n> \n> Signed-off-by: Colin Ian King <colin.king@canonical.com>\n> ---\n>   src/acpica/fwts_acpica.c | 36 ++++++++++++++++++++++++++++++++++++\n>   1 file changed, 36 insertions(+)\n> \n> diff --git a/src/acpica/fwts_acpica.c b/src/acpica/fwts_acpica.c\n> index b85e18d6..b0cefe73 100644\n> --- a/src/acpica/fwts_acpica.c\n> +++ b/src/acpica/fwts_acpica.c\n> @@ -1326,4 +1326,40 @@ fwts_list *fwts_acpica_get_object_names(int type)\n>   \treturn list;\n>   }\n>   \n> +#else\n> +\n> +static void __void_func(const char *funcname)\n> +{\n> +\tfprintf(stderr, \"fwts ACPICA library: unexpected call to %s()\\n\", funcname);\n> +\texit(EXIT_FAILURE);\n> +}\n> +\n> +#define VOID_FUNC(name) void name(void) { __void_func(#name); }\n> +\n> +/*\n> + *  With ACPI disabled, these functions should never\n> + *  be called. We should defined this otherwise we will\n> + *  get linker errors with some autotools/linker combos\n> + */\n> +VOID_FUNC(AcpiGbl_IgnoreErrors)\n> +VOID_FUNC(AcpiGbl_RegionFillValue)\n> +\n> +VOID_FUNC(AcpiOsCreateSemaphore)\n> +VOID_FUNC(AcpiOsDeleteSemaphore)\n> +VOID_FUNC(AcpiOsExecute)\n> +VOID_FUNC(AcpiOsGetRootPointer)\n> +VOID_FUNC(AcpiOsPrintf)\n> +VOID_FUNC(AcpiOsReadPciConfiguration)\n> +VOID_FUNC(AcpiOsReadPort)\n> +VOID_FUNC(AcpiOsSignal)\n> +VOID_FUNC(AcpiOsSignalSemaphore)\n> +VOID_FUNC(AcpiOsSleep)\n> +VOID_FUNC(AcpiOsVprintf)\n> +VOID_FUNC(AcpiOsWaitSemaphore)\n> +\n> +VOID_FUNC(AeTableOverride)\n> +\n> +VOID_FUNC(MpSaveGpioInfo)\n> +VOID_FUNC(MpSaveSerialInfo)\n> +\n>   #endif\n> \n\nAcked-by: Ivan Hu <ivan.hu@canonical.com>","headers":{"Return-Path":"<fwts-devel-bounces@lists.ubuntu.com>","X-Original-To":"incoming@patchwork.ozlabs.org","Delivered-To":"patchwork-incoming@bilbo.ozlabs.org","Authentication-Results":"ozlabs.org;\n\tspf=none (mailfrom) smtp.mailfrom=lists.ubuntu.com\n\t(client-ip=91.189.94.19; helo=huckleberry.canonical.com;\n\tenvelope-from=fwts-devel-bounces@lists.ubuntu.com;\n\treceiver=<UNKNOWN>)","Received":["from huckleberry.canonical.com (huckleberry.canonical.com\n\t[91.189.94.19])\n\tby ozlabs.org (Postfix) with ESMTP id 3xhvWx5WtFz9sN5;\n\tWed, 30 Aug 2017 15:41:49 +1000 (AEST)","from localhost ([127.0.0.1] helo=huckleberry.canonical.com)\n\tby huckleberry.canonical.com with esmtp (Exim 4.76)\n\t(envelope-from <fwts-devel-bounces@lists.ubuntu.com>)\n\tid 1dmvl6-0005Vu-58; Wed, 30 Aug 2017 05:41:48 +0000","from youngberry.canonical.com ([91.189.89.112])\n\tby huckleberry.canonical.com with esmtps\n\t(TLS1.0:RSA_AES_256_CBC_SHA1:32)\n\t(Exim 4.76) (envelope-from <ivan.hu@canonical.com>)\n\tid 1dmvkz-0005VM-Hs\n\tfor fwts-devel@lists.ubuntu.com; Wed, 30 Aug 2017 05:41:41 +0000","from [175.181.155.140] (helo=[192.168.31.95])\n\tby youngberry.canonical.com with esmtpsa\n\t(TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)\n\t(Exim 4.76) (envelope-from <ivan.hu@canonical.com>)\n\tid 1dmvkz-0004OL-0Y\n\tfor fwts-devel@lists.ubuntu.com; Wed, 30 Aug 2017 05:41:41 +0000"],"Subject":"ACK: [PATCH] acpica: fwts_acpica: fix linker issues on Fedora (LP:\n\t#1712572)","To":"fwts-devel@lists.ubuntu.com","References":"<20170829150426.5935-1-colin.king@canonical.com>","From":"ivanhu <ivan.hu@canonical.com>","Message-ID":"<07058a3c-bea6-1416-c9f5-c408ccf9700a@canonical.com>","Date":"Wed, 30 Aug 2017 13:41:37 +0800","User-Agent":"Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101\n\tThunderbird/52.2.1","MIME-Version":"1.0","In-Reply-To":"<20170829150426.5935-1-colin.king@canonical.com>","Content-Language":"en-GB","X-BeenThere":"fwts-devel@lists.ubuntu.com","X-Mailman-Version":"2.1.14","Precedence":"list","List-Id":"Firmware Test Suite Development <fwts-devel.lists.ubuntu.com>","List-Unsubscribe":"<https://lists.ubuntu.com/mailman/options/fwts-devel>,\n\t<mailto:fwts-devel-request@lists.ubuntu.com?subject=unsubscribe>","List-Archive":"<https://lists.ubuntu.com/archives/fwts-devel>","List-Post":"<mailto:fwts-devel@lists.ubuntu.com>","List-Help":"<mailto:fwts-devel-request@lists.ubuntu.com?subject=help>","List-Subscribe":"<https://lists.ubuntu.com/mailman/listinfo/fwts-devel>,\n\t<mailto:fwts-devel-request@lists.ubuntu.com?subject=subscribe>","Content-Transfer-Encoding":"7bit","Content-Type":"text/plain; charset=\"us-ascii\"; Format=\"flowed\"","Errors-To":"fwts-devel-bounces@lists.ubuntu.com","Sender":"fwts-devel-bounces@lists.ubuntu.com"}}]