From patchwork Mon Sep 1 19:56:59 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Julien Grall X-Patchwork-Id: 36424 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-yh0-f70.google.com (mail-yh0-f70.google.com [209.85.213.70]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 299DC2032B for ; Mon, 1 Sep 2014 22:39:12 +0000 (UTC) Received: by mail-yh0-f70.google.com with SMTP id b6sf23028118yha.1 for ; Mon, 01 Sep 2014 15:39:12 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:message-id:date:from:user-agent :mime-version:to:references:in-reply-to:cc:subject:precedence :list-id:list-unsubscribe:list-post:list-help:list-subscribe:sender :errors-to:x-original-sender:x-original-authentication-results :mailing-list:list-archive:content-type:content-transfer-encoding; bh=7Bif3FFmtGYX2K8T6mJV9hFjHmkwJpPrhp7DGUN4xXs=; b=Nn9lO1kNXqwCUmcTyc3jAPL1AkKH06JxXQKRHEZ/6yLkiOovKG7zZWM3wsVnOry4vb /pDnv54Djc8E4LEa5ugqr8kis+rCUEvxqXdXzYJJzjS12B80ViLtEch86D8+UsM1wW+B anLZKEVBAQPpjnsYPpfKHPMw6oEd+WI7bkEzqv7/YqPJ7TGSWpwwCZsMBl0zUVxVozhk 5gEgKad9IWPiLOgozR4P8bZaiZox10cOvmgaj+OAZHmrZe334ttr1vBC2IFM5BQJhtV4 8Ic7rPCs4bdlGUx+O/4HiGFyjvr0IuouqdVTjXi7K46BPnkrUXKzXmJJJjL+Q9nkTUF5 q+3w== X-Gm-Message-State: ALoCoQnX+2U3Nw7hwj3LlKOyuc4GrwJ01ihgK3OFkYbOqQ79WOuPHvhmY5jJVavu1tad1gOFYAr5 X-Received: by 10.236.36.99 with SMTP id v63mr10573402yha.2.1409611151981; Mon, 01 Sep 2014 15:39:11 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.102.23 with SMTP id v23ls2089491qge.51.gmail; Mon, 01 Sep 2014 15:39:11 -0700 (PDT) X-Received: by 10.220.132.207 with SMTP id c15mr27842732vct.12.1409611151909; Mon, 01 Sep 2014 15:39:11 -0700 (PDT) Received: from mail-vc0-f170.google.com (mail-vc0-f170.google.com [209.85.220.170]) by mx.google.com with ESMTPS id ve2si1451846vcb.94.2014.09.01.15.39.11 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 01 Sep 2014 15:39:11 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.170 as permitted sender) client-ip=209.85.220.170; Received: by mail-vc0-f170.google.com with SMTP id la4so6112941vcb.15 for ; Mon, 01 Sep 2014 15:39:11 -0700 (PDT) X-Received: by 10.52.162.74 with SMTP id xy10mr2047303vdb.51.1409611151828; Mon, 01 Sep 2014 15:39:11 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.221.45.67 with SMTP id uj3csp443369vcb; Mon, 1 Sep 2014 15:39:11 -0700 (PDT) X-Received: by 10.221.64.142 with SMTP id xi14mr2949602vcb.31.1409611151145; Mon, 01 Sep 2014 15:39:11 -0700 (PDT) Received: from lists.xen.org (lists.xen.org. [50.57.142.19]) by mx.google.com with ESMTPS id wv12si1476723vcb.21.2014.09.01.15.39.07 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Mon, 01 Sep 2014 15:39:11 -0700 (PDT) Received-SPF: none (google.com: xen-devel-bounces@lists.xen.org does not designate permitted sender hosts) client-ip=50.57.142.19; Received: from localhost ([127.0.0.1] helo=lists.xen.org) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1XOaDT-00085H-4A; Mon, 01 Sep 2014 22:36:51 +0000 Received: from mail6.bemta14.messagelabs.com ([193.109.254.103]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1XOaDS-00085C-DF for xen-devel@lists.xen.org; Mon, 01 Sep 2014 22:36:50 +0000 Received: from [193.109.254.147:40131] by server-15.bemta-14.messagelabs.com id 48/DB-30948-105F4045; Mon, 01 Sep 2014 22:36:49 +0000 X-Env-Sender: julien.grall@linaro.org X-Msg-Ref: server-2.tower-27.messagelabs.com!1409611007!12807268!1 X-Originating-IP: [209.85.218.46] X-SpamReason: No, hits=0.0 required=7.0 tests= X-StarScan-Received: X-StarScan-Version: 6.11.3; banners=-,-,- X-VirusChecked: Checked Received: (qmail 8538 invoked from network); 1 Sep 2014 22:36:48 -0000 Received: from mail-oi0-f46.google.com (HELO mail-oi0-f46.google.com) (209.85.218.46) by server-2.tower-27.messagelabs.com with RC4-SHA encrypted SMTP; 1 Sep 2014 22:36:48 -0000 Received: by mail-oi0-f46.google.com with SMTP id h136so3851782oig.19 for ; Mon, 01 Sep 2014 15:36:47 -0700 (PDT) X-Received: by 10.60.62.234 with SMTP id b10mr28725785oes.3.1409611007324; Mon, 01 Sep 2014 15:36:47 -0700 (PDT) Received: from [10.20.98.51] (ip-64-134-145-211.public.wayport.net. [64.134.145.211]) by mx.google.com with ESMTPSA id fg2sm2161062obb.16.2014.09.01.15.36.44 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 01 Sep 2014 15:36:47 -0700 (PDT) Message-ID: <5404CF8B.8030603@linaro.org> Date: Mon, 01 Sep 2014 15:56:59 -0400 From: Julien Grall User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.7.0 MIME-Version: 1.0 To: Tamas K Lengyel , xen-devel@lists.xen.org References: <1409581329-2607-1-git-send-email-tklengyel@sec.in.tum.de> In-Reply-To: <1409581329-2607-1-git-send-email-tklengyel@sec.in.tum.de> Cc: ian.campbell@citrix.com, tim@xen.org, ian.jackson@eu.citrix.com, stefano.stabellini@citrix.com, andres@lagarcavilla.org, jbeulich@suse.com, dgdegra@tycho.nsa.gov Subject: Re: [Xen-devel] [PATCH v3 00/15] Mem_event and mem_access for ARM X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Post: , List-Help: , List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: julien.grall@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.170 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Archive: Hello Tamas On 01/09/14 10:21, Tamas K Lengyel wrote: > The ARM virtualization extension provides 2-stage paging, a similar mechanisms > to Intel's EPT, which can be used to trace the memory accesses performed by > the guest systems. This series moves the mem_access and mem_event codebase > into Xen common, performs some code cleanup and architecture specific division > of components, then sets up the necessary infrastructure in the ARM code > to deliver the event on R/W/X traps. Finally, we turn on the compilation of > mem_access and mem_event on ARM and perform the necessary changes to the > tools side. > > This version of the series has been fully tested and is functional on an > Arndale board. domain_get_maximum_gpfn used in common code is defined as -ENOSYS. I've sent a patch a month ago on the mailing list about it (see patch below). Ian: Can you reconsider to apply the patch? (I will also reply to the thread). FYI, I have a patch to fix xc_dom_gnttab_hvm_seed in libxc. I will try to send it next week. Regards, ==================================================================== commit 7aa592b7a6f357b0003cd523e446d9d91dc96730 Author: Julien Grall Date: Mon Jun 30 17:21:13 2014 +0100 xen/arm: Implement domain_get_maximum_gpfn The function domain_get_maximum_gpfn is returning the maximum gpfn ever mapped in the guest. We can use d->arch.p2m.max_mapped_gfn for this purpose. Signed-off-by: Julien Grall diff --git a/xen/arch/arm/mm.c b/xen/arch/arm/mm.c index 0a243b0..e4a1e5e 100644 --- a/xen/arch/arm/mm.c +++ b/xen/arch/arm/mm.c @@ -954,7 +954,7 @@ int page_is_ram_type(unsigned long mfn, unsigned long mem_type) unsigned long domain_get_maximum_gpfn(struct domain *d) { - return -ENOSYS; + return d->arch.p2m.max_mapped_gfn; } void share_xen_page_with_guest(struct page_info *page,