I just updated my MPC8260 BSP to work with the rtems-ss-20010126 snapshot.  Its still a little rough around the edges but I came across a problem unlinking large files which I don't think is related to my BSP.  I saw similar symptoms with the beta3a release but never investigated fully.

Attached is a small test routine to demonstrate the problem.  Modify the NUM_BLOCKS value to get different file sizes (a value of 264 or above should generate the assertion).

Writing a 128k file and then calling unlink() is fine:

*** CRASH TEST, dummy? ***
Writing file of 131584 bytes
Written file
Now trying to unlink it
Success


Going to 135168 bytes generates an error:

*** CRASH TEST, dummy? ***
Writing file of 135168 bytes
Written file
Now trying to unlink it
assertion "0" failed: file "../../../../../../rtems-ss-20010126-afd/c/src/lib/libc/malloc.c", line 323

Just below that number is fine again:

*** CRASH TEST, dummy? ***
Writing file of 134656 bytes
Written file
Now trying to unlink it
Success

I should have enough heap (4M) so I don't think that's a problem.  By my calculations 135168 bytes is the magic number where triply indirect blocks would be required (for a filesystem using 128 byte blocks) so could it be related to that?

Any suggestions?

Andy




_______________________________________________________________________
FSmail - Get your free web-based email from Freeserve: www.fsmail.net



