Immense cleanup of libc, implemening login program. Slight changes to ACL handling...
[tpg/acess2.git] / Kernel / vfs / fs / fat.c
index bfae405..01c90c2 100644 (file)
@@ -1,28 +1,15 @@
 /*\r
- * Acess2\r
+ * Acess 2\r
  * FAT12/16/32 Driver Version (Incl LFN)\r
  */\r
-//INCLUDES\r
+#define DEBUG  0\r
 #include <common.h>\r
 #include <modules.h>\r
 #include <vfs.h>\r
 #include "fs_fat.h"\r
 \r
-#define DEBUG  0\r
 #define VERBOSE        1\r
 \r
-#if DEBUG\r
-# define DEBUGS(v...)  Log(v)\r
-#else\r
-# define DEBUGS(v...)\r
-# undef ENTER\r
-# undef LOG\r
-# undef LEAVE\r
-# define ENTER(...)\r
-# define LOG(...)\r
-# define LEAVE(...)\r
-#endif\r
-\r
 #define CACHE_FAT      1       //!< Caches the FAT in memory\r
 #define USE_LFN                1       //!< Enables the use of Long File Names\r
 \r
@@ -213,16 +200,13 @@ tVFS_Node *FAT_InitDevice(char *Device, char *options)
                        fat_cache[giFAT_PartCount][i] = buf[i&127];\r
                }\r
        }\r
-       DEBUGS(" FAT_InitDisk: FAT Fully Cached\n");\r
+       LOG("FAT Fully Cached");\r
        }\r
        #endif /*CACHE_FAT*/\r
        \r
        //Initalise inode cache for FAT\r
        gFAT_Disks[giFAT_PartCount].inodeHandle = Inode_GetHandle();\r
-       \r
-       #if DEBUG\r
-               Log(" FAT_InitDisk: Inode Cache handle is %i\n", gFAT_Disks[giFAT_PartCount].inodeHandle);\r
-       #endif\r
+       LOG("Inode Cache handle is %i", gFAT_Disks[giFAT_PartCount].inodeHandle);\r
        \r
        // == VFS Interface\r
        node = &gFAT_Disks[giFAT_PartCount].rootNode;\r
@@ -292,9 +276,7 @@ static Uint32 FAT_int_GetFatValue(int handle, Uint32 cluster)
  */\r
 static void FAT_int_ReadCluster(int Handle, Uint32 Cluster, int Length, void *Buffer)\r
 {\r
-       #if DEBUG\r
        ENTER("iHandle xCluster iLength pBuffer", Handle, Cluster, Length, Buffer);\r
-       #endif\r
        VFS_ReadAt(\r
                gFAT_Disks[Handle].fileHandle,\r
                (gFAT_Disks[Handle].firstDataSect + (Cluster-2)*gFAT_Disks[Handle].bootsect.spc )\r
@@ -302,9 +284,7 @@ static void FAT_int_ReadCluster(int Handle, Uint32 Cluster, int Length, void *Bu
                Length,\r
                Buffer\r
                );\r
-       #if DEBUG\r
        LEAVE('-');\r
-       #endif\r
 }\r
 \r
 /**\r

UCC git Repository :: git.ucc.asn.au