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=-3.8 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no 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 4AD25C4363D for ; Fri, 2 Oct 2020 14:38:44 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id E1056206B2 for ; Fri, 2 Oct 2020 14:38:43 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="U2OKz1gB"; dkim=fail reason="signature verification failed" (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="UzyWzjrD" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org E1056206B2 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=redhat.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References:Message-ID: Subject:To:From:Date:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=YAuq/V0qqfaGWrrbpApDnyEEZBGHqB/7+KCE7z6NIMY=; b=U2OKz1gBa8pga4FwsR8Q4ubfs Sx6VOMhneCP0FFZrqXyf/9vOywwURDu7MeH0qWtZiI8ss/xYtQ3+xvq/oxqrdtkSFeUO5mbAmdohl A/8QWqBTvu2Lt/lHt2xlmRzunqO6QC14lV5ttnlxmq2/2NQii84CiDPhXFDue+qz5qiQxqXLywu52 sGrsKYvp7HADN9si4lCU40KGxpWTKniL8UsWno2xV3Zdku7GOlIBjNaa7xGBRTztxYIVRCOi5xCwa zlHZLBGB8V0DBIQzgV835bCCSCeEONXkWkpbNT0Z/a5soqWs260q5RKcIf8cxxRmqwom9fSbifQ1d zsjRYj2nQ==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kOMB8-0003hC-GU; Fri, 02 Oct 2020 14:36:58 +0000 Received: from us-smtp-delivery-124.mimecast.com ([63.128.21.124]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kOMB5-0003g2-3y for linux-arm-kernel@lists.infradead.org; Fri, 02 Oct 2020 14:36:56 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1601649414; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=RL9FkyEQEEDC7i4TxK7mLdt4FElF6i+ix0CGBCfcTBQ=; b=UzyWzjrD4uKqCnX55w7+tqwTnjOQpkMGOxJMB1MIWjwaH5hVjZSeYYKrNyJLwiwagkldt1 HFs6yjc9bjWPrMbsaF+HxdI1vqUnJsABnjVMt8EvbMg2HWEpnCqcp/nYoNsHt0G6Dt2WFm IHaaOdUAH631K9jHmMW4kq/+vUob1Zc= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-528-O7mBmVrVOh-mquDb9eronA-1; Fri, 02 Oct 2020 10:36:50 -0400 X-MC-Unique: O7mBmVrVOh-mquDb9eronA-1 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id E0DEE8064BD; Fri, 2 Oct 2020 14:36:47 +0000 (UTC) Received: from kamzik.brq.redhat.com (unknown [10.40.194.110]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 4711660BE2; Fri, 2 Oct 2020 14:36:43 +0000 (UTC) Date: Fri, 2 Oct 2020 16:36:40 +0200 From: Andrew Jones To: Steven Price Subject: Re: [PATCH v3 0/2] MTE support for KVM guest Message-ID: <20201002143640.uzsz3nhr45payhlb@kamzik.brq.redhat.com> References: <20200925093607.3051-1-steven.price@arm.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20200925093607.3051-1-steven.price@arm.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201002_103655_201606_B531C0E9 X-CRM114-Status: GOOD ( 21.07 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Mark Rutland , Peter Maydell , Haibo Xu , Suzuki K Poulose , Catalin Marinas , Juan Quintela , Richard Henderson , "Dr. David Alan Gilbert" , qemu-devel@nongnu.org, James Morse , Julien Thierry , kvmarm@lists.cs.columbia.edu, Marc Zyngier , Thomas Gleixner , Will Deacon , Dave Martin , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Fri, Sep 25, 2020 at 10:36:05AM +0100, Steven Price wrote: > Version 3 of adding MTE support for KVM guests. See the previous (v2) > posting for background: > > https://lore.kernel.org/r/20200904160018.29481-1-steven.price%40arm.com > > These patches add support to KVM to enable MTE within a guest. They are > based on Catalin's v9 MTE user-space support series[1] (currently in > next). > > Changes since v2: > > * MTE is no longer a VCPU feature, instead it is a VM cap. > > * Being a VM cap means easier probing (check for KVM_CAP_ARM_MTE). > > * The cap must be set before any VCPUs are created, preventing any > shenanigans where MTE is enabled for the guest after memory accesses > have been performed. > > [1] https://lore.kernel.org/r/20200904103029.32083-1-catalin.marinas@arm.com > > Steven Price (2): > arm64: kvm: Save/restore MTE registers > arm64: kvm: Introduce MTE VCPU feature > > arch/arm64/include/asm/kvm_emulate.h | 3 +++ > arch/arm64/include/asm/kvm_host.h | 7 +++++++ > arch/arm64/include/asm/sysreg.h | 3 ++- > arch/arm64/kvm/arm.c | 9 +++++++++ > arch/arm64/kvm/hyp/include/hyp/sysreg-sr.h | 14 ++++++++++++++ > arch/arm64/kvm/mmu.c | 15 +++++++++++++++ > arch/arm64/kvm/sys_regs.c | 20 +++++++++++++++----- > include/uapi/linux/kvm.h | 1 + > 8 files changed, 66 insertions(+), 6 deletions(-) > > -- > 2.20.1 > > Hi Steven, These patches look fine to me, but I'd prefer we have a working implementation in QEMU before we get too excited about the KVM bits. kvmtool isn't sufficient since it doesn't support migration (at least afaik). In the past we've implemented features in KVM that look fine, but then issues have been discovered when trying to enable them from QEMU, where we also support migration. This feature looks like there's risk of issues with the userspace side. Although these two patches would probably stay the same, even if userspace requires more support. Thanks, drew _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel