Minor NTFS updates from kernel 2.4.37.
[tomato.git] / release / src / linux / linux / fs / ntfs / struct.h
blob0cb909b037e4a3fe5cb04990340457734ab74485
1 /*
2 * struct.h - Structure definitions
4 * Copyright (C) 1997 RĂ©gis Duchesne
5 * Copyright (C) 2000-2001 Anton Altaparmakov (AIA)
6 */
7 #include <linux/ntfs_fs.h>
9 /* Necessary forward definition. */
10 struct ntfs_inode;
12 /* Which files should be returned from a director listing. */
13 #define ngt_dos 1 /* only short names, no system files */
14 #define ngt_nt 2 /* only long names, all-uppercase becomes
15 * all-lowercase, no system files */
16 #define ngt_posix 3 /* all names except system files */
17 #define ngt_full 4 /* all entries */
19 typedef struct ntfs_sb_info ntfs_volume;
21 typedef struct {
22 ntfs_cluster_t lcn;
23 ntfs_cluster_t len;
24 } ntfs_runlist;
26 typedef struct ntfs_attribute {
27 int type;
28 ntfs_u16 *name;
29 int namelen;
30 int attrno;
31 __s64 size, allocated, initialized, compsize;
32 ATTR_FLAGS flags;
33 __u8 resident, indexed;
34 int cengine;
35 union {
36 void *data; /* if resident */
37 struct {
38 ntfs_runlist *runlist;
39 unsigned long len;
40 } r;
41 } d;
42 } ntfs_attribute;
44 typedef struct ntfs_inode_info ntfs_inode;
46 /* Structure to define IO to user buffer. do_read means that the destination
47 * has to be written using fn_put, do_write means that the destination has to
48 * read using fn_get. So, do_read is from a user's point of view, while put and
49 * get are from the driver's point of view. The first argument is always the
50 * destination of the IO. */
51 typedef struct ntfs_io{
52 int do_read;
53 void (*fn_put)(struct ntfs_io *dest, void *buf, ntfs_size_t);
54 void (*fn_get)(void *buf, struct ntfs_io *src, ntfs_size_t len);
55 void *param;
56 unsigned long size;
57 } ntfs_io;
59 #if 0
60 typedef struct {
61 ntfs_volume *vol;
62 ntfs_inode *ino;
63 int type;
64 char *name;
65 int mftno;
66 int start_vcn;
67 } ntfs_attrlist_item;
68 #endif