From patchwork Fri May 1 02:18:45 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "H.J. Lu" X-Patchwork-Id: 1281057 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=sourceware.org (client-ip=8.43.85.97; helo=sourceware.org; envelope-from=libc-alpha-bounces@sourceware.org; receiver=) Authentication-Results: ozlabs.org; dmarc=pass (p=none dis=none) header.from=sourceware.org Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.a=rsa-sha256 header.s=default header.b=Uj8T9eUn; dkim-atps=neutral Received: from sourceware.org (server2.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 49CwtR4gDHz9sRY for ; Fri, 1 May 2020 12:19:27 +1000 (AEST) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id CC61C3971C29; Fri, 1 May 2020 02:19:24 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org CC61C3971C29 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1588299564; bh=RFPlvWkTr6FcDff3wFuePD8R29lgrukX9S5EIvrVNXI=; h=References:In-Reply-To:Date:Subject:To:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: From; b=Uj8T9eUnY9R8KMZySuAPRSg4JRTQwop3205xU1SyWp+xWE5jM508yEVzrAK3/+Fpx AbjJnKY9qyikAbHKrcVV9HdExU3ftkgk+Bpp3KtyegECPf2qGXPisx7gkboq+gWuvO 41t/F4O0s7XFixVsbj99U/Blx/AZwg8tkA2vFZjs= X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from mail-io1-xd42.google.com (mail-io1-xd42.google.com [IPv6:2607:f8b0:4864:20::d42]) by sourceware.org (Postfix) with ESMTPS id E9C32385DC1C; Fri, 1 May 2020 02:19:21 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org E9C32385DC1C Received: by mail-io1-xd42.google.com with SMTP id b12so3687729ion.8; Thu, 30 Apr 2020 19:19:21 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=RFPlvWkTr6FcDff3wFuePD8R29lgrukX9S5EIvrVNXI=; b=FuwHfzh0MBFwLsjwROUXL77BGlHG9DinS3e6uGzfsh97kmwnliyANA9KIZ7zhQmCUN 6BitYbP5oL4EVzaGsU4tqWIpJQXN1RA2GOcLu/2IBwWvVUaHlAtjPsg3R/1fKbsF1m3W cNEUvHnQRaMnJBamFeIoywAunye10Hyf4xngNPvb8YiBQJC/EKlF4E2Ef50Vfk5y1vCI RZ0MuwBnJ+GMQ7CjpBl1v4VZF3htlqL+W19IFzGhmVN4fXh8vmnRSOC50HlL2c7uR5fO yfLjpFlGr5w/EsfA12l1TTXBmrwvf3Cu3AmzJg1otvxbKj8fHmM+PGQGhCUDFgEs4YRc 5QAA== X-Gm-Message-State: AGi0Pub+WnrJLypH33qCwZMo8cWxLWESNjw9ZCa4eL+VDHTNa6c912d/ 7Tc9k31BgFmO4rhxYVz3fnYSbdac2UXe9TzOTfipIc+E X-Google-Smtp-Source: APiQypJVYOKrw/gYBpoz31cXz9Y2ls9rQAKstkp/PFJiz3gPgNXXMW2lNPMyGUi/IHWDb4r4n+6deDwTplPslC445r8= X-Received: by 2002:a5e:d918:: with SMTP id n24mr1881326iop.28.1588299561352; Thu, 30 Apr 2020 19:19:21 -0700 (PDT) MIME-Version: 1.0 References: <20200429205217.2435607-1-hjl.tools@gmail.com> <87wo5xa0yt.fsf@mid.deneb.enyo.de> <20200430130333.GA254612@gmail.com> <39a57354-4ca8-53f5-bb89-dadf25f3671a@linaro.org> <871ro49atj.fsf@mid.deneb.enyo.de> <87tv10za12.fsf@linux.ibm.com> In-Reply-To: <87tv10za12.fsf@linux.ibm.com> Date: Thu, 30 Apr 2020 19:18:45 -0700 Message-ID: Subject: [PATCH] powerpc: Rename argN to _argN in LOADARGS_N [BZ #25902] To: Tulio Magno Quites Machado Filho , Libc-stable Mailing List X-Spam-Status: No, score=-19.1 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: "H.J. Lu via Libc-alpha" From: "H.J. Lu" Reply-To: "H.J. Lu" Cc: GNU C Library Errors-To: libc-alpha-bounces@sourceware.org Sender: "Libc-alpha" On Thu, Apr 30, 2020 at 7:03 PM Tulio Magno Quites Machado Filho wrote: > > "H.J. Lu via Libc-alpha" writes: > > > See: > > > > https://sourceware.org/bugzilla/show_bug.cgi?id=25902 > > > > with a patch. But I can't test it natively. > > Tested. LGTM. > > Could you push it, please? This is I am checking in. I will backport it to 2.30/2.31 branches together with commit ff026950e280bc3e9487b41b460fb31bc5b57721 Author: H.J. Lu Date: Thu Apr 30 10:42:43 2020 -0700 Add a C wrapper for prctl [BZ #25896] From 14f43dd34dcf1ba29386c01cd0b286dffb37412d Mon Sep 17 00:00:00 2001 From: "H.J. Lu" Date: Thu, 30 Apr 2020 15:49:47 -0700 Subject: [PATCH] powerpc: Rename argN to _argN in LOADARGS_N [BZ #25902] LOADARGS_N in powerpc/sysdep.h uses argN as local variables. It breaks when argN is also a function argument. Rename argN to _argN to avoid conflict. --- sysdeps/unix/sysv/linux/powerpc/sysdep.h | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/sysdeps/unix/sysv/linux/powerpc/sysdep.h b/sysdeps/unix/sysv/linux/powerpc/sysdep.h index fd79bbcf3c..b2bca598b9 100644 --- a/sysdeps/unix/sysv/linux/powerpc/sysdep.h +++ b/sysdeps/unix/sysv/linux/powerpc/sysdep.h @@ -100,53 +100,53 @@ #define LOADARGS_0(name, dummy) \ r0 = name #define LOADARGS_1(name, __arg1) \ - long int arg1 = (long int) (__arg1); \ + long int _arg1 = (long int) (__arg1); \ LOADARGS_0(name, 0); \ extern void __illegally_sized_syscall_arg1 (void); \ if (__builtin_classify_type (__arg1) != 5 \ && sizeof (__arg1) > SYSCALL_ARG_SIZE) \ __illegally_sized_syscall_arg1 (); \ - r3 = arg1 + r3 = _arg1 #define LOADARGS_2(name, __arg1, __arg2) \ - long int arg2 = (long int) (__arg2); \ + long int _arg2 = (long int) (__arg2); \ LOADARGS_1(name, __arg1); \ extern void __illegally_sized_syscall_arg2 (void); \ if (__builtin_classify_type (__arg2) != 5 \ && sizeof (__arg2) > SYSCALL_ARG_SIZE) \ __illegally_sized_syscall_arg2 (); \ - r4 = arg2 + r4 = _arg2 #define LOADARGS_3(name, __arg1, __arg2, __arg3) \ - long int arg3 = (long int) (__arg3); \ + long int _arg3 = (long int) (__arg3); \ LOADARGS_2(name, __arg1, __arg2); \ extern void __illegally_sized_syscall_arg3 (void); \ if (__builtin_classify_type (__arg3) != 5 \ && sizeof (__arg3) > SYSCALL_ARG_SIZE) \ __illegally_sized_syscall_arg3 (); \ - r5 = arg3 + r5 = _arg3 #define LOADARGS_4(name, __arg1, __arg2, __arg3, __arg4) \ - long int arg4 = (long int) (__arg4); \ + long int _arg4 = (long int) (__arg4); \ LOADARGS_3(name, __arg1, __arg2, __arg3); \ extern void __illegally_sized_syscall_arg4 (void); \ if (__builtin_classify_type (__arg4) != 5 \ && sizeof (__arg4) > SYSCALL_ARG_SIZE) \ __illegally_sized_syscall_arg4 (); \ - r6 = arg4 + r6 = _arg4 #define LOADARGS_5(name, __arg1, __arg2, __arg3, __arg4, __arg5) \ - long int arg5 = (long int) (__arg5); \ + long int _arg5 = (long int) (__arg5); \ LOADARGS_4(name, __arg1, __arg2, __arg3, __arg4); \ extern void __illegally_sized_syscall_arg5 (void); \ if (__builtin_classify_type (__arg5) != 5 \ && sizeof (__arg5) > SYSCALL_ARG_SIZE) \ __illegally_sized_syscall_arg5 (); \ - r7 = arg5 + r7 = _arg5 #define LOADARGS_6(name, __arg1, __arg2, __arg3, __arg4, __arg5, __arg6) \ - long int arg6 = (long int) (__arg6); \ + long int _arg6 = (long int) (__arg6); \ LOADARGS_5(name, __arg1, __arg2, __arg3, __arg4, __arg5); \ extern void __illegally_sized_syscall_arg6 (void); \ if (__builtin_classify_type (__arg6) != 5 \ && sizeof (__arg6) > SYSCALL_ARG_SIZE) \ __illegally_sized_syscall_arg6 (); \ - r8 = arg6 + r8 = _arg6 #define ASM_INPUT_0 "0" (r0) #define ASM_INPUT_1 ASM_INPUT_0, "1" (r3) -- 2.26.2