2026-04-02 16:00:27 +02:00
|
|
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
2026-04-02 16:25:49 +02:00
|
|
|
// Copyright (C) 2013 Andrea Mazzoleni
|
2014-01-18 10:37:09 +01:00
|
|
|
|
2026-01-17 21:16:21 +01:00
|
|
|
/* Self-test for the RAID library */
|
2014-01-18 10:37:09 +01:00
|
|
|
|
|
|
|
|
#include "internal.h"
|
|
|
|
|
#include "cpu.h"
|
|
|
|
|
|
|
|
|
|
#include <stdio.h>
|
|
|
|
|
#include <stdlib.h>
|
|
|
|
|
|
|
|
|
|
int main(void)
|
|
|
|
|
{
|
2026-01-17 21:16:21 +01:00
|
|
|
printf("Self-test for the RAID Cauchy library\n\n");
|
2014-01-18 10:37:09 +01:00
|
|
|
|
|
|
|
|
raid_init();
|
|
|
|
|
|
2026-01-17 21:16:21 +01:00
|
|
|
printf("Self-test...\n");
|
2014-01-18 10:37:09 +01:00
|
|
|
if (raid_selftest() != 0) {
|
2015-03-18 22:55:17 +01:00
|
|
|
/* LCOV_EXCL_START */
|
2014-01-18 10:37:09 +01:00
|
|
|
printf("FAILED!\n");
|
|
|
|
|
exit(EXIT_FAILURE);
|
2015-03-18 22:55:17 +01:00
|
|
|
/* LCOV_EXCL_STOP */
|
2014-01-18 10:37:09 +01:00
|
|
|
}
|
|
|
|
|
printf("OK\n\n");
|
|
|
|
|
|
|
|
|
|
return 0;
|
|
|
|
|
}
|
|
|
|
|
|