X-Git-Url: https://git.ucc.asn.au/?a=blobdiff_plain;f=Modules%2FFilesystems%2FExt2%2Fext2.c;h=7c4bf973ae16656cce01b9d14c0f3ee3dd21ad72;hb=7536e8afcc3018c4ca2a4aa8f8422cf86a6c188c;hp=52793d0179c695d47b6272cfc55202af17efc262;hpb=f429a25f24ffd4762d59bee5f7122ac06881f3ca;p=tpg%2Facess2.git diff --git a/Modules/Filesystems/Ext2/ext2.c b/Modules/Filesystems/Ext2/ext2.c index 52793d01..7c4bf973 100644 --- a/Modules/Filesystems/Ext2/ext2.c +++ b/Modules/Filesystems/Ext2/ext2.c @@ -12,10 +12,13 @@ #include "ext2_common.h" #include +// === IMPORTS === +extern tVFS_NodeType gExt2_DirType; + // === PROTOTYPES === int Ext2_Install(char **Arguments); // Interface Functions -tVFS_Node *Ext2_InitDevice(char *Device, char **Options); +tVFS_Node *Ext2_InitDevice(const char *Device, const char **Options); void Ext2_Unmount(tVFS_Node *Node); void Ext2_CloseFile(tVFS_Node *Node); // Internal Helpers @@ -44,13 +47,12 @@ int Ext2_Install(char **Arguments) } /** - \fn tVFS_Node *Ext2_InitDevice(char *Device, char **Options) \brief Initializes a device to be read by by the driver \param Device String - Device to read from \param Options NULL Terminated array of option strings \return Root Node */ -tVFS_Node *Ext2_InitDevice(char *Device, char **Options) +tVFS_Node *Ext2_InitDevice(const char *Device, const char **Options) { tExt2_Disk *disk; int fd; @@ -131,10 +133,8 @@ tVFS_Node *Ext2_InitDevice(char *Device, char **Options) disk->RootNode.ImplPtr = disk; // Save disk pointer disk->RootNode.Size = -1; // Fill in later (on readdir) disk->RootNode.Flags = VFS_FFLAG_DIRECTORY; - - disk->RootNode.ReadDir = Ext2_ReadDir; - disk->RootNode.FindDir = Ext2_FindDir; - //disk->RootNode.Relink = Ext2_Relink; + + disk->RootNode.Type = &gExt2_DirType; // Complete root node disk->RootNode.UID = inode.i_uid;