Received: by 2002:a05:6a10:1d13:0:0:0:0 with SMTP id pp19csp1131093pxb; Fri, 27 Aug 2021 01:47:39 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwbCW2sLRIwsuBsc1NTww15mrB6JunIIGwUHUsElVKIU3QqRabhTPTD1ytRZ4JgG+uxjkaA X-Received: by 2002:a92:a008:: with SMTP id e8mr5632507ili.187.1630054059687; Fri, 27 Aug 2021 01:47:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1630054059; cv=none; d=google.com; s=arc-20160816; b=fBvxTJeEhF2cJqaXvXe2LWoSbCd+balPnBKFgY1qIU3cbDbGQyx6KSPFeeutv0Wd6B dTxrbmxISGZ7U6XJ/MbeTAQvYpVeS80J7Zjl8tEA6TWAKUE2bL1+S+MLAPKf2yKaXUAC QEgYYa06GTh1XOSj4yyKK25V7wX+lBgqF7Gh9BbTizNAqanqBO3KJoVI4ve3XXwSkvQy Y5m1daQXvUu73pcDAgba/HmuK2/gBCS3x2pKUfJ3xthbiQaBU/f8RxyK+dxvCHBYEt0b 8mypqFCTvA/cOHUkili1MQTgI5rLBhoq0vXVNGGKq393pCENXtYuPTxHqR09QDAsnTNE hRMQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=IgpKkMLtQwfzkH2g74jIspVOvk02ulKTrkKTTz65czo=; b=oRHAnWDaqs47cqgzRogq9A+szNpDeUgdUpHF+H0yubVPYleOAk0Lc7bH5E7a1Bk2Cj pGm19xvkVdvXE9sUamGHwCSGnxsXQjYq+y5WjdlhVMBjFp+17YihJ7r/tuKYJX1DljbW z33mqlrXGZdH3Ldo1cmOZl0kR302PxkVniB40zvmDR0sYTiXOj8EDcvzDCDGuSlnt0A8 47YKFBfisPe7vOtDeHtMBMcDqbU/8E7Dc7bMpIEmN2yDq7Y6c3jeCwbHtLtlzdPasf5I KrUl79qOaoDKs6pmRaea7cYrW6kqQT5jifJqgCoOv6F6yxq387+l4rjLA256O12o/cbo XfDw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=bxXJAAvj; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id k2si5990229ilu.143.2021.08.27.01.47.27; Fri, 27 Aug 2021 01:47:39 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=bxXJAAvj; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244581AbhH0Iq2 (ORCPT + 99 others); Fri, 27 Aug 2021 04:46:28 -0400 Received: from mail.kernel.org ([198.145.29.99]:46930 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244548AbhH0Iq1 (ORCPT ); Fri, 27 Aug 2021 04:46:27 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id C124160FDA; Fri, 27 Aug 2021 08:45:36 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1630053939; bh=MiP2UIQ4KnpSOIPJ77kWFfno3nhfZ/L/F6vYRuSNwRw=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=bxXJAAvjzhPC2NNJj66cW5aAzXrPDUGTV3u+iGjWQOSCrPRbM1meJljy3Vn7wWqCl bfZmjsM7hOImDpgq7UuzlTfUFVuLGqb5OWChTm4Wi0yrT4NfDs2hv7blbAiQT5zX3Y L1seQXJESKdPOHcS4bkNPaZVTzdwMTT+sLFiQrvs= Date: Fri, 27 Aug 2021 10:45:32 +0200 From: Greg KH To: Li Fei1 Cc: linux-kernel@vger.kernel.org, yu1.wang@intel.com, shuox.liu@gmail.com Subject: Re: [PATCH v2 1/3] virt: acrn: Introduce interfaces for MMIO device passthrough Message-ID: References: <20210825090142.4418-1-fei1.li@intel.com> <20210825090142.4418-2-fei1.li@intel.com> <20210826013838.GA7915@louislifei-OptiPlex-7050> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210826013838.GA7915@louislifei-OptiPlex-7050> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Aug 26, 2021 at 09:38:38AM +0800, Li Fei1 wrote: > On Wed, Aug 25, 2021 at 10:43:29PM +0200, Greg KH wrote: > > On Wed, Aug 25, 2021 at 05:01:40PM +0800, Fei Li wrote: > > > From: Shuo Liu > > > > > > MMIO device passthrough enables an OS in a virtual machine to directly > > > access a MMIO device in the host. It promises almost the native > > > performance, which is required in performance-critical scenarios of > > > ACRN. > > > > > > HSM provides the following ioctls: > > > - Assign - ACRN_IOCTL_ASSIGN_MMIODEV > > > Pass data struct acrn_mmiodev from userspace to the hypervisor, and > > > inform the hypervisor to assign a MMIO device to a User VM. > > > > > > - De-assign - ACRN_IOCTL_DEASSIGN_PCIDEV > > > Pass data struct acrn_mmiodev from userspace to the hypervisor, and > > > inform the hypervisor to de-assign a MMIO device from a User VM. > > > > > > Signed-off-by: Shuo Liu > > > Signed-off-by: Fei Li > > > > Where is the userspace code that uses this new api? > > Hi Greg > > An ACRN userspace application (like QEMU) would uses these new apis in > https://github.com/projectacrn/acrn-hypervisor/blob/master/devicemodel/core/vmmapi.c#L562 > and > https://github.com/projectacrn/acrn-hypervisor/blob/master/devicemodel/core/vmmapi.c#L568 Please provide links in all of these patches when you resend them, to the userspace code as well, so that we know how it all works together. thanks, greg k-h