Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758220AbcC2Wwi (ORCPT ); Tue, 29 Mar 2016 18:52:38 -0400 Received: from mail-bn1on0074.outbound.protection.outlook.com ([157.56.110.74]:50696 "EHLO na01-bn1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1753154AbcC2Wwg (ORCPT ); Tue, 29 Mar 2016 18:52:36 -0400 Authentication-Results: arndb.de; dkim=none (message not signed) header.d=none;arndb.de; dmarc=none action=none header.from=caviumnetworks.com; Date: Wed, 30 Mar 2016 01:52:16 +0300 From: Yury Norov To: Arnd Bergmann CC: , , Subject: Re: arm64: kernel v4.6-rc1 hangs on QEMU Message-ID: <20160329225216.GB31869@yury-N73SV> References: <20160329220502.GA14443@yury-N73SV> <3753214.GGjb33ZPlQ@wuerfel> <20160329222217.GA31869@yury-N73SV> <3334343.7r57EH3qRj@wuerfel> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: <3334343.7r57EH3qRj@wuerfel> User-Agent: Mutt/1.5.23 (2014-03-12) X-Originating-IP: [95.143.213.121] X-ClientProxiedBy: VI1PR07CA0095.eurprd07.prod.outlook.com (25.165.229.149) To CO2PR07MB619.namprd07.prod.outlook.com (10.141.228.151) X-MS-Office365-Filtering-Correlation-Id: 4e712266-1503-4e02-57b4-08d35824d0ef X-Microsoft-Exchange-Diagnostics: 1;CO2PR07MB619;2:beC4baFcS2nBGgmk+HC17NgB+rNvnpM6DvKkZkwHyMs8s6SLJLPWOVKP8H7nPYiWwFrSYTzLmaZ4aVobmSMXzVyfYQhYILV6xvrsU19Yk8g07AdxTO0Lkt51TTXmat/xAKMR81HWiPJidHe5WoO6PJcBWvw3FdvM/vbNz8PhN4spV6VUDKOTtvhr8CSTZVZY;3:mci8SRKg+4JT0tmmqQOCE4TK66Xe0Rk3wvuBPw7dE+YdflUGjqkbrC/mSBlKMHRU2YYrIXJwSuVY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RPl4fXipCRrmKbDd6Oct40zIp4cpKaoLskoiCyl+HSDSB/LHXlGE7HbdzxO9xn2w4A0uVaqTxzLqbi0H7c73b/ivkanUUGmRYqU7uqGIlEEMWQfq0ABv3GIothTg76wGfeTfKTaJr7NbsZv8ALgxUYnPMa27kPmPnryd14O6kdSUuluj5myfaEY859WVZmG0iYJk44AyHVh84nlcrdO6Vtwq08WZVTm8GMfXdfPuSAnkvtTbqz8v2+YYtPdZ0W8luWp+PiJ+tTYIErq/Bb206EP87jDEDszfKeRBT6Xps= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(601004)(2401047)(5005006)(8121501046)(3002001)(10201501046);SRVR:CO2PR07MB619;BCL:0;PCL:0;RULEID:;SRVR:CO2PR07MB619; X-Microsoft-Exchange-Diagnostics: 1;CO2PR07MB619;4:52XR9nX+LnOZsNAr/w0d+NAgGNdB9bmpgRZ7fzLmT8V+utGEQonIxRd1lejyTxyF3xXb3OG7X68aYXMHya6iP3i9ipb6PS9uSsNtYXq9bHKkXByi1hmWjJBevVbZkORqbqzk3i9/03KIJGGDQFc5IXIlaVb2Sai5MtZ2iFM9YblXQjj20uF7YCBZFemzNE1LJSI8R++30QqWPKNgwoOeA5JD+rstR3MpawwQK6L5XAmr+nTshM0lhocZFWMNzP3s+YNmo9q9LhoREvJ/jE2KfyfHhyCjpsCJUyf9eekYY90+ApYVQHR1/lgYMPVjLSRkQc725iNEXpgmhdeIA7NHTmGlkCQwLSBegFyZ/NUQGpf3v6vuG7tMClh3TIiAeY8Q X-Forefront-PRVS: 0896BFCE6C X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10009020)(4630300001)(6009001)(6069001)(24454002)(83506001)(33656002)(46406003)(50986999)(76176999)(97756001)(2950100001)(2906002)(33716001)(76506005)(42186005)(6116002)(5004730100002)(1096002)(1076002)(54356999)(23726003)(77096005)(586003)(3846002)(81166005)(47776003)(50466002)(4001350100001)(93886004)(5008740100001)(92566002)(110136002)(4326007)(189998001)(66066001);DIR:OUT;SFP:1101;SCL:1;SRVR:CO2PR07MB619;H:localhost;FPR:;SPF:None;MLV:sfv;LANG:en; X-Microsoft-Exchange-Diagnostics: 1;CO2PR07MB619;23:2JVSiKfr8B6DK4ty7QiA4i4sTHEBzwGt2iqHFh6bdbzFOy6OaDz4KKngASZn/2LQH1fIIzbwZ1xQMtoTvAUk1LFeKe5ZTE2mEjxueFMjGRzh/f+sgsd6z7NuDT4eIDzlZsSlAH6FXfgjt553tatXkNUjgaG6VdIvmOZH5B+T5b4DNozqyGxrLd1Wq35K4lWejwbwkXZ4y/AzIOcb9hHiW+iaOmjgis/SMApoX2KE54ZwPcFsr+9NrVET4eL4IZv5IeqtPDSBbyKHW03O+E1B4cR7gaKcN3ZxVdvVVm8umPMg2XcUR/gGIGbjp/X7Ygj7lYNs87xzxN9VfJVGV+p0mgdeRptuZaylSs7Hr42MSw5HqtkKbBKYSxa4rSX1FRv1YphIlxgkuIHtp7yKbvUwGelhustb9PR/ZxN6cEt98R0LSUcMrDpfmmHe+j5RmXVMvfkkrsWUSEkSw3wATEY+ZaptWCXyRb6Og0Nirgp6WbrCH8M4JB1Ro0MZQqfwVG0HNIrFl1q/MfkmvXuwKToagx+x4zozHW8I8mbi0aLjTb4vdmYCM1bdmd0dI9O74MDyj+sCCeWxT4qGSAIxkWxLKRhP+5hsFiGCojRwue4z7adnMla14grq3NOer90syWJ541yYD6cORBPN+cJhYZZUpBGKEDTBA4Qh7fqHaTAMgT0sNjrG3qhTH8LmmFLP3uMoZf9PsqV7T4rodDSor6sFsND3yJJL4b06EzdQ7FkDnDh4LL2quhKIxR2SUABA4uBuckZi7icyu6cOB8WTBSO6doG8LpFK9NZetIePWZ+MLys/MSenr1olQ0DKZwu9IYZYPcYdg5B+410P0X/cRenJA/5I8gJXOHuA9YhGuPqXbaORAA7nPGH2LxhEhEjteFsoesFKftwYfpo7IJC8Cu8RvqQ0nyx485riqw8VtQpgOHDWmlTw2LvHaMNScneCFVhu X-Microsoft-Exchange-Diagnostics: 1;CO2PR07MB619;5:21lnbfbGPccq4T67TOPj1WFsvlg9vuiTdy8RPHkX7SM1JA7nFluvQ05urrJUa3WOLQUTYIUccamic8bVFDy3YrsDWUUxZewzSAP4zDUqwH+qDwPmnTtn0nBOz6NOrpJHtSAfaaBe5s1iPFKogZ7wFg==;24:evDAgwbuyfTasFLo2mhoVKcVZzleE5eyD/p6VVK4Ya1PVgt45wX/B8ttnZK+pMedtpzvL6N7St5jQGV5To3BYvmVSs7KuZ+pardyfop4gls= SpamDiagnosticOutput: 1:23 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 29 Mar 2016 22:52:33.1785 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: CO2PR07MB619 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 998 Lines: 30 On Wed, Mar 30, 2016 at 12:32:42AM +0200, Arnd Bergmann wrote: > On Wednesday 30 March 2016 01:22:17 Yury Norov wrote: > > > > > > Undefined instruction in cpuinfo_store_boot_cpu() could be related > > > to the SYS_ID_AA64MMFR2_EL1 access that was recently added. > > > > > > What does the architecture say about reading unknown cpuid registers? > > > > > > Arnd > > > > ThunderX has some unimplemented system registers. AFAIR, attempt to access it > > causes data abort. > > Ok, if that is the case, maybe the read_cpuid() macro can be changed > so it contains a fixup for the trap? That should handle both data abort > and undefinstr. > > Arnd Sounds alluring, but not clear what we'd return that way. I mean, how we'd distinguish between correct value and error code (0, -1 or whatever). But I think, we can do like this: val = read_cpuid_safe(reg, impossible_val); if (val == impossible_val) goto err; I think it will work for many cases. Yury.