When the elflink code determines a binary is not suitably aligned for the requested remapping mode, it emits a message to state this. Change the severity from ERROR to WARN since execution is able to continue, in spite of the failure to remap segments.
Also, the ERROR and FAIL test macros append their own newline to the end of messages. Remove extra '\n' characters from the counters and linkhuge_rw tests. Signed-off-by: Adam Litke <[EMAIL PROTECTED]> --- elflink.c | 4 ++-- tests/counters.c | 2 +- tests/linkhuge_rw.c | 8 ++++---- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/elflink.c b/elflink.c index c1761fc..d1bc463 100644 --- a/elflink.c +++ b/elflink.c @@ -624,7 +624,7 @@ static int verify_segment_layout(struct seg_layout *segs, int num_segs) /* Make sure alignment hasn't caused segments to overlap */ if (prev_end > start) { - ERROR("Layout problem with segments %i and %i:\n\t" + WARNING("Layout problem with segments %i and %i:\n\t" "Segments would overlap\n", i - 1, i); return 1; } @@ -633,7 +633,7 @@ static int verify_segment_layout(struct seg_layout *segs, int num_segs) if ((segs[i - 1].huge != segs[i].huge) && hugetlb_slice_end(prev_end) > hugetlb_slice_start(start)) { - ERROR("Layout problem with segments %i and %i:\n\t" + WARNING("Layout problem with segments %i and %i:\n\t" "Only one page size per slice\n", i - 1, i); return 1; } diff --git a/tests/counters.c b/tests/counters.c index 9a018e4..e3a804b 100644 --- a/tests/counters.c +++ b/tests/counters.c @@ -100,7 +100,7 @@ void bad_value(int line, const char *name, long expect, long actual) if (actual == -1) ERROR("%s not found in /proc/meminfo", name); else - FAIL("Line %i: Bad %s: expected %li, actual %li\n", + FAIL("Line %i: Bad %s: expected %li, actual %li", line, name, expect, actual); } diff --git a/tests/linkhuge_rw.c b/tests/linkhuge_rw.c index e5f510d..b153e20 100644 --- a/tests/linkhuge_rw.c +++ b/tests/linkhuge_rw.c @@ -196,14 +196,14 @@ int main(int argc, char *argv[]) for (i = 0; i < NUM_TESTS; i++) { if (testtab[i].writable) { if (elfmap_writable && !testtab[i].is_huge) - FAIL("%s is not hugepage\n", testtab[i].name); + FAIL("%s is not hugepage", testtab[i].name); if (!elfmap_writable && testtab[i].is_huge) - FAIL("%s is hugepage\n", testtab[i].name); + FAIL("%s is hugepage", testtab[i].name); } else if (!testtab[i].writable) { if (elfmap_readonly && !testtab[i].is_huge) - FAIL("%s is not hugepage\n", testtab[i].name); + FAIL("%s is not hugepage", testtab[i].name); if (!elfmap_readonly && testtab[i].is_huge) - FAIL("%s is hugepage\n", testtab[i].name); + FAIL("%s is hugepage", testtab[i].name); } } PASS(); ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ Libhugetlbfs-devel mailing list Libhugetlbfs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/libhugetlbfs-devel