From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:55467) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QAqnc-0002jJ-8N for qemu-devel@nongnu.org; Fri, 15 Apr 2011 17:43:33 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QAqnb-0003y4-Cd for qemu-devel@nongnu.org; Fri, 15 Apr 2011 17:43:32 -0400 Received: from mail-gy0-f173.google.com ([209.85.160.173]:58420) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QAqnb-0003xu-A3 for qemu-devel@nongnu.org; Fri, 15 Apr 2011 17:43:31 -0400 Received: by gyg4 with SMTP id 4so1248654gyg.4 for ; Fri, 15 Apr 2011 14:43:30 -0700 (PDT) Message-ID: <4DA8BC01.2030705@codemonkey.ws> Date: Fri, 15 Apr 2011 16:43:29 -0500 From: Anthony Liguori MIME-Version: 1.0 References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] Para-virtualized ram-based filesystem? List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Ritchie, Stuart" Cc: "qemu-devel@nongnu.org" On 04/15/2011 04:09 PM, Ritchie, Stuart wrote: > Hi all, > > Has anyone looked at implementing a para-virtualized ram-based filesystem > for qemu? Or any similar dynamic memory mapping techniques for running > guests? > > What I had in mind would be a convenient, zero-copy mechanism for sharing > dynamically allocated, memory mapped files between host and guests. > > The host provides a primary memory-mapped file system (ramfs, tmpfs, > hugetlbfs, etc), and the guest kernel and qemu use this host fs to provide > the illusion to guest applications that the filesystem is local. > > The guest kernel contains a new filesystem, say call it vramfs, > implementing the various VFS handlers for a para-virt filesystem. These > handlers call out to qemu, which in turn emulates them by invoking the > required host system calls. You can do this with ivshmem today. You give it a path to a shared memory file, and then there's a path in sysfs that you can mmap() in userspace in the guest. Regards, Anthony Liguori > Handling mmap/munmap is tricky -- but this is where the magic is. There > does seem to be some qemu infrastructure to dynamically map memory into a > running system, though it may be designed for different requirements > (e.g., device memory). > > I currently have the resources to work on this and am looking forward to > contributing my work back to the community. I would appreciate any help > or pointers on this effort. > > Cheers, > --Stuart > > > ============================================================ > The information contained in this message may be privileged > and confidential and protected from disclosure. If the reader > of this message is not the intended recipient, or an employee > or agent responsible for delivering this message to the > intended recipient, you are hereby notified that any reproduction, > dissemination or distribution of this communication is strictly > prohibited. If you have received this communication in error, > please notify us immediately by replying to the message and > deleting it from your computer. Thank you. Tellabs > ============================================================ > >