We malloc'd cpu_map, and then did:
cpu_map[CPU_IDX(cpu)] |= (1UL << CPU_BIT(cpu));
... not sure how that ever worked if cpu_map was not initialized!
Signed-off-by: Eric Sandeen <sandeen@redhat.com>
Signed-off-by: Jens Axboe <jaxboe@fusionio.com>
* create a map of the cpus we have traces for
*/
cpu_map = malloc(pdi->cpu_map_max / sizeof(long));
+ memset(cpu_map, 0, sizeof(*cpu_map));
n = rb_first(&rb_sort_root);
while (n) {
__t = rb_entry(n, struct trace, rb_node);