Received: by 2002:ac0:bc90:0:0:0:0:0 with SMTP id a16csp4466339img; Tue, 26 Mar 2019 09:56:08 -0700 (PDT) X-Google-Smtp-Source: APXvYqxaNA/t3DOLTxFaEz9rf0ZjdQMz7zbxHP9w3I3sv7CRt6VNH9lwuLbyfmdYvhoUKbVJqXJy X-Received: by 2002:a63:94:: with SMTP id 142mr29917509pga.277.1553619368766; Tue, 26 Mar 2019 09:56:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1553619368; cv=none; d=google.com; s=arc-20160816; b=jeCHBm0rG6LoDyN67Ac7U2Y+PoOKos7Zxw2sCcosD6uQGKTGsRWwWw/OqFfatoYWe7 LVOQUhWoCXTrIj6PxcEStZ3J82a9z/UZlmsS1amYa3Ak7HR0JhUoXaCGBxxHqfVJNIfk EZ6Cr/+tfTaJrd9s3JRUDPgglBHG+tqWNxKhwjL8MaloWzuulURucs1L+SyXpHQ1r9zg u1MYlkWj9K9p/D9EmHHLNPOusrCATe1EG8ezf8YkhBcDemxBGp0LkUGRk6q7dd146k8w P4w/yJ9MfMQ+qfXXdJ7k/Fgp2tUZiPVi1twMmqQvdtWSw4Q8XoBpsiCqtGXgh5hNjzAv +FxQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=AT7xvjAWIyJCcePl132t7T+n+TzpQQuXNXm3pdI4blo=; b=rZx1uh/0g48TI8u8vG1V4e6wFPgPDMSHui92dIRrz3kuLsjQmMnYdKvR9rST5XkubK kPkHjyqub8eMn54dSCxj0rb24f7oyQLpgNP0QnvyCq4dUa8tK3D+Mcm0FNQr9FiST0EX PQ66Gs5GUeNDOOP+fT4mWzjXKTc+37NmOeQN3zQX35rNmDhqOye/DM7+P/3UCb6WFRpL mKwXfLnzKw3lkFFk1RLpKs5xP9xEIGg83FK0Ugb8C/Ixm6xgoTHwTQGDMBpDBEn43mXT ZqbFEHHb4p1fKE+IlS+iXqGhb06ha36Ye35XAOpFtTWQuUT50d0umSKjz6SZkPrYpqcs T7LQ== ARC-Authentication-Results: i=1; mx.google.com; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id p17si1394766pgl.181.2019.03.26.09.55.53; Tue, 26 Mar 2019 09:56:08 -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; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730697AbfCZQyE (ORCPT + 99 others); Tue, 26 Mar 2019 12:54:04 -0400 Received: from mail-qk1-f193.google.com ([209.85.222.193]:42498 "EHLO mail-qk1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726261AbfCZQyE (ORCPT ); Tue, 26 Mar 2019 12:54:04 -0400 Received: by mail-qk1-f193.google.com with SMTP id b74so8043353qkg.9 for ; Tue, 26 Mar 2019 09:54:03 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=AT7xvjAWIyJCcePl132t7T+n+TzpQQuXNXm3pdI4blo=; b=uRbPhYYIDiMv04qKSRSjhNHs8Fw2agg6a3DRRw5aByJ/GGImTFu2c9RAmjon+fE73T ynX8k8y9YqZCHCtxPniAsJ91tmEyhu3tky5HRsfkKccD0RTTcT90B8qggDYcmbd7GNK7 hMiwQzvQ9erBf8R/qTv2jIibeD7RUNNQVLU3XGDp+JYgT8bQrV5/kQ0XOzEwaVLc+37h +/3SIGzSO9FqW+64oeHNBocCVMs2lpCYTghS4x1R3l7UBayRNxy140YYLWCz0iwM12D5 Jg87ICBspXMn7hCvEOV3SMEQv5c/xx+ETsHKU/YO3RTLPneohrtre2lm7aEqFl8h6zSz 0o2g== X-Gm-Message-State: APjAAAW52wafS+m9YW9lJTqXWF6YxaoKi6Hn4hpYFab6nZaVst4xEId6 hS7Rhl7IJaGSId3fCCrWv7EDCA== X-Received: by 2002:a05:620a:1597:: with SMTP id d23mr25900044qkk.226.1553619243524; Tue, 26 Mar 2019 09:54:03 -0700 (PDT) Received: from redhat.com ([66.187.232.66]) by smtp.gmail.com with ESMTPSA id o68sm10908092qkc.89.2019.03.26.09.54.01 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 26 Mar 2019 09:54:02 -0700 (PDT) Date: Tue, 26 Mar 2019 12:53:59 -0400 From: "Michael S. Tsirkin" To: Christoph Hellwig Cc: Jason Wang , Thiago Jung Bauermann , virtualization@lists.linux-foundation.org, linuxppc-dev@lists.ozlabs.org, iommu@lists.linux-foundation.org, linux-kernel@vger.kernel.org, David Gibson , Alexey Kardashevskiy , Paul Mackerras , Benjamin Herrenschmidt , Ram Pai , Jean-Philippe Brucker , eric.auger@redhat.com, joro@8bytes.org, tnowicki@caviumnetworks.com, kevin.tian@intel.com, Lorenzo.Pieralisi@arm.com, bharat.bhushan@nxp.com, Will.Deacon@arm.com, Robin.Murphy@arm.com, Marc.Zyngier@arm.com Subject: Re: [RFC PATCH] virtio_ring: Use DMA API if guest memory is encrypted Message-ID: <20190325084348-mutt-send-email-mst@kernel.org> References: <87zhrj8kcp.fsf@morokweng.localdomain> <87womn8inf.fsf@morokweng.localdomain> <20190129134750-mutt-send-email-mst@kernel.org> <6c68f7f7-1b28-6eba-9b8b-2c32efac9701@redhat.com> <20190129213137-mutt-send-email-mst@kernel.org> <20190130074427.GA29516@lst.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190130074427.GA29516@lst.de> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jan 30, 2019 at 08:44:27AM +0100, Christoph Hellwig wrote: > On Tue, Jan 29, 2019 at 09:36:08PM -0500, Michael S. Tsirkin wrote: > > This has been discussed ad nauseum. virtio is all about compatibility. > > Losing a couple of lines of code isn't worth breaking working setups. > > People that want "just use DMA API no tricks" now have the option. > > Setting a flag in a feature bit map is literally a single line > > of code in the hypervisor. So stop pushing for breaking working > > legacy setups and just fix it in the right place. > > I agree with the legacy aspect. What I am missing is an extremely > strong wording that says you SHOULD always set this flag for new > hosts, including an explanation why. So as far as power is concerned, IIUC the issue they are struggling with is that some platforms do not support pass-through mode in the emulated IOMMU. Disabling PLATFORM_ACCESS is so far a way around that, unfortunately just for virtio devices. I would like virtio-iommu to be able to address that need as well. -- MST