From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-11.6 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, MENTIONS_GIT_HOSTING,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7ADA5C1975A for ; Wed, 25 Mar 2020 11:12:22 +0000 (UTC) Received: from lists.ozlabs.org (lists.ozlabs.org [203.11.71.2]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 115F020714 for ; Wed, 25 Mar 2020 11:12:21 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=ellerman.id.au header.i=@ellerman.id.au header.b="PPAh879i" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 115F020714 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=ellerman.id.au Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=linuxppc-dev-bounces+linuxppc-dev=archiver.kernel.org@lists.ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 48nQSM4PPDzDqgV for ; Wed, 25 Mar 2020 22:12:19 +1100 (AEDT) Received: from ozlabs.org (bilbo.ozlabs.org [IPv6:2401:3900:2:1::2]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 48nPp73mKbzDqlQ for ; Wed, 25 Mar 2020 21:42:39 +1100 (AEDT) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=ellerman.id.au Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=ellerman.id.au header.i=@ellerman.id.au header.a=rsa-sha256 header.s=201909 header.b=PPAh879i; dkim-atps=neutral Received: from authenticated.ozlabs.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mail.ozlabs.org (Postfix) with ESMTPSA id 48nPp65x6Mz9sR4; Wed, 25 Mar 2020 21:42:38 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ellerman.id.au; s=201909; t=1585132959; bh=MIDM4vlJXdEfVW+ViGJHSFPdc7Mk/IuOQUQ1rBvfuCw=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=PPAh879iuIuGEf2yGiujeAw6ewMCs3lEi/MG3GEuRkpvFIa5Pg4/t3zaQ3X2MoutK I0lilZsHBtLI/jgHQ2fra/KEXkHYkIuVQqZoimwpHDUcTQRI5Hub3TTvXeSGcBxY0q rU2q7jz7Gs+en0nIvQsAefrP9IyV5MtzFT+oG8DwrJlGJkB1CTnOTJf//0Wd5tTw4G SK60p40ufvlG9+TchDs8eFSAjQS3MljVBaNbJxrAswKhZdKbT02SifcRvfOAy2MjTB uyFz/eXghtNm/u3nfmiw9Kv8JqjZSsBhtVqorKefjkPpLzOkPBMUMJaSKUwWF2FfJw FV/EsDrwyDeFQ== From: Michael Ellerman To: Fangrui Song , linuxppc-dev@lists.ozlabs.org Subject: Re: [PATCH] powerpc/boot: Delete unneeded .globl _zimage_start In-Reply-To: <20200325051820.163253-1-maskray@google.com> References: <20200325051820.163253-1-maskray@google.com> Date: Wed, 25 Mar 2020 21:42:46 +1100 Message-ID: <87sghwww9l.fsf@mpe.ellerman.id.au> MIME-Version: 1.0 Content-Type: text/plain X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: clang-built-linux@googlegroups.com, Nick Desaulniers , Joel Stanley , Fangrui Song Errors-To: linuxppc-dev-bounces+linuxppc-dev=archiver.kernel.org@lists.ozlabs.org Sender: "Linuxppc-dev" Fangrui Song writes: > .globl sets the symbol binding to STB_GLOBAL while .weak sets the > binding to STB_WEAK. They should not be used together. It is accidetal > rather then intentional that GNU as let .weak override .globl while > clang integrated assembler let the last win. > Fixes: cd197ffcf10b "[POWERPC] zImage: Cleanup and improve zImage entry point" > Fixes: ee9d21b3b358 "powerpc/boot: Ensure _zimage_start is a weak symbol" > Link: https://github.com/ClangBuiltLinux/linux/issues/937 > Signed-off-by: Fangrui Song So it seems the patch is OK but people don't agree with the explanation in the changelog. Please send a v2 that captures the responses from Segher and Alan. cheers > diff --git a/arch/powerpc/boot/crt0.S b/arch/powerpc/boot/crt0.S > index 92608f34d312..1d83966f5ef6 100644 > --- a/arch/powerpc/boot/crt0.S > +++ b/arch/powerpc/boot/crt0.S > @@ -44,9 +44,6 @@ p_end: .long _end > p_pstack: .long _platform_stack_top > #endif > > - .globl _zimage_start > - /* Clang appears to require the .weak directive to be after the symbol > - * is defined. See https://bugs.llvm.org/show_bug.cgi?id=38921 */ > .weak _zimage_start > _zimage_start: > .globl _zimage_start_lib > -- > 2.25.1.696.g5e7596f4ac-goog