Hi Dave,
I have a corrupt vmcore file (for ARM) that makes crash loop forever. The problem is in
memory.c, function max_cpudata_limit. The last part of that function:
if (VALID_MEMBER(kmem_list3_shared) && VALID_MEMBER(kmem_cache_s_lists)
&&
readmem(kmem_cache_nodelists(cache), KVADDR, &start_address[0],
sizeof(ulong) * vt->kmem_cache_len_nodes, "array nodelist
array",
RETURN_ON_ERROR)) {
for (i = 0; i < vt->kmem_cache_len_nodes; i++) {
if (start_address[i] == 0)
continue;
if (readmem(start_address[i] + OFFSET(kmem_list3_shared),
KVADDR, &shared, sizeof(void *),
"kmem_list3 shared", RETURN_ON_ERROR|QUIET)) {
if (!shared)
break;
}
if (readmem(shared + OFFSET(array_cache_limit),
KVADDR, &limit, sizeof(int), "shared array_cache
limit",
RETURN_ON_ERROR|QUIET)) {
if (limit > max_limit)
max_limit = limit;
break;
}
}
}
FREEBUF(start_address);
return max_limit;
bail_out:
vt->flags |= KMEM_CACHE_UNAVAIL;
error(INFO, "unable to initialize kmem slab cache subsystem\n\n");
*cpus = 0;
return 0;
The problem is that the readmem statement "if (readmem(start_address[i] +
OFFSET(kmem_list3_shared), ....." fails, and then the function max_cpudata_limit is
called over and over again. I did a patch adding "else goto bail_out;" if the
readmem fails and then crash managed to continue. I do not know if this is really a good
idea.
As this seems only to be a problem for corrupt vmcore files I do not know if you want to
do anything about it.
Best regards
Jan
Jan Karlsson
Senior Software Engineer
MIB
Sony Mobile Communications
Tel: +46703062174
sonymobile.com<http://sonymobile.com/>
[cid:image001.jpg@01CD22E9.EA9DB1E0]