Whamcloud - gitweb
git://git.whamcloud.com
/
fs
/
lustre-release.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
LU-657 test: limit the write size in run_dd
[fs/lustre-release.git]
/
lustre
/
tests
/
it_test.c
diff --git
a/lustre/tests/it_test.c
b/lustre/tests/it_test.c
index
39ae318
..
7b6906a
100644
(file)
--- a/
lustre/tests/it_test.c
+++ b/
lustre/tests/it_test.c
@@
-1,6
+1,4
@@
-/* -*- mode: c; c-basic-offset: 8; indent-tabs-mode: nil; -*-
- * vim:expandtab:shiftwidth=8:tabstop=8:
- *
+/*
* GPL HEADER START
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* GPL HEADER START
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@
-26,7
+24,7
@@
* GPL HEADER END
*/
/*
* GPL HEADER END
*/
/*
- * Copyright
2008 Sun Microsystems, Inc. All rights reserved
+ * Copyright
(c) 2008, 2010, Oracle and/or its affiliates. All rights reserved.
* Use is subject to license terms.
*/
/*
* Use is subject to license terms.
*/
/*
@@
-63,7
+61,7
@@
static struct it_node {
struct interval_node node;
static struct it_node {
struct interval_node node;
-
struct list_head
list;
+
cfs_list_t
list;
int hit, valid;
} *it_array;
static int it_count;
int hit, valid;
} *it_array;
static int it_count;
@@
-379,7
+377,7
@@
static int it_test_performance(struct interval_node *root, unsigned long len)
/* list */
contended_count = 0;
gettimeofday(&start, NULL);
/* list */
contended_count = 0;
gettimeofday(&start, NULL);
- list_for_each_entry(n, &header, list) {
+
cfs_
list_for_each_entry(n, &header, list) {
if (extent_overlapped(&ext, &n->node.in_extent)) {
count = LOOP_COUNT;
while (count--);
if (extent_overlapped(&ext, &n->node.in_extent)) {
count = LOOP_COUNT;
while (count--);
@@
-424,7
+422,7
@@
static struct interval_node *it_test_helper(struct interval_node *root)
__F(&n->node.in_extent));
interval_erase(&n->node, &root);
n->valid = 0;
__F(&n->node.in_extent));
interval_erase(&n->node, &root);
n->valid = 0;
- list_del_init(&n->list);
+
cfs_
list_del_init(&n->list);
} else {
__u64 low, high;
low = (random() % max_count) & ALIGN_MASK;
} else {
__u64 low, high;
low = (random() % max_count) & ALIGN_MASK;
@@
-437,7
+435,7
@@
static struct interval_node *it_test_helper(struct interval_node *root)
dprintf("Adding a node "__S"\n",
__F(&n->node.in_extent));
n->valid = 1;
dprintf("Adding a node "__S"\n",
__F(&n->node.in_extent));
n->valid = 1;
- list_add(&n->list, &header);
+
cfs_
list_add(&n->list, &header);
}
}
}
}
@@
-474,9
+472,9
@@
static struct interval_node *it_test_init(int count)
n->hit = 0;
n->valid = 1;
if (i == 0)
n->hit = 0;
n->valid = 1;
if (i == 0)
- list_add_tail(&n->list, &header);
+
cfs_
list_add_tail(&n->list, &header);
else
else
- list_add_tail(&n->list, &it_array[rand()%i].list);
+
cfs_
list_add_tail(&n->list, &it_array[rand()%i].list);
}
return root;
}
return root;