From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753196AbcGDHiZ (ORCPT ); Mon, 4 Jul 2016 03:38:25 -0400 Received: from mail-wm0-f67.google.com ([74.125.82.67]:35916 "EHLO mail-wm0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752680AbcGDHiX (ORCPT ); Mon, 4 Jul 2016 03:38:23 -0400 Subject: Re: [PATCH 0/2] KVM: MMU: support VMAs that got remap_pfn_range-ed To: Xiao Guangrong , linux-kernel@vger.kernel.org, kvm@vger.kernel.org References: <1467291711-3230-1-git-send-email-pbonzini@redhat.com> <577A049A.4000402@linux.intel.com> Cc: Kirti Wankhede , Neo Jia , Andrea Arcangeli , =?UTF-8?B?UmFkaW0gS3LEjW3DocWZ?= From: Paolo Bonzini Message-ID: Date: Mon, 4 Jul 2016 09:38:15 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.1.1 MIME-Version: 1.0 In-Reply-To: <577A049A.4000402@linux.intel.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 04/07/2016 08:39, Xiao Guangrong wrote: > Why the memory mapped by this mmap() is not a portion of MMIO from > underlayer physical device? If it is a valid system memory, is this > interface > really needed to implemented in vfio? (you at least need to set VM_MIXEDMAP > if it mixed system memory with MMIO) The KVM code does not care if VM_MIXEDMAP is set or not, it works in either case. Paolo > IIUC, the kernel assumes that VM_PFNMAP is a continuous memory, e.g, like > current KVM and vaddr_get_pfn() in vfio, but it seems nvdia's patchset > breaks this semantic as ops->validate_map_request() can adjust the physical > address arbitrarily. (again, the name 'validate' should be changed to match > the thing as it is really doing) > > > -- > To unsubscribe from this list: send the line "unsubscribe kvm" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html >