[PATCH] Re: kern/73514: mount_ntfs: can't access large file
dmitry at atlantis.dp.ua
dmitry at atlantis.dp.ua
Thu Mar 3 14:00:40 GMT 2005
The following reply was made to PR kern/73514; it has been noted by GNATS.
From: dmitry at atlantis.dp.ua
To: freebsd-gnats-submit at FreeBSD.org, dohzono at hf.rim.or.jp
Cc:
Subject: [PATCH] Re: kern/73514: mount_ntfs: can't access large file
Date: Thu, 3 Mar 2005 15:57:31 +0200 (EET)
Hello!
I've reviewed ntfs code and found that it isn't 64-bit clean (it uses
32-bit data and 32-bit min()/max() comparisons instead of 64-bit ones).
So I've tried to repair it. Look at results at
ftp://external.atlantis.dp.ua/FreeBSD/ntfs-64/ntfs-5.01.patch
(patch against 5.3-RELEASE and 5-STABLE) or
ftp://external.atlantis.dp.ua/FreeBSD/ntfs-64/ntfs-6.01.patch
(patch against HEAD). I verified this patch under 5.3-RELEASE - now sequential
read of long (4.9Gb and 6Gb) files works correctly: I can play them using
mplayer and verify MD5-sum using gmd5sum. However, mmap() doesn't work
correctly and even crashes system after my patch. Before patch,
the following command:
cmp file.avi file.avi 0x100000000 0x100000000
against file on NTFS causes the following diagnostics:
Feb 25 20:42:53 homelynx kernel: ntfs_strategy: ntfs_readattr failed
Feb 25 20:42:53 homelynx kernel: vnode_pager_getpages: I/O read error
Feb 25 20:42:53 homelynx kernel: vm_fault: pager read error, pid 2774 (cmp)
With my patch, I'm getting the following panic (hand-transcribed):
panic: vnode_pager_getpages: unexpected missing page: firstaddr: -1,
foff: 0x080000000, vnp_size: 0x1127ba3e00
I'm asking for the help of people who know mmap()-related stuff well.
I can't find this remaining bug myself.
Sincerely, Dmitry
--
Atlantis ISP, System Administrator
e-mail: dmitry at atlantis.dp.ua
nic-hdl: LYNX-RIPE
More information about the freebsd-bugs
mailing list