OpenCores
URL https://opencores.org/ocsvn/c0or1k/c0or1k/trunk

Subversion Repositories c0or1k

[/] [c0or1k/] [trunk/] [conts/] [posix/] [test0/] [src/] [undeftest.c] - Blame information for rev 2

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 2 drasko
/*
2
 * undeftest.c:
3
 * Tests to see if kernel gracefully handles the undef exception
4
 */
5
 
6
#include <stdio.h>
7
#include <unistd.h>
8
#include <sys/types.h>
9
#include <sys/stat.h>
10
#include <fcntl.h>
11
#include <string.h>
12
#include <tests.h>
13
#include <errno.h>
14
#include INC_GLUE(memory.h)
15
 
16
int undeftest(void)
17
{
18
       test_printf("UNDEF: Start\n");
19
 
20
       /* need a way to report FAIL case */
21
       __asm__ __volatile__(".word 0xf1f0feed\n\t"); /* Some pattern for easy recongition */
22
 
23
       /* If code reaches here its passed */
24
       if (getpid() == parent_of_all)
25
               printf("UNDEF TEST          -- PASSED --\n");
26
 
27
       return 0;
28
}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.