for working on fsck the disk mounted on board, i read the the code of the e2fsck, study some useful skills, such like this:
malloc_trace.
we malloc or free the memory in programes, some skills will be useful for us to debug
if want get more information, please 'man malloc_hook'
a example follw: