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=-20.3 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,MENTIONS_GIT_HOSTING,NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=unavailable 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 3E9C6C433DB for ; Fri, 12 Mar 2021 08:29:11 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 0D93264FB3 for ; Fri, 12 Mar 2021 08:29:11 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232255AbhCLI2k (ORCPT ); Fri, 12 Mar 2021 03:28:40 -0500 Received: from pegase1.c-s.fr ([93.17.236.30]:56643 "EHLO pegase1.c-s.fr" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231466AbhCLI2U (ORCPT ); Fri, 12 Mar 2021 03:28:20 -0500 Received: from localhost (mailhub1-int [192.168.12.234]) by localhost (Postfix) with ESMTP id 4Dxf8b39xTz9v0tW; Fri, 12 Mar 2021 09:28:15 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at c-s.fr Received: from pegase1.c-s.fr ([192.168.12.234]) by localhost (pegase1.c-s.fr [192.168.12.234]) (amavisd-new, port 10024) with ESMTP id rGbVLOrLdM_k; Fri, 12 Mar 2021 09:28:15 +0100 (CET) Received: from messagerie.si.c-s.fr (messagerie.si.c-s.fr [192.168.25.192]) by pegase1.c-s.fr (Postfix) with ESMTP id 4Dxf8b16PLz9tyZB; Fri, 12 Mar 2021 09:28:15 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by messagerie.si.c-s.fr (Postfix) with ESMTP id 505238B80F; Fri, 12 Mar 2021 09:28:15 +0100 (CET) X-Virus-Scanned: amavisd-new at c-s.fr Received: from messagerie.si.c-s.fr ([127.0.0.1]) by localhost (messagerie.si.c-s.fr [127.0.0.1]) (amavisd-new, port 10023) with ESMTP id q81IV4vGYKsG; Fri, 12 Mar 2021 09:28:15 +0100 (CET) Received: from [192.168.4.90] (unknown [192.168.4.90]) by messagerie.si.c-s.fr (Postfix) with ESMTP id DF8D18B764; Fri, 12 Mar 2021 09:28:14 +0100 (CET) Subject: Re: [PATCH v2 25/43] powerpc/32: Replace ASM exception exit by C exception exit from ppc64 To: Michael Ellerman , Benjamin Herrenschmidt , Paul Mackerras , npiggin@gmail.com Cc: linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org References: <87tuphkdkz.fsf@mpe.ellerman.id.au> <0296d1bc-b37e-43c8-06cf-00ec458fb74e@csgroup.eu> <87r1kljmr9.fsf@mpe.ellerman.id.au> From: Christophe Leroy Message-ID: <8b2ee16c-1661-d97c-04f0-5881e53ab835@csgroup.eu> Date: Fri, 12 Mar 2021 09:28:12 +0100 User-Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.8.0 MIME-Version: 1.0 In-Reply-To: <87r1kljmr9.fsf@mpe.ellerman.id.au> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: fr Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Le 12/03/2021 à 00:26, Michael Ellerman a écrit : > Christophe Leroy writes: >> Le 11/03/2021 à 14:46, Michael Ellerman a écrit : >>> Christophe Leroy writes: >>>> This patch replaces the PPC32 ASM exception exit by C exception exit. >>>> >>>> Signed-off-by: Christophe Leroy >>>> --- >>>> arch/powerpc/kernel/entry_32.S | 481 +++++++++----------------------- >>>> arch/powerpc/kernel/interrupt.c | 4 + >>>> 2 files changed, 132 insertions(+), 353 deletions(-) >>> >>> Bisect points to this breaking qemu mac99 for me, with pmac32_defconfig. >>> >>> I haven't had time to dig any deeper sorry. >> >> Embarrasing ... > > Nah, these things happen. > >> I don't get this problem on the 8xx (nohash/32) or the 83xx (book3s/32). >> I don't get this problem with qemu mac99 when using my klibc-based initramfs. >> >> I managed to reproduce it with the rootfs.cpio that I got some time ago from linuxppc github Wiki. > > OK. > > I'm using the ppc-rootfs.cpio.gz from here: > > https://github.com/linuxppc/ci-scripts/blob/master/root-disks/Makefile > > And the boot script is: > > https://github.com/linuxppc/ci-scripts/blob/master/scripts/boot/qemu-mac99 > > I've been meaning to write docs on how to use those scripts, but haven't > got around to it. > > There's nothing really special though it's just a wrapper around qemu -M mac99. > >> I'll investigate it tomorrow. > Problem is the fast_interrupt_return, registers are not all saved yet on ppc32 (msr, nip, xer, ctr), can't restore them all as ppc64 do. The problem happens only when userspace uses floating point or altivec. For the time being, I'll keep the original fast_interrupt_return. I will likely send a new version of the series later today, taking into account Nick's comments. Christophe