Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp5661766ybi; Tue, 4 Jun 2019 10:01:33 -0700 (PDT) X-Google-Smtp-Source: APXvYqypoBNJJpkUiDmKGKm3/2dVm+Ydsv7QyY7gBsfBIKYyHO/KhowyqRedKPuNihLvaWWuCVqP X-Received: by 2002:a17:90a:a10c:: with SMTP id s12mr25274924pjp.49.1559667692852; Tue, 04 Jun 2019 10:01:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1559667692; cv=none; d=google.com; s=arc-20160816; b=uAERQI7Y8QjMXp81n8Mm4L8JnZP68RjB1KYeAcifgCnd6uBasTRE8afCfgCIDyki3w gOZ+W59Ez1CWNne1xE3XX2cTtMftW8cbddUhe0brlEIQ97RN2pqGpy+iTuCIC6pc867M qGITpy/Qat+k/QroF5RO1wD4byO7yIZScojiLxKnfdHquj1B8Dq1o+c+AgKQ+mUsTN0j TNlv4QG7R0YV22ZkN37Tmp59eZjXsEIJ5lVKuzB8Cxq7JDrnnqR/M9OHJHR3RiOVe+Kq lHSRwtXsBhoS+nAj+FKewy26c7flAsCyM2ztXwZ7DZ1sU8yrV0bWWnzitTWqmVQvMPxj kpWA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=M/gFqK7lNCwKusjAc9u2ML0vs/6IGlCg8EgQMDWaRl4=; b=WBwfRvR0bdx/CYS2SMHgpvCTZaFN13czpmgxTtdfGiKuYgc7TfIh0W13IXUjIPmaNH 7OkfBk6gmpzEwvWsJf2sMZmNnnCwGEqdDwwg8I26jvMoPWY+8sE0Zm33fLTdw38wtk/m v5T4bUvbGegBq4O6dTV+6PHa8asMrcdMeLZLgPts5hmU4bV8SYt4GIJhEnBnwRq78ugq F1CyArruI2r1lx9dC2SLwGX4sj8OtUZwivCY9A951MalRhhqrYmHzqY0k6l5yGZ+4YNc EGEQHRP3XTV+VP7VdURgeYZiZ1eNNHnHO5/8NmoLNXSfelflE3ml+m9lfCwzT//rIv4Z ycAA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@c-s.fr header.s=mail header.b=lRxptcyc; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id p13si486894plq.276.2019.06.04.10.01.16; Tue, 04 Jun 2019 10:01:32 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@c-s.fr header.s=mail header.b=lRxptcyc; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727868AbfFDQ7y (ORCPT + 99 others); Tue, 4 Jun 2019 12:59:54 -0400 Received: from pegase1.c-s.fr ([93.17.236.30]:18925 "EHLO pegase1.c-s.fr" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727715AbfFDQ7x (ORCPT ); Tue, 4 Jun 2019 12:59:53 -0400 Received: from localhost (mailhub1-int [192.168.12.234]) by localhost (Postfix) with ESMTP id 45JJ7V5b3jz9v0FN; Tue, 4 Jun 2019 18:59:50 +0200 (CEST) Authentication-Results: localhost; dkim=pass reason="1024-bit key; insecure key" header.d=c-s.fr header.i=@c-s.fr header.b=lRxptcyc; dkim-adsp=pass; dkim-atps=neutral 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 qW66f5xptFAU; Tue, 4 Jun 2019 18:59:50 +0200 (CEST) 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 45JJ7V4X7Fz9v0FC; Tue, 4 Jun 2019 18:59:50 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=c-s.fr; s=mail; t=1559667590; bh=M/gFqK7lNCwKusjAc9u2ML0vs/6IGlCg8EgQMDWaRl4=; h=Subject:To:Cc:References:From:Date:In-Reply-To:From; b=lRxptcyctzAGCWwul2GIdV7aOB8ReA46oksDDYQi3pzV9AeOgmMt8+fjTTgSkggWX WYpt4JHhHwBc1XCOCFFFDHeoHInHEy+S9f9zprJONpsT4lTON9AvUBnfMZLqDSwTFj RiLWx3ZGLJU2Ytu2/c1p5zcupyEDzbAAGEMON3dA= Received: from localhost (localhost [127.0.0.1]) by messagerie.si.c-s.fr (Postfix) with ESMTP id C27848B99C; Tue, 4 Jun 2019 18:59:51 +0200 (CEST) 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 0mnSeiSXSBB8; Tue, 4 Jun 2019 18:59:51 +0200 (CEST) Received: from PO15451 (unknown [192.168.4.90]) by messagerie.si.c-s.fr (Postfix) with ESMTP id 6B0A18B98E; Tue, 4 Jun 2019 18:59:51 +0200 (CEST) Subject: Re: [PATCH v3 14/16] powerpc/32: implement fast entry for syscalls on BOOKE To: Paul Mackerras Cc: Benjamin Herrenschmidt , Michael Ellerman , Nicholas Piggin , linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org References: <3e254178a157e7eaeef48f983880f71f97d1f296.1556627571.git.christophe.leroy@c-s.fr> <20190523061427.GA19655@blackberry> From: Christophe Leroy Message-ID: <4f5fa8af-08c2-e71a-dd43-4c1a64018409@c-s.fr> Date: Tue, 4 Jun 2019 18:59:51 +0200 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.7.0 MIME-Version: 1.0 In-Reply-To: <20190523061427.GA19655@blackberry> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: fr Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Paul, Le 23/05/2019 à 08:14, Paul Mackerras a écrit : > On Tue, Apr 30, 2019 at 12:39:03PM +0000, Christophe Leroy wrote: >> This patch implements a fast entry for syscalls. >> >> Syscalls don't have to preserve non volatile registers except LR. >> >> This patch then implement a fast entry for syscalls, where >> volatile registers get clobbered. >> >> As this entry is dedicated to syscall it always sets MSR_EE >> and warns in case MSR_EE was previously off >> >> It also assumes that the call is always from user, system calls are >> unexpected from kernel. > > This is now upstream as commit 1a4b739bbb4f. On the e500mc test > config that I use, I'm getting this build failure: > > arch/powerpc/kernel/head_fsl_booke.o: In function `SystemCall': > arch/powerpc/kernel/head_fsl_booke.S:416: undefined reference to `kvmppc_handler_BOOKE_INTERRUPT_SYSCALL_SPRN_SRR1' > Makefile:1052: recipe for target 'vmlinux' failed Does my patch (https://patchwork.ozlabs.org/patch/1103909/) fixes the issue for you ? Thanks Christophe > >> +.macro SYSCALL_ENTRY trapno intno >> + mfspr r10, SPRN_SPRG_THREAD >> +#ifdef CONFIG_KVM_BOOKE_HV >> +BEGIN_FTR_SECTION >> + mtspr SPRN_SPRG_WSCRATCH0, r10 >> + stw r11, THREAD_NORMSAVE(0)(r10) >> + stw r13, THREAD_NORMSAVE(2)(r10) >> + mfcr r13 /* save CR in r13 for now */ >> + mfspr r11, SPRN_SRR1 >> + mtocrf 0x80, r11 /* check MSR[GS] without clobbering reg */ >> + bf 3, 1975f >> + b kvmppc_handler_BOOKE_INTERRUPT_\intno\()_SPRN_SRR1 > > It seems to me that the "_SPRN_SRR1" on the end of this line > isn't meant to be there... However, it still fails to link with that > removed. > > Paul. >