Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751998AbcDZCJ3 (ORCPT ); Mon, 25 Apr 2016 22:09:29 -0400 Received: from szxga02-in.huawei.com ([119.145.14.65]:22172 "EHLO szxga02-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750821AbcDZCJ2 (ORCPT ); Mon, 25 Apr 2016 22:09:28 -0400 From: "Zengtao (B)" To: "catalin.marinas@arm.com" CC: "Zengtao (B)" , "linux-arm-kernel@lists.infradead.org" , "mark.rutland@arm.com" , "suzuki.poulose@arm.com" , "will.deacon@arm.com" , "james.morse@arm.com" , "linux-kernel@vger.kernel.org" , "yang.shi@linaro.org" Subject: Re: [PATCH] arm64: fix /proc/cpuinfo for elf32 Thread-Topic: Re: [PATCH] arm64: fix /proc/cpuinfo for elf32 Thread-Index: AdGfYHNxVKfnYYjzSfOQbjbFa+yLhg== Date: Tue, 26 Apr 2016 02:07:56 +0000 Message-ID: <678F3D1BB717D949B966B68EAEB446ED0A6E6F56@SZXEMA509-MBX.china.huawei.com> Accept-Language: en-US Content-Language: zh-CN X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.67.233.8] Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 X-CFilter-Loop: Reflected X-Mirapoint-Virus-RAPID-Raw: score=unknown(0), refid=str=0001.0A020202.571ECD88.006A,ss=1,re=0.000,recu=0.000,reip=0.000,cl=1,cld=1,fgs=0, ip=169.254.1.183, so=2013-06-18 04:22:30, dmn=2013-03-21 17:37:32 X-Mirapoint-Loop-Id: 4471c3ee2624492b6d1f501344b1fdb9 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by mail.home.local id u3Q29Ycb001843 Content-Length: 1139 Lines: 33 On 2016-04-25 09:12, Catalin Marinas wrote: > On Mon, Apr 25, 2016 at 11:37:33AM +0800, Zeng Tao wrote: > > For elf32 thread, personality is used for arm32, > > and thread_flag for arm64. > > > > Here personality is used for arm64, so fix it. > > > > Signed-off-by: Zeng Tao > > --- > > arch/arm64/kernel/cpuinfo.c | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > We discussed this some time ago and we decided against it. One reason > was scripts where you may or may not end up with the desired cpuinfo > (e.g. grep being 64-bit invoked by a 32-bit bash). The personality at > least is inherited by child processes. > So you mean the 64-bit grep should see the same cpuinfo as 32-bit bash as It is the child process? But currently we have same 32-bit application which don't have their personality set, so they get the wrong cpuinfo. How to fix, call the personality syscall? > -- > Catalin > > _______________________________________________ > linux-arm-kernel mailing list > linux-arm-kernel@lists.infradead.org > http://lists.infradead.org/mailman/listinfo/linux-arm-kernel > >