From nobody Tue Feb 10 00:22:52 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=git.sr.ht Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1646057722539755.4854910994296; Mon, 28 Feb 2022 06:15:22 -0800 (PST) Received: from localhost ([::1]:43838 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nOgo5-00044a-Dn for importer@patchew.org; Mon, 28 Feb 2022 09:15:21 -0500 Received: from eggs.gnu.org ([209.51.188.92]:47816) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nOZn6-0001Ye-Ks; Mon, 28 Feb 2022 01:45:52 -0500 Received: from mail-b.sr.ht ([173.195.146.151]:58200) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nOZn2-0003IP-Lm; Mon, 28 Feb 2022 01:45:51 -0500 Received: from git.sr.ht (unknown [173.195.146.142]) by mail-b.sr.ht (Postfix) with ESMTPSA id 37CDE11EF41; Mon, 28 Feb 2022 06:45:46 +0000 (UTC) Authentication-Results: mail-b.sr.ht; dkim=none From: ~ubzeme Date: Mon, 28 Feb 2022 09:15:36 +0800 Subject: [PATCH qemu 4/7] hvf: rename struct hvf_slot to HVFSlot Message-ID: <164603074537.20094.1732342403585879912-4@git.sr.ht> X-Mailer: git.sr.ht In-Reply-To: <164603074537.20094.1732342403585879912-0@git.sr.ht> To: qemu-devel@nongnu.org Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=173.195.146.151; envelope-from=outgoing@sr.ht; helo=mail-b.sr.ht X-Spam_score_int: 18 X-Spam_score: 1.8 X-Spam_bar: + X-Spam_report: (1.8 / 5.0 requ) BAYES_00=-1.9, DATE_IN_PAST_03_06=1.592, FREEMAIL_FORGED_REPLYTO=2.095, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=no autolearn_force=no X-Spam_action: no action X-Mailman-Approved-At: Mon, 28 Feb 2022 09:07:40 -0500 X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: ~ubzeme Cc: Yan-Jie Wang , qemu-devel@nongnu.org, Cameron Esfahani , Roman Bolshakov , Alexander Graf , qemu-arm@nongnu.org Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZM-MESSAGEID: 1646057723136100001 From: Yan-Jie Wang Follow the QEMU coding style. Structured type names are in CamelCase. Signed-off-by: Yan-Jie Wang --- accel/hvf/hvf-mem.c | 14 +++++++------- include/sysemu/hvf_int.h | 8 ++++---- target/i386/hvf/hvf.c | 4 ++-- 3 files changed, 13 insertions(+), 13 deletions(-) diff --git a/accel/hvf/hvf-mem.c b/accel/hvf/hvf-mem.c index e8cd6b9251..36ae1abc06 100644 --- a/accel/hvf/hvf-mem.c +++ b/accel/hvf/hvf-mem.c @@ -30,11 +30,11 @@ =20 #define HVF_NUM_SLOTS 32 =20 -static hvf_slot memslots[HVF_NUM_SLOTS]; +static HVFSlot memslots[HVF_NUM_SLOTS]; =20 -hvf_slot *hvf_find_overlap_slot(hwaddr start, hwaddr size) +HVFSlot *hvf_find_overlap_slot(hwaddr start, hwaddr size) { - hvf_slot *slot; + HVFSlot *slot; int x; for (x =3D 0; x < HVF_NUM_SLOTS; ++x) { slot =3D &memslots[x]; @@ -46,9 +46,9 @@ hvf_slot *hvf_find_overlap_slot(hwaddr start, hwaddr size) return NULL; } =20 -static hvf_slot *hvf_find_free_slot(void) +static HVFSlot *hvf_find_free_slot(void) { - hvf_slot *slot; + HVFSlot *slot; int x; for (x =3D 0; x < HVF_NUM_SLOTS; x++) { slot =3D &memslots[x]; @@ -91,7 +91,7 @@ static hwaddr hvf_align_section(MemoryRegionSection *sect= ion, =20 static void hvf_set_phys_mem(MemoryRegionSection *section, bool add) { - hvf_slot *slot; + HVFSlot *slot; hwaddr start, size, offset, delta; uint8_t *host_addr; MemoryRegion *area =3D section->mr; @@ -172,7 +172,7 @@ static void hvf_set_phys_mem(MemoryRegionSection *secti= on, bool add) =20 static void hvf_set_dirty_tracking(MemoryRegionSection *section, bool on) { - hvf_slot *slot; + HVFSlot *slot; =20 slot =3D hvf_find_overlap_slot( section->offset_within_address_space, diff --git a/include/sysemu/hvf_int.h b/include/sysemu/hvf_int.h index 2c4a97debe..0aafbc9357 100644 --- a/include/sysemu/hvf_int.h +++ b/include/sysemu/hvf_int.h @@ -17,17 +17,17 @@ #include #endif =20 -/* hvf_slot flags */ +/* HVFSlot flags */ #define HVF_SLOT_LOG (1 << 0) #define HVF_SLOT_READONLY (1 << 1) =20 -typedef struct hvf_slot { +typedef struct HVFSlot { hwaddr start; hwaddr size; /* 0 if the slot is free */ hwaddr offset; /* offset within memory region */ uint32_t flags; MemoryRegion *region; -} hvf_slot; +} HVFSlot; =20 typedef struct hvf_vcpu_caps { uint64_t vmx_cap_pinbased; @@ -58,7 +58,7 @@ int hvf_arch_init(void); int hvf_arch_init_vcpu(CPUState *cpu); void hvf_arch_vcpu_destroy(CPUState *cpu); int hvf_vcpu_exec(CPUState *); -hvf_slot *hvf_find_overlap_slot(hwaddr, hwaddr); +HVFSlot *hvf_find_overlap_slot(hwaddr, hwaddr); int hvf_put_registers(CPUState *); int hvf_get_registers(CPUState *); void hvf_kick_vcpu_thread(CPUState *cpu); diff --git a/target/i386/hvf/hvf.c b/target/i386/hvf/hvf.c index 4ba6e82fab..2ddb4fc825 100644 --- a/target/i386/hvf/hvf.c +++ b/target/i386/hvf/hvf.c @@ -113,7 +113,7 @@ void hvf_handle_io(CPUArchState *env, uint16_t port, vo= id *buffer, } } =20 -static bool ept_emulation_fault(hvf_slot *slot, uint64_t gpa, uint64_t ept= _qual) +static bool ept_emulation_fault(HVFSlot *slot, uint64_t gpa, uint64_t ept_= qual) { int read, write; =20 @@ -469,7 +469,7 @@ int hvf_vcpu_exec(CPUState *cpu) /* Need to check if MMIO or unmapped fault */ case EXIT_REASON_EPT_FAULT: { - hvf_slot *slot; + HVFSlot *slot; uint64_t gpa =3D rvmcs(cpu->hvf->fd, VMCS_GUEST_PHYSICAL_ADDRE= SS); =20 if (((idtvec_info & VMCS_IDT_VEC_VALID) =3D=3D 0) && --=20 2.34.1