// === IMPORTS ===
extern char *NTFS_ReadDir(tVFS_Node *Node, int Pos);
-extern tVFS_Node *NTFS_FindDir(tVFS_Node *Node, char *Name);
+extern tVFS_Node *NTFS_FindDir(tVFS_Node *Node, const char *Name);
// === PROTOTYPES ===
int NTFS_Install(char **Arguments);
-tVFS_Node *NTFS_InitDevice(char *Devices, char **Options);
+tVFS_Node *NTFS_InitDevice(const char *Devices, const char **Options);
void NTFS_Unmount(tVFS_Node *Node);
void NTFS_DumpEntry(tNTFS_Disk *Disk, Uint32 Entry);
// === GLOBALS ===
MODULE_DEFINE(0, 0x0A /*v0.1*/, FS_NTFS, NTFS_Install, NULL);
tVFS_Driver gNTFS_FSInfo = {"ntfs", 0, NTFS_InitDevice, NTFS_Unmount, NULL};
+tVFS_NodeType gNTFS_DirType = {
+ .TypeName = "NTFS-File",
+ .ReadDir = NTFS_ReadDir,
+ .FindDir = NTFS_FindDir,
+ .Close = NULL
+ };
tNTFS_Disk gNTFS_Disks;
/**
* \brief Mount a NTFS volume
*/
-tVFS_Node *NTFS_InitDevice(char *Device, char **Options)
+tVFS_Node *NTFS_InitDevice(const char *Device, const char **Options)
{
tNTFS_Disk *disk;
tNTFS_BootSector bs;
disk->RootNode.NumACLs = 1;
disk->RootNode.ACLs = &gVFS_ACL_EveryoneRX;
- disk->RootNode.ReadDir = NTFS_ReadDir;
- disk->RootNode.FindDir = NTFS_FindDir;
- disk->RootNode.MkNod = NULL;
- disk->RootNode.Link = NULL;
- disk->RootNode.Relink = NULL;
- disk->RootNode.Close = NULL;
+ disk->RootNode.Type = &gNTFS_DirType;
+
NTFS_DumpEntry(disk, 5);