Received: by 2002:ad5:4acb:0:0:0:0:0 with SMTP id n11csp4483068imw; Tue, 19 Jul 2022 07:27:03 -0700 (PDT) X-Google-Smtp-Source: AGRyM1uLTJnuhkD6KsbHc41bOx9N4LlRJpFJnR7rRMlZ+wxLawPgIw2YldCBGB2EoNoHSZdzf5nw X-Received: by 2002:a05:620a:2983:b0:6b5:e5f5:f2c5 with SMTP id r3-20020a05620a298300b006b5e5f5f2c5mr6975633qkp.138.1658240823232; Tue, 19 Jul 2022 07:27:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1658240823; cv=none; d=google.com; s=arc-20160816; b=Ur3Z3+tcaPwNIXtEJWPf/J9nKWnTjR3NY/Fgdcig1iA+fucaUIR6IAhR7KChjGkZfV 5UnQfOK+swylJNSPBdXeP3q/w1p5cm7DhcnfW14KrC8xyZTn4rUBbgQDga0JQ/ganBOn vCtK4F95VGWYigy0WW16JRwKRwufEhI74u3sz2x4nH2OHrGoR6gF+ID7NPe8WB99Bph3 DTpIqvxsHnY6GapA19hkJ836s63YqAH74iKAkiEaFDSBuO4DR5OQlXHnkbPIrScGOW9/ 8U6z6+AvcZTOx5eIjRmntZ5R4UiGqtyYURAgh86Q3kT53cyWuUXYRBNWlzomQin+XE/+ noDw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:references :in-reply-to:subject:cc:to:from:dkim-signature; bh=CrnNLr81S4YloGowqIvvpwhKM5iqnery0Z9Yt9RUyUs=; b=qZLRgytd4dzmBPJEbTBhtmhiTjLyTaoCwQCMC6fGbIjvKUMdRJa/4/DEEWuk6JCUWr +XwYUBRxz+rxPSd6PXxL1fWNKxgEg+r1ERlULWZw/kAAEgnjkMPCOIlZu6dqcWBF7mvx LnjC0zvdpBxFUW4iEUTN2jylVn/EvIfliGQ2v9FNhpqgMXRTH5HyOPSrzbpvI+yzZyuI +QMBQ2ilXIUBov7YT7/jq1v1SP0ZKOKhPlpXQkKWw+jR4hog+LsW/2SpREDXEPGv+UW3 SySzKLEzjd4Fb/DEdyLGXhLfXjYvgw2/wURwJ8Go37+tUDwi3Y6iziihbqKzMkAWo3ip 1GQg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ellerman.id.au header.s=201909 header.b=aHMRxUHb; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id c14-20020ac8660e000000b0031ecf0c5519si4624559qtp.588.2022.07.19.07.26.49; Tue, 19 Jul 2022 07:27:03 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@ellerman.id.au header.s=201909 header.b=aHMRxUHb; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237606AbiGSONN (ORCPT + 99 others); Tue, 19 Jul 2022 10:13:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52422 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238786AbiGSOMs (ORCPT ); Tue, 19 Jul 2022 10:12:48 -0400 Received: from gandalf.ozlabs.org (mail.ozlabs.org [IPv6:2404:9400:2221:ea00::3]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A51533AB34; Tue, 19 Jul 2022 06:35:42 -0700 (PDT) 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 4LnKbF1NT5z4x7X; Tue, 19 Jul 2022 23:35:37 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ellerman.id.au; s=201909; t=1658237737; bh=CrnNLr81S4YloGowqIvvpwhKM5iqnery0Z9Yt9RUyUs=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=aHMRxUHbnCfBomhXQ9tcldDT7Pg5cCo4FncMhuN9OsMFUFaf1g9O5F7eSr913cN8V 6htMn2aBuGi1A0ciVH+PVPjaqPpmy4axP36kZF1GMcKGDvsIng09UB3jFSApnWQnVF qpwEBvIATnpJkrTY9K7VLEIVWsp/LcImBXE2obx++KfGOLC7R63Ry00J0hGkmmSUlk so2xQ8rIVeHG4gFXtj4tp3I53J7LL3AhVDLFSRcweulMtvcSYBl1o4dfbkI7m2cgYd ToqoL7kkOTto9lRWn68KxknxrSec249u8WrBzJC+0+kUvx2Sr+jOv6O6W6LmYdHb0i tJzl1r/3dGEtA== From: Michael Ellerman To: Linus Torvalds Cc: Sudip Mukherjee , Benjamin Herrenschmidt , Paul Mackerras , Kees Cook , linuxppc-dev , linux-kernel , linux-hardening@vger.kernel.org Subject: Re: mainline build failure of powerpc allmodconfig for prom_init_check In-Reply-To: References: <87cze3docs.fsf@mpe.ellerman.id.au> Date: Tue, 19 Jul 2022 23:35:33 +1000 Message-ID: <871quhdy3e.fsf@mpe.ellerman.id.au> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW,SPF_HELO_PASS, SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Linus Torvalds writes: > On Sun, Jul 17, 2022 at 9:41 PM Michael Ellerman wrote: >> >> > li 4,254 #, >> >> Here we load 254 into r4, which is the 2nd parameter to memset (c). > > I love how even powerpc people know that "4" is bogus, and have to > make it clear that it means "r4". I wouldn't say it's bogus, I was just translating from asm to English :) But I agree it's preferable to use a proper register name rather than a bare integer. I never write asm using bare integers, I always use r4 or %r4, because as you say it's too easy to get mixed up otherwise. When looking at generated code I usually use objdump -d output, which uses the "r4" syntax. > It's not even an IBM thing. S390 uses perfectly sane register syntax, > and calls things '%r4" etc. as accepts that syntax if you tell it to. We use that syntax in some of our newer inline asm blocks. > The human-written asm files have those #define's in headers just to > make things slightly more legible, because apparently the assembler > doesn't even *accept* the sane names. I would like to switch to using %rX everywhere and get rid of those defines, but it's never seemed like it's worth the churn. We have ~48K lines of asm in arch/powerpc. cheers