From: Tom Herbert <t...@herbertland.com> Date: Mon, 28 Jan 2019 10:22:52 -0800
> + tpt = vmalloc(tlv_param_table_size(old->count - 1)); > + if (!tpt) > + return -ENOMEM; ... > + tsize = tlv_param_table_size(ARRAY_SIZE(tlv_init_params) + 1); > + > + tpt = vmalloc(tsize); > + if (!tpt) > + return -ENOMEM; Most of the time this is going to be well within range for a quick, more efficient, linearly mapped kmalloc allocation. So please use kvzalloc() or similar for this table.