From patchwork Thu Dec 20 15:21:17 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Julien Grall X-Patchwork-Id: 10739051 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id C62F713BF for ; Thu, 20 Dec 2018 15:21:42 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id B6FE428CFB for ; Thu, 20 Dec 2018 15:21:42 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id B31F428D3E; Thu, 20 Dec 2018 15:21:42 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id DF1E128D29 for ; Thu, 20 Dec 2018 15:21:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2387750AbeLTPVj (ORCPT ); Thu, 20 Dec 2018 10:21:39 -0500 Received: from usa-sjc-mx-foss1.foss.arm.com ([217.140.101.70]:57830 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729693AbeLTPVj (ORCPT ); Thu, 20 Dec 2018 10:21:39 -0500 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id B1C3BEBD; Thu, 20 Dec 2018 07:21:38 -0800 (PST) Received: from e108454-lin.cambridge.arm.com (e108454-lin.cambridge.arm.com [10.1.196.50]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 9EE9E3F5C0; Thu, 20 Dec 2018 07:21:37 -0800 (PST) From: Julien Grall To: kvm@vger.kernel.org Cc: suzuki.poulose@arm.com, marc.zyngier@arm.com, will.deacon@arm.com, Julien Grall Subject: [PATCH kvmtool v3 0/9] arm: Allow the user to specify where the RAM is placed in the memory Date: Thu, 20 Dec 2018 15:21:17 +0000 Message-Id: <20181220152126.18741-1-julien.grall@arm.com> X-Mailer: git-send-email 2.11.0 Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Hi all, At the moment, a user is only able to specify the amount of RAM used by the guest. Where the RAM will live is left to the software and hardcoded. It could be useful for testing purpose to move the RAM in different place. This series adds the possibility for the user to specify multiple RAM region. The option -m/--mem is extended to specify the address using the following format: @. The option needs to be repeated as many times as the number of RAM region in the guest layout. For instance, if you want 512MB at 3GB and 512MB 4GB it would look like: -m 512@0xc0000000 -m 512@0x100000000 Note that the memory layout is not yet fully configurable by the user, so the MMIO region is still living below 2GB. This means RAM cannot live in the region 0-2GB. This could be changed in the future. Cheers, Julien Grall (7): kvm__arch_init: Don't pass hugetlbfs_path and ram_size in parameter virtio/scsi: Allow to use multiple banks Fold kvm__init_ram call in kvm__arch_init arm: Add an helper to sanitize KVM configuration arm: Move anything related to RAM initialization in kvm__init_ram Allow the user to specify where the RAM is placed in the memory arm: Add support for multi memory regions Suzuki K Poulose (2): arm: Allow use of hugepage with 16K pagesize host kvmtool: Allow standard size specifiers for memory bank arm/aarch32/include/kvm/kvm-arch.h | 2 +- arm/aarch64/include/kvm/kvm-arch.h | 4 +- arm/fdt.c | 19 +++-- arm/include/arm-common/kvm-arch.h | 24 ++++-- arm/kvm.c | 160 ++++++++++++++++++++++++++++++------- builtin-run.c | 129 +++++++++++++++++++++++++++--- include/kvm/kvm-config.h | 16 +++- include/kvm/kvm.h | 24 ++++-- kvm.c | 8 +- mips/kvm.c | 47 ++++++----- powerpc/kvm.c | 33 +++++--- virtio/scsi.c | 21 +++-- x86/bios.c | 8 +- x86/kvm.c | 54 ++++++++----- 14 files changed, 417 insertions(+), 132 deletions(-)