Received: from eggs.gnu.org ([2001:4830:134:3::10]:33344) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bjrLB-0007zP-FT for qemu-devel@nongnu.org; Tue, 13 Sep 2016 13:17:50 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bjrLA-0005FP-3J for qemu-devel@nongnu.org; Tue, 13 Sep 2016 13:17:49 -0400 Received: from mail-wm0-f67.google.com ([74.125.82.67]:35655) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bjrL9-0005E9-TA for qemu-devel@nongnu.org; Tue, 13 Sep 2016 13:17:48 -0400 Received: by mail-wm0-f67.google.com with SMTP id c131so3940741wmh.2 for ; Tue, 13 Sep 2016 10:17:47 -0700 (PDT) Sender: Paolo Bonzini From: Paolo Bonzini Date: Tue, 13 Sep 2016 19:15:43 +0200 Message-Id: <1473786989-54823-13-git-send-email-pbonzini@redhat.com> In-Reply-To: <1473786989-54823-1-git-send-email-pbonzini@redhat.com> References: <1473786989-54823-1-git-send-email-pbonzini@redhat.com> Subject: [Qemu-devel] [PULL 12/58] tcg: rename tb_find_physical() List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Sergey Fedorov , Sergey Fedorov From: Sergey Fedorov In fact, this function does not exactly perform a lookup by physical address as it is descibed for comment on get_page_addr_code(). Thus it may be a bit confusing to have "physical" in it's name. So rename it to tb_htable_lookup() to better reflect its actual functionality. Signed-off-by: Sergey Fedorov Signed-off-by: Sergey Fedorov Message-Id: <20160715175852.30749-13-sergey.fedorov@linaro.org> Signed-off-by: Paolo Bonzini --- cpu-exec.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/cpu-exec.c b/cpu-exec.c index f7f60b1..b240b9f 100644 --- a/cpu-exec.c +++ b/cpu-exec.c @@ -260,7 +260,7 @@ static bool tb_cmp(const void *p, const void *d) return false; } -static TranslationBlock *tb_find_physical(CPUState *cpu, +static TranslationBlock *tb_htable_lookup(CPUState *cpu, target_ulong pc, target_ulong cs_base, uint32_t flags) @@ -296,7 +296,7 @@ static inline TranslationBlock *tb_find(CPUState *cpu, tb = atomic_rcu_read(&cpu->tb_jmp_cache[tb_jmp_cache_hash_func(pc)]); if (unlikely(!tb || tb->pc != pc || tb->cs_base != cs_base || tb->flags != flags)) { - tb = tb_find_physical(cpu, pc, cs_base, flags); + tb = tb_htable_lookup(cpu, pc, cs_base, flags); if (!tb) { /* mmap_lock is needed by tb_gen_code, and mmap_lock must be @@ -310,7 +310,7 @@ static inline TranslationBlock *tb_find(CPUState *cpu, /* There's a chance that our desired tb has been translated while * taking the locks so we check again inside the lock. */ - tb = tb_find_physical(cpu, pc, cs_base, flags); + tb = tb_htable_lookup(cpu, pc, cs_base, flags); if (!tb) { /* if no translated code available, then translate it now */ tb = tb_gen_code(cpu, pc, cs_base, flags, 0); -- 1.8.3.1