memattrs: Convert unspecified member to bool
authorZhao Liu <zhao1.liu@intel.com>
Tue, 21 Jan 2025 15:13:21 +0000 (23:13 +0800)
committerPaolo Bonzini <pbonzini@redhat.com>
Thu, 23 Jan 2025 10:50:53 +0000 (11:50 +0100)
commit5014e33b1e00d330f13df33c09a3932ac88f8d94
tree1e32ab58756e7897e0d60d4548ce3506d899634b
parent06a1cfb5550a090b63c81cf5f44d2558010a8ed7
memattrs: Convert unspecified member to bool

Convert `unspecified` member of MemTxAttrs from bit field to bool, so
that bindgen could generate more ergonomic Rust binding with bool type.

As a result, MemTxAttrs needs to be expanded from 4 bytes to 8 bytes.

Therefore, move `unspecified` to after the bit fields and add reserved
members to ensure that the whole structure is packed into 8 bytes.

Suggested-by: Richard Henderson <richard.henderson@linaro.org>
Suggested-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Zhao Liu <zhao1.liu@intel.com>
Link: https://lore.kernel.org/r/20250121151322.171832-2-zhao1.liu@intel.com
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
include/exec/memattrs.h