From 96351801c9487eb00f092f4858ad0b2aa62ff0a8 Mon Sep 17 00:00:00 2001 From: Norman Feske Date: Thu, 19 Oct 2017 17:35:49 +0200 Subject: [PATCH] wifi_drv: implement vzalloc This function is called by the rarely executed error handling code (iwl_mvm_fw_error_dump) of wifi.lib.so. --- repos/dde_linux/src/lib/wifi/dummies.cc | 1 - repos/dde_linux/src/lib/wifi/lxcc_emul.cc | 11 +++++++++++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/repos/dde_linux/src/lib/wifi/dummies.cc b/repos/dde_linux/src/lib/wifi/dummies.cc index 763cff552..ea311378a 100644 --- a/repos/dde_linux/src/lib/wifi/dummies.cc +++ b/repos/dde_linux/src/lib/wifi/dummies.cc @@ -346,7 +346,6 @@ DUMMY(-1, ktime_sub) DUMMY(-1, sg_init_one) DUMMY(-1, vlan_hw_offload_capable) DUMMY(-1, vlan_tx_tag_get_id) -DUMMY(-1, vzalloc) DUMMY(-1, tsk_restore_flags) DUMMY(-1, put_user) diff --git a/repos/dde_linux/src/lib/wifi/lxcc_emul.cc b/repos/dde_linux/src/lib/wifi/lxcc_emul.cc index d9158f85a..fb670ded0 100644 --- a/repos/dde_linux/src/lib/wifi/lxcc_emul.cc +++ b/repos/dde_linux/src/lib/wifi/lxcc_emul.cc @@ -407,6 +407,17 @@ void *vmalloc(unsigned long size) } +void *vzalloc(unsigned long size) +{ + void *addr = vmalloc(size); + + if (addr) + memset(addr, 0, size); + + return addr; +} + + void vfree(const void *addr) { if (!addr) return;