Skip to contentSkip to conversation

Fix test scenario in cl_event_wheel

PATCH New Hal Rosenstock 1 participant 1 message Jul 12, 2013 InfiniBand

lore
Share & tools
lore
#0 lore raw

PATCH 1/3 Fix test scenario in cl_event_wheel

From: Alex Netes <alexne-VPRAkNaXOzVWk0Htik3J/[email protected]>

The testing code is missing complib init/destroy functions and use incorrect callback function prototype.

---
 complib/cl_event_wheel.c |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)
complib/cl_event_wheel.c +6 -1
index d3caa03..21d1ed1 100644
@@ -503,7 +503,7 @@ void __cl_event_wheel_dump(IN cl_event_wheel_t * const p_event_wheel)
 
 /* The callback for aging event */
 /* We assume we pass a text context */
-void __test_event_aging(uint64_t key, void *context)
+static uint64_t __test_event_aging(uint64_t key, uint32_t num_regs, void *context)
 {
 	printf("*****************************************************\n");
 	printf("Aged key: 0x%" PRIx64 " Context:%s\n", key, (char *)context);
@@ -514,6 +514,9 @@ int main()
 	cl_event_wheel_t event_wheel;
 	/*  uint64_t key; */
 
+	/* init complib */
+	complib_init();
+
 	/* construct */
 	cl_event_wheel_construct(&event_wheel);
 
@@ -560,6 +563,8 @@ int main()
 	/* destroy */
 	cl_event_wheel_destroy(&event_wheel);
 
+	complib_exit();
+
 	return (0);
 }
 
Signature · 6 lines
1.7.8.2

--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html