1 | /* |
---|
2 | * Shared Network Test Initialization File |
---|
3 | */ |
---|
4 | |
---|
5 | #include <bsp.h> |
---|
6 | #include <stdlib.h> |
---|
7 | #include <stdio.h> |
---|
8 | #include <freebsd/bsd.h> |
---|
9 | |
---|
10 | /* XXX should these be in a header? */ |
---|
11 | void print_test_name(void); |
---|
12 | void test_main(void); |
---|
13 | |
---|
14 | /* XXX temporary until in .h file */ |
---|
15 | void rtems_initialize_interfaces(void); |
---|
16 | |
---|
17 | rtems_task Init( |
---|
18 | rtems_task_argument ignored |
---|
19 | ) |
---|
20 | { |
---|
21 | print_test_name(); |
---|
22 | |
---|
23 | /* |
---|
24 | * BSD must support the new "shared IRQ PIC implementation" at this point. |
---|
25 | * BSPs must also provide rtems_interrupt_server_initialize() which |
---|
26 | * just requires including irq-server.[ch] in their build. |
---|
27 | */ |
---|
28 | |
---|
29 | rtems_bsd_initialize_with_interrupt_server(); |
---|
30 | |
---|
31 | puts( "Initializing interfaces" ); |
---|
32 | rtems_initialize_interfaces(); |
---|
33 | |
---|
34 | test_main(); |
---|
35 | /* should not return */ |
---|
36 | |
---|
37 | printf( "*** Test main returned and should not have ***\n" ); |
---|
38 | exit( 5 ); |
---|
39 | } |
---|
40 | |
---|
41 | /* configuration information */ |
---|
42 | |
---|
43 | /* NOTICE: the clock driver is explicitly disabled */ |
---|
44 | #define CONFIGURE_APPLICATION_NEEDS_CLOCK_DRIVER |
---|
45 | #define CONFIGURE_APPLICATION_NEEDS_CONSOLE_DRIVER |
---|
46 | |
---|
47 | #define CONFIGURE_APPLICATION_NEEDS_LIBBLOCK |
---|
48 | #define CONFIGURE_USE_IMFS_AS_BASE_FILESYSTEM |
---|
49 | |
---|
50 | #define CONFIGURE_LIBIO_MAXIMUM_FILE_DESCRIPTORS 32 |
---|
51 | |
---|
52 | #define CONFIGURE_UNLIMITED_OBJECTS |
---|
53 | #define CONFIGURE_UNIFIED_WORK_AREAS |
---|
54 | |
---|
55 | #define CONFIGURE_RTEMS_INIT_TASKS_TABLE |
---|
56 | |
---|
57 | #define CONFIGURE_INIT |
---|
58 | #include <rtems/confdefs.h> |
---|
59 | |
---|
60 | /* |
---|
61 | * FreeBSD TCP/IP Initialization |
---|
62 | */ |
---|
63 | |
---|
64 | #include <freebsd/machine/rtems-bsd-sysinit.h> |
---|
65 | |
---|
66 | #define CONFIGURE_NEED_NET |
---|
67 | /* only include FXP and PCI for i386/pc386 for debug on qemu (for now) */ |
---|
68 | #if defined(i386) |
---|
69 | #define CONFIGURE_NEED_PCIB |
---|
70 | #define CONFIGURE_NEED_NET_IF_FXP |
---|
71 | #endif |
---|
72 | |
---|
73 | /* |
---|
74 | * This is correct for the PC |
---|
75 | */ |
---|
76 | char static_hints[] = { |
---|
77 | "hint.fxp.0.prefer_iomap=1\0\n" |
---|
78 | }; |
---|
79 | |
---|
80 | #include "nic-sysinit.h" |
---|
81 | |
---|
82 | /* end of file */ |
---|