Received: by 2002:a05:6a10:413:0:0:0:0 with SMTP id 19csp2381841pxp; Mon, 7 Mar 2022 14:18:25 -0800 (PST) X-Google-Smtp-Source: ABdhPJwLVW/VkU7vNmG6rRrDJkLJwr8wViuOwAvBKrxwYvG4ADIfzecizpTz+uUk9C6gOQNaWtet X-Received: by 2002:a17:902:ea05:b0:150:1294:cd91 with SMTP id s5-20020a170902ea0500b001501294cd91mr14637740plg.112.1646691504939; Mon, 07 Mar 2022 14:18:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1646691504; cv=none; d=google.com; s=arc-20160816; b=Ic9G4sTm34MVJPD/YB+LYMjAFq/q2GHMr0ZhV3TM3ZrhBhD1BleFFeJPVFblzTfVxm ZomigG5b/B+iCxr1j/1sayXPJP1GhasyUoUeG8q7qfdGUiaTOaT9DLTSut8baRkE/9Za Gx64C1NeKABOdhz1DZ3MSOLw0XEqVJA+Lo3XVH53QzsT7LEPFhnJH/hw7PwVgn/7jaRR jQsvi95N+JOOyxDIwATWENwHXFspMVAMqDzWNqNiPwcKOs/+FtribuBUHFcIugcleFKi m/hw3WM+NSFuciA8yR6mlnAEgyOgKcj5olYq9vCLvXteVcC2rcUdfplvBW/meTkw0R2I xJ9w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id; bh=Gv6VAdYZXTa3irmVgsXS1zJQNH54sh4AYmU96kgY7NU=; b=njbk9fdBGB4GtCYem90M+grZ4I+rI+pz53SgK7gaPWFjk4RA8aRN4hc9aVkFVFnLde hh6cHCOsGLcpINia9LdVsXrk1mwx9Gid80VJIAUNil6x9l4duI4gD5EEv112pMf40U8J cfkks69H8O0d4uPyUo7pk5BkJ6TQgVWuRYYD9uXNlQHt/1lKk2AjdCVWGEv+kXWW6Hch r38FS2eLtqBDJuDWuKo8OagpryTA1PIrK8Vh7WdrXlW+84rCvDWpMjUSJQjsWBpbu4OJ UWySA5KwyfbiWnFOoMv3TeDbdTEqlT0wRGe7aGHuSqZIEmQOsVDzIWO2yA2x0eBnkoCl uLzQ== ARC-Authentication-Results: i=1; mx.google.com; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k15-20020a633d0f000000b003805b75ef96si4651066pga.800.2022.03.07.14.18.08; Mon, 07 Mar 2022 14:18:24 -0800 (PST) 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; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244304AbiCGQuL (ORCPT + 99 others); Mon, 7 Mar 2022 11:50:11 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44470 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S240721AbiCGQuJ (ORCPT ); Mon, 7 Mar 2022 11:50:09 -0500 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id E6E4824590 for ; Mon, 7 Mar 2022 08:49:14 -0800 (PST) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 6E206153B; Mon, 7 Mar 2022 08:49:14 -0800 (PST) Received: from [10.1.196.40] (e121345-lin.cambridge.arm.com [10.1.196.40]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 4247B3FA45; Mon, 7 Mar 2022 08:49:13 -0800 (PST) Message-ID: <1b94af8b-a294-5765-4e1e-896f70db621f@arm.com> Date: Mon, 7 Mar 2022 16:48:51 +0000 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux aarch64; rv:91.0) Gecko/20100101 Thunderbird/91.5.0 Subject: Re: [PATCH RFC] arm64: improve display about CPU architecture in cpuinfo Content-Language: en-GB To: Marc Zyngier , Rongwei Wang Cc: catalin.marinas@arm.com, will@kernel.org, joey.gouly@arm.com, mark.rutland@arm.com, akpm@linux-foundation.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org References: <20220307030417.22974-1-rongwei.wang@linux.alibaba.com> <87h78a178u.wl-maz@kernel.org> <87bkyi0x53.wl-maz@kernel.org> From: Robin Murphy In-Reply-To: <87bkyi0x53.wl-maz@kernel.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00,NICE_REPLY_A, RCVD_IN_DNSWL_HI,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE 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 On 07/03/2022 12:23 pm, Marc Zyngier wrote: > On Mon, 07 Mar 2022 12:13:50 +0000, > Rongwei Wang wrote: >> >> >> >> On 3/7/22 4:45 PM, Marc Zyngier wrote: >>> On Mon, 07 Mar 2022 03:04:17 +0000, >>> Rongwei Wang wrote: >>>> >>>> Now, it is unsuitable for both ARMv8 and ARMv9 to show a >>>> fixed string "CPU architecture: 8" in /proc/cpuinfo. >>> >>> Please read the various threads that have been going on over the past >>> 10+ years about *why* we don't allow this sort of change (TL;DR: it >>> breaks userspace, and we don't do that). >>> >>> Also, there is no material difference between v8 and v9 that would be >>> observable from userspace outside of the "Features:" line. And if that >>> doesn't convince you, just think of '8' as the number of bytes >>> used by > >> I got your point. It seems that we can regard '8' as the number of >> bytes. But what make me do this is that 'CPU architecture: 8' is >> confusing, especially those responsible for testing. >> And I believe that most people regard this '8' as ARMv8, maybe not. > > That was the original intention. But given that there is no userspace > visible difference between v8, v9 and whatever comes after it, this > is a pointless change. My comment about the size of a VA was just a > joke, and not something to be taken seriously. > >> In fact, I'm not sure it has potential ABI implications, so seek your >> advice. > > Plenty of userspace programs parse /proc/cpuinfo. If you replace '8' > with anything else, they will fail. Which is why although your patch > makes sense, it comes 10 years too late, and we can't change this > anymore. And arguably it's not even too late, because 10 years ago this *did* say "AArch64". I don't remember all the exact details behind commit 44b82b7700d0 ("arm64: Fix up /proc/cpuinfo") - this just tickled enough of a memory to go and look up the git history - but I don't think we changed any of those fields without a real reason. Robin.