From patchwork Tue Apr 26 14:52:14 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Roger_Pau_Monn=C3=A9?= X-Patchwork-Id: 8939581 Return-Path: X-Original-To: patchwork-xen-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id F1C99BF29F for ; Tue, 26 Apr 2016 14:55:09 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 149C520121 for ; Tue, 26 Apr 2016 14:55:09 +0000 (UTC) Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id DF66B20204 for ; Tue, 26 Apr 2016 14:55:07 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1av4MC-0007Sd-PP; Tue, 26 Apr 2016 14:52:56 +0000 Received: from mail6.bemta3.messagelabs.com ([195.245.230.39]) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1av4MC-0007SM-Dn for xen-devel@lists.xenproject.org; Tue, 26 Apr 2016 14:52:56 +0000 Received: from [85.158.137.68] by server-9.bemta-3.messagelabs.com id 1A/F3-03814-7C08F175; Tue, 26 Apr 2016 14:52:55 +0000 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFlrBIsWRWlGSWpSXmKPExsXitHSDve7xBvl wg3eLeC2+b5nM5MDocfjDFZYAxijWzLyk/IoE1oyTz34xF+znrej/spaxgbGBu4uRk0NCwF/i f9tvZhCbTUBH4uLcnWxdjBwcIgIqErf3GoCEmQWKJb6u6mMFsYUFMiXuHn0EVs4ioCpx6cEHN hCbV8BF4vvticwQI3UlTu7exA5icwq4Smxe8IoJxBYCqlmy6TE7RL2gxMmZT1gg5mtKtG7/zQ 5hy0s0b53NDFGvKNE/7wEbxExuidunpzJPYOSfhaR9FpL2WUjaFzAyr2LUKE4tKkst0jU00Us qykzPKMlNzMzRNTQw1stNLS5OTE/NSUwq1kvOz93ECAxBBiDYwbhiu+chRkkOJiVR3nt58uFC fEn5KZUZicUZ8UWlOanFhxhlODiUJHhN6oFygkWp6akVaZk5wGiASUtw8CiJ8DaBpHmLCxJzi zPTIVKnGBWlxHmngCQEQBIZpXlwbbAIvMQoKyXMywh0iBBPQWpRbmYJqvwrRnEORiVh3hCQKT yZeSVw018BLWYCWnz5kCzI4pJEhJRUA+MhrvZ9T5j92e5/0LaveqFxbr9PVdh5IcWFweJlqxl Xrn7l/OqA/bV4k+gbqlziuzZM2H/SJ2/C/dLPv1ssfldlaJdHvnStY//A9+1AH7tZtbek4iqd l7XtDm5qb7z2zNuftqOiU8HD7cUBxqcHT5Q0rjNh2yR402Hhveee3+d758xd75wh1KDEUpyRa KjFXFScCAB/E7PDuwIAAA== X-Env-Sender: prvs=917dd492e=roger.pau@citrix.com X-Msg-Ref: server-5.tower-31.messagelabs.com!1461682370!33860613!3 X-Originating-IP: [66.165.176.63] X-SpamReason: No, hits=0.0 required=7.0 tests=sa_preprocessor: VHJ1c3RlZCBJUDogNjYuMTY1LjE3Ni42MyA9PiAzMDYwNDg=\n, received_headers: No Received headers X-StarScan-Received: X-StarScan-Version: 8.28; banners=-,-,- X-VirusChecked: Checked Received: (qmail 62903 invoked from network); 26 Apr 2016 14:52:54 -0000 Received: from smtp02.citrix.com (HELO SMTP02.CITRIX.COM) (66.165.176.63) by server-5.tower-31.messagelabs.com with RC4-SHA encrypted SMTP; 26 Apr 2016 14:52:54 -0000 X-IronPort-AV: E=Sophos;i="5.24,536,1454976000"; d="scan'208";a="356517641" From: Roger Pau Monne To: Date: Tue, 26 Apr 2016 16:52:14 +0200 Message-ID: <1461682343-20597-6-git-send-email-roger.pau@citrix.com> X-Mailer: git-send-email 2.6.4 (Apple Git-63) In-Reply-To: <1461682343-20597-1-git-send-email-roger.pau@citrix.com> References: <1461682343-20597-1-git-send-email-roger.pau@citrix.com> MIME-Version: 1.0 X-DLP: MIA2 Cc: Wei Liu , Ian Jackson , Roger Pau Monne Subject: [Xen-devel] [PATCH v2 for-4.7 05/14] tools/headers: prevent adding two __align8__ to uint64_t in ARM headers X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xen.org Sender: "Xen-devel" X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Due to the fact that on ARM headers types are substituted to uint64_t and then uint64_t is also substituted to contain the aligment, this would lead to some types containing two __align8__ directives. Fix this by first expanding Xen specific types to uint64_t only, and then replacing all the uint64_t types to __align8__ uint64_t. This relies on the fact that all Xen-specific types will have longer names, so they will always be replaced first. Signed-off-by: Roger Pau Monné Reviewed-by: Andrew Cooper Reviewed-by: Doug Goldstein Acked-by: Wei Liu --- Cc: Ian Jackson Cc: Wei Liu --- tools/include/xen-foreign/mkheader.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tools/include/xen-foreign/mkheader.py b/tools/include/xen-foreign/mkheader.py index 0504cb8..0e42e14 100644 --- a/tools/include/xen-foreign/mkheader.py +++ b/tools/include/xen-foreign/mkheader.py @@ -20,8 +20,8 @@ footer = {}; inttypes["arm32"] = { "unsigned long" : "__danger_unsigned_long_on_arm32", "long" : "__danger_long_on_arm32", - "xen_pfn_t" : "__align8__ uint64_t", - "xen_ulong_t" : "__align8__ uint64_t", + "xen_pfn_t" : "uint64_t", + "xen_ulong_t" : "uint64_t", "uint64_t" : "__align8__ uint64_t", }; header["arm32"] = """ @@ -41,8 +41,8 @@ footer["arm32"] = """ inttypes["arm64"] = { "unsigned long" : "__danger_unsigned_long_on_arm64", "long" : "__danger_long_on_arm64", - "xen_pfn_t" : "__align8__ uint64_t", - "xen_ulong_t" : "__align8__ uint64_t", + "xen_pfn_t" : "uint64_t", + "xen_ulong_t" : "uint64_t", "uint64_t" : "__align8__ uint64_t", }; header["arm64"] = """