summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorburet2008-03-25 10:08:39 +0000
committerburet2008-03-25 10:08:39 +0000
commit032d77cb2bd2a6f733841129e01e847136eba0bd (patch)
tree7295f32369fd3b2869c61ab7ece3277bad1cc346
parent0b2f42f4cf16e6269d3caed70ee49cf66f7115b5 (diff)
Maximus V2: tests corrections after errors in nightly tests.
git-svn-id: svn+ssh://pessac/svn/cesar/trunk@1629 017c9cb6-072f-447c-8318-d5b54f68fe89
-rw-r--r--maximus/ethernet/src/EthernetProcessorTest.cpp2
-rw-r--r--maximus/stationtest/src/test_ether.c10
-rw-r--r--maximus/stationtest/src/test_station.c12
3 files changed, 12 insertions, 12 deletions
diff --git a/maximus/ethernet/src/EthernetProcessorTest.cpp b/maximus/ethernet/src/EthernetProcessorTest.cpp
index 2c8694da3f..8fee360a58 100644
--- a/maximus/ethernet/src/EthernetProcessorTest.cpp
+++ b/maximus/ethernet/src/EthernetProcessorTest.cpp
@@ -133,7 +133,7 @@ void EthernetProcessorTest::allocTapTest (void)
}
catch (...)
{
- CPPUNIT_ASSERT_MESSAGE ( "allocTap failed", EPERM == errno );
+ CPPUNIT_ASSERT_MESSAGE ( "allocTap failed", (EPERM == errno) || (EACCES == errno) );
}
}
diff --git a/maximus/stationtest/src/test_ether.c b/maximus/stationtest/src/test_ether.c
index 4e3c3b0d8c..87a00ecebe 100644
--- a/maximus/stationtest/src/test_ether.c
+++ b/maximus/stationtest/src/test_ether.c
@@ -48,6 +48,11 @@ void ipmbox_rx_cb (void *user_data, u32 *first_msg, uint length)
memcpy(ctx->first_buffer->next->data, (u32 *)ctx->rx.mailbox[1], data_length);
memcpy(ctx->first_buffer->next->next->data, (u32 *)ctx->rx.mailbox[1], data_length);
+ // Release allocated buffer
+ hdr->type = HLE_MSG_TYPE_SEND_DONE;
+ ipmbox_tx (ctx, ctx->rx.mailbox, 2);
+
+ hdr->type = HLE_MSG_TYPE_DATA;
hdr->param &= 0xFFE;
ctx->rx.mailbox[1] = (u32)ctx->first_buffer->next->data;
ipmbox_tx (ctx, ctx->rx.mailbox, ctx->rx.length);
@@ -55,11 +60,6 @@ void ipmbox_rx_cb (void *user_data, u32 *first_msg, uint length)
hdr->param |= 0x001;
ctx->rx.mailbox[1] = (u32)ctx->first_buffer->next->data;
ipmbox_tx (ctx, ctx->rx.mailbox, ctx->rx.length);
-
- /* Release allocated buffer. */
-
- hdr->type = HLE_MSG_TYPE_SEND_DONE;
- ipmbox_tx (ctx, ctx->rx.mailbox, 2);
}
else if (HLE_MSG_TYPE_BUFFER_ADD == hdr->type)
{
diff --git a/maximus/stationtest/src/test_station.c b/maximus/stationtest/src/test_station.c
index 34c9282d24..d4357ea082 100644
--- a/maximus/stationtest/src/test_station.c
+++ b/maximus/stationtest/src/test_station.c
@@ -40,16 +40,16 @@ void ipmbox_rx_cb (void *user_data, u32 *first_msg, uint length)
char *data = (char *)ctx->first_buffer->next->data;
*(data + 15) = *(data + 15) + 1; // REQ => CNF
*(data + 19) = 0x01; // Success
- memset(ctx->first_buffer->next->data + 19, '\0', data_length - 19);
+ memset(data + 20, '\0', data_length - 20);
+ // Release allocated buffer
+ hdr->type = HLE_MSG_TYPE_SEND_DONE;
+ ipmbox_tx (ctx, ctx->rx.mailbox, 2);
+
+ hdr->type = HLE_MSG_TYPE_DATA;
hdr->param |= 0x001;
ctx->rx.mailbox[1] = (u32)ctx->first_buffer->next->data;
ipmbox_tx (ctx, ctx->rx.mailbox, ctx->rx.length);
-
- /* Release allocated buffer. */
-
- hdr->type = HLE_MSG_TYPE_SEND_DONE;
- ipmbox_tx (ctx, ctx->rx.mailbox, 2);
}
return;