git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@1659 35acf78f-673a-0410-8e92-d51de3d6d3f4
This commit is contained in:
parent
c09d291303
commit
7d19745641
|
@ -144,7 +144,7 @@
|
||||||
BIUCR_MASTER0_PREFETCH | \
|
BIUCR_MASTER0_PREFETCH | \
|
||||||
BIUCR_DPFEN | \
|
BIUCR_DPFEN | \
|
||||||
BIUCR_IPFEN | \
|
BIUCR_IPFEN | \
|
||||||
BIUCR_PFLIM_ON_HITMISS | \
|
BIUCR_PFLIM_ON_MISS | \
|
||||||
BIUCR_BFEN)
|
BIUCR_BFEN)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
@ -114,7 +114,10 @@ static void heap1_execute(void) {
|
||||||
chHeapFree(p1);
|
chHeapFree(p1);
|
||||||
test_assert(5, chHeapStatus(&test_heap, &n) == 2, "invalid state");
|
test_assert(5, chHeapStatus(&test_heap, &n) == 2, "invalid state");
|
||||||
p1 = chHeapAlloc(&test_heap, SIZE);
|
p1 = chHeapAlloc(&test_heap, SIZE);
|
||||||
test_assert(6, chHeapStatus(&test_heap, &n) == 1, "heap fragmented");
|
/* Note, the first situation happens when the alignment size is smaller
|
||||||
|
than the header size, the second in the other cases.*/
|
||||||
|
test_assert(6, (chHeapStatus(&test_heap, &n) == 1) ||
|
||||||
|
(chHeapStatus(&test_heap, &n) == 2), "heap fragmented");
|
||||||
chHeapFree(p2);
|
chHeapFree(p2);
|
||||||
chHeapFree(p1);
|
chHeapFree(p1);
|
||||||
test_assert(7, chHeapStatus(&test_heap, &n) == 1, "heap fragmented");
|
test_assert(7, chHeapStatus(&test_heap, &n) == 1, "heap fragmented");
|
||||||
|
|
Loading…
Reference in New Issue