x86/vPMU: make use of xmalloc_flex_struct()
authorJan Beulich <jbeulich@suse.com>
Mon, 7 Dec 2020 13:54:08 +0000 (14:54 +0100)
committerJan Beulich <jbeulich@suse.com>
Mon, 7 Dec 2020 13:54:08 +0000 (14:54 +0100)
commit826a6dd030fe7d2a62b019e7d6e51ab79227f4aa
treebed1970b80e01455ebbe13ea95cd3bf9f997057d
parentd218fb11884346bb079fa2226ab8786a7bfeee16
x86/vPMU: make use of xmalloc_flex_struct()

... instead of effectively open-coding it in a type-unsafe way. Drop the
regs_sz variable altogether, replacing other uses suitably.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Acked-by: Andrew Cooper <andrew.cooper3@citrix.com>
xen/arch/x86/cpu/vpmu_amd.c