Received: by 10.223.176.5 with SMTP id f5csp65852wra; Tue, 6 Feb 2018 17:18:30 -0800 (PST) X-Google-Smtp-Source: AH8x227Gr4COhap/F3ZC8HmuVQDpVP91LCKzcoLar4Cb+aKRVWw8286Ga44ssljnzE24ic8/YPtE X-Received: by 2002:a17:902:7486:: with SMTP id h6-v6mr4288810pll.236.1517966310888; Tue, 06 Feb 2018 17:18:30 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1517966310; cv=none; d=google.com; s=arc-20160816; b=aTDhDE+Xl6GWTV45zGBEWir9LZSoLPudjP/EZ9xX60Us8rduvOv0DqqUbErew/nDhN 3/tIIY0W8lyMUzXY4sljtE5Q63fKq27fyf4ZNZi7TsGIdhAy6TAswELwi8TfNYBXG5K2 cLYkKTKSG+fl3cRIgm94ez3rttz4pB9OIIH6zzHgMCWKuAYGMz3UhkOfsJbzYUySFOWT KPWzKW5SzC5lznElMjg+CxhZi31x9xbA5sgDXbhhfXTa5fVmXwc0FeizO34g1fx7Ly7u FdjSInGHbEE0oXB9h5QQEn1k0LWQ/udHSDZPilbgQtijWkg5l0oJrcyylwgOtuXM5gwJ iE+w== 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 :arc-authentication-results; bh=EvJojNqMqVHnfh89qmgUmER7ZVvBP/a8jJ6RwHEePN8=; b=tGLSQLkjeYosaXj3jQHXT9qL/5fiWJi4CUboDL85tyG8HgNsQZBy9YVdGnuBr/fr3d LMugLF/6G/yB7+3uFnNUrsymGhAYYwtY7r02PmU1baNOPI/OWkQZ8YimwzyilRRE8NEm uB4UIT2fC40S5auDalT4JxumNxDp+d0W+ZYkvcUsrqT0qNeRlWMbl/xH/+CrZmXudP+/ BI065z+/oAcFAiBit61HtMtHoQJqRCaf9BESlZ85t/d2XZnQAwKX2f5StRGVh/glDRas CHLlYINww1QAeEpVqTH6WXRPTpfGOMIRQ6WUJhGa/dhlEhNWMYbZkHKjaSe/xTJxNBMO MxvQ== 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 k185si210011pgd.284.2018.02.06.17.18.02; Tue, 06 Feb 2018 17:18:30 -0800 (PST) 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 S1754311AbeBGBRG (ORCPT + 99 others); Tue, 6 Feb 2018 20:17:06 -0500 Received: from mx3-rdu2.redhat.com ([66.187.233.73]:54894 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1754298AbeBGBRF (ORCPT ); Tue, 6 Feb 2018 20:17:05 -0500 X-Greylist: delayed 464 seconds by postgrey-1.27 at vger.kernel.org; Tue, 06 Feb 2018 20:17:05 EST Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.rdu2.redhat.com [10.11.54.4]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id CE9B4E44B5; Wed, 7 Feb 2018 01:09:20 +0000 (UTC) Received: from redhat.com (ovpn-125-114.rdu2.redhat.com [10.10.125.114]) by smtp.corp.redhat.com (Postfix) with SMTP id B88BB202660C; Wed, 7 Feb 2018 01:09:19 +0000 (UTC) Date: Wed, 7 Feb 2018 03:09:19 +0200 From: "Michael S. Tsirkin" To: Gerd Hoffmann Cc: Tomeu Vizoso , linux-kernel@vger.kernel.org, Zach Reizner , kernel@collabora.com, dri-devel@lists.freedesktop.org, virtualization@lists.linux-foundation.org, David Airlie , Jason Wang , Stefan Hajnoczi Subject: Re: [PATCH v3 1/2] drm/virtio: Add window server support Message-ID: <20180207030636-mutt-send-email-mst@kernel.org> References: <20180126135803.29781-1-tomeu.vizoso@collabora.com> <20180126135803.29781-2-tomeu.vizoso@collabora.com> <20180201163623.5cs2ysykg5wgulf4@sirius.home.kraxel.org> <49785e0d-936a-c3b4-62dd-aafc7083a942@collabora.com> <20180205122017.4vb5nlpodkq2uhxa@sirius.home.kraxel.org> <20180205160322.sntv5uoqp5o7flnh@sirius.home.kraxel.org> <20180206142302.vdjyqmnoypydci4t@sirius.home.kraxel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180206142302.vdjyqmnoypydci4t@sirius.home.kraxel.org> X-Scanned-By: MIMEDefang 2.78 on 10.11.54.4 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.1]); Wed, 07 Feb 2018 01:09:20 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.1]); Wed, 07 Feb 2018 01:09:20 +0000 (UTC) for IP:'10.11.54.4' DOMAIN:'int-mx04.intmail.prod.int.rdu2.redhat.com' HELO:'smtp.corp.redhat.com' FROM:'mst@redhat.com' RCPT:'' Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Feb 06, 2018 at 03:23:02PM +0100, Gerd Hoffmann wrote: > > Creation of shareable buffer by guest > > ------------------------------------------------- > > > > 1. Client requests virtio driver to create a buffer suitable for sharing > > with host (DRM_VIRTGPU_RESOURCE_CREATE) > > client or guest proxy? > > > 4. QEMU maps that buffer to the guest's address space > > (KVM_SET_USER_MEMORY_REGION), passes the guest PFN to the virtio driver > > That part is problematic. The host can't simply allocate something in > the physical address space, because most physical address space > management is done by the guest. All pci bars are mapped by the guest > firmware for example (or by the guest OS in case of hotplug). > > > 4. QEMU pops data+buffers from the virtqueue, looks up shmem FD for each > > resource, sends data + FDs to the compositor with SCM_RIGHTS If you squint hard, this sounds a bit like a use-case for vhost-user-gpu, does it not? > BTW: Is there a 1:1 relationship between buffers and shmem blocks? Or > does the wayland protocol allow for offsets in buffer meta data, so you > can place multiple buffers in a single shmem block? > > cheers, > Gerd