diff options
Diffstat (limited to 'arch/x86/platform/efi/runtime-map.c')
| -rw-r--r-- | arch/x86/platform/efi/runtime-map.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/x86/platform/efi/runtime-map.c b/arch/x86/platform/efi/runtime-map.c index a6f02cef3ca2..053ff161eb9a 100644 --- a/arch/x86/platform/efi/runtime-map.c +++ b/arch/x86/platform/efi/runtime-map.c @@ -114,7 +114,7 @@ add_sysfs_runtime_map_entry(struct kobject *kobj, int nr, return ERR_PTR(-ENOMEM); } - entry = kzalloc(sizeof(*entry), GFP_KERNEL); + entry = kzalloc_obj(*entry); if (!entry) { kset_unregister(map_kset); map_kset = NULL; @@ -166,7 +166,7 @@ static int __init efi_runtime_map_init(void) if (!efi_enabled(EFI_MEMMAP) || !efi_kobj) return 0; - map_entries = kcalloc(efi.memmap.nr_map, sizeof(entry), GFP_KERNEL); + map_entries = kzalloc_objs(entry, efi.memmap.nr_map); if (!map_entries) { ret = -ENOMEM; goto out; |
