source: network-demos/tftpTest/init.c @ 0c9330e

4.11netdemos-4-5-branchnetwork-demos-4-10-branchnetwork-demos-4-6-branchnetwork-demos-4-7-branchnetwork-demos-4-8-branchnetwork-demos-4-9-branchrtems-4-5-branch
Last change on this file since 0c9330e was 0c9330e, checked in by Joel Sherrill <joel.sherrill@…>, on 08/21/98 at 13:22:35

KA9Q -> FreeBSD changes from Eric Norum

  • Property mode set to 100644
File size: 1.8 KB
RevLine 
[c87143a]1/*
[0c9330e]2 * RTEMS configuration/initialization
3 *
[c87143a]4 * This program may be distributed and used for any purpose.
5 * I ask only that you:
[0c9330e]6 *      1. Leave this author information intact.
7 *      2. Document any changes you make.
[c87143a]8 *
9 * W. Eric Norum
10 * Saskatchewan Accelerator Laboratory
11 * University of Saskatchewan
12 * Saskatoon, Saskatchewan, CANADA
13 * eric@skatter.usask.ca
14 */
15
16#include <bsp.h>
[0c9330e]17#include <rtems/tftp.h>
[c87143a]18
[0c9330e]19#define CONFIGURE_TEST_NEEDS_CONSOLE_DRIVER
20#define CONFIGURE_TEST_NEEDS_CLOCK_DRIVER
[c87143a]21#define CONFIGURE_RTEMS_INIT_TASKS_TABLE
22
[0c9330e]23#define CONFIGURE_EXECUTIVE_RAM_SIZE    (512*1024)
24#define CONFIGURE_MAXIMUM_SEMAPHORES    20
25#define CONFIGURE_MAXIMUM_TASKS         20
[c87143a]26
27#define CONFIGURE_MICROSECONDS_PER_TICK 10486
28
[0c9330e]29#define CONFIGURE_INIT_TASK_STACK_SIZE  (10*1024)
30#define CONFIGURE_INIT_TASK_PRIORITY    100
31#define CONFIGURE_INIT_TASK_INITIAL_MODES (RTEMS_PREEMPT | \
32                                           RTEMS_NO_TIMESLICE | \
33                                           RTEMS_NO_ASR | \
34                                           RTEMS_INTERRUPT_LEVEL(0))
35
[c87143a]36#define CONFIGURE_INIT
37rtems_task Init (rtems_task_argument argument);
38
39#define CONFIGURE_HAS_OWN_DEVICE_DRIVER_TABLE
40rtems_driver_address_table Device_drivers[] = {
41  CONSOLE_DRIVER_TABLE_ENTRY,
42  CLOCK_DRIVER_TABLE_ENTRY,
43  TFTP_DRIVER_TABLE_ENTRY,
44};
45
46#include <confdefs.h>
47
[0c9330e]48#include <stdio.h>
49#include <rtems/rtems_bsdnet.h>
50#include "../networkconfig.h"
[c87143a]51
52/*
53 * RTEMS Startup Task
54 */
55rtems_task
56Init (rtems_task_argument ignored)
57{
[0c9330e]58        const char *hostname, *filename;
[c87143a]59
[0c9330e]60        rtems_bsdnet_initialize_network ();
[c87143a]61
[0c9330e]62#if (defined (RTEMS_USE_BOOTP))
63        hostname = NULL;
64        filename = rtems_bsdnet_bootp_boot_file_name;
[19a33c6]65#else
[0c9330e]66        hostname = RTEMS_TFTP_TEST_HOST_NAME;
67        filename = RTEMS_TFTP_TEST_FILE_NAME;
[19a33c6]68#endif
69
[0c9330e]70        testTFTP (hostname, filename);
[c87143a]71        exit (0);
72}
Note: See TracBrowser for help on using the repository browser.