Windows: OpenAFS reparse points are surrogates
[openafs.git] / src / WINNT / afsrdr / kernel / lib / Include / AFSDefines.h
index a8370ff..fc5dc2c 100644 (file)
@@ -96,8 +96,8 @@ NTSTATUS
 // Worker thread count
 //
 
-#define AFS_WORKER_COUNT        5
-#define AFS_IO_WORKER_COUNT     5
+#define AFS_WORKER_COUNT        16
+#define AFS_IO_WORKER_COUNT     8
 
 //
 // Worker thread states
@@ -116,7 +116,7 @@ NTSTATUS
 #define AFS_WORK_ASYNCH_WRITE                   0x0004
 #define AFS_WORK_UNUSED_5                       0x0005
 #define AFS_WORK_ENUMERATE_GLOBAL_ROOT          0x0006
-#define AFS_WORK_UNUSED_7                       0x0007
+#define AFS_WORK_INVALIDATE_OBJECT              0x0007
 #define AFS_WORK_START_IOS                      0x0008
 
 //
@@ -136,6 +136,7 @@ NTSTATUS
 #define AFS_FCB_FLAG_UPDATE_ACCESS_TIME                      0x00000010
 #define AFS_FCB_FLAG_UPDATE_CREATE_TIME                      0x00000020
 #define AFS_FCB_FLAG_UPDATE_LAST_WRITE_TIME                  0x00000040
+#define AFS_FCB_FLAG_PURGE_ON_CLOSE                          0x00000080
 
 //
 // Object information flags
@@ -153,12 +154,20 @@ NTSTATUS
 #define AFS_OBJECT_FLAGS_VERIFY_DATA                    0x00000200
 
 //
+// Define one second in terms of 100 nS units
+//
+
+#define AFS_ONE_SECOND          10000000
+#define AFS_ONE_MILLISECOND     10000
+#define AFS_ONE_MICROSECOND     10
+
+//
 // Fcb lifetime in seconds
 //
 
-#define AFS_OBJECT_LIFETIME             300000000
+#define AFS_OBJECT_LIFETIME             600 * AFS_ONE_SECOND
 
-#define AFS_EXTENT_REQUEST_TIME        1200000000
+#define AFS_EXTENT_REQUEST_TIME         10 * AFS_ONE_SECOND
 
 //
 // How big to make the runs
@@ -187,14 +196,8 @@ NTSTATUS
 
 #define CRC32_POLYNOMIAL     0xEDB88320L;
 
-//
-// Define one second in terms of 100 nS units
-//
-
-#define AFS_ONE_SECOND          10000000
-
-#define AFS_SERVER_FLUSH_DELAY  30
-#define AFS_SERVER_PURGE_DELAY  60
+#define AFS_SERVER_FLUSH_DELAY  (5LL * AFS_ONE_SECOND)
+#define AFS_SERVER_PURGE_DELAY  (300LL * AFS_ONE_SECOND)
 //
 // PURGE_SLEEP is the number of PURGE_DELAYS we wait before we will unilaterally
 // give back extents.
@@ -431,6 +434,10 @@ DEFINE_GUID (GUID_SD_AFS_REDIRECTOR_CONTROL_OBJECT,
 #define IO_REPARSE_TAG_OPENAFS_DFS              0x00000037L
 #endif
 
+#ifndef IO_REPARSE_TAG_SURROGATE
+#define IO_REPARSE_TAG_SURROGATE                0x20000000L
+#endif
+
 //  {EF21A155-5C92-4470-AB3B-370403D96369}
 DEFINE_GUID (GUID_AFS_REPARSE_GUID,
         0xEF21A155, 0x5C92, 0x4470, 0xAB, 0x3B, 0x37, 0x04, 0x03, 0xD9, 0x63, 0x69);