xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: George Dunlap <george.dunlap@eu.citrix.com>
To: xen-devel@lists.xensource.com
Cc: george.dunlap@eu.citrix.com
Subject: [PATCH 1 of 4] xen,pod: Cosmetic code motion
Date: Wed, 27 Jun 2012 17:57:28 +0100	[thread overview]
Message-ID: <b4e1fec1c98f6cbad666.1340816248@elijah> (raw)
In-Reply-To: <patchbomb.1340816247@elijah>

# HG changeset patch
# User George Dunlap <george.dunlap@eu.citrix.com>
# Date 1340815810 -3600
# Node ID b4e1fec1c98f6cbad666a972f473854518c25500
# Parent  b91ef972029ddaa110af6463171715ab9070c9d8
xen,pod: Cosmetic code motion

No point in doing the assignment if we're just going to crash anyway.

Signed-off-by: George Dunlap <george.dunlap@eu.citrix.com>

diff --git a/xen/arch/x86/mm/p2m-pod.c b/xen/arch/x86/mm/p2m-pod.c
--- a/xen/arch/x86/mm/p2m-pod.c
+++ b/xen/arch/x86/mm/p2m-pod.c
@@ -1022,13 +1022,13 @@ p2m_pod_demand_populate(struct p2m_domai
             p2m_pod_emergency_sweep(p2m);
     }
 
+    if ( p2m->pod.count == 0 )
+        goto out_of_memory;
+
     /* Keep track of the highest gfn demand-populated by a guest fault */
     if ( gfn > p2m->pod.max_guest )
         p2m->pod.max_guest = gfn;
 
-    if ( p2m->pod.count == 0 )
-        goto out_of_memory;
-
     /* Get a page f/ the cache.  A NULL return value indicates that the
      * 2-meg range should be marked singleton PoD, and retried */
     if ( (p = p2m_pod_cache_get(p2m, order)) == NULL )

  reply	other threads:[~2012-06-27 16:57 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-27 16:57 [PATCH 0 of 4] xen, pod: Populate-on-demand reclaim improvements George Dunlap
2012-06-27 16:57 ` George Dunlap [this message]
2012-06-28 12:04   ` [PATCH 1 of 4] xen,pod: Cosmetic code motion Tim Deegan
2012-06-27 16:57 ` [PATCH 2 of 4] xen, pod: Zero-check recently populated pages (checklast) George Dunlap
2012-06-28 12:48   ` Tim Deegan
2012-06-27 16:57 ` [PATCH 3 of 4] xen, pod: Only sweep in an emergency, and only for 4k pages George Dunlap
2012-06-28 12:48   ` Tim Deegan
2012-06-27 16:57 ` [PATCH 4 of 4] xen, pod: Try to reclaim superpages when ballooning down George Dunlap
2012-06-28 12:45   ` Tim Deegan
2012-06-28 12:53 ` [PATCH 0 of 4] xen, pod: Populate-on-demand reclaim improvements Tim Deegan
2012-06-28 13:04   ` George Dunlap
2012-06-28 13:51   ` George Dunlap

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=b4e1fec1c98f6cbad666.1340816248@elijah \
    --to=george.dunlap@eu.citrix.com \
    --cc=xen-devel@lists.xensource.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).