Sean Christopherson eb79cd00ce KVM: x86: Add more protection against undefined behavior in rsvd_bits()
Add compile-time asserts in rsvd_bits() to guard against KVM passing in
garbage hardcoded values, and cap the upper bound at '63' for dynamic
values to prevent generating a mask that would overflow a u64.

Suggested-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Sean Christopherson <seanjc@google.com>
Message-Id: <20210113204515.3473079-1-seanjc@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2021-01-25 18:52:06 -05:00
..
2020-12-19 11:18:38 -08:00
2020-12-14 17:34:12 -08:00
2020-11-05 11:32:03 -08:00
2021-01-08 15:06:02 -08:00
2020-12-14 18:29:11 -08:00
2021-01-05 11:40:23 +01:00
2020-12-16 16:38:41 -08:00
2020-08-09 14:10:26 -07:00