KVM: PPC: Book3S HV: Replace kmalloc_node+memset with kzalloc_node

Replace kmalloc_node and memset with kzalloc_node

Signed-off-by: wangbo <wang.bo116@zte.com.cn>
Signed-off-by: Paul Mackerras <paulus@ozlabs.org>
This commit is contained in:
wangbo 2019-01-07 20:15:52 +08:00 committed by Paul Mackerras
parent 41a8645ab1
commit 08434ab469
1 changed files with 1 additions and 3 deletions

View File

@ -5342,13 +5342,11 @@ static int kvm_init_subcore_bitmap(void)
continue;
sibling_subcore_state =
kmalloc_node(sizeof(struct sibling_subcore_state),
kzalloc_node(sizeof(struct sibling_subcore_state),
GFP_KERNEL, node);
if (!sibling_subcore_state)
return -ENOMEM;
memset(sibling_subcore_state, 0,
sizeof(struct sibling_subcore_state));
for (j = 0; j < threads_per_core; j++) {
int cpu = first_cpu + j;