Re: NTFS directory read lockup

Steve Dodd (dirk@loth.demon.co.uk)
Mon, 18 Jan 1999 01:44:44 +0000


Hi,

I have some more info - hope it is useful. My current way to induce the
oops is to fire up netscape and read my JDK documentation which is on
the NTFS partition for a bit, whilst running updatedb in the background.

I added a bit of debug in and got this:

kernel: root==NULL!! length=1024, walk->dir->vol=c000e044, walk->dir=c271d1a4, walk=c2829f28
kernel: ntfs_read_attr called with buf=c2829ee4, buf->param=00000000
kernel: Ack, r/w attr about to put with dest=c2829ee4, dest->size=56, dest->param=00000000, l=56
kernel: Ick, ntfs_put called with dest->param NULL; dest=c2829ee4, src=c196e860, n=56
kernel: memcpy called with null dest; src=c196e860, n=56
kernel: Unable to handle kernel NULL pointer dereference at virtual address 00000000

The problem is in ntfs_getdir:

int ntfs_getdir(ntfs_iterate_s* walk)
{
int length=walk->dir->vol->mft_recordsize;
int retval,error;
/* start at the index root.*/
char *root=ntfs_malloc(length);
ntfs_io io;

if( !root ) {
printk( KERN_ERR "root==NULL!! length=%lu, walk->dir->vol=%p,"
" walk->dir=%p, walk=%p\n", length, walk->dir->vol, walk->dir, walk );
}
io.fn_put=ntfs_put;
io.param=root;
io.size=length;
error=ntfs_read_attr(walk->dir,walk->dir->vol->at_index_root,
I30,0,&io);
if(error)

As you can see, ntfs_malloc seems to be returning null, even though it should
only be trying to allocate 1024 bytes.. I'd thought maybe it was getting a
nonsensically large value passed in there, but it seems not. Oh well, I'll
carry on looking around..

Cheers,
Steve

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/