r15015: add an explanation for this test
authorAndrew Tridgell <tridge@samba.org>
Mon, 10 Apr 2006 05:12:49 +0000 (05:12 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 19:04:01 +0000 (14:04 -0500)
(This used to be commit 9fdeec506fe5005601c0589574d2b8ae3c6166e5)

source4/torture/raw/oplock.c

index e7fa335e7aa8680b372dbacc99bbeb5f42df0060..6008724d4899f5789477025628c1155e22405814 100644 (file)
@@ -553,7 +553,16 @@ BOOL torture_bench_oplock(struct torture_context *torture)
                NTCREATEX_FLAGS_REQUEST_BATCH_OPLOCK;
 
        tv = timeval_current(); 
-               
+
+       /*
+         we open the same file with SHARE_ACCESS_NONE from all the
+         connections in a round robin fashion. Each open causes an
+         oplock break on the previous connection, which is answered
+         by the oplock_handler_close() to close the file.
+
+         This measures how fast we can pass on oplocks, and stresses
+         the oplock handling code
+       */
        printf("Running for %d seconds\n", timelimit);
        while (timeval_elapsed(&tv) < timelimit) {
                for (i=0;i<torture_nprocs;i++) {