From patchwork Tue Jun 14 17:02:00 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Takuya Yoshikawa X-Patchwork-Id: 879562 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter2.kernel.org (8.14.4/8.14.4) with ESMTP id p5EH2Aaa028833 for ; Tue, 14 Jun 2011 17:02:10 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751788Ab1FNRCG (ORCPT ); Tue, 14 Jun 2011 13:02:06 -0400 Received: from mail-pw0-f46.google.com ([209.85.160.46]:58556 "EHLO mail-pw0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751511Ab1FNRCF (ORCPT ); Tue, 14 Jun 2011 13:02:05 -0400 Received: by pwi15 with SMTP id 15so2719152pwi.19 for ; Tue, 14 Jun 2011 10:02:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:date:from:to:cc:subject:message-id:in-reply-to :references:x-mailer:mime-version:content-type :content-transfer-encoding; bh=A3nQA2YWsgRl7soshEYnyMpBd3WJNrmRBezMR7vtPDA=; b=sFXllCbSfyGPmOM25nGu2O/XGhrn7akRxyp4XjFhE2c2VY1/uGZjhuCSkM/KZzc/lA EiG6kZX8hb8Mf046+MYzq9ljmeebohOHZJtW8aE1XY5sOheuLrHDQfOSsiWJ+P1mOARI DOL4GeR5+9noBeZcdv4ZhR94iDwPCGarDlQ9c= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=date:from:to:cc:subject:message-id:in-reply-to:references:x-mailer :mime-version:content-type:content-transfer-encoding; b=QvHdGTVDAaZUp2/UmxxUopD4ODZk4ioVQJpLkUYllXmuT/bgUV/ePvbf8ZXmFiVrpQ 4ezPoFXLYxUcQdEDcKEjVTTccCnjmWkN1/0LmG74Uejlpgwlmvg4lb+umpZnPQUpUidX AAtKsct2e1q2knloFv49DWgPqIeftsMO+T1TQ= Received: by 10.68.6.5 with SMTP id w5mr3030130pbw.15.1308070924742; Tue, 14 Jun 2011 10:02:04 -0700 (PDT) Received: from amd (x096101.dynamic.ppp.asahi-net.or.jp [122.249.96.101]) by mx.google.com with ESMTPS id p5sm4623936pbd.44.2011.06.14.10.02.02 (version=SSLv3 cipher=OTHER); Tue, 14 Jun 2011 10:02:03 -0700 (PDT) Date: Wed, 15 Jun 2011 02:02:00 +0900 From: Takuya Yoshikawa To: avi@redhat.com, mtosatti@redhat.com Cc: kvm@vger.kernel.org, yoshikawa.takuya@oss.ntt.co.jp, mingo@elte.hu Subject: [PATCH 2/3] KVM: MMU: Rename the walk label in walk_addr_generic() Message-Id: <20110615020200.8eccaf54.takuya.yoshikawa@gmail.com> In-Reply-To: <20110615020003.15722a29.takuya.yoshikawa@gmail.com> References: <20110615020003.15722a29.takuya.yoshikawa@gmail.com> X-Mailer: Sylpheed 3.1.0 (GTK+ 2.24.4; x86_64-pc-linux-gnu) Mime-Version: 1.0 Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter2.kernel.org [140.211.167.43]); Tue, 14 Jun 2011 17:02:10 +0000 (UTC) From: Takuya Yoshikawa The current name does not explain the meaning well. So give it a better name "retry_walk" to show that we are retrying the walk again. This was suggested by Ingo Molnar. Cc: Ingo Molnar Signed-off-by: Takuya Yoshikawa --- arch/x86/kvm/paging_tmpl.h | 6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/arch/x86/kvm/paging_tmpl.h b/arch/x86/kvm/paging_tmpl.h index 137aa45..92fe275 100644 --- a/arch/x86/kvm/paging_tmpl.h +++ b/arch/x86/kvm/paging_tmpl.h @@ -134,7 +134,7 @@ static int FNAME(walk_addr_generic)(struct guest_walker *walker, trace_kvm_mmu_pagetable_walk(addr, write_fault, user_fault, fetch_fault); -walk: +retry_walk: eperm = false; walker->level = mmu->root_level; pte = mmu->get_cr3(vcpu); @@ -222,7 +222,7 @@ walk: errcode |= PFERR_PRESENT_MASK; goto error; } else if (ret) - goto walk; + goto retry_walk; mark_page_dirty(vcpu->kvm, table_gfn); pte |= PT_ACCESSED_MASK; @@ -287,7 +287,7 @@ walk: errcode |= PFERR_PRESENT_MASK; goto error; } else if (ret) - goto walk; + goto retry_walk; mark_page_dirty(vcpu->kvm, table_gfn); pte |= PT_DIRTY_MASK;