WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] [PATCH] xen: do not unmap grant status on suspend when using

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] [PATCH] xen: do not unmap grant status on suspend when using v1 grant tables
From: Ian Campbell <ian.campbell@xxxxxxxxxx>
Date: Wed, 25 Nov 2009 14:45:27 +0000
Cc: Jeremy Fitzhardinge <jeremy.fitzhardinge@xxxxxxxxxx>, Ian Campbell <ian.campbell@xxxxxxxxxx>, Steven Smith <steven.smith@xxxxxxxxxx>
Delivery-date: Wed, 25 Nov 2009 06:45:49 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
grstatus is only used/initialised for v2 grant tables.

Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxx>
Cc: Steven Smith <steven.smith@xxxxxxxxxx>
Cc: Jeremy Fitzhardinge <jeremy.fitzhardinge@xxxxxxxxxx>
---
 drivers/xen/grant-table.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/drivers/xen/grant-table.c b/drivers/xen/grant-table.c
index 2240adf..068cbd6 100644
--- a/drivers/xen/grant-table.c
+++ b/drivers/xen/grant-table.c
@@ -898,7 +898,8 @@ int gnttab_resume(void)
 int gnttab_suspend(void)
 {
        arch_gnttab_unmap(shared.raw, nr_grant_frames);
-       arch_gnttab_unmap(grstatus, nr_status_frames(nr_grant_frames));
+       if (grant_table_version > 1)
+               arch_gnttab_unmap(grstatus, nr_status_frames(nr_grant_frames));
        return 0;
 }
 
-- 
1.5.6.5


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-devel] [PATCH] xen: do not unmap grant status on suspend when using v1 grant tables, Ian Campbell <=