root / Whitix / branches / hybrid / fs / reiserfs / super.c

Revision 1, 1.8 kB (checked in by mtw07, 9 months ago)

Initial import of projects.

Line 
1/*  This file is part of Whitix.
2 *
3 *  Whitix is free software; you can redistribute it and/or modify
4 *  it under the terms of the GNU General Public License as published by
5 *  the Free Software Foundation; either version 2 of the License, or
6 *  (at your option) any later version.
7 *
8 *  Whitix is distributed in the hope that it will be useful,
9 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
10 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
11 *  GNU General Public License for more details.
12 *
13 *  You should have received a copy of the GNU General Public License
14 *  along with Whitix; if not, write to the Free Software
15 *  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
16 *
17 */
18
19#include <reiserfs.h>
20
21/* Document soon */
22
23struct ReFsSuperBlock
24{
25        DWORD blockCount;
26        DWORD freeBlocks;
27        DWORD rootBlockNo;
28
29        /* Journal information */
30        DWORD journFirstBlock;
31        DWORD journDev;
32        DWORD journSize;
33        DWORD journMaxTrans;
34        DWORD journMagic;
35        DWORD journMaxBatch;
36        DWORD journMaxCommitAge;
37        DWORD journMaxTransAge;
38
39        WORD blockSize;
40        WORD oidMaxSize;
41        WORD oidCurSize;
42        WORD uMountState;
43        char magic[10];
44        WORD fsState;
45        DWORD hashFuncCode;
46        WORD treeHeight;
47        WORD bMapNo;
48        WORD version;
49        WORD reservedForJournal;
50
51        DWORD vNodeGen;
52        DWORD flags;
53        BYTE uuid[16];
54        BYTE label[16];
55        char unUsed[88];
56}PACKED;
57
58struct SuperBlock* ReFsReadSuper(struct StorageDevice* dev,int flags,char* data)
59{
60        if (!dev || BlockSetSize(dev,1024))
61                return NULL;
62
63        struct Buffer* block=BlockRead(dev,0);
64        if (!block)
65                return NULL;
66
67        ReFsSuperBlock* info=(RsFsSuperBlock*)(block->data);
68        return true;
69}
70
71struct VfsFileSystem rFs={
72};
73
74int RFsInit()
75{
76        printf("ReiserFsInit\n");
77}
78
79FsInit(RFsInit);
Note: See TracBrowser for help on using the browser.