summaryrefslogtreecommitdiffstats
path: root/fs/ntfs/inode.c
diff options
context:
space:
mode:
authorAnton Altaparmakov <aia21@cantab.net>2005-02-03 12:02:56 +0000
committerAnton Altaparmakov <aia21@cantab.net>2005-05-05 10:53:01 +0100
commitc002f42543e155dd2b5b5039ea2637ab26c82513 (patch)
treeea408493d2e0e9096166ab39a8657689c15c7dfa /fs/ntfs/inode.c
parentf40661be038ce6ed9ef6a8b80307a9153bd95769 (diff)
downloadlinux-c002f42543e155dd2b5b5039ea2637ab26c82513.tar.bz2
NTFS: - Add disable_sparse mount option together with a per volume sparse
enable bit which is set appropriately and a per inode sparse disable bit which is preset on some system file inodes as appropriate. - Enforce that sparse support is disabled on NTFS volumes pre 3.0. Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
Diffstat (limited to 'fs/ntfs/inode.c')
-rw-r--r--fs/ntfs/inode.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/fs/ntfs/inode.c b/fs/ntfs/inode.c
index 6c631dbe0f4c..372c7fcdc068 100644
--- a/fs/ntfs/inode.c
+++ b/fs/ntfs/inode.c
@@ -1,7 +1,7 @@
/**
* inode.c - NTFS kernel inode handling. Part of the Linux-NTFS project.
*
- * Copyright (c) 2001-2004 Anton Altaparmakov
+ * Copyright (c) 2001-2005 Anton Altaparmakov
*
* This program/include file is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as published
@@ -1731,6 +1731,7 @@ int ntfs_read_inode_mount(struct inode *vi)
/* Setup the data attribute. It is special as it is mst protected. */
NInoSetNonResident(ni);
NInoSetMstProtected(ni);
+ NInoSetSparseDisabled(ni);
ni->type = AT_DATA;
ni->name = NULL;
ni->name_len = 0;
@@ -2279,6 +2280,8 @@ int ntfs_show_options(struct seq_file *sf, struct vfsmount *mnt)
seq_printf(sf, ",case_sensitive");
if (NVolShowSystemFiles(vol))
seq_printf(sf, ",show_sys_files");
+ if (!NVolSparseEnabled(vol))
+ seq_printf(sf, ",disable_sparse");
for (i = 0; on_errors_arr[i].val; i++) {
if (on_errors_arr[i].val & vol->on_errors)
seq_printf(sf, ",errors=%s", on_errors_arr[i].str);