aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/exec/cpu-defs.h8
-rw-r--r--include/qom/cpu.h6
2 files changed, 7 insertions, 7 deletions
diff --git a/include/exec/cpu-defs.h b/include/exec/cpu-defs.h
index 9005923..659c73d 100644
--- a/include/exec/cpu-defs.h
+++ b/include/exec/cpu-defs.h
@@ -145,8 +145,14 @@ typedef struct CPUIOTLBEntry {
* Data elements that are shared between all MMU modes.
*/
typedef struct CPUTLBCommon {
- /* lock serializes updates to tlb_table and tlb_v_table */
+ /* Serialize updates to tlb_table and tlb_v_table, and others as noted. */
QemuSpin lock;
+ /*
+ * Within pending_flush, for each bit N, there exists an outstanding
+ * cross-cpu flush for mmu_idx N. Further cross-cpu flushes to that
+ * mmu_idx may be discarded. Protected by tlb_c.lock.
+ */
+ uint16_t pending_flush;
} CPUTLBCommon;
/*
diff --git a/include/qom/cpu.h b/include/qom/cpu.h
index def0c64..1396f53 100644
--- a/include/qom/cpu.h
+++ b/include/qom/cpu.h
@@ -429,12 +429,6 @@ struct CPUState {
struct hax_vcpu_state *hax_vcpu;
- /* The pending_tlb_flush flag is set and cleared atomically to
- * avoid potential races. The aim of the flag is to avoid
- * unnecessary flushes.
- */
- uint16_t pending_tlb_flush;
-
int hvf_fd;
/* track IOMMUs whose translations we've cached in the TCG TLB */