hv: move the define of MAX_IR_ENTRIES to offline tool

There is an issue of calculate 2^n roundup of CONFIG_MAX_PT_IRQ_ENTRIES,
and the code style is very ugly when we use macro to fix it.

So this patch move MAX_IR_ENTRIES to offline tool which could do align
check and calculate it automatically.

Signed-off-by: Chenli Wei <chenli.wei@intel.com>
Reviewed-by: Fei Li <fei1.li@intel.com>
This commit is contained in:
Chenli Wei
2022-05-13 17:28:52 +08:00
committed by acrnsi-robot
parent f7094466cb
commit 5f0588b5f8
3 changed files with 1 additions and 28 deletions

View File

@@ -128,6 +128,7 @@ struct dmar_drhd_rt {
uint64_t root_table_addr;
uint64_t ir_table_addr;
/* MAX_IR_ENTRIES is roundup (to power of 2) of CONFIG_MAX_PT_IRQ_ENTRIES. */
uint64_t irte_alloc_bitmap[MAX_IR_ENTRIES / 64U];
uint64_t irte_reserved_bitmap[MAX_IR_ENTRIES / 64U];
uint64_t qi_queue;