mvme167 patch for rtems-4.5.0-beta1c

Charles-Antoine Gauthier charles.gauthier at nrc.ca
Tue Mar 7 21:40:16 UTC 2000


Enclosed is a patch that solves a number of problems with the MVME167
port and that cleans up a few things.

Problems:

linkcmds file was broken for ELF/DWARF2. Gdb is unhappy with the DWARF2
debug info if it is not relocated to 0. Go figure... Added directives
that used to be in elflinkcmds, which were originally copied from the
linker scripts supplied with binutils 2.9.1 (in other words, it works,
but don't ask me why).


Cleanup

Default compiler is now ELF rather than COFF. COFF support was removed
from the port. The -qelf flag was removed from mvme167.cfg. Changes were
required to the bsp_specs file. The elflinkcmds is deleted.


Additions

Conditional addition of libstdc++ and java runtime libraries during
linking when the application makefile contains
XLDFLAGS+= -qjava -qc++

Network driver. This is work in progress; it doesn't work yet. But those
who are interested can look at it and email their comments to us. 

Joel: With the addition of the network driver, we had to run bootstrap.
This caused a number of trivial changes to the Makefile.in files et al.
Also, our version of automake must be different from yours. The results
are slightly different (automake 1.4 gave similar output, automake 1.4a
was quite different, which makes me think that your version is a much
older 1.4a than the one I have). I recommend that you rerun bootstrap on
our files with your tools just for consistency.


-- 
Charles-Antoine Gauthier
Institute for Information Technology   Institut de technologie de
l'information
National Research Council of Canada    Conseil national de recherches du
Canada
-------------- next part --------------
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/Makefile.am rtems/c/src/lib/libbsp/m68k/mvme167/Makefile.am
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/Makefile.am	Mon Jan 10 09:29:44 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/Makefile.am	Tue Mar  7 13:02:35 2000
***************
*** 1,5 ****
  ## 
! ## $Id: Makefile.am,v 1.1 2000/01/10 14:29:44 joel Exp $
  ## 
  
  AUTOMAKE_OPTIONS = foreign 1.4
--- 1,5 ----
  ## 
! ## $Id: Makefile.am,v 1.3 2000/03/07 18:02:35 gauthier Exp $
  ## 
  
  AUTOMAKE_OPTIONS = foreign 1.4
***************
*** 7,13 ****
  
  # wrapup is the one that actually builds and installs the library
  #  from the individual .rel files built in other directories
! SUBDIRS = . include start startup clock console fatal timer wrapup
  
  include $(top_srcdir)/../../bsp.am
  
--- 7,19 ----
  
  # wrapup is the one that actually builds and installs the library
  #  from the individual .rel files built in other directories
! 
! if HAS_NETWORKING
! NETWORKING_DRIVER = network
! endif
! 
! SUBDIRS = . include start startup clock console fatal timer \
!   $(NETWORKING_DRIVER) wrapup
  
  include $(top_srcdir)/../../bsp.am
  
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/Makefile.in rtems/c/src/lib/libbsp/m68k/mvme167/Makefile.in
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/Makefile.in	Tue Feb 29 09:21:59 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/Makefile.in	Tue Mar  7 12:12:19 2000
***************
*** 1,4 ****
! # Makefile.in generated automatically by automake 1.4a from Makefile.am
  
  # Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
  # This Makefile.in is free software; the Free Software Foundation
--- 1,4 ----
! # Makefile.in generated automatically by automake 1.4 from Makefile.am
  
  # Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
  # This Makefile.in is free software; the Free Software Foundation
***************
*** 49,58 ****
  AUTOHEADER = @AUTOHEADER@
  
  INSTALL = @INSTALL@
! INSTALL_PROGRAM = @INSTALL_PROGRAM@
  INSTALL_DATA = @INSTALL_DATA@
  INSTALL_SCRIPT = @INSTALL_SCRIPT@
- INSTALL_STRIP_FLAG =
  transform = @program_transform_name@
  
  NORMAL_INSTALL = :
--- 49,57 ----
  AUTOHEADER = @AUTOHEADER@
  
  INSTALL = @INSTALL@
! INSTALL_PROGRAM = @INSTALL_PROGRAM@ $(AM_INSTALL_PROGRAM_FLAGS)
  INSTALL_DATA = @INSTALL_DATA@
  INSTALL_SCRIPT = @INSTALL_SCRIPT@
  transform = @program_transform_name@
  
  NORMAL_INSTALL = :
***************
*** 67,76 ****
  host_triplet = @host@
  target_alias = @target_alias@
  target_triplet = @target@
! CC = @CC@
! CC_FOR_TARGET = @CC_FOR_TARGET@
! CPP = @CPP@
! GCCSED = @GCCSED@
  MAINT = @MAINT@
  MAKEINFO = @MAKEINFO@
  PACKAGE = @PACKAGE@
--- 66,73 ----
  host_triplet = @host@
  target_alias = @target_alias@
  target_triplet = @target@
! HAS_NETWORKING = @HAS_NETWORKING@
! INSTALL_CHANGE = @INSTALL_CHANGE@
  MAINT = @MAINT@
  MAKEINFO = @MAKEINFO@
  PACKAGE = @PACKAGE@
***************
*** 82,87 ****
--- 79,85 ----
  RTEMS_BSP_FAMILY = @RTEMS_BSP_FAMILY@
  RTEMS_CPU = @RTEMS_CPU@
  RTEMS_CPU_MODEL = @RTEMS_CPU_MODEL@
+ RTEMS_HAS_NETWORKING = @RTEMS_HAS_NETWORKING@
  RTEMS_HOST = @RTEMS_HOST@
  RTEMS_LIBC_DIR = @RTEMS_LIBC_DIR@
  RTEMS_ROOT = @RTEMS_ROOT@
***************
*** 93,99 ****
  
  # wrapup is the one that actually builds and installs the library
  #  from the individual .rel files built in other directories
! SUBDIRS = . include start startup clock console fatal timer wrapup
  
  PREINSTALL_FILES =  $(PROJECT_ROOT)/@RTEMS_BSP@/lib $(PROJECT_ROOT)/@RTEMS_BSP@/lib/bsp_specs
  
--- 91,101 ----
  
  # wrapup is the one that actually builds and installs the library
  #  from the individual .rel files built in other directories
! 
! @HAS_NETWORKING_TRUE at NETWORKING_DRIVER = network
! 
! SUBDIRS = . include start startup clock console fatal timer   $(NETWORKING_DRIVER) wrapup
! 
  
  PREINSTALL_FILES =  $(PROJECT_ROOT)/@RTEMS_BSP@/lib $(PROJECT_ROOT)/@RTEMS_BSP@/lib/bsp_specs
  
***************
*** 109,114 ****
--- 111,118 ----
  
  TAR = gtar
  GZIP_ENV = --best
+ DIST_SUBDIRS =  . include start startup clock console fatal timer \
+ network wrapup
  all: all-redirect
  .SUFFIXES:
  $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4) $(top_srcdir)/../../bsp.am $(top_srcdir)/../../../../../../automake/subdirs.am $(top_srcdir)/../../../../../../automake/local.am
***************
*** 268,274 ****
  	    || cp -p $$d/$$file $(distdir)/$$file || :; \
  	  fi; \
  	done
! 	for subdir in $(SUBDIRS); do \
  	  if test "$$subdir" = .; then :; else \
  	    test -d $(distdir)/$$subdir \
  	    || mkdir $(distdir)/$$subdir \
--- 272,278 ----
  	    || cp -p $$d/$$file $(distdir)/$$file || :; \
  	  fi; \
  	done
! 	for subdir in $(DIST_SUBDIRS); do \
  	  if test "$$subdir" = .; then :; else \
  	    test -d $(distdir)/$$subdir \
  	    || mkdir $(distdir)/$$subdir \
***************
*** 300,306 ****
  all-am: Makefile
  all-redirect: all-recursive
  install-strip:
! 	$(MAKE) $(AM_MAKEFLAGS) INSTALL_STRIP_FLAG=-s install
  installdirs: installdirs-recursive
  installdirs-am:
  
--- 304,310 ----
  all-am: Makefile
  all-redirect: all-recursive
  install-strip:
! 	$(MAKE) $(AM_MAKEFLAGS) AM_INSTALL_PROGRAM_FLAGS=-s install
  installdirs: installdirs-recursive
  installdirs-am:
  
***************
*** 390,408 ****
  .PHONY: depend-recursive
  
  debug-am:
- 	$(MAKE) $(AM_MAKEFLAGS) "ARCH=o-debug" \
-       "CFLAGS_DEBUG=$(CFLAGS_DEBUG_V)" \
-       "CFLAGS_OPTIMIZE=$(CFLAGS_DEBUG_OPTIMIZE_V)" \
-       "LDFLAGS_DEBUG=$(LDFLAGS_DEBUG_V)" $(TARGET_VA)
- 
  debug: debug-am
  .PHONY: debug debug-am
  
  profile-am:
- 	$(MAKE) $(AM_MAKEFLAGS) "ARCH=o-profile" \
-       "CFLAGS_PROFILE=$(CFLAGS_PROFILE_V)" \
-       "LDFLAGS_PROFILE=$(LDFLAGS_PROFILE_V)" $(TARGET_VA)
- 
  profile: profile-am
  .PHONY: profile profile-am
  
--- 394,403 ----
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/README rtems/c/src/lib/libbsp/m68k/mvme167/README
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/README	Wed Feb 24 10:37:46 1999
--- rtems/c/src/lib/libbsp/m68k/mvme167/README	Tue Mar  7 14:19:42 2000
***************
*** 1,20 ****
  #
! #  $Id: README,v 1.3 1999/02/24 15:37:46 joel Exp $
  #
  
! This is a README file for the MVME167 port of RTEMS 4.0.0.
  
  Please send any comments, improvements, or bug reports to:
  
  Charles-Antoine Gauthier
  Software Engineering Group
  Institute for Information Technology
  National Research Council of Canada
  Ottawa, ON, K1A 0R6
  Canada
  
! charles.gauthier at iit.nrc.ca
!   
  
  Disclaimer
  ----------
--- 1,33 ----
  #
! #  $Id: README,v 1.4 1999/02/24 15:37:46 joel Exp $
  #
  
! This is a README file for the MVME167 port of RTEMS 4.5.0.
  
  Please send any comments, improvements, or bug reports to:
  
  Charles-Antoine Gauthier
+ charles.gauthier at nrc.ca
+ 
+ or
+ 
+ Darlene Stewart
+ Darlene.Stewart at nrc.ca
+   
  Software Engineering Group
  Institute for Information Technology
  National Research Council of Canada
  Ottawa, ON, K1A 0R6
  Canada
  
! 
! WARNING:
! --------
! 
! At this time, the network driver does not work. The driver is
! currently being worked on. Before making any changes, you should
! check with us for the availability of updates.
! 
  
  Disclaimer
  ----------
***************
*** 43,57 ****
  Nothing unique to the MVME167. It uses the standard build process for
  m68k targets. You will need to edit linkcmds to put in the start address
  of your board. We do TFTP transfers to our target. The mvme167.cfg file
! builds only the coff images, which we download to the target, skipping over
! the first 0xA8 bytes; Motorola S-records are not generated. Edit this file
! if you want S-records.
  
  
  Port Description
  Console driver
  
! ----------------
  
  This BSP includes an termios-capable console driver that supports all
  four serial ports on the MVME167 model. The RTEMS console, /dev/console,
--- 56,70 ----
  Nothing unique to the MVME167. It uses the standard build process for
  m68k targets. You will need to edit linkcmds to put in the start address
  of your board. We do TFTP transfers to our target. The mvme167.cfg file
! builds only the ELF images, which we download to the target, skipping
! over the first 0x54 bytes; Motorola S-records are not generated. Edit
! this file if you want S-records.
  
  
  Port Description
  Console driver
  
! ---------------
  
  This BSP includes an termios-capable console driver that supports all
  four serial ports on the MVME167 model. The RTEMS console, /dev/console,
***************
*** 60,86 ****
  do not open /dev/tty00 if you are debugging using 167Bug.
  
  The console is initialized with whatever parameters are set up in termios
! before it calls the firtOpen driver callback, EXCEPT THAT HARDWARE HANDSHAKING
! IS TURNED OFF, i.e. CLOCAL is set in the struct termios c_cflag field. We use
! 3-wire cables for I/O, and find hardware handshaking a pain. If you enable
! hardware handshaking, you must drive CTS* low on the CD2401 for output to
! occur. If the port is in the DTE configuration, you must drive the RS-232 CTS
! line to space; if the port is in the DCE configuration, you must drive the
! RS-232 RTS line to space.
! 
! Limited support is provided for polled terminal I/O. This is used when running
! the timing tests. Set the CD2401_POLLED_IO manifest constant to 1 in
! rtems/c/src/lib/libbsp/m68k/mvme167/console/console.c to enable polled I/O.
! In this case, I/O is done through 167Bug, usually to the Serial Port 1/Console
  
  Floating-point
  
  The MC68040 has a built-in FPU. This FPU does not implement all the
! instruction of the MC68881/MC68882 floating-point coprocessors in hardware.
! The -m68040 compilation options instructs gcc to not generate the missing
! instructions. All of the RTEMS code is built this way. Some of the missing
! functionality must be supplied by external libraries. The required functions
! are part of libgcc.a.
  
  The issue gets complicated because libc, libm and libgcc do not come as
  m68040-specific variants. The default variants of these libraries are for the
--- 73,102 ----
  do not open /dev/tty00 if you are debugging using 167Bug.
  
  The console is initialized with whatever parameters are set up in termios
! before it calls the firtOpen driver callback, EXCEPT THAT HARDWARE
! HANDSHAKING IS TURNED OFF, i.e. CLOCAL is set in the struct termios
! c_cflag field. We use 3-wire cables for I/O, and find hardware handshaking
! a pain. If you enable hardware handshaking, you must drive CTS* low on the
! CD2401 for output to occur. If the port is in the DTE configuration, you
! must drive the RS-232 CTS line to space; if the port is in the DCE
! configuration, you must drive the RS-232 RTS line to space.
! 
! Limited support is provided for polled terminal I/O. This is used when
! running the timing tests. Set the CD2401_POLLED_IO manifest constant to 1
! in rtems/c/src/lib/libbsp/m68k/mvme167/console/console.c to enable polled
! I/O. In this case, I/O is done through 167Bug, usually to the Serial Port
! 1/Console port. Interrupt-driven and polled I/O cannot be mixed in the
! MVME167.
! 
  
  Floating-point
  
  The MC68040 has a built-in FPU. This FPU does not implement all the
! instruction of the MC68881/MC68882 floating-point coprocessors in
! hardware. The -m68040 compilation options instructs gcc to not generate
! the missing instructions. All of the RTEMS code is built this way. Some
! of the missing functionality must be supplied by external libraries. The
! required functions are part of libgcc.a.
  
  The issue gets complicated because libc, libm and libgcc do not come as
  m68040-specific variants. The default variants of these libraries are for the
***************
*** 127,135 ****
  against.
  
  
! Miscellaneous
  
! port. Interrupt-driven and polled I/O cannot be mixed in the MVME167.
  
  The timer and clock drivers were patterned after the MVME162 and MVME152
  ports.
--- 143,164 ----
  against.
  
  
! Cache Control and Memory Mapping
! 
! If Jumper J1-7 is installed, the data cache will be turned on. If Jumper
! J1-6 is installed, the instruction cache will be turned on. Removing the
! jumper causes the corresponding cache to be left disabled.
! 
! If Jumper J1-5 is installed, the data cache will be placed in copyback
! mode. If it is removed, it will be placed in writethrough mode.
! 
! Currently, block address translation is set up to map the virtual
! 0x00000000--0x7FFFFFFF to the physical range 0x00000000--0x7FFFFFFF. The
! port relies on the hardware to raise exceptions when addressing
! non-existent memory. Caching is not controllable on a finer grain.
  
! 
! Miscellaneous
  
  The timer and clock drivers were patterned after the MVME162 and MVME152
  ports.
***************
*** 137,144 ****
  At this time, we do not have an MPCI layer for the MVME167. We are planning
  to write one.
  
- The port does not have a network driver.
- 
  This port supplies its own fatal_error_handler, which attempts to print some
  error message through 167Bug (on the Serial Port 1/Console on the MVME712M).
  
--- 166,171 ----
***************
*** 153,169 ****
        m68k-rtems target;
      - GNU binutils 2.9.1 configured for a powerpc-ibm-aix4.2.0.0 host and
        m68k-rtems target;
  It was also tested on a Pentium II-based PC running Windows NT Workstation 4.0
! and the Cygnus Cygwin32 release b20.1 environment, witht he following tools:
  
      - EGCS 1.1.1 configured for a i586-cygwin32 host and m68k-rtems target;
      - GNU binutils 2.9.4 configured for a i586-cygwin32 host and m68k-rtems
        target;
-     - Cygnus newlib 1.8.0 with RTEMS 4.0.0 patches.
  
  With the latter environment, be patient; builds take a very looong time...
  
!     - Cygnus newlib 1.8.0 with RTEMS 4.0.0 patches.
  
  
  Known Problems
--- 180,199 ----
        m68k-rtems target;
      - GNU binutils 2.9.1 configured for a powerpc-ibm-aix4.2.0.0 host and
        m68k-rtems target;
+ 
  It was also tested on a Pentium II-based PC running Windows NT Workstation 4.0
! and the Cygnus Cygwin32 release b20.1 environment, with the following tools:
  
      - EGCS 1.1.1 configured for a i586-cygwin32 host and m68k-rtems target;
      - GNU binutils 2.9.4 configured for a i586-cygwin32 host and m68k-rtems
        target;
  
  With the latter environment, be patient; builds take a very looong time...
  
! Current development is done on a Pentium III PC running RedHat Linux 6.1.
! At the time this README was composed, the latest working compiler that was
! used successfully was gcc version 2.96 20000213 (experimental). Both the C
! and C++ compilers were working. Binutils 2.9.1 are used.
  
  
  Known Problems
***************
*** 202,207 ****
--- 232,242 ----
  stack does cause problems (but hey, an exception occurred, which is better
  than propagating the error).
  
+ In the stackchk test, an access fault exception is raised after the stack is
+ blown. This is one case were overwritting the first or last 16 bytes of the
+ stack does cause problems (but hey, an exception occurred, which is better
+ than propagating the error).
+ 
  When using interrupt-driven I/O, psx08 produces all the expected output, but
  it does not return control to 167Bug. Is this test supposed to work with
  interrupt-driven console I/O?
***************
*** 210,215 ****
--- 245,252 ----
  What's new
  ----------
  
+ Support for Java is being actively worked on.
+ 
  
  Thanks
  ------
***************
*** 251,467 ****
                           
                           
  Multi-processort tests:  not applicable -- No MPCI layer yet.
- 
- 
- Timing tests:
- 
- 	Context Switch
- 
-     context switch: no floating point contexts 12
-     context switch: self 3
-     context switch: to another task 3
-     fp context switch: restore 1st FP task 14
-     fp context switch: save idle, restore initialized 5
-     fp context switch: save idle, restore idle 15
-     fp context switch: save initialized, restore initialized 5
-     
-     
-   Miscellaneous
-   
-     _ISR_Disable 1
-     _ISR_Flash 0
-     _ISR_Enable 0
-     
-     _Thread_Disable_dispatch 0
-     _Thread_Enable_dispatch 3
-     _Thread_Set_state 9
-     _Thread_Disptach (NO FP) 16
-     _Thread_Resume 6
-     _Thread_Unblock 4
-     _Thread_Ready 6
-     _Thread_Get 3
-     _Thread_Get: invalid id 0
-     
-     _Semaphore_Get 2
- 
- 
- 	Task Manager
- 
-     rtems_task_create 56
-     rtems_task_ident 106
-     rtems_task_start 21
-     rtems_task_restart: calling task 24
-     rtems_task_restart: suspended task -- returns to caller 27
-     rtems_task_restart: blocked task -- returns to caller 36
-     rtems_task_restart: ready task -- returns to caller 27
-     rtems_task_restart: suspended task -- preempts caller 40
-     rtems_task_restart: blocked task -- preempts caller 51
-     rtems_task_restart: ready task -- preempts caller 52
-     rtems_task_delete: calling task 67
-     rtems_task_delete: suspended task 52
-     rtems_task_delete: blocked task 54
-     rtems_task_delete: ready task 54
-     rtems_task_suspend: calling task 23
-     rtems_task_suspend: returns to caller 12
-     rtems_task_resume: task readied -- returns to caller 13
-     rtems_task_resume: task readied -- preempts caller 22
-     rtems_task_set_priority: obtain current priority 8
-     rtems_task_set_priority: returns to caller 16
-     rtems_task_set_priority: preempts caller 34
-     rtems_task_mode: obtain current mode 4
-     rtems_task_mode: no reschedule 5
-     rtems_task_mode: reschedule -- returns to caller 12
-     rtems_task_mode: reschedule -- preempts caller 26
-     rtems_task_get_note 8
-     rtems_task_set_note 8
-     rtems_task_wake_after: yield -- returns to caller 4
-     rtems_task_wake_after: yields -- preempts caller 19
-     rtems_task_wake_when 36
- 
- 
- 	Interrupt Manager
- 
-     interrupt entry overhead: returns to nested interrupt 5
-     interrupt entry overhead: returns to interrupted task 9
-     interrupt entry overhead: returns to preempting task 7
-     interrupt exit overhead: returns to nested interrupt 1
-     interrupt exit overhead: returns to interrupted task 2
-     interrupt exit overhead: returns to preempting task 26
- 
- 
- 	Clock Manager
- 
-     rtems_clock_set 20
-     rtems_clock_get <1
-     rtems_clock_tick 8
- 
- 
- 	Timer Manager
- 
-     rtems_timer_create 8
-   	rtems_timer_ident 104
-     rtems_timer_delete: inactive 12
-     rtems_timer_delete: active 13
-     rtems_timer_fire_after: inactive 17
-     rtems_timer_fire_after: active 18
-     rtems_timer_fire_when: inactive 23
-     rtems_timer_fire_when: active 23
-     rtems_timer_reset: inactive 16
-     rtems_timer_reset: active 17
-     rtems_timer_cancel: inactive 9
-     rtems_timer_cancel: active 10
- 
- 
- 	Semaphore Manager
- 
-     rtems_semaphore_create 22
-     rtems_semaphore_ident 119
-     rtems_semaphore_delete 24
-     rtems_semaphore_obtain: available 10
-     rtems_semaphore_obtain: not available -- NO_WAIT 10
-     rtems_semaphore_obtain: not available -- caller blocks 35
-     rtems_semaphore_release: no waiting tasks 11
-     rtems_semaphore_release: task readied -- returns to caller 17
-     rtems_semaphore_release: task readied -- preempts caller 27
- 
- 
- 	Message Queue Manager
- 
-     rtems_message_queue_create 85
-     rtems_message_queue_ident 103
-     rtems_message_queue_delete 32
-     rtems_message_queue_send: no waiting tasks 25
-     rtems_message_queue_send: task readied -- returns to caller 27
-     rtems_message_queue_send: task readied -- preempts caller 39
-     rtems_message_queue_urgent: no waiting tasks 26
-     rtems_message_queue_urgent: task readied -- returns to caller 28
-     rtems_message_queue_urgent: task readied -- preempts caller 39
-     rtems_message_queue_broadcast: no waiting tasks 13
-     rtems_message_queue_broadcast: task readied -- returns to caller 37
-     rtems_message_queue_broadcast: task readied -- preempts caller 45
-     rtems_message_queue_receive: available 21
-     rtems_message_queue_receive: not available -- NO_WAIT 11
-     rtems_message_queue_receive: not available -- caller blocks 37
-     rtems_message_queue_flush: no messages flushed 7
-     rtems_message_queue_flush: messages flushed 10
- 
- 
- 	Event Manager
- 
-     rtems_event_send: no task readied 7
-     rtems_event_send: task readied -- returns to caller 18
-     rtems_event_send: task readied -- preempts caller 29
-     rtems_event_receive: obtain current events <1
-     rtems_event_receive: available 10
-     rtems_event_receive: not available -- NO_WAIT 5
-     rtems_event_receive: not available -- caller blocks 28
- 
- 
- 	Signal Manager
- 
-     rtems_signal_catch 5
-     rtems_signal_send: returns to caller 15
-     rtems_signal_send: signal to self 24
-     exit ASR overhead: returns to calling task 20
-     exit ASR overhead: returns to preempting task 21
- 
- 
- 	Partition Manager
- 
-     rtems_partition_create 30
-     rtems_partition_ident 103
-     rtems_partition_delete 14
-     rtems_partition_get_buffer: available 14
-     rtems_partition_get_buffer: not available 9
-     rtems_partition_return_buffer 18
- 
- 
- 	Region Manager
- 
-     rtems_region_create 25
-     rtems_region_ident 105
-     rtems_region_delete 13
-     rtems_region_get_segment: available 13
-     rtems_region_get_segment: not available -- NO_WAIT 17
-     rtems_region_get_segment: not available -- caller blocks 49
-     rtems_region_return_segment: no waiting tasks 16
-     rtems_region_return_segment: task readied -- returns to caller 35
-     rtems_region_return_segment: task readied -- preempts caller 58
- 
- 
- 	Dual-Ported Memory Manager
- 
-     rtems_port_create 13
- 	  rtems_port_ident 103
-     rtems_port_delete 14
-     rtems_port_external_to_internal 5
-     rtems_port_internal_to_external 5
- 
- 
- 	IO Manager
- 
-     rtems_io_initialize <1
-     rtems_io_open <1
-     rtems_io_close <1
-     rtems_io_read <1
-     rtems_io_write <1
-     rtems_io_control <1
- 
- 
- 	Rate Monotonic Manager
- 
-     rtems_rate_monotonic_create 15
- 	  rtems_rate_monotonic_ident 103
-     rtems_rate_monotonic_cancel 16
-     rtems_rate_monotonic_delete: active 18
-     rtems_rate_monotonic_delete: inactive 20
-     rtems_rate_monotonic_period: initiate period -- returns to caller 23
-     rtems_rate_monotonic_period: conclude periods -- caller blocks 25
-     rtems_rate_monotonic_period: obtain status 13
- 
- 
- Network tests:
-        Network driver is not implemented.
- 
- 
- 
--- 288,290 ----
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/aclocal.m4 rtems/c/src/lib/libbsp/m68k/mvme167/aclocal.m4
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/aclocal.m4	Tue Feb 29 09:21:58 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/aclocal.m4	Tue Mar  7 13:02:36 2000
***************
*** 1,4 ****
! dnl aclocal.m4 generated automatically by aclocal 1.4a
  
  dnl Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
  dnl This file is free software; the Free Software Foundation
--- 1,4 ----
! dnl aclocal.m4 generated automatically by aclocal 1.4
  
  dnl Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
  dnl This file is free software; the Free Software Foundation
***************
*** 10,16 ****
  dnl even the implied warranty of MERCHANTABILITY or FITNESS FOR A
  dnl PARTICULAR PURPOSE.
  
! dnl $Id: rtems-top.m4,v 1.5 1999/10/04 18:19:20 joel Exp $
  
  dnl
  dnl RTEMS_TOP($1)
--- 10,16 ----
  dnl even the implied warranty of MERCHANTABILITY or FITNESS FOR A
  dnl PARTICULAR PURPOSE.
  
! dnl $Id: aclocal.m4,v 1.4 2000/03/07 18:02:36 gauthier Exp $
  
  dnl
  dnl RTEMS_TOP($1)
***************
*** 58,65 ****
  
  AC_DEFUN(AM_INIT_AUTOMAKE,
  [AC_REQUIRE([AC_PROG_INSTALL])
- dnl We require 2.13 because we rely on SHELL being computed by configure.
- AC_PREREQ([2.13])
  PACKAGE=[$1]
  AC_SUBST(PACKAGE)
  VERSION=[$2]
--- 58,63 ----
***************
*** 142,148 ****
  AC_SUBST($1)])
  
  dnl
! dnl $Id: canonical-target-name.m4,v 1.7 1999/10/11 15:50:20 joel Exp $
  dnl
  
  dnl canonicalize target cpu
--- 140,146 ----
  AC_SUBST($1)])
  
  dnl
! dnl $Id: aclocal.m4,v 1.4 2000/03/07 18:02:36 gauthier Exp $
  dnl
  
  dnl canonicalize target cpu
***************
*** 212,450 ****
    $1_FALSE=
  fi])
  
! dnl
! dnl $Id: prog-cc.m4,v 1.7 2000/02/08 22:32:41 joel Exp $
! dnl 
! dnl Check for target gcc
! dnl
! dnl 98/05/20 Ralf Corsepius 	(corsepiu at faw.uni-ulm.de)
! dnl				Completely reworked
! 
! AC_DEFUN(RTEMS_PROG_CC,
! [
! AC_BEFORE([$0], [AC_PROG_CPP])dnl
! AC_BEFORE([$0], [AC_PROG_CC])dnl
! AC_BEFORE([$0], [RTEMS_CANONICALIZE_TOOLS])dnl
! AC_REQUIRE([RTEMS_TOOL_PREFIX])dnl
! AC_REQUIRE([RTEMS_ENABLE_LIBCDIR])dnl
! 
! dnl Only accept gcc and cc
! dnl NOTE: This might be too restrictive for native compilation
! AC_PATH_PROGS(CC_FOR_TARGET, "$program_prefix"gcc "$program_prefix"cc )
! test -z "$CC_FOR_TARGET" \
!   && AC_MSG_ERROR([no acceptable cc found in \$PATH])
! 
! dnl backup 
! rtems_save_CC=$CC
! rtems_save_CFLAGS=$CFLAGS
! 
! dnl temporarily set CC
! CC=$CC_FOR_TARGET
! 
! AC_PROG_CC_WORKS
! AC_PROG_CC_GNU
! 
! if test $ac_cv_prog_gcc = yes; then
!   GCC=yes
! dnl Check whether -g works, even if CFLAGS is set, in case the package
! dnl plays around with CFLAGS (such as to build both debugging and
! dnl normal versions of a library), tasteless as that idea is.
!   ac_test_CFLAGS="${CFLAGS+set}"
!   ac_save_CFLAGS="$CFLAGS"
!   CFLAGS=
!   AC_PROG_CC_G
!   if test "$ac_test_CFLAGS" = set; then
!     CFLAGS="$ac_save_CFLAGS"
!   elif test $ac_cv_prog_cc_g = yes; then
!     CFLAGS="-g -O2"
!   else
!     CFLAGS="-O2"
!   fi
! else
!   GCC=
!   test "${CFLAGS+set}" = set || CFLAGS="-g"
! fi
! 
! rtems_cv_prog_gcc=$ac_cv_prog_gcc
! rtems_cv_prog_cc_g=$ac_cv_prog_cc_g
! rtems_cv_prog_cc_works=$ac_cv_prog_cc_works
! rtems_cv_prog_cc_cross=$ac_cv_prog_cc_cross
! 
! dnl restore initial values
! CC=$rtems_save_CC
! CFLAGS=$rtems_save_CFLAGS
! 
! unset ac_cv_prog_gcc
! unset ac_cv_prog_cc_g
! unset ac_cv_prog_cc_works
! unset ac_cv_prog_cc_cross
! ])
! 
! AC_DEFUN(RTEMS_PROG_CC_FOR_TARGET,
! [
! dnl check target cc
! RTEMS_PROG_CC
! dnl check if the compiler supports --specs
! RTEMS_GCC_SPECS
! dnl check if the target compiler may use --pipe
! RTEMS_GCC_PIPE
! dnl check if the compiler supports --specs if gcc28 is requested
! if test "$RTEMS_USE_GCC272" != "yes" ; then
!   if test "$rtems_cv_gcc_specs" = "no"; then
!     AC_MSG_WARN([*** disabling --enable-gcc28])
!       RTEMS_USE_GCC272=yes
!   fi
! fi
! test "$rtems_cv_gcc_pipe" = "yes" && CC_FOR_TARGET="$CC_FOR_TARGET --pipe"
! 
! dnl FIXME: HACK for egcs/cygwin mixing '\\' and '/' in gcc -print-*
! case $host_os in
! *cygwin*)     GCCSED="| sed 's%\\\\%/%g'" ;;
! *) ;;
! esac
! AC_SUBST(GCCSED)
! ])
! 
! dnl
! dnl $Id: canonicalize-tools.m4,v 1.12 2000/02/08 22:32:41 joel Exp $
! dnl
! dnl Set target tools
! dnl
! dnl 98/06/23 Ralf Corsepius	(corsepiu at faw.uni-ulm.de)
! dnl		fixing cache/environment variable handling
! dnl		adding checks for cygwin/egcs '\\'-bug
! dnl		adding checks for ranlib/ar -s problem 
! dnl
! dnl 98/02/12 Ralf Corsepius	(corsepiu at faw.uni-ulm.de)
! dnl
! 
! AC_DEFUN(RTEMS_GCC_PRINT,
! [
!     $1=`$CC_FOR_TARGET --print-prog-name=$2`
! ])
! 
! AC_DEFUN(RTEMS_PATH_TOOL,
! [
! AC_MSG_CHECKING([target's $2])
! AC_CACHE_VAL(ac_cv_path_$1,:)
! AC_MSG_RESULT([$ac_cv_path_$1])
! 
! if test -n "$ac_cv_path_$1"; then
!   dnl retrieve the value from the cache
!   $1=$ac_cv_path_$1
! else
!   dnl the cache was not set
!   if test -z "[$]$1" ; then
!     if test "$rtems_cv_prog_gcc" = "yes"; then
!       # We are using gcc, ask it about its tool
!       # NOTE: Necessary if gcc was configured to use the target's 
!       # native tools or uses prefixes for gnutools (e.g. gas instead of as)
!       RTEMS_GCC_PRINT($1,$2)
!     fi
!   else
!     # The user set an environment variable.
!     # Check whether it is an absolute path, otherwise AC_PATH_PROG 
!     # will override the environment variable, which isn't what the user
!     # intends
!     AC_MSG_CHECKING([whether environment variable $1 is an absolute path])
!     case "[$]$1" in
!     /*) # valid
!       AC_MSG_RESULT("yes")
!     ;;
!     *)  # invalid for AC_PATH_PROG
!       AC_MSG_RESULT("no")
!       AC_MSG_ERROR([***]
!         [Environment variable $1 should either]
! 	[be unset (preferred) or contain an absolute path])
!     ;;
!     esac
!   fi
! 
!   AC_PATH_PROG($1,"$program_prefix"$2,$3)
! fi
! ])
! 
! AC_DEFUN(RTEMS_CANONICALIZE_TOOLS,
! [AC_REQUIRE([RTEMS_PROG_CC])dnl
! 
! dnl FIXME: What shall be done if these tools are not available?
!   RTEMS_PATH_TOOL(AR_FOR_TARGET,ar,no)
!   RTEMS_PATH_TOOL(AS_FOR_TARGET,as,no)
!   RTEMS_PATH_TOOL(LD_FOR_TARGET,ld,no)
!   RTEMS_PATH_TOOL(NM_FOR_TARGET,nm,no)
! 
! dnl special treatment of ranlib
!   RTEMS_PATH_TOOL(RANLIB_FOR_TARGET,ranlib,no)
!   if test "$RANLIB_FOR_TARGET" = "no"; then
!     # ranlib wasn't found; check if ar -s is available
!     RTEMS_AR_FOR_TARGET_S
!     if test $rtems_cv_AR_FOR_TARGET_S = "yes" ; then
!       dnl override RANLIB_FOR_TARGET's cache
!       ac_cv_path_RANLIB_FOR_TARGET="$AR_FOR_TARGET -s"
!       RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
!     else
!       AC_MSG_ERROR([***]
!         [Can't figure out how to build a library index]
! 	[Neither ranlib nor ar -s seem to be available] )
!     fi
!   fi
! 
! dnl NOTE: These may not be available if not using gnutools
!   RTEMS_PATH_TOOL(OBJCOPY_FOR_TARGET,objcopy,no)
!   RTEMS_PATH_TOOL(SIZE_FOR_TARGET,size,no)
!   RTEMS_PATH_TOOL(STRIP_FOR_TARGET,strip,no)
! ])
! 
! dnl
! dnl $Id: ar-s.m4,v 1.2 1998/09/30 19:51:38 joel Exp $
! dnl
! 
! AC_DEFUN(RTEMS_AR_FOR_TARGET_S,
! [
! AC_CACHE_CHECK(whether $AR_FOR_TARGET -s works,
! rtems_cv_AR_FOR_TARGET_S,
! [
! cat > conftest.$ac_ext <<EOF
! int foo( int b ) 
! { return b; }
! EOF
! if AC_TRY_COMMAND($CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext) \
!   && AC_TRY_COMMAND($AR_FOR_TARGET -sr conftest.a conftest.o) \
!   && test -s conftest.a ; \
! then
!   rtems_cv_AR_FOR_TARGET_S="yes"
! else
!   rtems_cv_AR_FOR_TARGET_S="no"
! fi
!   rm -f conftest*
! ])
! ])
! 
! 
! dnl
! dnl  $Id: tool-prefix.m4,v 1.3 1999/07/26 19:58:26 joel Exp $
! dnl 
! dnl Set program_prefix
! dnl
! dnl 98/05/20 Ralf Corsepius	(corsepiu at faw.uni-ulm.de)
! dnl				Extracted from configure
! 
! AC_DEFUN(RTEMS_TOOL_PREFIX,
! [AC_REQUIRE([AC_CANONICAL_TARGET])dnl
! AC_REQUIRE([AC_CANONICAL_BUILD])dnl
! 
! changequote(,)dnl
! if [ "${program_prefix}" = "NONE" ] ; then
!   if [ "${target}" = "${host}" ] ; then
!     program_prefix=
!   else
!     program_prefix=${target}-
!   fi
! fi
! changequote([,])dnl
! ])
! 
! dnl $Id: enable-libcdir.m4,v 1.2 1999/03/29 21:07:31 joel Exp $
  
  AC_DEFUN(RTEMS_ENABLE_LIBCDIR,
  [
--- 210,216 ----
    $1_FALSE=
  fi])
  
! dnl $Id: aclocal.m4,v 1.4 2000/03/07 18:02:36 gauthier Exp $
  
  AC_DEFUN(RTEMS_ENABLE_LIBCDIR,
  [
***************
*** 455,504 ****
  AC_SUBST(RTEMS_LIBC_DIR)dnl
  ])
  
! dnl
! dnl $Id: gcc-specs.m4,v 1.3 1999/10/04 18:19:19 joel Exp $
! dnl
! dnl Check whether the target compiler accepts -specs
! dnl
! 
! AC_DEFUN(RTEMS_GCC_SPECS,
! [AC_REQUIRE([RTEMS_PROG_CC])
! AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts -specs,rtems_cv_gcc_specs,
! [
! rtems_cv_gcc_specs=no
! if test "$rtems_cv_prog_gcc" = "yes"; then
!   touch confspec
!   echo 'void f(){}' >conftest.c
!   if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
!     rtems_cv_gcc_specs=yes
!   fi
! fi
! rm -f confspec conftest*
! ])])
! 
! dnl
! dnl $Id: gcc-pipe.m4,v 1.6 2000/02/08 22:32:41 joel Exp $
! dnl
! dnl Check whether the target compiler accepts -pipe
! dnl
! 
! AC_DEFUN(RTEMS_GCC_PIPE,
! [AC_REQUIRE([RTEMS_PROG_CC]) 
! AC_REQUIRE([AC_CANONICAL_HOST])
! AC_CACHE_CHECK(whether $CC_FOR_TARGET accepts --pipe,rtems_cv_gcc_pipe,
! [
! rtems_cv_gcc_pipe=no
! if test "$rtems_cv_prog_gcc" = "yes"; then
!     echo 'void f(){}' >conftest.c
!     if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
!       rtems_cv_gcc_pipe=yes
!     fi
!     rm -f conftest*
! fi
! ])
! ])
! 
! dnl $Id: enable-rtemsbsp.m4,v 1.3 1999/11/22 13:34:12 joel Exp $
  
  dnl Override the set of BSPs to be built.
  dnl used by the toplevel configure script
--- 221,227 ----
  AC_SUBST(RTEMS_LIBC_DIR)dnl
  ])
  
! dnl $Id: aclocal.m4,v 1.4 2000/03/07 18:02:36 gauthier Exp $
  
  dnl Override the set of BSPs to be built.
  dnl used by the toplevel configure script
***************
*** 536,542 ****
  ])
  
  dnl
! dnl $Id: project-root.m4,v 1.3 2000/02/08 22:32:41 joel Exp $
  dnl 
  
  AC_DEFUN(RTEMS_PROJECT_ROOT,
--- 259,265 ----
  ])
  
  dnl
! dnl $Id: aclocal.m4,v 1.4 2000/03/07 18:02:36 gauthier Exp $
  dnl 
  
  AC_DEFUN(RTEMS_PROJECT_ROOT,
***************
*** 552,557 ****
--- 275,283 ----
  RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
  AC_SUBST(RTEMS_ROOT)
  
+ INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+ AC_SUBST(INSTALL_CHANGE)
+ 
  PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
  AC_SUBST(PACKHEX)
  
***************
*** 563,569 ****
  ])
  
  
! dnl $Id: check-bsps.m4,v 1.6 2000/01/27 17:06:49 joel Exp $
  
  dnl Report all available bsps for a target,
  dnl check if a bsp-subdirectory is present for all bsps found
--- 289,295 ----
  ])
  
  
! dnl $Id: aclocal.m4,v 1.4 2000/03/07 18:02:36 gauthier Exp $
  
  dnl Report all available bsps for a target,
  dnl check if a bsp-subdirectory is present for all bsps found
***************
*** 588,593 ****
--- 314,320 ----
          gen68360)          rtems_bsp="$rtems_bsp gen68360 gen68360_040";;
          p4000)             rtems_bsp="$rtems_bsp p4600 p4650";;
          mvme162)           rtems_bsp="$rtems_bsp mvme162 mvme162lx";;
+         mbx8xx)            rtems_bsp="$rtems_bsp mbx821_001 mbx860_002";;
  	motorola_powerpc)  rtems_bsp="$rtems_bsp mvme2307 mcp750";;
  	pc386)             rtems_bsp="$rtems_bsp pc386 pc486 pc586 pc686";;
          *) $1="[$]$1 $file";;
***************
*** 610,616 ****
  fi
  ])dnl
  
! dnl $Id: check-cpu.m4,v 1.4 1999/11/22 13:34:08 joel Exp $
  
  dnl check if RTEMS support a cpu
  AC_DEFUN(RTEMS_CHECK_CPU,
--- 337,343 ----
  fi
  ])dnl
  
! dnl $Id: aclocal.m4,v 1.4 2000/03/07 18:02:36 gauthier Exp $
  
  dnl check if RTEMS support a cpu
  AC_DEFUN(RTEMS_CHECK_CPU,
***************
*** 628,634 ****
  ])dnl
  
  
! dnl $Id: check-bsp-cache.m4,v 1.1 1999/12/03 13:31:55 joel Exp $
  
  dnl RTEMS_CHECK_BSP_CACHE(RTEMS_BSP)
  AC_DEFUN(RTEMS_CHECK_BSP_CACHE,
--- 355,361 ----
  ])dnl
  
  
! dnl $Id: aclocal.m4,v 1.4 2000/03/07 18:02:36 gauthier Exp $
  
  dnl RTEMS_CHECK_BSP_CACHE(RTEMS_BSP)
  AC_DEFUN(RTEMS_CHECK_BSP_CACHE,
***************
*** 646,652 ****
  AC_SUBST(RTEMS_BSP_FAMILY)
  ])dnl
  
! dnl $Id: canonical-host.m4,v 1.2 1999/03/19 23:11:21 joel Exp $
  
  AC_DEFUN(RTEMS_CANONICAL_HOST,
  [dnl
--- 373,424 ----
  AC_SUBST(RTEMS_BSP_FAMILY)
  ])dnl
  
! dnl $Id: aclocal.m4,v 1.4 2000/03/07 18:02:36 gauthier Exp $
! dnl
! AC_DEFUN(RTEMS_CHECK_NETWORKING,
! [dnl
! AC_REQUIRE([RTEMS_CHECK_CPU])dnl
! AC_REQUIRE([RTEMS_ENABLE_NETWORKING])dnl
! 
! AC_CACHE_CHECK([whether BSP supports networking],
!   rtems_cv_HAS_NETWORKING,
!   [dnl
!     case "$RTEMS_CPU" in
!     unix*)
!       rtems_cv_HAS_NETWORKING="no"
!       ;;
!     *)
!       if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
!         rtems_cv_HAS_NETWORKING="yes";
!       else
!         rtems_cv_HAS_NETWORKING="disabled";
!       fi
!       ;;
!     esac])
! if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
!   HAS_NETWORKING="yes";
! else
!   HAS_NETWORKING="no";
! fi
! AC_SUBST(HAS_NETWORKING)dnl
! ])
! 
! dnl $Id: aclocal.m4,v 1.4 2000/03/07 18:02:36 gauthier Exp $
! 
! AC_DEFUN(RTEMS_ENABLE_NETWORKING,
! [
! 
! AC_ARG_ENABLE(networking,
! [  --enable-networking                  enable TCP/IP stack],
! [case "${enableval}" in
!   yes) RTEMS_HAS_NETWORKING=yes ;;
!   no) RTEMS_HAS_NETWORKING=no ;;
!   *)  AC_MSG_ERROR(bad value ${enableval} for enable-networking option) ;;
! esac],[RTEMS_HAS_NETWORKING=yes])
! AC_SUBST(RTEMS_HAS_NETWORKING)dnl
! ])
! 
! dnl $Id: aclocal.m4,v 1.4 2000/03/07 18:02:36 gauthier Exp $
  
  AC_DEFUN(RTEMS_CANONICAL_HOST,
  [dnl
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/bsp_specs rtems/c/src/lib/libbsp/m68k/mvme167/bsp_specs
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/bsp_specs	Thu Jan 13 15:45:07 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/bsp_specs	Thu Mar  2 19:16:39 2000
***************
*** 8,21 ****
  %(old_cpp) %{qrtems: -D__embedded__} -Asystem(embedded)
  
  *endfile:
! %{qelf: crtend.o%s crtn.o%s}
  
  *lib:
  %{!qrtems: %(old_lib)} %{qrtems: --start-group \
  %{!qrtems_debug: -lrtemsall} %{qrtems_debug: -lrtemsall_g} \
! -lc -lgcc --end-group \
! %{!qelf: %{!qnolinkcmds: -T linkcmds%s}} %{qelf: %{!qnolinkcmd: -T
! linkcmds%s}}}
  
  *startfile:
  %{!qrtems: %(old_startfile)} %{qrtems: \
--- 8,21 ----
  %(old_cpp) %{qrtems: -D__embedded__} -Asystem(embedded)
  
  *endfile:
! %{!qrtems: %(old_endfile)} \
! %{qrtems: crtend.o%s crtn.o%s}
  
  *lib:
  %{!qrtems: %(old_lib)} %{qrtems: --start-group \
  %{!qrtems_debug: -lrtemsall} %{qrtems_debug: -lrtemsall_g} \
! %{qjava: -lffi -lzgcj -lgcj} %{qc++: -lstdc++} -lc -lgcc --end-group \
! %{!qnolinkcmds: -T linkcmds%s}}
  
  *startfile:
  %{!qrtems: %(old_startfile)} %{qrtems: \
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/clock/Makefile.am rtems/c/src/lib/libbsp/m68k/mvme167/clock/Makefile.am
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/clock/Makefile.am	Fri Feb 25 09:50:41 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/clock/Makefile.am	Thu Feb 10 10:19:22 2000
***************
*** 1,5 ****
  ## 
! ## $Id: Makefile.am,v 1.1.2.1 2000/02/25 14:50:41 joel Exp $
  ## 
  
  AUTOMAKE_OPTIONS = foreign 1.4
--- 1,5 ----
  ## 
! ## $Id: Makefile.am,v 1.1.1.1 2000/02/10 15:19:22 cotton Exp $
  ## 
  
  AUTOMAKE_OPTIONS = foreign 1.4
***************
*** 23,29 ****
  
  # the .rel file built here will be put into libbsp.a by ../wrapup/Makefile
  
! all: $(ARCH) $(OBJS) $(PGM)
  
  .PRECIOUS: $(PGM)
  
--- 23,29 ----
  
  # the .rel file built here will be put into libbsp.a by ../wrapup/Makefile
  
! all-local: $(ARCH) $(OBJS) $(PGM)
  
  .PRECIOUS: $(PGM)
  
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/clock/Makefile.in rtems/c/src/lib/libbsp/m68k/mvme167/clock/Makefile.in
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/clock/Makefile.in	Tue Feb 29 09:21:59 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/clock/Makefile.in	Thu Mar  2 12:59:01 2000
***************
*** 66,75 ****
  host_triplet = @host@
  target_alias = @target_alias@
  target_triplet = @target@
! CC = @CC@
! CC_FOR_TARGET = @CC_FOR_TARGET@
! CPP = @CPP@
! GCCSED = @GCCSED@
  MAINT = @MAINT@
  MAKEINFO = @MAKEINFO@
  PACKAGE = @PACKAGE@
--- 66,72 ----
  host_triplet = @host@
  target_alias = @target_alias@
  target_triplet = @target@
! INSTALL_CHANGE = @INSTALL_CHANGE@
  MAINT = @MAINT@
  MAKEINFO = @MAKEINFO@
  PACKAGE = @PACKAGE@
***************
*** 160,166 ****
  install: install-am
  uninstall-am:
  uninstall: uninstall-am
! all-am: Makefile
  all-redirect: all-am
  install-strip:
  	$(MAKE) $(AM_MAKEFLAGS) INSTALL_STRIP_FLAG=-s install
--- 157,163 ----
  install: install-am
  uninstall-am:
  uninstall: uninstall-am
! all-am: Makefile all-local
  all-redirect: all-am
  install-strip:
  	$(MAKE) $(AM_MAKEFLAGS) INSTALL_STRIP_FLAG=-s install
***************
*** 197,203 ****
  .PHONY: tags distdir info-am info dvi-am dvi check check-am \
  installcheck-am installcheck install-exec-am install-exec \
  install-data-am install-data install-am install uninstall-am uninstall \
! all-redirect all-am all installdirs mostlyclean-generic \
  distclean-generic clean-generic maintainer-clean-generic clean \
  mostlyclean distclean maintainer-clean
  
--- 194,200 ----
  .PHONY: tags distdir info-am info dvi-am dvi check check-am \
  installcheck-am installcheck install-exec-am install-exec \
  install-data-am install-data install-am install uninstall-am uninstall \
! all-local all-redirect all-am all installdirs mostlyclean-generic \
  distclean-generic clean-generic maintainer-clean-generic clean \
  mostlyclean distclean maintainer-clean
  
***************
*** 226,249 ****
  
  # the .rel file built here will be put into libbsp.a by ../wrapup/Makefile
  
! all: $(ARCH) $(OBJS) $(PGM)
  
  .PRECIOUS: $(PGM)
  
  debug-am:
- 	$(MAKE) $(AM_MAKEFLAGS) "ARCH=o-debug" \
-       "CFLAGS_DEBUG=$(CFLAGS_DEBUG_V)" \
-       "CFLAGS_OPTIMIZE=$(CFLAGS_DEBUG_OPTIMIZE_V)" \
-       "LDFLAGS_DEBUG=$(LDFLAGS_DEBUG_V)" $(TARGET_VA)
- 
  debug: debug-am
  .PHONY: debug debug-am
  
  profile-am:
- 	$(MAKE) $(AM_MAKEFLAGS) "ARCH=o-profile" \
-       "CFLAGS_PROFILE=$(CFLAGS_PROFILE_V)" \
-       "LDFLAGS_PROFILE=$(LDFLAGS_PROFILE_V)" $(TARGET_VA)
- 
  profile: profile-am
  .PHONY: profile profile-am
  
--- 223,237 ----
  
  # the .rel file built here will be put into libbsp.a by ../wrapup/Makefile
  
! all-local: $(ARCH) $(OBJS) $(PGM)
  
  .PRECIOUS: $(PGM)
  
  debug-am:
  debug: debug-am
  .PHONY: debug debug-am
  
  profile-am:
  profile: profile-am
  .PHONY: profile profile-am
  
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/configure rtems/c/src/lib/libbsp/m68k/mvme167/configure
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/configure	Tue Feb 29 09:21:58 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/configure	Tue Mar  7 11:57:06 2000
***************
*** 18,23 ****
--- 18,25 ----
                            (and sometimes confusing) to the casual installer"
  ac_help="$ac_help
    --enable-libcdir=directory           set the directory for the C library"
+ ac_help="$ac_help
+   --enable-networking                  enable TCP/IP stack"
  
  # Initialize some variables set by options.
  # The variables have the same names as the options, with
***************
*** 542,548 ****
  
  
  echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
! echo "configure:546: checking for RTEMS Version" >&5
  if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
  RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
  sed -e 's%RTEMS[ 	]*Version[ 	]*\(.*\)[ 	]*%\1%g'`
--- 544,550 ----
  
  
  echo $ac_n "checking for RTEMS Version""... $ac_c" 1>&6
! echo "configure:548: checking for RTEMS Version" >&5
  if test -r "${srcdir}/${RTEMS_TOPdir}/VERSION"; then
  RTEMS_VERSION=`grep Version ${srcdir}/${RTEMS_TOPdir}/VERSION | \
  sed -e 's%RTEMS[ 	]*Version[ 	]*\(.*\)[ 	]*%\1%g'`
***************
*** 603,609 ****
  fi
  
  echo $ac_n "checking host system type""... $ac_c" 1>&6
! echo "configure:607: checking host system type" >&5
  
  host_alias=$host
  case "$host_alias" in
--- 605,611 ----
  fi
  
  echo $ac_n "checking host system type""... $ac_c" 1>&6
! echo "configure:609: checking host system type" >&5
  
  host_alias=$host
  case "$host_alias" in
***************
*** 624,630 ****
  echo "$ac_t""$host" 1>&6
  
  echo $ac_n "checking target system type""... $ac_c" 1>&6
! echo "configure:628: checking target system type" >&5
  
  target_alias=$target
  case "$target_alias" in
--- 626,632 ----
  echo "$ac_t""$host" 1>&6
  
  echo $ac_n "checking target system type""... $ac_c" 1>&6
! echo "configure:630: checking target system type" >&5
  
  target_alias=$target
  case "$target_alias" in
***************
*** 642,648 ****
  echo "$ac_t""$target" 1>&6
  
  echo $ac_n "checking build system type""... $ac_c" 1>&6
! echo "configure:646: checking build system type" >&5
  
  build_alias=$build
  case "$build_alias" in
--- 644,650 ----
  echo "$ac_t""$target" 1>&6
  
  echo $ac_n "checking build system type""... $ac_c" 1>&6
! echo "configure:648: checking build system type" >&5
  
  build_alias=$build
  case "$build_alias" in
***************
*** 665,671 ****
    program_prefix=${target_alias}-
  
  echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
! echo "configure:669: checking rtems target cpu" >&5
  case "${target}" in
    # hpux unix port should go here
    i[3456]86-pc-linux*)		# unix "simulator" port
--- 667,673 ----
    program_prefix=${target_alias}-
  
  echo $ac_n "checking rtems target cpu""... $ac_c" 1>&6
! echo "configure:671: checking rtems target cpu" >&5
  case "${target}" in
    # hpux unix port should go here
    i[3456]86-pc-linux*)		# unix "simulator" port
***************
*** 699,705 ****
  # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
  # ./install, which can be erroneously created by make from ./install.sh.
  echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
! echo "configure:703: checking for a BSD compatible install" >&5
  if test -z "$INSTALL"; then
  if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
    echo $ac_n "(cached) $ac_c" 1>&6
--- 701,707 ----
  # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
  # ./install, which can be erroneously created by make from ./install.sh.
  echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
! echo "configure:705: checking for a BSD compatible install" >&5
  if test -z "$INSTALL"; then
  if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
    echo $ac_n "(cached) $ac_c" 1>&6
***************
*** 752,758 ****
  test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
  
  echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
! echo "configure:756: checking whether build environment is sane" >&5
  # Just in case
  sleep 1
  echo timestamp > conftestfile
--- 754,760 ----
  test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
  
  echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
! echo "configure:758: checking whether build environment is sane" >&5
  # Just in case
  sleep 1
  echo timestamp > conftestfile
***************
*** 809,815 ****
  test "$program_transform_name" = "" && program_transform_name="s,x,x,"
  
  echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
! echo "configure:813: checking whether ${MAKE-make} sets \${MAKE}" >&5
  set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
  if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
    echo $ac_n "(cached) $ac_c" 1>&6
--- 811,817 ----
  test "$program_transform_name" = "" && program_transform_name="s,x,x,"
  
  echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
! echo "configure:815: checking whether ${MAKE-make} sets \${MAKE}" >&5
  set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
  if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
    echo $ac_n "(cached) $ac_c" 1>&6
***************
*** 836,842 ****
  fi
  
  
- 
  PACKAGE=rtems-c-src-lib-libbsp-m68k-mvme167
  
  VERSION=$RTEMS_VERSION
--- 838,843 ----
***************
*** 849,855 ****
  
  missing_dir=`cd $ac_aux_dir && pwd`
  echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
! echo "configure:853: checking for working aclocal" >&5
  # Run test in a subshell; some versions of sh will print an error if
  # an executable is not found, even if stderr is redirected.
  # Redirect stdin to placate older versions of autoconf.  Sigh.
--- 850,856 ----
  
  missing_dir=`cd $ac_aux_dir && pwd`
  echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
! echo "configure:854: checking for working aclocal" >&5
  # Run test in a subshell; some versions of sh will print an error if
  # an executable is not found, even if stderr is redirected.
  # Redirect stdin to placate older versions of autoconf.  Sigh.
***************
*** 862,868 ****
  fi
  
  echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
! echo "configure:866: checking for working autoconf" >&5
  # Run test in a subshell; some versions of sh will print an error if
  # an executable is not found, even if stderr is redirected.
  # Redirect stdin to placate older versions of autoconf.  Sigh.
--- 863,869 ----
  fi
  
  echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
! echo "configure:867: checking for working autoconf" >&5
  # Run test in a subshell; some versions of sh will print an error if
  # an executable is not found, even if stderr is redirected.
  # Redirect stdin to placate older versions of autoconf.  Sigh.
***************
*** 875,881 ****
  fi
  
  echo $ac_n "checking for working automake""... $ac_c" 1>&6
! echo "configure:879: checking for working automake" >&5
  # Run test in a subshell; some versions of sh will print an error if
  # an executable is not found, even if stderr is redirected.
  # Redirect stdin to placate older versions of autoconf.  Sigh.
--- 876,882 ----
  fi
  
  echo $ac_n "checking for working automake""... $ac_c" 1>&6
! echo "configure:880: checking for working automake" >&5
  # Run test in a subshell; some versions of sh will print an error if
  # an executable is not found, even if stderr is redirected.
  # Redirect stdin to placate older versions of autoconf.  Sigh.
***************
*** 888,894 ****
  fi
  
  echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
! echo "configure:892: checking for working autoheader" >&5
  # Run test in a subshell; some versions of sh will print an error if
  # an executable is not found, even if stderr is redirected.
  # Redirect stdin to placate older versions of autoconf.  Sigh.
--- 889,895 ----
  fi
  
  echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
! echo "configure:893: checking for working autoheader" >&5
  # Run test in a subshell; some versions of sh will print an error if
  # an executable is not found, even if stderr is redirected.
  # Redirect stdin to placate older versions of autoconf.  Sigh.
***************
*** 901,907 ****
  fi
  
  echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
! echo "configure:905: checking for working makeinfo" >&5
  # Run test in a subshell; some versions of sh will print an error if
  # an executable is not found, even if stderr is redirected.
  # Redirect stdin to placate older versions of autoconf.  Sigh.
--- 902,908 ----
  fi
  
  echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
! echo "configure:906: checking for working makeinfo" >&5
  # Run test in a subshell; some versions of sh will print an error if
  # an executable is not found, even if stderr is redirected.
  # Redirect stdin to placate older versions of autoconf.  Sigh.
***************
*** 915,921 ****
  
  
  echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
! echo "configure:919: checking whether to enable maintainer-specific portions of Makefiles" >&5
      # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
  if test "${enable_maintainer_mode+set}" = set; then
    enableval="$enable_maintainer_mode"
--- 916,922 ----
  
  
  echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
! echo "configure:920: checking whether to enable maintainer-specific portions of Makefiles" >&5
      # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
  if test "${enable_maintainer_mode+set}" = set; then
    enableval="$enable_maintainer_mode"
***************
*** 939,953 ****
  
  
  
- if [ "${program_prefix}" = "NONE" ] ; then
-   if [ "${target}" = "${host}" ] ; then
-     program_prefix=
-   else
-     program_prefix=${target}-
-   fi
- fi
- 
- 
  # Check whether --enable-libcdir or --disable-libcdir was given.
  if test "${enable_libcdir+set}" = set; then
    enableval="$enable_libcdir"
--- 940,945 ----
***************
*** 958,1871 ****
  
  
  
- 
- for ac_prog in "$program_prefix"gcc "$program_prefix"cc 
- do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
- set dummy $ac_prog; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
- echo "configure:968: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_path_CC_FOR_TARGET'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   case "$CC_FOR_TARGET" in
-   /*)
-   ac_cv_path_CC_FOR_TARGET="$CC_FOR_TARGET" # Let the user override the test with a path.
-   ;;
-   ?:/*)			 
-   ac_cv_path_CC_FOR_TARGET="$CC_FOR_TARGET" # Let the user override the test with a dos path.
-   ;;
-   *)
-   IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
-   ac_dummy="$PATH"
-   for ac_dir in $ac_dummy; do 
-     test -z "$ac_dir" && ac_dir=.
-     if test -f $ac_dir/$ac_word; then
-       ac_cv_path_CC_FOR_TARGET="$ac_dir/$ac_word"
-       break
-     fi
-   done
-   IFS="$ac_save_ifs"
-   ;;
- esac
- fi
- CC_FOR_TARGET="$ac_cv_path_CC_FOR_TARGET"
- if test -n "$CC_FOR_TARGET"; then
-   echo "$ac_t""$CC_FOR_TARGET" 1>&6
- else
-   echo "$ac_t""no" 1>&6
- fi
- 
- test -n "$CC_FOR_TARGET" && break
- done
- 
- test -z "$CC_FOR_TARGET" \
-   && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
- 
- rtems_save_CC=$CC
- rtems_save_CFLAGS=$CFLAGS
- 
- CC=$CC_FOR_TARGET
- 
- echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
- echo "configure:1012: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
- 
- ac_ext=c
- # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
- ac_cpp='$CPP $CPPFLAGS'
- ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
- ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
- cross_compiling=$ac_cv_prog_cc_cross
- 
- cat > conftest.$ac_ext << EOF
- 
- #line 1023 "configure"
- #include "confdefs.h"
- 
- main(){return(0);}
- EOF
- if { (eval echo configure:1028: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-   ac_cv_prog_cc_works=yes
-   # If we can't run a trivial program, we are probably using a cross compiler.
-   if (./conftest; exit) 2>/dev/null; then
-     ac_cv_prog_cc_cross=no
-   else
-     ac_cv_prog_cc_cross=yes
-   fi
- else
-   echo "configure: failed program was:" >&5
-   cat conftest.$ac_ext >&5
-   ac_cv_prog_cc_works=no
- fi
- rm -fr conftest*
- ac_ext=c
- # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
- ac_cpp='$CPP $CPPFLAGS'
- ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
- ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
- cross_compiling=$ac_cv_prog_cc_cross
- 
- echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
- if test $ac_cv_prog_cc_works = no; then
-   { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
- fi
- echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
- echo "configure:1054: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
- echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
- cross_compiling=$ac_cv_prog_cc_cross
- 
- echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
- echo "configure:1059: checking whether we are using GNU C" >&5
- if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   cat > conftest.c <<EOF
- #ifdef __GNUC__
-   yes;
- #endif
- EOF
- if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1068: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
-   ac_cv_prog_gcc=yes
- else
-   ac_cv_prog_gcc=no
- fi
- fi
- 
- echo "$ac_t""$ac_cv_prog_gcc" 1>&6
- 
- if test $ac_cv_prog_gcc = yes; then
-   GCC=yes
-   ac_test_CFLAGS="${CFLAGS+set}"
-   ac_save_CFLAGS="$CFLAGS"
-   CFLAGS=
-   echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
- echo "configure:1083: checking whether ${CC-cc} accepts -g" >&5
- if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   echo 'void f(){}' > conftest.c
- if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
-   ac_cv_prog_cc_g=yes
- else
-   ac_cv_prog_cc_g=no
- fi
- rm -f conftest*
- 
- fi
- 
- echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
-   if test "$ac_test_CFLAGS" = set; then
-     CFLAGS="$ac_save_CFLAGS"
-   elif test $ac_cv_prog_cc_g = yes; then
-     CFLAGS="-g -O2"
-   else
-     CFLAGS="-O2"
-   fi
- else
-   GCC=
-   test "${CFLAGS+set}" = set || CFLAGS="-g"
- fi
- 
- rtems_cv_prog_gcc=$ac_cv_prog_gcc
- rtems_cv_prog_cc_g=$ac_cv_prog_cc_g
- rtems_cv_prog_cc_works=$ac_cv_prog_cc_works
- rtems_cv_prog_cc_cross=$ac_cv_prog_cc_cross
- 
- CC=$rtems_save_CC
- CFLAGS=$rtems_save_CFLAGS
- 
- unset ac_cv_prog_gcc
- unset ac_cv_prog_cc_g
- unset ac_cv_prog_cc_works
- unset ac_cv_prog_cc_cross
- 
- 
- echo $ac_n "checking whether $CC_FOR_TARGET accepts -specs""... $ac_c" 1>&6
- echo "configure:1125: checking whether $CC_FOR_TARGET accepts -specs" >&5
- if eval "test \"`echo '$''{'rtems_cv_gcc_specs'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   
- rtems_cv_gcc_specs=no
- if test "$rtems_cv_prog_gcc" = "yes"; then
-   touch confspec
-   echo 'void f(){}' >conftest.c
-   if test -z "`${CC_FOR_TARGET} -specs confspec -c conftest.c 2>&1`";then
-     rtems_cv_gcc_specs=yes
-   fi
- fi
- rm -f confspec conftest*
- 
- fi
- 
- echo "$ac_t""$rtems_cv_gcc_specs" 1>&6
-  
- 
- echo $ac_n "checking whether $CC_FOR_TARGET accepts --pipe""... $ac_c" 1>&6
- echo "configure:1146: checking whether $CC_FOR_TARGET accepts --pipe" >&5
- if eval "test \"`echo '$''{'rtems_cv_gcc_pipe'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   
- rtems_cv_gcc_pipe=no
- if test "$rtems_cv_prog_gcc" = "yes"; then
-     echo 'void f(){}' >conftest.c
-     if test -z "`${CC_FOR_TARGET} --pipe -c conftest.c 2>&1`";then
-       rtems_cv_gcc_pipe=yes
-     fi
-     rm -f conftest*
- fi
- 
- fi
- 
- echo "$ac_t""$rtems_cv_gcc_pipe" 1>&6
- 
- if test "$RTEMS_USE_GCC272" != "yes" ; then
-   if test "$rtems_cv_gcc_specs" = "no"; then
-     echo "configure: warning: *** disabling --enable-gcc28" 1>&2
-       RTEMS_USE_GCC272=yes
-   fi
- fi
- test "$rtems_cv_gcc_pipe" = "yes" && CC_FOR_TARGET="$CC_FOR_TARGET --pipe"
- 
- case $host_os in
- *cygwin*)     GCCSED="| sed 's%\\\\%/%g'" ;;
- *) ;;
- esac
- 
- 
- 
-   
- echo $ac_n "checking target's ar""... $ac_c" 1>&6
- echo "configure:1181: checking target's ar" >&5
- if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   :
- fi
- 
- echo "$ac_t""$ac_cv_path_AR_FOR_TARGET" 1>&6
- 
- if test -n "$ac_cv_path_AR_FOR_TARGET"; then
-     AR_FOR_TARGET=$ac_cv_path_AR_FOR_TARGET
- else
-     if test -z "$AR_FOR_TARGET" ; then
-     if test "$rtems_cv_prog_gcc" = "yes"; then
-       # We are using gcc, ask it about its tool
-       # NOTE: Necessary if gcc was configured to use the target's 
-       # native tools or uses prefixes for gnutools (e.g. gas instead of as)
-       
-     AR_FOR_TARGET=`$CC_FOR_TARGET --print-prog-name=ar`
- 
-     fi
-   else
-     # The user set an environment variable.
-     # Check whether it is an absolute path, otherwise AC_PATH_PROG 
-     # will override the environment variable, which isn't what the user
-     # intends
-     echo $ac_n "checking whether environment variable AR_FOR_TARGET is an absolute path""... $ac_c" 1>&6
- echo "configure:1208: checking whether environment variable AR_FOR_TARGET is an absolute path" >&5
-     case "$AR_FOR_TARGET" in
-     /*) # valid
-       echo "$ac_t"""yes"" 1>&6
-     ;;
-     *)  # invalid for AC_PATH_PROG
-       echo "$ac_t"""no"" 1>&6
-       { echo "configure: error: ***
-         Environment variable AR_FOR_TARGET should either
- 	be unset (preferred) or contain an absolute path" 1>&2; exit 1; }
-     ;;
-     esac
-   fi
- 
-   # Extract the first word of ""$program_prefix"ar", so it can be a program name with args.
- set dummy "$program_prefix"ar; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
- echo "configure:1225: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_path_AR_FOR_TARGET'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   case "$AR_FOR_TARGET" in
-   /*)
-   ac_cv_path_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test with a path.
-   ;;
-   ?:/*)			 
-   ac_cv_path_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test with a dos path.
-   ;;
-   *)
-   IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
-   ac_dummy="$PATH"
-   for ac_dir in $ac_dummy; do 
-     test -z "$ac_dir" && ac_dir=.
-     if test -f $ac_dir/$ac_word; then
-       ac_cv_path_AR_FOR_TARGET="$ac_dir/$ac_word"
-       break
-     fi
-   done
-   IFS="$ac_save_ifs"
-   test -z "$ac_cv_path_AR_FOR_TARGET" && ac_cv_path_AR_FOR_TARGET="no"
-   ;;
- esac
- fi
- AR_FOR_TARGET="$ac_cv_path_AR_FOR_TARGET"
- if test -n "$AR_FOR_TARGET"; then
-   echo "$ac_t""$AR_FOR_TARGET" 1>&6
- else
-   echo "$ac_t""no" 1>&6
- fi
- 
- fi
- 
-   
- echo $ac_n "checking target's as""... $ac_c" 1>&6
- echo "configure:1262: checking target's as" >&5
- if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   :
- fi
- 
- echo "$ac_t""$ac_cv_path_AS_FOR_TARGET" 1>&6
- 
- if test -n "$ac_cv_path_AS_FOR_TARGET"; then
-     AS_FOR_TARGET=$ac_cv_path_AS_FOR_TARGET
- else
-     if test -z "$AS_FOR_TARGET" ; then
-     if test "$rtems_cv_prog_gcc" = "yes"; then
-       # We are using gcc, ask it about its tool
-       # NOTE: Necessary if gcc was configured to use the target's 
-       # native tools or uses prefixes for gnutools (e.g. gas instead of as)
-       
-     AS_FOR_TARGET=`$CC_FOR_TARGET --print-prog-name=as`
- 
-     fi
-   else
-     # The user set an environment variable.
-     # Check whether it is an absolute path, otherwise AC_PATH_PROG 
-     # will override the environment variable, which isn't what the user
-     # intends
-     echo $ac_n "checking whether environment variable AS_FOR_TARGET is an absolute path""... $ac_c" 1>&6
- echo "configure:1289: checking whether environment variable AS_FOR_TARGET is an absolute path" >&5
-     case "$AS_FOR_TARGET" in
-     /*) # valid
-       echo "$ac_t"""yes"" 1>&6
-     ;;
-     *)  # invalid for AC_PATH_PROG
-       echo "$ac_t"""no"" 1>&6
-       { echo "configure: error: ***
-         Environment variable AS_FOR_TARGET should either
- 	be unset (preferred) or contain an absolute path" 1>&2; exit 1; }
-     ;;
-     esac
-   fi
- 
-   # Extract the first word of ""$program_prefix"as", so it can be a program name with args.
- set dummy "$program_prefix"as; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
- echo "configure:1306: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_path_AS_FOR_TARGET'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   case "$AS_FOR_TARGET" in
-   /*)
-   ac_cv_path_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test with a path.
-   ;;
-   ?:/*)			 
-   ac_cv_path_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test with a dos path.
-   ;;
-   *)
-   IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
-   ac_dummy="$PATH"
-   for ac_dir in $ac_dummy; do 
-     test -z "$ac_dir" && ac_dir=.
-     if test -f $ac_dir/$ac_word; then
-       ac_cv_path_AS_FOR_TARGET="$ac_dir/$ac_word"
-       break
-     fi
-   done
-   IFS="$ac_save_ifs"
-   test -z "$ac_cv_path_AS_FOR_TARGET" && ac_cv_path_AS_FOR_TARGET="no"
-   ;;
- esac
- fi
- AS_FOR_TARGET="$ac_cv_path_AS_FOR_TARGET"
- if test -n "$AS_FOR_TARGET"; then
-   echo "$ac_t""$AS_FOR_TARGET" 1>&6
- else
-   echo "$ac_t""no" 1>&6
- fi
- 
- fi
- 
-   
- echo $ac_n "checking target's ld""... $ac_c" 1>&6
- echo "configure:1343: checking target's ld" >&5
- if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   :
- fi
- 
- echo "$ac_t""$ac_cv_path_LD_FOR_TARGET" 1>&6
- 
- if test -n "$ac_cv_path_LD_FOR_TARGET"; then
-     LD_FOR_TARGET=$ac_cv_path_LD_FOR_TARGET
- else
-     if test -z "$LD_FOR_TARGET" ; then
-     if test "$rtems_cv_prog_gcc" = "yes"; then
-       # We are using gcc, ask it about its tool
-       # NOTE: Necessary if gcc was configured to use the target's 
-       # native tools or uses prefixes for gnutools (e.g. gas instead of as)
-       
-     LD_FOR_TARGET=`$CC_FOR_TARGET --print-prog-name=ld`
- 
-     fi
-   else
-     # The user set an environment variable.
-     # Check whether it is an absolute path, otherwise AC_PATH_PROG 
-     # will override the environment variable, which isn't what the user
-     # intends
-     echo $ac_n "checking whether environment variable LD_FOR_TARGET is an absolute path""... $ac_c" 1>&6
- echo "configure:1370: checking whether environment variable LD_FOR_TARGET is an absolute path" >&5
-     case "$LD_FOR_TARGET" in
-     /*) # valid
-       echo "$ac_t"""yes"" 1>&6
-     ;;
-     *)  # invalid for AC_PATH_PROG
-       echo "$ac_t"""no"" 1>&6
-       { echo "configure: error: ***
-         Environment variable LD_FOR_TARGET should either
- 	be unset (preferred) or contain an absolute path" 1>&2; exit 1; }
-     ;;
-     esac
-   fi
- 
-   # Extract the first word of ""$program_prefix"ld", so it can be a program name with args.
- set dummy "$program_prefix"ld; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
- echo "configure:1387: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_path_LD_FOR_TARGET'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   case "$LD_FOR_TARGET" in
-   /*)
-   ac_cv_path_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test with a path.
-   ;;
-   ?:/*)			 
-   ac_cv_path_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test with a dos path.
-   ;;
-   *)
-   IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
-   ac_dummy="$PATH"
-   for ac_dir in $ac_dummy; do 
-     test -z "$ac_dir" && ac_dir=.
-     if test -f $ac_dir/$ac_word; then
-       ac_cv_path_LD_FOR_TARGET="$ac_dir/$ac_word"
-       break
-     fi
-   done
-   IFS="$ac_save_ifs"
-   test -z "$ac_cv_path_LD_FOR_TARGET" && ac_cv_path_LD_FOR_TARGET="no"
-   ;;
- esac
- fi
- LD_FOR_TARGET="$ac_cv_path_LD_FOR_TARGET"
- if test -n "$LD_FOR_TARGET"; then
-   echo "$ac_t""$LD_FOR_TARGET" 1>&6
- else
-   echo "$ac_t""no" 1>&6
- fi
- 
- fi
- 
-   
- echo $ac_n "checking target's nm""... $ac_c" 1>&6
- echo "configure:1424: checking target's nm" >&5
- if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   :
- fi
- 
- echo "$ac_t""$ac_cv_path_NM_FOR_TARGET" 1>&6
- 
- if test -n "$ac_cv_path_NM_FOR_TARGET"; then
-     NM_FOR_TARGET=$ac_cv_path_NM_FOR_TARGET
- else
-     if test -z "$NM_FOR_TARGET" ; then
-     if test "$rtems_cv_prog_gcc" = "yes"; then
-       # We are using gcc, ask it about its tool
-       # NOTE: Necessary if gcc was configured to use the target's 
-       # native tools or uses prefixes for gnutools (e.g. gas instead of as)
-       
-     NM_FOR_TARGET=`$CC_FOR_TARGET --print-prog-name=nm`
- 
-     fi
-   else
-     # The user set an environment variable.
-     # Check whether it is an absolute path, otherwise AC_PATH_PROG 
-     # will override the environment variable, which isn't what the user
-     # intends
-     echo $ac_n "checking whether environment variable NM_FOR_TARGET is an absolute path""... $ac_c" 1>&6
- echo "configure:1451: checking whether environment variable NM_FOR_TARGET is an absolute path" >&5
-     case "$NM_FOR_TARGET" in
-     /*) # valid
-       echo "$ac_t"""yes"" 1>&6
-     ;;
-     *)  # invalid for AC_PATH_PROG
-       echo "$ac_t"""no"" 1>&6
-       { echo "configure: error: ***
-         Environment variable NM_FOR_TARGET should either
- 	be unset (preferred) or contain an absolute path" 1>&2; exit 1; }
-     ;;
-     esac
-   fi
- 
-   # Extract the first word of ""$program_prefix"nm", so it can be a program name with args.
- set dummy "$program_prefix"nm; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
- echo "configure:1468: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_path_NM_FOR_TARGET'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   case "$NM_FOR_TARGET" in
-   /*)
-   ac_cv_path_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test with a path.
-   ;;
-   ?:/*)			 
-   ac_cv_path_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test with a dos path.
-   ;;
-   *)
-   IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
-   ac_dummy="$PATH"
-   for ac_dir in $ac_dummy; do 
-     test -z "$ac_dir" && ac_dir=.
-     if test -f $ac_dir/$ac_word; then
-       ac_cv_path_NM_FOR_TARGET="$ac_dir/$ac_word"
-       break
-     fi
-   done
-   IFS="$ac_save_ifs"
-   test -z "$ac_cv_path_NM_FOR_TARGET" && ac_cv_path_NM_FOR_TARGET="no"
-   ;;
- esac
- fi
- NM_FOR_TARGET="$ac_cv_path_NM_FOR_TARGET"
- if test -n "$NM_FOR_TARGET"; then
-   echo "$ac_t""$NM_FOR_TARGET" 1>&6
- else
-   echo "$ac_t""no" 1>&6
- fi
- 
- fi
- 
- 
-   
- echo $ac_n "checking target's ranlib""... $ac_c" 1>&6
- echo "configure:1506: checking target's ranlib" >&5
- if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   :
- fi
- 
- echo "$ac_t""$ac_cv_path_RANLIB_FOR_TARGET" 1>&6
- 
- if test -n "$ac_cv_path_RANLIB_FOR_TARGET"; then
-     RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
- else
-     if test -z "$RANLIB_FOR_TARGET" ; then
-     if test "$rtems_cv_prog_gcc" = "yes"; then
-       # We are using gcc, ask it about its tool
-       # NOTE: Necessary if gcc was configured to use the target's 
-       # native tools or uses prefixes for gnutools (e.g. gas instead of as)
-       
-     RANLIB_FOR_TARGET=`$CC_FOR_TARGET --print-prog-name=ranlib`
- 
-     fi
-   else
-     # The user set an environment variable.
-     # Check whether it is an absolute path, otherwise AC_PATH_PROG 
-     # will override the environment variable, which isn't what the user
-     # intends
-     echo $ac_n "checking whether environment variable RANLIB_FOR_TARGET is an absolute path""... $ac_c" 1>&6
- echo "configure:1533: checking whether environment variable RANLIB_FOR_TARGET is an absolute path" >&5
-     case "$RANLIB_FOR_TARGET" in
-     /*) # valid
-       echo "$ac_t"""yes"" 1>&6
-     ;;
-     *)  # invalid for AC_PATH_PROG
-       echo "$ac_t"""no"" 1>&6
-       { echo "configure: error: ***
-         Environment variable RANLIB_FOR_TARGET should either
- 	be unset (preferred) or contain an absolute path" 1>&2; exit 1; }
-     ;;
-     esac
-   fi
- 
-   # Extract the first word of ""$program_prefix"ranlib", so it can be a program name with args.
- set dummy "$program_prefix"ranlib; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
- echo "configure:1550: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_path_RANLIB_FOR_TARGET'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   case "$RANLIB_FOR_TARGET" in
-   /*)
-   ac_cv_path_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test with a path.
-   ;;
-   ?:/*)			 
-   ac_cv_path_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test with a dos path.
-   ;;
-   *)
-   IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
-   ac_dummy="$PATH"
-   for ac_dir in $ac_dummy; do 
-     test -z "$ac_dir" && ac_dir=.
-     if test -f $ac_dir/$ac_word; then
-       ac_cv_path_RANLIB_FOR_TARGET="$ac_dir/$ac_word"
-       break
-     fi
-   done
-   IFS="$ac_save_ifs"
-   test -z "$ac_cv_path_RANLIB_FOR_TARGET" && ac_cv_path_RANLIB_FOR_TARGET="no"
-   ;;
- esac
- fi
- RANLIB_FOR_TARGET="$ac_cv_path_RANLIB_FOR_TARGET"
- if test -n "$RANLIB_FOR_TARGET"; then
-   echo "$ac_t""$RANLIB_FOR_TARGET" 1>&6
- else
-   echo "$ac_t""no" 1>&6
- fi
- 
- fi
- 
-   if test "$RANLIB_FOR_TARGET" = "no"; then
-     # ranlib wasn't found; check if ar -s is available
-     
- echo $ac_n "checking whether $AR_FOR_TARGET -s works""... $ac_c" 1>&6
- echo "configure:1589: checking whether $AR_FOR_TARGET -s works" >&5
- if eval "test \"`echo '$''{'rtems_cv_AR_FOR_TARGET_S'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   
- cat > conftest.$ac_ext <<EOF
- int foo( int b ) 
- { return b; }
- EOF
- if { ac_try='$CC_FOR_TARGET -o conftest.o -c conftest.$ac_ext'; { (eval echo configure:1598: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
-   && { ac_try='$AR_FOR_TARGET -sr conftest.a conftest.o'; { (eval echo configure:1599: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } \
-   && test -s conftest.a ; \
- then
-   rtems_cv_AR_FOR_TARGET_S="yes"
- else
-   rtems_cv_AR_FOR_TARGET_S="no"
- fi
-   rm -f conftest*
- 
- fi
- 
- echo "$ac_t""$rtems_cv_AR_FOR_TARGET_S" 1>&6
- 
-     if test $rtems_cv_AR_FOR_TARGET_S = "yes" ; then
-             ac_cv_path_RANLIB_FOR_TARGET="$AR_FOR_TARGET -s"
-       RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
-     else
-       { echo "configure: error: ***
-         Can't figure out how to build a library index
- 	Neither ranlib nor ar -s seem to be available " 1>&2; exit 1; }
-     fi
-   fi
- 
-   
- echo $ac_n "checking target's objcopy""... $ac_c" 1>&6
- echo "configure:1624: checking target's objcopy" >&5
- if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   :
- fi
- 
- echo "$ac_t""$ac_cv_path_OBJCOPY_FOR_TARGET" 1>&6
- 
- if test -n "$ac_cv_path_OBJCOPY_FOR_TARGET"; then
-     OBJCOPY_FOR_TARGET=$ac_cv_path_OBJCOPY_FOR_TARGET
- else
-     if test -z "$OBJCOPY_FOR_TARGET" ; then
-     if test "$rtems_cv_prog_gcc" = "yes"; then
-       # We are using gcc, ask it about its tool
-       # NOTE: Necessary if gcc was configured to use the target's 
-       # native tools or uses prefixes for gnutools (e.g. gas instead of as)
-       
-     OBJCOPY_FOR_TARGET=`$CC_FOR_TARGET --print-prog-name=objcopy`
- 
-     fi
-   else
-     # The user set an environment variable.
-     # Check whether it is an absolute path, otherwise AC_PATH_PROG 
-     # will override the environment variable, which isn't what the user
-     # intends
-     echo $ac_n "checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path""... $ac_c" 1>&6
- echo "configure:1651: checking whether environment variable OBJCOPY_FOR_TARGET is an absolute path" >&5
-     case "$OBJCOPY_FOR_TARGET" in
-     /*) # valid
-       echo "$ac_t"""yes"" 1>&6
-     ;;
-     *)  # invalid for AC_PATH_PROG
-       echo "$ac_t"""no"" 1>&6
-       { echo "configure: error: ***
-         Environment variable OBJCOPY_FOR_TARGET should either
- 	be unset (preferred) or contain an absolute path" 1>&2; exit 1; }
-     ;;
-     esac
-   fi
- 
-   # Extract the first word of ""$program_prefix"objcopy", so it can be a program name with args.
- set dummy "$program_prefix"objcopy; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
- echo "configure:1668: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY_FOR_TARGET'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   case "$OBJCOPY_FOR_TARGET" in
-   /*)
-   ac_cv_path_OBJCOPY_FOR_TARGET="$OBJCOPY_FOR_TARGET" # Let the user override the test with a path.
-   ;;
-   ?:/*)			 
-   ac_cv_path_OBJCOPY_FOR_TARGET="$OBJCOPY_FOR_TARGET" # Let the user override the test with a dos path.
-   ;;
-   *)
-   IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
-   ac_dummy="$PATH"
-   for ac_dir in $ac_dummy; do 
-     test -z "$ac_dir" && ac_dir=.
-     if test -f $ac_dir/$ac_word; then
-       ac_cv_path_OBJCOPY_FOR_TARGET="$ac_dir/$ac_word"
-       break
-     fi
-   done
-   IFS="$ac_save_ifs"
-   test -z "$ac_cv_path_OBJCOPY_FOR_TARGET" && ac_cv_path_OBJCOPY_FOR_TARGET="no"
-   ;;
- esac
- fi
- OBJCOPY_FOR_TARGET="$ac_cv_path_OBJCOPY_FOR_TARGET"
- if test -n "$OBJCOPY_FOR_TARGET"; then
-   echo "$ac_t""$OBJCOPY_FOR_TARGET" 1>&6
- else
-   echo "$ac_t""no" 1>&6
- fi
- 
- fi
- 
-   
- echo $ac_n "checking target's size""... $ac_c" 1>&6
- echo "configure:1705: checking target's size" >&5
- if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   :
- fi
- 
- echo "$ac_t""$ac_cv_path_SIZE_FOR_TARGET" 1>&6
- 
- if test -n "$ac_cv_path_SIZE_FOR_TARGET"; then
-     SIZE_FOR_TARGET=$ac_cv_path_SIZE_FOR_TARGET
- else
-     if test -z "$SIZE_FOR_TARGET" ; then
-     if test "$rtems_cv_prog_gcc" = "yes"; then
-       # We are using gcc, ask it about its tool
-       # NOTE: Necessary if gcc was configured to use the target's 
-       # native tools or uses prefixes for gnutools (e.g. gas instead of as)
-       
-     SIZE_FOR_TARGET=`$CC_FOR_TARGET --print-prog-name=size`
- 
-     fi
-   else
-     # The user set an environment variable.
-     # Check whether it is an absolute path, otherwise AC_PATH_PROG 
-     # will override the environment variable, which isn't what the user
-     # intends
-     echo $ac_n "checking whether environment variable SIZE_FOR_TARGET is an absolute path""... $ac_c" 1>&6
- echo "configure:1732: checking whether environment variable SIZE_FOR_TARGET is an absolute path" >&5
-     case "$SIZE_FOR_TARGET" in
-     /*) # valid
-       echo "$ac_t"""yes"" 1>&6
-     ;;
-     *)  # invalid for AC_PATH_PROG
-       echo "$ac_t"""no"" 1>&6
-       { echo "configure: error: ***
-         Environment variable SIZE_FOR_TARGET should either
- 	be unset (preferred) or contain an absolute path" 1>&2; exit 1; }
-     ;;
-     esac
-   fi
- 
-   # Extract the first word of ""$program_prefix"size", so it can be a program name with args.
- set dummy "$program_prefix"size; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
- echo "configure:1749: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_path_SIZE_FOR_TARGET'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   case "$SIZE_FOR_TARGET" in
-   /*)
-   ac_cv_path_SIZE_FOR_TARGET="$SIZE_FOR_TARGET" # Let the user override the test with a path.
-   ;;
-   ?:/*)			 
-   ac_cv_path_SIZE_FOR_TARGET="$SIZE_FOR_TARGET" # Let the user override the test with a dos path.
-   ;;
-   *)
-   IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
-   ac_dummy="$PATH"
-   for ac_dir in $ac_dummy; do 
-     test -z "$ac_dir" && ac_dir=.
-     if test -f $ac_dir/$ac_word; then
-       ac_cv_path_SIZE_FOR_TARGET="$ac_dir/$ac_word"
-       break
-     fi
-   done
-   IFS="$ac_save_ifs"
-   test -z "$ac_cv_path_SIZE_FOR_TARGET" && ac_cv_path_SIZE_FOR_TARGET="no"
-   ;;
- esac
- fi
- SIZE_FOR_TARGET="$ac_cv_path_SIZE_FOR_TARGET"
- if test -n "$SIZE_FOR_TARGET"; then
-   echo "$ac_t""$SIZE_FOR_TARGET" 1>&6
- else
-   echo "$ac_t""no" 1>&6
- fi
- 
- fi
- 
-   
- echo $ac_n "checking target's strip""... $ac_c" 1>&6
- echo "configure:1786: checking target's strip" >&5
- if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   :
- fi
- 
- echo "$ac_t""$ac_cv_path_STRIP_FOR_TARGET" 1>&6
- 
- if test -n "$ac_cv_path_STRIP_FOR_TARGET"; then
-     STRIP_FOR_TARGET=$ac_cv_path_STRIP_FOR_TARGET
- else
-     if test -z "$STRIP_FOR_TARGET" ; then
-     if test "$rtems_cv_prog_gcc" = "yes"; then
-       # We are using gcc, ask it about its tool
-       # NOTE: Necessary if gcc was configured to use the target's 
-       # native tools or uses prefixes for gnutools (e.g. gas instead of as)
-       
-     STRIP_FOR_TARGET=`$CC_FOR_TARGET --print-prog-name=strip`
- 
-     fi
-   else
-     # The user set an environment variable.
-     # Check whether it is an absolute path, otherwise AC_PATH_PROG 
-     # will override the environment variable, which isn't what the user
-     # intends
-     echo $ac_n "checking whether environment variable STRIP_FOR_TARGET is an absolute path""... $ac_c" 1>&6
- echo "configure:1813: checking whether environment variable STRIP_FOR_TARGET is an absolute path" >&5
-     case "$STRIP_FOR_TARGET" in
-     /*) # valid
-       echo "$ac_t"""yes"" 1>&6
-     ;;
-     *)  # invalid for AC_PATH_PROG
-       echo "$ac_t"""no"" 1>&6
-       { echo "configure: error: ***
-         Environment variable STRIP_FOR_TARGET should either
- 	be unset (preferred) or contain an absolute path" 1>&2; exit 1; }
-     ;;
-     esac
-   fi
- 
-   # Extract the first word of ""$program_prefix"strip", so it can be a program name with args.
- set dummy "$program_prefix"strip; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
- echo "configure:1830: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_path_STRIP_FOR_TARGET'+set}'`\" = set"; then
-   echo $ac_n "(cached) $ac_c" 1>&6
- else
-   case "$STRIP_FOR_TARGET" in
-   /*)
-   ac_cv_path_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test with a path.
-   ;;
-   ?:/*)			 
-   ac_cv_path_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test with a dos path.
-   ;;
-   *)
-   IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
-   ac_dummy="$PATH"
-   for ac_dir in $ac_dummy; do 
-     test -z "$ac_dir" && ac_dir=.
-     if test -f $ac_dir/$ac_word; then
-       ac_cv_path_STRIP_FOR_TARGET="$ac_dir/$ac_word"
-       break
-     fi
-   done
-   IFS="$ac_save_ifs"
-   test -z "$ac_cv_path_STRIP_FOR_TARGET" && ac_cv_path_STRIP_FOR_TARGET="no"
-   ;;
- esac
- fi
- STRIP_FOR_TARGET="$ac_cv_path_STRIP_FOR_TARGET"
- if test -n "$STRIP_FOR_TARGET"; then
-   echo "$ac_t""$STRIP_FOR_TARGET" 1>&6
- else
-   echo "$ac_t""no" 1>&6
- fi
- 
- fi
- 
- 
- 
- 
  echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
! echo "configure:1869: checking for RTEMS_BSP" >&5
  if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
    echo $ac_n "(cached) $ac_c" 1>&6
  else
--- 950,957 ----
  
  
  
  echo $ac_n "checking for RTEMS_BSP""... $ac_c" 1>&6
! echo "configure:955: checking for RTEMS_BSP" >&5
  if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP'+set}'`\" = set"; then
    echo $ac_n "(cached) $ac_c" 1>&6
  else
***************
*** 1882,1888 ****
  
  
  echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
! echo "configure:1886: checking for make/custom/$RTEMS_BSP.cfg" >&5
  if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
    echo "$ac_t""yes" 1>&6
  else
--- 968,974 ----
  
  
  echo $ac_n "checking for make/custom/$RTEMS_BSP.cfg""... $ac_c" 1>&6
! echo "configure:972: checking for make/custom/$RTEMS_BSP.cfg" >&5
  if test -r "$srcdir/$RTEMS_TOPdir/make/custom/$RTEMS_BSP.cfg"; then
    echo "$ac_t""yes" 1>&6
  else
***************
*** 1894,1900 ****
  
  # Is this a supported CPU?
  echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
! echo "configure:1898: checking if cpu $RTEMS_CPU is supported" >&5
  if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
    echo "$ac_t""yes" 1>&6
  else
--- 980,986 ----
  
  # Is this a supported CPU?
  echo $ac_n "checking if cpu $RTEMS_CPU is supported""... $ac_c" 1>&6
! echo "configure:984: checking if cpu $RTEMS_CPU is supported" >&5
  if test -d "$srcdir/$RTEMS_TOPdir/c/src/exec/score/cpu/$RTEMS_CPU"; then
    echo "$ac_t""yes" 1>&6
  else
***************
*** 1903,1909 ****
  
  
  echo $ac_n "checking "for RTEMS_CPU_MODEL"""... $ac_c" 1>&6
! echo "configure:1907: checking "for RTEMS_CPU_MODEL"" >&5
  if eval "test \"`echo '$''{'rtems_cv_RTEMS_CPU_MODEL'+set}'`\" = set"; then
    echo $ac_n "(cached) $ac_c" 1>&6
  else
--- 989,995 ----
  
  
  echo $ac_n "checking "for RTEMS_CPU_MODEL"""... $ac_c" 1>&6
! echo "configure:993: checking "for RTEMS_CPU_MODEL"" >&5
  if eval "test \"`echo '$''{'rtems_cv_RTEMS_CPU_MODEL'+set}'`\" = set"; then
    echo $ac_n "(cached) $ac_c" 1>&6
  else
***************
*** 1914,1920 ****
  RTEMS_CPU_MODEL=$rtems_cv_RTEMS_CPU_MODEL
  
  echo $ac_n "checking "for RTEMS_BSP_FAMILY"""... $ac_c" 1>&6
! echo "configure:1918: checking "for RTEMS_BSP_FAMILY"" >&5
  if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP_FAMILY'+set}'`\" = set"; then
    echo $ac_n "(cached) $ac_c" 1>&6
  else
--- 1000,1006 ----
  RTEMS_CPU_MODEL=$rtems_cv_RTEMS_CPU_MODEL
  
  echo $ac_n "checking "for RTEMS_BSP_FAMILY"""... $ac_c" 1>&6
! echo "configure:1004: checking "for RTEMS_BSP_FAMILY"" >&5
  if eval "test \"`echo '$''{'rtems_cv_RTEMS_BSP_FAMILY'+set}'`\" = set"; then
    echo $ac_n "(cached) $ac_c" 1>&6
  else
***************
*** 1926,1931 ****
--- 1012,1059 ----
  
  
  
+ 
+ # Check whether --enable-networking or --disable-networking was given.
+ if test "${enable_networking+set}" = set; then
+   enableval="$enable_networking"
+   case "${enableval}" in
+   yes) RTEMS_HAS_NETWORKING=yes ;;
+   no) RTEMS_HAS_NETWORKING=no ;;
+   *)  { echo "configure: error: bad value ${enableval} for enable-networking option" 1>&2; exit 1; } ;;
+ esac
+ else
+   RTEMS_HAS_NETWORKING=yes
+ fi
+ 
+ 
+ 
+ echo $ac_n "checking whether BSP supports networking""... $ac_c" 1>&6
+ echo "configure:1032: checking whether BSP supports networking" >&5
+ if eval "test \"`echo '$''{'rtems_cv_HAS_NETWORKING'+set}'`\" = set"; then
+   echo $ac_n "(cached) $ac_c" 1>&6
+ else
+       case "$RTEMS_CPU" in
+     unix*)
+       rtems_cv_HAS_NETWORKING="no"
+       ;;
+     *)
+       if test "${RTEMS_HAS_NETWORKING}" = "yes"; then
+         rtems_cv_HAS_NETWORKING="yes";
+       else
+         rtems_cv_HAS_NETWORKING="disabled";
+       fi
+       ;;
+     esac
+ fi
+ 
+ echo "$ac_t""$rtems_cv_HAS_NETWORKING" 1>&6
+ if test "$rtems_cv_HAS_NETWORKING" = "yes"; then
+   HAS_NETWORKING="yes";
+ else
+   HAS_NETWORKING="no";
+ fi
+ 
+ 
  RTEMS_HOST=$host_os
  case "${target}" in
    # hpux unix port should go here
***************
*** 1955,1960 ****
--- 1083,1091 ----
  RTEMS_ROOT=$RTEMS_TOPdir/'$(top_builddir)'/c/$RTEMS_BSP
  
  
+ INSTALL_CHANGE="\$(KSH) \$(PROJECT_ROOT)/tools/build/install-if-change"
+ 
+ 
  PACKHEX="\$(PROJECT_ROOT)/tools/build/packhex"
  
  
***************
*** 1965,1971 ****
  
  
  
! # Explicitly list all Makefiles here
  trap '' 1 2 15
  cat > confcache <<\EOF
  # This file is a shell script that caches the results of configure
--- 1096,1111 ----
  
  
  
! 
! if test "$HAS_NETWORKING" = "yes"; then
!   HAS_NETWORKING_TRUE=
!   HAS_NETWORKING_FALSE='#'
! else
!   HAS_NETWORKING_TRUE='#'
!   HAS_NETWORKING_FALSE=
! fi
! 
! # Explicitly list a Makefile here 
  trap '' 1 2 15
  cat > confcache <<\EOF
  # This file is a shell script that caches the results of configure
***************
*** 2087,2092 ****
--- 1227,1233 ----
  start/Makefile
  startup/Makefile
  timer/Makefile
+ network/Makefile
  wrapup/Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
  EOF
  cat >> $CONFIG_STATUS <<EOF
***************
*** 2151,2175 ****
  s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g
  s%@MAINT@%$MAINT%g
  s%@RTEMS_LIBC_DIR@%$RTEMS_LIBC_DIR%g
- s%@CC_FOR_TARGET@%$CC_FOR_TARGET%g
- s%@GCCSED@%$GCCSED%g
- s%@AR_FOR_TARGET@%$AR_FOR_TARGET%g
- s%@AS_FOR_TARGET@%$AS_FOR_TARGET%g
- s%@LD_FOR_TARGET@%$LD_FOR_TARGET%g
- s%@NM_FOR_TARGET@%$NM_FOR_TARGET%g
- s%@RANLIB_FOR_TARGET@%$RANLIB_FOR_TARGET%g
- s%@OBJCOPY_FOR_TARGET@%$OBJCOPY_FOR_TARGET%g
- s%@SIZE_FOR_TARGET@%$SIZE_FOR_TARGET%g
- s%@STRIP_FOR_TARGET@%$STRIP_FOR_TARGET%g
  s%@RTEMS_BSP@%$RTEMS_BSP%g
  s%@RTEMS_CPU_MODEL@%$RTEMS_CPU_MODEL%g
  s%@RTEMS_BSP_FAMILY@%$RTEMS_BSP_FAMILY%g
  s%@RTEMS_HOST@%$RTEMS_HOST%g
  s%@PROJECT_ROOT@%$PROJECT_ROOT%g
  s%@RTEMS_ROOT@%$RTEMS_ROOT%g
  s%@PACKHEX@%$PACKHEX%g
  s%@PROJECT_INCLUDE@%$PROJECT_INCLUDE%g
  s%@PROJECT_RELEASE@%$PROJECT_RELEASE%g
  
  CEOF
  EOF
--- 1292,1311 ----
  s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g
  s%@MAINT@%$MAINT%g
  s%@RTEMS_LIBC_DIR@%$RTEMS_LIBC_DIR%g
  s%@RTEMS_BSP@%$RTEMS_BSP%g
  s%@RTEMS_CPU_MODEL@%$RTEMS_CPU_MODEL%g
  s%@RTEMS_BSP_FAMILY@%$RTEMS_BSP_FAMILY%g
+ s%@RTEMS_HAS_NETWORKING@%$RTEMS_HAS_NETWORKING%g
+ s%@HAS_NETWORKING@%$HAS_NETWORKING%g
  s%@RTEMS_HOST@%$RTEMS_HOST%g
  s%@PROJECT_ROOT@%$PROJECT_ROOT%g
  s%@RTEMS_ROOT@%$RTEMS_ROOT%g
+ s%@INSTALL_CHANGE@%$INSTALL_CHANGE%g
  s%@PACKHEX@%$PACKHEX%g
  s%@PROJECT_INCLUDE@%$PROJECT_INCLUDE%g
  s%@PROJECT_RELEASE@%$PROJECT_RELEASE%g
+ s%@HAS_NETWORKING_TRUE@%$HAS_NETWORKING_TRUE%g
+ s%@HAS_NETWORKING_FALSE@%$HAS_NETWORKING_FALSE%g
  
  CEOF
  EOF
***************
*** 2219,2224 ****
--- 1355,1361 ----
  start/Makefile
  startup/Makefile
  timer/Makefile
+ network/Makefile
  wrapup/Makefile"}
  EOF
  cat >> $CONFIG_STATUS <<\EOF
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/configure.in rtems/c/src/lib/libbsp/m68k/mvme167/configure.in
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/configure.in	Tue Feb  8 17:33:08 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/configure.in	Tue Mar  7 11:24:40 2000
***************
*** 1,6 ****
  dnl Process this file with autoconf to produce a configure script.
  dnl
! dnl $Id: configure.in,v 1.2 2000/02/08 22:33:08 joel Exp $
  
  AC_PREREQ(2.13)
  AC_INIT(bsp_specs)
--- 1,6 ----
  dnl Process this file with autoconf to produce a configure script.
  dnl
! dnl $Id: configure.in,v 1.2 2000/03/07 16:24:40 gauthier Exp $
  
  AC_PREREQ(2.13)
  AC_INIT(bsp_specs)
***************
*** 11,27 ****
  AM_INIT_AUTOMAKE(rtems-c-src-lib-libbsp-m68k-mvme167,$RTEMS_VERSION,no)
  AM_MAINTAINER_MODE
  
! RTEMS_PROG_CC_FOR_TARGET
! RTEMS_CANONICALIZE_TOOLS
  
  RTEMS_ENV_RTEMSBSP
  RTEMS_CHECK_CUSTOM_BSP(RTEMS_BSP)
  RTEMS_CHECK_BSP_CACHE(RTEMS_BSP)
  RTEMS_CANONICAL_HOST
  
  RTEMS_PROJECT_ROOT
  
! # Explicitly list all Makefiles here
  AC_OUTPUT( 
  Makefile
  clock/Makefile
--- 11,28 ----
  AM_INIT_AUTOMAKE(rtems-c-src-lib-libbsp-m68k-mvme167,$RTEMS_VERSION,no)
  AM_MAINTAINER_MODE
  
! RTEMS_ENABLE_LIBCDIR
  
  RTEMS_ENV_RTEMSBSP
  RTEMS_CHECK_CUSTOM_BSP(RTEMS_BSP)
  RTEMS_CHECK_BSP_CACHE(RTEMS_BSP)
+ RTEMS_CHECK_NETWORKING
  RTEMS_CANONICAL_HOST
  
  RTEMS_PROJECT_ROOT
+ AM_CONDITIONAL(HAS_NETWORKING,test "$HAS_NETWORKING" = "yes")
  
! # Explicitly list a Makefile here 
  AC_OUTPUT( 
  Makefile
  clock/Makefile
***************
*** 31,34 ****
--- 32,36 ----
  start/Makefile
  startup/Makefile
  timer/Makefile
+ network/Makefile
  wrapup/Makefile)
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/console/Makefile.am rtems/c/src/lib/libbsp/m68k/mvme167/console/Makefile.am
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/console/Makefile.am	Fri Feb 25 09:50:41 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/console/Makefile.am	Thu Feb 10 10:19:22 2000
***************
*** 1,5 ****
  ## 
! ## $Id: Makefile.am,v 1.1.2.1 2000/02/25 14:50:41 joel Exp $
  ## 
  
  AUTOMAKE_OPTIONS = foreign 1.4
--- 1,5 ----
  ## 
! ## $Id: Makefile.am,v 1.1.1.1 2000/02/10 15:19:22 cotton Exp $
  ## 
  
  AUTOMAKE_OPTIONS = foreign 1.4
***************
*** 23,29 ****
  
  # the .rel file built here will be put into libbsp.a by ../wrapup/Makefile
  
! all: $(ARCH) $(OBJS) $(PGM)
  
  .PRECIOUS: $(PGM)
  
--- 23,29 ----
  
  # the .rel file built here will be put into libbsp.a by ../wrapup/Makefile
  
! all-local: $(ARCH) $(OBJS) $(PGM)
  
  .PRECIOUS: $(PGM)
  
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/console/Makefile.in rtems/c/src/lib/libbsp/m68k/mvme167/console/Makefile.in
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/console/Makefile.in	Tue Feb 29 09:21:59 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/console/Makefile.in	Thu Mar  2 12:59:01 2000
***************
*** 66,75 ****
  host_triplet = @host@
  target_alias = @target_alias@
  target_triplet = @target@
! CC = @CC@
! CC_FOR_TARGET = @CC_FOR_TARGET@
! CPP = @CPP@
! GCCSED = @GCCSED@
  MAINT = @MAINT@
  MAKEINFO = @MAKEINFO@
  PACKAGE = @PACKAGE@
--- 66,72 ----
  host_triplet = @host@
  target_alias = @target_alias@
  target_triplet = @target@
! INSTALL_CHANGE = @INSTALL_CHANGE@
  MAINT = @MAINT@
  MAKEINFO = @MAKEINFO@
  PACKAGE = @PACKAGE@
***************
*** 160,166 ****
  install: install-am
  uninstall-am:
  uninstall: uninstall-am
! all-am: Makefile
  all-redirect: all-am
  install-strip:
  	$(MAKE) $(AM_MAKEFLAGS) INSTALL_STRIP_FLAG=-s install
--- 157,163 ----
  install: install-am
  uninstall-am:
  uninstall: uninstall-am
! all-am: Makefile all-local
  all-redirect: all-am
  install-strip:
  	$(MAKE) $(AM_MAKEFLAGS) INSTALL_STRIP_FLAG=-s install
***************
*** 197,203 ****
  .PHONY: tags distdir info-am info dvi-am dvi check check-am \
  installcheck-am installcheck install-exec-am install-exec \
  install-data-am install-data install-am install uninstall-am uninstall \
! all-redirect all-am all installdirs mostlyclean-generic \
  distclean-generic clean-generic maintainer-clean-generic clean \
  mostlyclean distclean maintainer-clean
  
--- 194,200 ----
  .PHONY: tags distdir info-am info dvi-am dvi check check-am \
  installcheck-am installcheck install-exec-am install-exec \
  install-data-am install-data install-am install uninstall-am uninstall \
! all-local all-redirect all-am all installdirs mostlyclean-generic \
  distclean-generic clean-generic maintainer-clean-generic clean \
  mostlyclean distclean maintainer-clean
  
***************
*** 226,249 ****
  
  # the .rel file built here will be put into libbsp.a by ../wrapup/Makefile
  
! all: $(ARCH) $(OBJS) $(PGM)
  
  .PRECIOUS: $(PGM)
  
  debug-am:
- 	$(MAKE) $(AM_MAKEFLAGS) "ARCH=o-debug" \
-       "CFLAGS_DEBUG=$(CFLAGS_DEBUG_V)" \
-       "CFLAGS_OPTIMIZE=$(CFLAGS_DEBUG_OPTIMIZE_V)" \
-       "LDFLAGS_DEBUG=$(LDFLAGS_DEBUG_V)" $(TARGET_VA)
- 
  debug: debug-am
  .PHONY: debug debug-am
  
  profile-am:
- 	$(MAKE) $(AM_MAKEFLAGS) "ARCH=o-profile" \
-       "CFLAGS_PROFILE=$(CFLAGS_PROFILE_V)" \
-       "LDFLAGS_PROFILE=$(LDFLAGS_PROFILE_V)" $(TARGET_VA)
- 
  profile: profile-am
  .PHONY: profile profile-am
  
--- 223,237 ----
  
  # the .rel file built here will be put into libbsp.a by ../wrapup/Makefile
  
! all-local: $(ARCH) $(OBJS) $(PGM)
  
  .PRECIOUS: $(PGM)
  
  debug-am:
  debug: debug-am
  .PHONY: debug debug-am
  
  profile-am:
  profile: profile-am
  .PHONY: profile profile-am
  
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/console/console.c rtems/c/src/lib/libbsp/m68k/mvme167/console/console.c
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/console/console.c	Thu Feb 18 14:23:27 1999
--- rtems/c/src/lib/libbsp/m68k/mvme167/console/console.c	Thu Mar  2 12:59:01 2000
***************
*** 2,23 ****
   *  console.c
   *
   *  This file contains the MVME167 termios console package. Only asynchronous
!  *  I/O is supported. Normal I/O uses DMA for output, interrupts for input.
!  *  Very limited support is provided for polled I/O. Polled I/O is intended
!  *  only for running the RTEMS test suites, and uses the 167Bug console only.
   *
   *  /dev/tty0 is channel 0, Serial Port 1/Console on the MVME712M.
   *  /dev/tty1 is channel 1, Serial Port 2/TTY01 on the MVME712M.
   *  /dev/tty2 is channel 2, Serial Port 3 on the MVME712M.
   *  /dev/tty3 is channel 3, Serial Port 4 on the MVME712M.
   *
!  *  /dev/console is fixed to be /dev/tty01, Serial Port 2. 167Bug is given
!  *  Serial Port 1/Console. Do not open /dev/tty00.
   *
   *  Modern I/O chips often contain a number of I/O devices that can operate
   *  almost independently of each other. Typically, in RTEMS, all devices in
   *  an I/O chip are handled by a single device driver, but that need not be
!  *  always the case. Each device driver must supply six entry  points in the
   *  Device Driver Table: a device initialization function, as well as an open,
   *  close, read, write and a control function. RTEMS assigns a device major
   *  number to each device driver. This major device number is the index of the
--- 2,25 ----
   *  console.c
   *
   *  This file contains the MVME167 termios console package. Only asynchronous
!  *  I/O is supported.
   *
   *  /dev/tty0 is channel 0, Serial Port 1/Console on the MVME712M.
   *  /dev/tty1 is channel 1, Serial Port 2/TTY01 on the MVME712M.
   *  /dev/tty2 is channel 2, Serial Port 3 on the MVME712M.
   *  /dev/tty3 is channel 3, Serial Port 4 on the MVME712M.
   *
!  *  Normal I/O uses DMA for output, interrupts for input. /dev/console is
!  *  fixed to be /dev/tty01, Serial Port 2. Very limited support is provided
!  *  for polled I/O. Polled I/O is intended only for running the RTEMS test
!  *  suites. In all cases, Serial Port 1/Console is allocated to 167Bug and
!  *  is the dedicated debugger port. We configure GDB to use 167Bug for
!  *  debugging. When debugging with GDB or 167Bug, do not open /dev/tty00.
   *
   *  Modern I/O chips often contain a number of I/O devices that can operate
   *  almost independently of each other. Typically, in RTEMS, all devices in
   *  an I/O chip are handled by a single device driver, but that need not be
!  *  always the case. Each device driver must supply six entry points in the
   *  Device Driver Table: a device initialization function, as well as an open,
   *  close, read, write and a control function. RTEMS assigns a device major
   *  number to each device driver. This major device number is the index of the
***************
*** 59,65 ****
   *  Worse, it requires that the sub-devices be initialized in some
   *  configuration, and that configuration then changed through a series of
   *  device driver control calls. There is no standard API in RTEMS to switch
!  *   a serial line to some synchronous protocol.
   *
   *  A better approach is to treat each channel as a separate device, each with
   *  its own device device driver. The application then supplies its own device
--- 61,67 ----
   *  Worse, it requires that the sub-devices be initialized in some
   *  configuration, and that configuration then changed through a series of
   *  device driver control calls. There is no standard API in RTEMS to switch
!  *  a serial line to some synchronous protocol.
   *
   *  A better approach is to treat each channel as a separate device, each with
   *  its own device device driver. The application then supplies its own device
***************
*** 96,102 ****
   *  THIS MODULE IS NOT RE-ENTRANT! Simultaneous access to a device from
   *  multiple tasks is likely to cause significant problems! Concurrency
   *  control is implemented in the termios package.
! *
   *  THE INTERRUPT LEVEL IS SET TO 1 FOR ALL CHANNELS.
   *  If the CD2401 is to be used for high speed synchronous serial I/O, the
   *  interrupt priority might need to be increased.
--- 98,104 ----
   *  THIS MODULE IS NOT RE-ENTRANT! Simultaneous access to a device from
   *  multiple tasks is likely to cause significant problems! Concurrency
   *  control is implemented in the termios package.
!  *
   *  THE INTERRUPT LEVEL IS SET TO 1 FOR ALL CHANNELS.
   *  If the CD2401 is to be used for high speed synchronous serial I/O, the
   *  interrupt priority might need to be increased.
***************
*** 125,137 ****
  
  #define M167_INIT
  
  #include <termios.h>
  #include <bsp.h>                /* Must be before libio.h */
  #include <rtems/libio.h>
  
- #define CD2401_INT_LEVEL 1      /* Interrupt level for the CD2401 */
- #define CD2401_POLLED_IO 0      /* 0 for interrupt-driven, 1 for polled I/O */
- 
  
  /* Channel info */
  /* static */ struct {
--- 127,138 ----
  
  #define M167_INIT
  
+ #include <stdarg.h>
+ #include <stdio.h>
  #include <termios.h>
  #include <bsp.h>                /* Must be before libio.h */
  #include <rtems/libio.h>
  
  
  /* Channel info */
  /* static */ struct {
***************
*** 569,575 ****
    if ( status & 0x20 ) {
      /* DMA done */
      cd2401->ier &= 0xFC;        /* Shut up the interrupts */
!     
      /* This call can result in a call to cd2401_write() */
      rtems_termios_dequeue_characters (
          CD2401_Channel_Info[ch].tty,
--- 570,576 ----
    if ( status & 0x20 ) {
      /* DMA done */
      cd2401->ier &= 0xFC;        /* Shut up the interrupts */
! 
      /* This call can result in a call to cd2401_write() */
      rtems_termios_dequeue_characters (
          CD2401_Channel_Info[ch].tty,
***************
*** 634,640 ****
    sc = rtems_termios_ioctl (&newarg);
    if (sc != RTEMS_SUCCESSFUL)
      rtems_fatal_error_occurred (sc);
!     
    /*
     *  Turn off hardware flow control. It is a pain with 3-wire cables.
     *  The rtems_termios_ioctl() call below results in a call to
--- 635,641 ----
    sc = rtems_termios_ioctl (&newarg);
    if (sc != RTEMS_SUCCESSFUL)
      rtems_fatal_error_occurred (sc);
! 
    /*
     *  Turn off hardware flow control. It is a pain with 3-wire cables.
     *  The rtems_termios_ioctl() call below results in a call to
***************
*** 646,652 ****
    sc = rtems_termios_ioctl (&newarg);
    if (sc != RTEMS_SUCCESSFUL)
      rtems_fatal_error_occurred (sc);
!   
    /* Mark that the channel as initialized */
    CD2401_Channel_Info[minor].tty = args->iop->data1;
  
--- 647,653 ----
    sc = rtems_termios_ioctl (&newarg);
    if (sc != RTEMS_SUCCESSFUL)
      rtems_fatal_error_occurred (sc);
! 
    /* Mark that the channel as initialized */
    CD2401_Channel_Info[minor].tty = args->iop->data1;
  
***************
*** 876,885 ****
    else
      istrip = 0;                 /* Leave as 8 bits */
  
!   
    /* Clear channel and disable rx and tx */
    cd2401_chan_cmd (minor, 0x40, 1);
!   
    /* Write to the ports */
    cd2401->car = minor;          /* Select channel */
    cd2401->cmr = 0x42;           /* Interrupt Rx, DMA Tx, async mode */
--- 877,886 ----
    else
      istrip = 0;                 /* Leave as 8 bits */
  
! 
    /* Clear channel and disable rx and tx */
    cd2401_chan_cmd (minor, 0x40, 1);
! 
    /* Write to the ports */
    cd2401->car = minor;          /* Select channel */
    cd2401->cmr = 0x42;           /* Interrupt Rx, DMA Tx, async mode */
***************
*** 1079,1102 ****
  {
    int char_not_available;
    unsigned char c;
!   
    /* Check for a char in the input FIFO */
!   asm volatile( "trap   #15       /* Trap to 167Bug (.INSTAT) */
!                  .short 0x01
!                  move   %%cc, %0  /* Get condition codes */
!                  andil  #4, %0"
!     : "=d" (char_not_available) :: "%%cc" );
!     
    if (char_not_available)
      return -1;
!     
    /* Read the char and return it */
!   asm volatile( "subq.l #2,%%a7   /* Space for result */
!                  trap   #15       /* Trap to 167 Bug (.INCHR) */
!                  .short 0x00
!                  moveb  (%%a7)+, %0"
!     : "=d" (c) );
!     
    return (int)c;
  }
  
--- 1080,1107 ----
  {
    int char_not_available;
    unsigned char c;
! 
    /* Check for a char in the input FIFO */
!   asm volatile( "movew  #0x1, -(%%sp)   /* Code for .INSTAT */
!                  movew  %1, -(%%sp)     /* Channel */
!                  trap   #15             /* Trap to 167Bug */
!                  .short 0x60            /* Code for .REDIR */
!                  move   %%cc, %0        /* Get condition codes */
!                  andil  #4, %0"         /* Keep the Zero bit */
!     : "=d" (char_not_available) : "d" (minor): "%%cc" );
! 
    if (char_not_available)
      return -1;
! 
    /* Read the char and return it */
!   asm volatile( "subq.l #2,%%a7         /* Space for result */
!                  movew  #0x0, -(%%sp)   /* Code for .INCHR */
!                  movew  %1, -(%%sp)     /* Channel */
!                  trap   #15             /* Trap to 167 Bug */
!                  .short 0x60            /* Code for .REDIR */
!                  moveb  (%%a7)+, %0"    /* Pop char into c */
!     : "=d" (c) : "d" (minor) );
! 
    return (int)c;
  }
  
***************
*** 1105,1111 ****
   * _167Bug_pollWrite
   *
   *  Output buffer through 167Bug. Returns only once every character has been
!  *  sent (polled output). 
   *
   *  Input parameters:
   *    minor - selected channel
--- 1110,1116 ----
   * _167Bug_pollWrite
   *
   *  Output buffer through 167Bug. Returns only once every character has been
!  *  sent (polled output).
   *
   *  Input parameters:
   *    minor - selected channel
***************
*** 1127,1145 ****
  )
  {
    const char *endbuf = buf + len;
!   
!   asm volatile( "pea    (%0)
!                  pea    (%1)
!                  trap   #15     /* trap to 167Bug (.OUTSTR) */
!                  .short 0x21"
!     :: "a" (endbuf), "a" (buf) );
!     
    /* Return something */
    return RTEMS_SUCCESSFUL;
  }
  
  
  /*
   ***************
   * BOILERPLATE *
   ***************
--- 1132,1187 ----
  )
  {
    const char *endbuf = buf + len;
! 
!   asm volatile( "pea    (%0)            /* endbuf */
!                  pea    (%1)            /* buf */
!                  movew  #0x21, -(%%sp)  /* Code for .OUTSTR */
!                  movew  %2, -(%%sp)     /* Channel */
!                  trap   #15             /* Trap to 167Bug */
!                  .short 0x60"           /* Code for .REDIR */
!     :: "a" (endbuf), "a" (buf), "d" (minor) );
! 
    /* Return something */
    return RTEMS_SUCCESSFUL;
  }
  
  
  /*
+  *  Print functions: prototyped in bsp.h
+  *  Debug printing on Channel 1
+  */
+  
+ void printk( char *fmt, ... )
+ {
+   va_list  ap;      		/* points to each unnamed argument in turn */
+   static char buf[256];
+   unsigned int level;
+   
+   _CPU_ISR_Disable(level);
+   
+   va_start(ap, fmt); 		/* make ap point to 1st unnamed arg */
+   vsprintf(buf, fmt, ap);	/* send output to buffer */
+   
+   BSP_output_string(buf);	/* print buffer -- Channel 1 */
+   
+   va_end(ap);				/* clean up and re-enable interrupts */
+   _CPU_ISR_Enable(level);
+ }
+ 
+ 
+ void BSP_output_string( char * buf )
+ {
+   int len = strlen(buf);
+   int minor;				/* will be ignored */
+   rtems_status_code sc;
+ 
+   sc = _167Bug_pollWrite(minor, buf, len);
+   if (sc != RTEMS_SUCCESSFUL)
+     rtems_fatal_error_occurred (sc);
+ }
+ 
+ 
+ /*
   ***************
   * BOILERPLATE *
   ***************
***************
*** 1229,1235 ****
      NULL,                       /* startRemoteTx */
      0                           /* outputUsesInterrupts */
    };
!   
  #else
  
    static const rtems_termios_callbacks callbacks = {
--- 1271,1277 ----
      NULL,                       /* startRemoteTx */
      0                           /* outputUsesInterrupts */
    };
! 
  #else
  
    static const rtems_termios_callbacks callbacks = {
***************
*** 1242,1248 ****
      cd2401_startRemoteTx,       /* startRemoteTx */
      1                           /* outputUsesInterrupts */
    };
!   
  #endif
  
    return rtems_termios_open (major, minor, arg, &callbacks);
--- 1284,1290 ----
      cd2401_startRemoteTx,       /* startRemoteTx */
      1                           /* outputUsesInterrupts */
    };
! 
  #endif
  
    return rtems_termios_open (major, minor, arg, &callbacks);
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/fatal/Makefile.am rtems/c/src/lib/libbsp/m68k/mvme167/fatal/Makefile.am
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/fatal/Makefile.am	Fri Feb 25 09:50:41 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/fatal/Makefile.am	Thu Feb 10 10:19:23 2000
***************
*** 1,5 ****
  ## 
! ## $Id: Makefile.am,v 1.1.2.1 2000/02/25 14:50:41 joel Exp $
  ## 
  
  AUTOMAKE_OPTIONS = foreign 1.4
--- 1,5 ----
  ## 
! ## $Id: Makefile.am,v 1.1.1.1 2000/02/10 15:19:23 cotton Exp $
  ## 
  
  AUTOMAKE_OPTIONS = foreign 1.4
***************
*** 23,29 ****
  
  # the .rel file built here will be put into libbsp.a by ../wrapup/Makefile
  
! all: $(ARCH) $(OBJS) $(PGM)
  
  .PRECIOUS: $(PGM)
  
--- 23,29 ----
  
  # the .rel file built here will be put into libbsp.a by ../wrapup/Makefile
  
! all-local: $(ARCH) $(OBJS) $(PGM)
  
  .PRECIOUS: $(PGM)
  
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/fatal/Makefile.in rtems/c/src/lib/libbsp/m68k/mvme167/fatal/Makefile.in
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/fatal/Makefile.in	Tue Feb 29 09:21:59 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/fatal/Makefile.in	Thu Mar  2 12:59:01 2000
***************
*** 66,75 ****
  host_triplet = @host@
  target_alias = @target_alias@
  target_triplet = @target@
! CC = @CC@
! CC_FOR_TARGET = @CC_FOR_TARGET@
! CPP = @CPP@
! GCCSED = @GCCSED@
  MAINT = @MAINT@
  MAKEINFO = @MAKEINFO@
  PACKAGE = @PACKAGE@
--- 66,72 ----
  host_triplet = @host@
  target_alias = @target_alias@
  target_triplet = @target@
! INSTALL_CHANGE = @INSTALL_CHANGE@
  MAINT = @MAINT@
  MAKEINFO = @MAKEINFO@
  PACKAGE = @PACKAGE@
***************
*** 160,166 ****
  install: install-am
  uninstall-am:
  uninstall: uninstall-am
! all-am: Makefile
  all-redirect: all-am
  install-strip:
  	$(MAKE) $(AM_MAKEFLAGS) INSTALL_STRIP_FLAG=-s install
--- 157,163 ----
  install: install-am
  uninstall-am:
  uninstall: uninstall-am
! all-am: Makefile all-local
  all-redirect: all-am
  install-strip:
  	$(MAKE) $(AM_MAKEFLAGS) INSTALL_STRIP_FLAG=-s install
***************
*** 197,203 ****
  .PHONY: tags distdir info-am info dvi-am dvi check check-am \
  installcheck-am installcheck install-exec-am install-exec \
  install-data-am install-data install-am install uninstall-am uninstall \
! all-redirect all-am all installdirs mostlyclean-generic \
  distclean-generic clean-generic maintainer-clean-generic clean \
  mostlyclean distclean maintainer-clean
  
--- 194,200 ----
  .PHONY: tags distdir info-am info dvi-am dvi check check-am \
  installcheck-am installcheck install-exec-am install-exec \
  install-data-am install-data install-am install uninstall-am uninstall \
! all-local all-redirect all-am all installdirs mostlyclean-generic \
  distclean-generic clean-generic maintainer-clean-generic clean \
  mostlyclean distclean maintainer-clean
  
***************
*** 226,249 ****
  
  # the .rel file built here will be put into libbsp.a by ../wrapup/Makefile
  
! all: $(ARCH) $(OBJS) $(PGM)
  
  .PRECIOUS: $(PGM)
  
  debug-am:
- 	$(MAKE) $(AM_MAKEFLAGS) "ARCH=o-debug" \
-       "CFLAGS_DEBUG=$(CFLAGS_DEBUG_V)" \
-       "CFLAGS_OPTIMIZE=$(CFLAGS_DEBUG_OPTIMIZE_V)" \
-       "LDFLAGS_DEBUG=$(LDFLAGS_DEBUG_V)" $(TARGET_VA)
- 
  debug: debug-am
  .PHONY: debug debug-am
  
  profile-am:
- 	$(MAKE) $(AM_MAKEFLAGS) "ARCH=o-profile" \
-       "CFLAGS_PROFILE=$(CFLAGS_PROFILE_V)" \
-       "LDFLAGS_PROFILE=$(LDFLAGS_PROFILE_V)" $(TARGET_VA)
- 
  profile: profile-am
  .PHONY: profile profile-am
  
--- 223,237 ----
  
  # the .rel file built here will be put into libbsp.a by ../wrapup/Makefile
  
! all-local: $(ARCH) $(OBJS) $(PGM)
  
  .PRECIOUS: $(PGM)
  
  debug-am:
  debug: debug-am
  .PHONY: debug debug-am
  
  profile-am:
  profile: profile-am
  .PHONY: profile profile-am
  
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/include/Makefile.am rtems/c/src/lib/libbsp/m68k/mvme167/include/Makefile.am
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/include/Makefile.am	Fri Feb 25 09:50:41 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/include/Makefile.am	Thu Feb 10 10:19:24 2000
***************
*** 1,5 ****
  ## 
! ## $Id: Makefile.am,v 1.1.2.1 2000/02/25 14:50:41 joel Exp $
  ## 
  
  AUTOMAKE_OPTIONS = foreign 1.4
--- 1,5 ----
  ## 
! ## $Id: Makefile.am,v 1.1.1.1 2000/02/10 15:19:24 cotton Exp $
  ## 
  
  AUTOMAKE_OPTIONS = foreign 1.4
***************
*** 25,31 ****
      $(PROJECT_INCLUDE)/coverhd.h $(PROJECT_INCLUDE)/page_table.h \
      $(PROJECT_INCLUDE)/fatal.h
  
! all: $(TMPINSTALL_FILES)
  
  EXTRA_DIST = bsp.h coverhd.h fatal.h page_table.h
  
--- 25,31 ----
      $(PROJECT_INCLUDE)/coverhd.h $(PROJECT_INCLUDE)/page_table.h \
      $(PROJECT_INCLUDE)/fatal.h
  
! all-local: $(TMPINSTALL_FILES)
  
  EXTRA_DIST = bsp.h coverhd.h fatal.h page_table.h
  
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/include/Makefile.in rtems/c/src/lib/libbsp/m68k/mvme167/include/Makefile.in
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/include/Makefile.in	Tue Feb 29 09:21:59 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/include/Makefile.in	Thu Mar  2 12:59:01 2000
***************
*** 65,74 ****
  host_triplet = @host@
  target_alias = @target_alias@
  target_triplet = @target@
! CC = @CC@
! CC_FOR_TARGET = @CC_FOR_TARGET@
! CPP = @CPP@
! GCCSED = @GCCSED@
  MAINT = @MAINT@
  MAKEINFO = @MAKEINFO@
  PACKAGE = @PACKAGE@
--- 65,71 ----
  host_triplet = @host@
  target_alias = @target_alias@
  target_triplet = @target@
! INSTALL_CHANGE = @INSTALL_CHANGE@
  MAINT = @MAINT@
  MAKEINFO = @MAKEINFO@
  PACKAGE = @PACKAGE@
***************
*** 155,161 ****
  install: install-am
  uninstall-am:
  uninstall: uninstall-am
! all-am: Makefile
  all-redirect: all-am
  install-strip:
  	$(MAKE) $(AM_MAKEFLAGS) INSTALL_STRIP_FLAG=-s install
--- 152,158 ----
  install: install-am
  uninstall-am:
  uninstall: uninstall-am
! all-am: Makefile all-local
  all-redirect: all-am
  install-strip:
  	$(MAKE) $(AM_MAKEFLAGS) INSTALL_STRIP_FLAG=-s install
***************
*** 192,198 ****
  .PHONY: tags distdir info-am info dvi-am dvi check check-am \
  installcheck-am installcheck install-exec-am install-exec \
  install-data-am install-data install-am install uninstall-am uninstall \
! all-redirect all-am all installdirs mostlyclean-generic \
  distclean-generic clean-generic maintainer-clean-generic clean \
  mostlyclean distclean maintainer-clean
  
--- 189,195 ----
  .PHONY: tags distdir info-am info dvi-am dvi check check-am \
  installcheck-am installcheck install-exec-am install-exec \
  install-data-am install-data install-am install uninstall-am uninstall \
! all-local all-redirect all-am all installdirs mostlyclean-generic \
  distclean-generic clean-generic maintainer-clean-generic clean \
  mostlyclean distclean maintainer-clean
  
***************
*** 212,233 ****
  $(PROJECT_INCLUDE)/fatal.h: fatal.h
  	$(INSTALL_DATA) $< $@
  
! all: $(TMPINSTALL_FILES)
  
  debug-am:
- 	$(MAKE) $(AM_MAKEFLAGS) "ARCH=o-debug" \
-       "CFLAGS_DEBUG=$(CFLAGS_DEBUG_V)" \
-       "CFLAGS_OPTIMIZE=$(CFLAGS_DEBUG_OPTIMIZE_V)" \
-       "LDFLAGS_DEBUG=$(LDFLAGS_DEBUG_V)" $(TARGET_VA)
- 
  debug: debug-am
  .PHONY: debug debug-am
  
  profile-am:
- 	$(MAKE) $(AM_MAKEFLAGS) "ARCH=o-profile" \
-       "CFLAGS_PROFILE=$(CFLAGS_PROFILE_V)" \
-       "LDFLAGS_PROFILE=$(LDFLAGS_PROFILE_V)" $(TARGET_VA)
- 
  profile: profile-am
  .PHONY: profile profile-am
  
--- 209,221 ----
  $(PROJECT_INCLUDE)/fatal.h: fatal.h
  	$(INSTALL_DATA) $< $@
  
! all-local: $(TMPINSTALL_FILES)
  
  debug-am:
  debug: debug-am
  .PHONY: debug debug-am
  
  profile-am:
  profile: profile-am
  .PHONY: profile profile-am
  
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/include/bsp.h rtems/c/src/lib/libbsp/m68k/mvme167/include/bsp.h
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/include/bsp.h	Wed Nov 17 12:51:03 1999
--- rtems/c/src/lib/libbsp/m68k/mvme167/include/bsp.h	Tue Nov 23 17:29:45 1999
***************
*** 33,38 ****
--- 33,47 ----
  
  
  /*
+  * Network driver configuration
+  */
+  
+ struct rtems_bsdnet_ifconfig;
+ extern int uti596_attach(struct rtems_bsdnet_ifconfig * pConfig );
+ #define RTEMS_BSP_NETWORK_DRIVER_NAME   "i82596_1"
+ #define RTEMS_BSP_NETWORK_DRIVER_ATTACH uti596_attach
+ 
+ /*
   *  This is NOT the base address of local RAM!
   *  This is the base local address of the VMEbus short I/O space. A local
   *  access to this space results in a A16 VMEbus I/O cycle. This base address
***************
*** 395,400 ****
--- 404,431 ----
  #define CD2401_CLK_RATE 20000000
  
  void console_reserve_resources( rtems_configuration_table *configuration );
+ 
+ /* 
+  *  Debug print functions: implemented in console.c
+  */
+ void printk( char *fmt, ... );
+ void BSP_output_string( char * buf );
+ 
+ /*
+  *  Representation of 82596CA LAN controller: Memory Map
+  */
+ typedef volatile struct i82596_regs_ {
+   unsigned short	port_upper;				/* 0xFFF46000 */
+   unsigned short	port_lower;     		/* 0xFFF42002 */
+   unsigned long		chan_attn;				/* 0xFFF42004 */
+ } i82596_regs;
+ 
+ /*
+  *  Base address of the 82596.
+  */
+ #define i82596    ((i82596_regs * const) 0xFFF46000)
+ 
+ 
  
  /* BSP-wide functions */
  
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/network/Makefile.am rtems/c/src/lib/libbsp/m68k/mvme167/network/Makefile.am
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/network/Makefile.am	Wed Dec 31 19:00:00 1969
--- rtems/c/src/lib/libbsp/m68k/mvme167/network/Makefile.am	Tue Mar  7 11:26:10 2000
***************
*** 0 ****
--- 1,36 ----
+ ## 
+ ## $Id: Makefile.am,v 1.1 2000/03/07 16:26:10 gauthier Exp $
+ ## 
+ 
+ AUTOMAKE_OPTIONS = foreign 1.4
+ 
+ PGM = $(ARCH)/network.rel
+ 
+ C_FILES = network.c
+ C_O_FILES = $(C_FILES:%.c=$(ARCH)/%.o)
+ 
+ OBJS = $(C_O_FILES)
+ 
+ include $(RTEMS_ROOT)/make/custom/@RTEMS_BSP at .cfg
+ include $(top_srcdir)/../../../../../../automake/lib.am
+ 
+ #
+ # (OPTIONAL) Add local stuff here using +=
+ #
+ 
+ AM_CPPFLAGS += -D__INSIDE_RTEMS_BSD_TCPIP_STACK__
+ 
+ $(PGM): $(OBJS)
+ 	$(make-rel)
+ 
+ # the .rel file built here will be put into libbsp.a by ../wrapup/Makefile
+ 
+ if HAS_NETWORKING
+ all-local: $(ARCH) $(OBJS) $(PGM)
+ endif
+ 
+ .PRECIOUS: $(PGM)
+ 
+ EXTRA_DIST = network.c
+ 
+ include $(top_srcdir)/../../../../../../automake/local.am
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/network/Makefile.in rtems/c/src/lib/libbsp/m68k/mvme167/network/Makefile.in
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/network/Makefile.in	Wed Dec 31 19:00:00 1969
--- rtems/c/src/lib/libbsp/m68k/mvme167/network/Makefile.in	Tue Mar  7 12:11:29 2000
***************
*** 0 ****
--- 1,251 ----
+ # Makefile.in generated automatically by automake 1.4 from Makefile.am
+ 
+ # Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
+ # This Makefile.in is free software; the Free Software Foundation
+ # gives unlimited permission to copy and/or distribute it,
+ # with or without modifications, as long as this notice is preserved.
+ 
+ # This program is distributed in the hope that it will be useful,
+ # but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+ # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+ # PARTICULAR PURPOSE.
+ 
+ 
+ 
+ 
+ SHELL = @SHELL@
+ 
+ srcdir = @srcdir@
+ top_srcdir = @top_srcdir@
+ VPATH = @srcdir@
+ prefix = @prefix@
+ exec_prefix = @exec_prefix@
+ 
+ bindir = @bindir@
+ sbindir = @sbindir@
+ libexecdir = @libexecdir@
+ datadir = @datadir@
+ sysconfdir = @sysconfdir@
+ sharedstatedir = @sharedstatedir@
+ localstatedir = @localstatedir@
+ libdir = @libdir@
+ infodir = @infodir@
+ mandir = @mandir@
+ includedir = @includedir@
+ oldincludedir = /usr/include
+ 
+ DESTDIR =
+ 
+ pkgdatadir = $(datadir)/@PACKAGE@
+ pkglibdir = $(libdir)/@PACKAGE@
+ pkgincludedir = $(includedir)/@PACKAGE@
+ 
+ top_builddir = ..
+ 
+ ACLOCAL = @ACLOCAL@
+ AUTOCONF = @AUTOCONF@
+ AUTOMAKE = @AUTOMAKE@
+ AUTOHEADER = @AUTOHEADER@
+ 
+ INSTALL = @INSTALL@
+ INSTALL_PROGRAM = @INSTALL_PROGRAM@ $(AM_INSTALL_PROGRAM_FLAGS)
+ INSTALL_DATA = @INSTALL_DATA@
+ INSTALL_SCRIPT = @INSTALL_SCRIPT@
+ transform = @program_transform_name@
+ 
+ NORMAL_INSTALL = :
+ PRE_INSTALL = :
+ POST_INSTALL = :
+ NORMAL_UNINSTALL = :
+ PRE_UNINSTALL = :
+ POST_UNINSTALL = :
+ build_alias = @build_alias@
+ build_triplet = @build@
+ host_alias = @host_alias@
+ host_triplet = @host@
+ target_alias = @target_alias@
+ target_triplet = @target@
+ HAS_NETWORKING = @HAS_NETWORKING@
+ INSTALL_CHANGE = @INSTALL_CHANGE@
+ MAINT = @MAINT@
+ MAKEINFO = @MAKEINFO@
+ PACKAGE = @PACKAGE@
+ PACKHEX = @PACKHEX@
+ PROJECT_INCLUDE = @PROJECT_INCLUDE@
+ PROJECT_RELEASE = @PROJECT_RELEASE@
+ PROJECT_ROOT = @PROJECT_ROOT@
+ RTEMS_BSP = @RTEMS_BSP@
+ RTEMS_BSP_FAMILY = @RTEMS_BSP_FAMILY@
+ RTEMS_CPU = @RTEMS_CPU@
+ RTEMS_CPU_MODEL = @RTEMS_CPU_MODEL@
+ RTEMS_HAS_NETWORKING = @RTEMS_HAS_NETWORKING@
+ RTEMS_HOST = @RTEMS_HOST@
+ RTEMS_LIBC_DIR = @RTEMS_LIBC_DIR@
+ RTEMS_ROOT = @RTEMS_ROOT@
+ RTEMS_TOPdir = @RTEMS_TOPdir@
+ VERSION = @VERSION@
+ 
+ AUTOMAKE_OPTIONS = foreign 1.4
+ 
+ PGM = $(ARCH)/network.rel
+ 
+ C_FILES = network.c
+ C_O_FILES = $(C_FILES:%.c=$(ARCH)/%.o)
+ 
+ OBJS = $(C_O_FILES)
+ 
+ TMPINSTALL_FILES = $(PROJECT_RELEASE)/lib
+ 
+ #
+ # (OPTIONAL) Add local stuff here using +=
+ #
+ 
+ AM_CPPFLAGS =  -D__INSIDE_RTEMS_BSD_TCPIP_STACK__
+ 
+ EXTRA_DIST = network.c
+ mkinstalldirs = $(SHELL) $(top_srcdir)/../../../../../../mkinstalldirs
+ CONFIG_CLEAN_FILES = 
+ DIST_COMMON =  Makefile.am Makefile.in
+ 
+ 
+ DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
+ 
+ TAR = gtar
+ GZIP_ENV = --best
+ all: all-redirect
+ .SUFFIXES:
+ $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4) $(top_srcdir)/../../../../../../automake/lib.am $(top_srcdir)/../../../../../../automake/local.am
+ 	cd $(top_srcdir) && $(AUTOMAKE) --foreign network/Makefile
+ 
+ Makefile: $(srcdir)/Makefile.in  $(top_builddir)/config.status $(BUILT_SOURCES)
+ 	cd $(top_builddir) \
+ 	  && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
+ 
+ tags: TAGS
+ TAGS:
+ 
+ 
+ distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir)
+ 
+ subdir = network
+ 
+ distdir: $(DISTFILES)
+ 	here=`cd $(top_builddir) && pwd`; \
+ 	top_distdir=`cd $(top_distdir) && pwd`; \
+ 	distdir=`cd $(distdir) && pwd`; \
+ 	cd $(top_srcdir) \
+ 	  && $(AUTOMAKE) --include-deps --build-dir=$$here --srcdir-name=$(top_srcdir) --output-dir=$$top_distdir --foreign network/Makefile
+ 	@for file in $(DISTFILES); do \
+ 	  d=$(srcdir); \
+ 	  if test -d $$d/$$file; then \
+ 	    cp -pr $$/$$file $(distdir)/$$file; \
+ 	  else \
+ 	    test -f $(distdir)/$$file \
+ 	    || ln $$d/$$file $(distdir)/$$file 2> /dev/null \
+ 	    || cp -p $$d/$$file $(distdir)/$$file || :; \
+ 	  fi; \
+ 	done
+ info-am:
+ info: info-am
+ dvi-am:
+ dvi: dvi-am
+ check-am: all-am
+ check: check-am
+ installcheck-am:
+ installcheck: installcheck-am
+ install-exec-am:
+ install-exec: install-exec-am
+ 
+ install-data-am:
+ install-data: install-data-am
+ 
+ install-am: all-am
+ 	@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+ install: install-am
+ uninstall-am:
+ uninstall: uninstall-am
+ all-am: Makefile all-local
+ all-redirect: all-am
+ install-strip:
+ 	$(MAKE) $(AM_MAKEFLAGS) AM_INSTALL_PROGRAM_FLAGS=-s install
+ installdirs:
+ 
+ 
+ mostlyclean-generic:
+ 
+ clean-generic:
+ 
+ distclean-generic:
+ 	-rm -f Makefile $(CONFIG_CLEAN_FILES)
+ 	-rm -f config.cache config.log stamp-h stamp-h[0-9]*
+ 
+ maintainer-clean-generic:
+ mostlyclean-am:  mostlyclean-generic
+ 
+ mostlyclean: mostlyclean-am
+ 
+ clean-am:  clean-generic mostlyclean-am
+ 
+ clean: clean-am
+ 
+ distclean-am:  distclean-generic clean-am
+ 
+ distclean: distclean-am
+ 
+ maintainer-clean-am:  maintainer-clean-generic distclean-am
+ 	@echo "This command is intended for maintainers to use;"
+ 	@echo "it deletes files that may require special tools to rebuild."
+ 
+ maintainer-clean: maintainer-clean-am
+ 
+ .PHONY: tags distdir info-am info dvi-am dvi check check-am \
+ installcheck-am installcheck install-exec-am install-exec \
+ install-data-am install-data install-am install uninstall-am uninstall \
+ all-local all-redirect all-am all installdirs mostlyclean-generic \
+ distclean-generic clean-generic maintainer-clean-generic clean \
+ mostlyclean distclean maintainer-clean
+ 
+ 
+ include $(RTEMS_ROOT)/make/custom/@RTEMS_BSP at .cfg
+ 
+ include $(RTEMS_ROOT)/make/leaf.cfg
+ 
+ define make-library
+ $(RM) $@
+ $(AR) $(ARFLAGS) $@ $^
+ $(RANLIB) $@
+ endef
+ 
+ $(PROJECT_RELEASE)/lib:
+ 	@$(mkinstalldirs) $@
+ 
+ .PRECIOUS: $(LIB)
+ 
+ $(PGM): $(OBJS)
+ 	$(make-rel)
+ 
+ # the .rel file built here will be put into libbsp.a by ../wrapup/Makefile
+ 
+ @HAS_NETWORKING_TRUE at all-local: $(ARCH) $(OBJS) $(PGM)
+ 
+ .PRECIOUS: $(PGM)
+ 
+ debug-am:
+ debug: debug-am
+ .PHONY: debug debug-am
+ 
+ profile-am:
+ profile: profile-am
+ .PHONY: profile profile-am
+ 
+ preinstall-am: $(PREINSTALL_FILES)
+ preinstall: preinstall-am
+ .PHONY: preinstall preinstall-am
+ 
+ depend-am:
+ depend: depend-am
+ .PHONY: depend depend-am
+ 
+ # Tell versions [3.59,3.63) of GNU make to not export all variables.
+ # Otherwise a system limit (for SysV at least) may be exceeded.
+ .NOEXPORT:
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/network/netexterns.h rtems/c/src/lib/libbsp/m68k/mvme167/network/netexterns.h
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/network/netexterns.h	Wed Dec 31 19:00:00 1969
--- rtems/c/src/lib/libbsp/m68k/mvme167/network/netexterns.h	Tue Aug 10 10:49:15 1999
***************
*** 0 ****
--- 1,18 ----
+ /*
+  *  $Id: netexterns.h,v 1.2 1999/01/20 18:55:49 joel Exp $
+  */
+ 
+ #ifndef NET_EXTERNS_H
+ #define NET_EXTERNS_H
+ 
+ /*
+  * External entry points
+  */
+ 
+ extern int uti596_attach(struct rtems_bsdnet_ifconfig *);
+ extern int uti596dump(char * );
+ extern void uti596reset(void);
+ extern void uti596Diagnose(int);
+ extern void uti596_request_reset(void);
+ 
+ #endif
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/network/network.c rtems/c/src/lib/libbsp/m68k/mvme167/network/network.c
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/network/network.c	Wed Dec 31 19:00:00 1969
--- rtems/c/src/lib/libbsp/m68k/mvme167/network/network.c	Tue Mar  7 13:17:55 2000
***************
*** 0 ****
--- 1,2695 ----
+ /* uti596.c: An 82596 ethernet driver for rtems-bsd.
+  *
+  *  $Id: network.c,v 1.1 1999/08/10 15:49:44 cotton Exp $
+  */
+ 
+ void dump_scb(void);
+ void printk_time(void);
+ 
+ #define KERNEL
+ 
+ /* 
+  *  Selectively define to debug the network driver. If you define any of these
+  *  you must run with polled console I/O.
+  */
+ #define DBG_596
+ #define DBG_596_RFA
+ #define DBG_START
+ #define DBG_INIT
+ #define DBG_INIT_2
+ #define DBG_RESET
+ #define DBG_VERSION
+ #define DBG_ISR
+ #define DBG_RAW_ISR
+ #define DBG_596_RFD
+ #define DBG_FR
+ #define DBG_RAW
+ #define DBG_ATTACH
+ #define DBG_POLLED_CMD
+ #define DBG_ADD
+ #define DBG_SUPPLY_FD
+ 
+ struct i596_rfd *pISR_Rfd;
+ 
+ void show_buffers (void);
+ void show_queues(void);
+ void dumpQ(void);
+ 
+ int count_rx = 0;
+ 
+ #include <bsp.h>
+ #include <stdio.h>
+ /*#include <stdlib.h>*/
+ #include <rtems/error.h>
+ #include <rtems/rtems_bsdnet.h>
+ 
+ #include <sys/param.h>
+ #include <sys/mbuf.h>
+ #include <sys/socket.h>
+ #include <sys/sockio.h>
+ 
+ #include <net/if.h>
+ 
+ #include <netinet/in.h>
+ #include <netinet/if_ether.h>
+ 
+ #include "uti596.h"
+ #include "netexterns.h"
+ 
+ #define UTI_596_ASSERT( condition, str ) { if (!( condition ) ) printk(str); }
+ 
+ static struct uti596_softc uti596_softc;
+ 
+ static    int scbStatus;
+ static    rtems_status_code sc;
+ static    struct i596_cmd *pIsrCmd;
+ static    struct i596_rfd *pIsrRfd;
+ 
+ /*
+  * Initial 596 configuration
+  */
+ char uti596initSetup[] = {
+         0x0E,   /* length, prefetch off ( no RBD's ) */
+         0xC8,   /* fifo to 8, monitor off */
+         0x40,   /* don't save bad frames ( was save= 80, use intel's 40 )*/
+         0x2E,   /* No source address insertion, 8 byte preamble */
+         0x00,   /* priority and backoff defaults */
+         0x60,   /* interframe spacing */
+         0x00,   /* slot time LSB */
+         0xf2,   /* slot time and retries */
+         0x0C,   /* */
+         0x08,   /* collision detect */
+         0x40,   /* minimum frame length */
+         0xfb,   /* tried C8 same as byte 1 in bits 6-7, else ignored*/
+         0x00,
+         0x3f    /*  no multi IA */ };
+ /*
+  *  Externally defined symbols
+  */
+ #define RX_BUF_COUNT     15
+ #define TX_BUF_COUNT     4
+ #define TX_BD_PER_BUF    4
+ 
+ #define INTERRUPT_EVENT         RTEMS_EVENT_1
+ #define START_TRANSMIT_EVENT    RTEMS_EVENT_2
+ #define NIC_RESET_EVENT         RTEMS_EVENT_3
+ 
+ #define RBUF_SIZE       1520
+ 
+ /*
+  * Local Routines
+  */
+ 
+ /* These are extern, and non-inline  for testing purposes */
+ 
+ void uti596addCmd( struct i596_cmd *pCmd );
+ void uti596_initMem( struct uti596_softc * );
+ void uti596_init( void * );
+ int uti596initRxBufs( int num );
+ int uti596_initRFA( int num );
+ int uti596initRxBufs( int num );
+ static int uti596_ioctl( struct ifnet *, int, caddr_t );
+ rtems_isr uti596DynamicInterruptHandler (rtems_vector_number );
+ 
+ void uti596_txDaemon( void * );
+ void uti596_rxDaemon( void * );
+ void uti596_resetDaemon( void * );
+ 
+ void uti596_stop( struct uti596_softc * );
+ static void uti596_start( struct ifnet * );
+ 
+ void uti596reset( void );
+ 
+ void uti596_stats( struct uti596_softc * );
+ 
+ void uti596_initialize_hardware( struct uti596_softc * );
+ void uti596_reset_hardware( struct uti596_softc *);
+ 
+ void uti596clearListStatus( struct i596_rfd * );
+ void uti596addPolledCmd( struct i596_cmd * );
+ 
+ void uti596supplyFD( struct i596_rfd * );
+ 
+ struct i596_rfd * uti596dequeue( struct i596_rfd ** );
+ void uti596append( struct i596_rfd ** , struct i596_rfd * );
+ 
+ #ifdef DEBUG_INIT
+ static void print_eth( unsigned char * );
+ static void print_hdr( unsigned char * );
+ static void print_pkt( unsigned char * );
+ #endif
+ 
+ void send_packet( struct ifnet *, struct mbuf * );
+ 
+ #define UTI_596_IRQ 5
+ #define UTI_596_ETH_MIN_SIZE 60
+ 
+ /* Waits for the command word to clear.  The command word is cleared AFTER the interrupt is
+  * generated. This allows the CPU to issue the next command
+  */
+ #define  UTI_WAIT_COMMAND_ACCEPTED(duration,function)\
+ {   int waitcount = duration; \
+     while (  uti596_softc.scb.command ) \
+       if (--waitcount == 0) \
+         { \
+           printk("%s: i82596 timed out with status %x, cmd %x.\n", function, \
+                   uti596_softc.scb.status,  uti596_softc.scb.command); \
+           break; \
+         } \
+ }
+ /*************************************************************************/
+ 
+ void uti596_request_reset( void )
+ {
+    uti596_softc.nic_reset = 0;
+    sc = rtems_event_send(uti596_softc.resetDaemonTid, NIC_RESET_EVENT);
+    if ( sc != RTEMS_SUCCESSFUL )
+      rtems_panic ("Can't notify resetDaemon: %s\n", rtems_status_text (sc));
+ }
+ 
+ 
+ /***********************************************************************
+  *  Function:   uti596initRFA(int num) ( New )
+  *
+  *  Description:
+  *              attempts to allocate and initialize ( chain together )
+  *              the requested number of FD's
+  *
+  *  Algorithm:
+  *
+  ***********************************************************************/
+ 
+ int uti596_initRFA( int num )
+ {
+     struct i596_rfd *pRfd;
+     int i = 0;
+ 
+ #ifdef DBG_596
+     printk ("uti596_initRFA %d.\n", num);
+ #endif
+ 
+     /*
+      * Initialize the first rfd in the rfa
+      */
+     pRfd = (struct i596_rfd *) calloc (1, sizeof (struct i596_rfd));
+     if ( !pRfd ) {
+       printf("Can't allocate all buffers: only %d allocated\n", i);
+       return 0;
+     }
+     else {
+       uti596_softc.countRFD = 1;
+       uti596_softc.pBeginRFA = uti596_softc.pEndRFA = pRfd;
+     printf ( "First Rfd allocated is: %p\n",
+              uti596_softc.pBeginRFA);
+     }
+ 
+     for (i = 1; i < num; i++) {
+       pRfd = (struct i596_rfd *) calloc (1, sizeof (struct i596_rfd) );
+       if ( pRfd != NULL ) {
+         uti596_softc.countRFD++;
+         uti596_softc.pEndRFA -> next = pRfd; /* link it in   */
+         uti596_softc.pEndRFA         = pRfd; /* move the end */
+ #ifdef DBG_596_RFA
+         printk("Allocated RFD @ %p\n", pRfd);
+ #endif
+       }
+       else {
+         printf("Can't allocate all buffers: only %d allocated\n", i);
+         break;
+       }
+     } /* end for */
+ 
+     uti596_softc.pEndRFA -> next = I596_NULL;
+     UTI_596_ASSERT(uti596_softc.countRFD == RX_BUF_COUNT,"INIT:WRONG RFD COUNT\n" );
+ 
+ #ifdef DBG_596_RFA
+     printk ( "Head of RFA is buffer %p\nEnd of RFA is buffer %p \n",
+              uti596_softc.pBeginRFA,
+              uti596_softc.pEndRFA );
+ #endif
+     /* initialize the Rfd's */
+     for ( pRfd = uti596_softc.pBeginRFA;
+           pRfd != I596_NULL;
+           pRfd = pRfd -> next ) {
+ 
+       pRfd->cmd = 0x0000;
+       pRfd->stat = 0x0000;
+       pRfd->pRbd =  I596_NULL;
+       pRfd->count = 0;  /* number of bytes in buffer: usually less than size */
+       pRfd->size = 1532;      /* was 1532;  buffer size ( All RBD ) */
+       if ( pRfd -> data == NULL )
+         printf("Can't allocate the RFD data buffer\n");
+     }
+ 
+     /* mark the last FD */
+     uti596_softc.pEndRFA -> cmd = CMD_EOL; /* moved jan 13 from before the init stuff */
+ 
+ #ifdef DBG_596_RFA
+     printk ( "Head of RFA is buffer @ %p \n", uti596_softc.pBeginRFA );
+ #endif
+ 
+     uti596_softc.pSavedRfdQueue =
+       uti596_softc.pEndSavedQueue = I596_NULL;   /* initially empty */
+ 
+     uti596_softc.savedCount = 0;
+ 
+     uti596_softc.nop.cmd.command = CmdNOp; /* initialize the nop command */
+ 
+     return (i); /* the number of allocated buffers */
+ }
+ 
+ 
+ /***********************************************************************
+  *  Function:   uti596supplyFD
+  *
+  *  Description: returns a buffer to the receive frame pool.
+  *               call this with Inetrrupts disabled!
+  *
+  *  Algorithm:
+  *
+  ***********************************************************************/
+  
+ void uti596supplyFD(
+   struct i596_rfd * pRfd
+ )
+ {
+  struct i596_rfd *pLastRfd;
+ 
+  UTI_596_ASSERT(pRfd != I596_NULL, "Supplying NULL RFD!\n");
+  pRfd -> cmd  = CMD_EOL;
+  pRfd -> pRbd = I596_NULL;
+  pRfd -> next = I596_NULL;
+  pRfd -> stat = 0x0000;      /* clear STAT_C and STAT_B bits */
+ 
+  /*
+   * Check if the list is empty:
+   */
+  if ( uti596_softc.pBeginRFA == I596_NULL ) {
+    /* Init a list w/ one entry */
+    uti596_softc.pBeginRFA = uti596_softc.pEndRFA = pRfd;
+    UTI_596_ASSERT(uti596_softc.countRFD == 0, "Null begin, but non-zero count\n");
+    if ( uti596_softc.pLastUnkRFD != I596_NULL )
+      printf("LastUnkRFD is NOT NULL!!\n");
+    uti596_softc.countRFD = 1;
+    return;
+  }
+  /*
+   * Check if the last RFD is used/read by the 596.
+   */
+  pLastRfd = uti596_softc.pEndRFA;
+ 
+  if (    pLastRfd != I596_NULL &&
+       ! (pLastRfd -> stat & ( STAT_C | STAT_B ) )) { /* C = complete, B = busy (prefetched) */
+ 
+    /*
+     * Not yet too late to add it
+     */
+    pLastRfd -> next = pRfd;
+    pLastRfd -> cmd &= ~CMD_EOL;  /* RESET_EL : reset EL bit to 0  */
+    uti596_softc.countRFD++;  /* Lets assume we add it successfully
+                                 If not, the RFD may be used, and may decrement countRFD < 0 !!*/
+    /*
+     * Check if the last RFD was used while appending.
+     */
+    if ( pLastRfd -> stat & ( STAT_C | STAT_B ) ) { /* completed or was prefetched */
+      /*
+       * Either the EL bit of the last rfd has been read by the 82596,
+       * and it will stop after reception,( true when RESET_EL not reached ) or
+       * the EL bit was NOT read by the 82596 and it will use the linked
+       * RFD for the next reception. ( true is RESET_EL was reached )
+       * So, it is unknown whether or not the linked rfd will be used.
+       * Therefore, the end of list CANNOT be updated.
+       */
+      UTI_596_ASSERT ( uti596_softc.pLastUnkRFD == I596_NULL, "Too many Unk RFD's\n" );
+      uti596_softc.pLastUnkRFD = pRfd;
+      return;
+    }
+    else {
+      /*
+       * The RFD being added was not touched by the 82596
+       */
+      if (uti596_softc.pLastUnkRFD != I596_NULL ) {
+ 
+        uti596append(&uti596_softc.pSavedRfdQueue, pRfd); /* Only here! saved Q */
+        uti596_softc.pEndSavedQueue = pRfd;
+        uti596_softc.savedCount++;
+        uti596_softc.countRFD--;
+ 
+      }
+      else {
+        uti596_softc.pEndRFA = pRfd;           /* the RFA has been extended */
+        if ( ( uti596_softc.scb.status & SCB_STAT_RNR ||
+               uti596_softc.scb.status & RU_NO_RESOURCES ) &&
+             uti596_softc.countRFD > 1 ) {   /* was == 2 */
+          uti596_softc.pBeginRFA -> cmd &= ~CMD_EOL;  /* Ensure that beginRFA is not EOL */
+ 
+          UTI_596_ASSERT(uti596_softc.pEndRFA -> next == I596_NULL, "supply: List buggered\n");
+          UTI_596_ASSERT(uti596_softc.pEndRFA -> cmd & CMD_EOL, "supply: No EOL at end.\n");
+          UTI_596_ASSERT(uti596_softc.scb.command == 0, "Supply: scb command must be zero\n");
+ #ifdef DBG_START
+          printk("Supply FD: starting receiver");
+ #endif
+          /* start the receiver */
+          UTI_596_ASSERT(uti596_softc.pBeginRFA != I596_NULL, "rx start w/ NULL begin! \n");
+          uti596_softc.scb.pRfd = uti596_softc.pBeginRFA;
+          uti596_softc.scb.command = RX_START | SCB_STAT_RNR;  /* Don't ack RNR! The receiver should be stopped in this case */
+          UTI_596_ASSERT( !(uti596_softc.scb.status & SCB_STAT_FR),"FRAME RECEIVED INT COMING!\n");
+ 	 i82596->chan_attn = 0;			/* send CA signal */
+        }
+      }
+      return;
+ 
+    }
+  }
+  else {
+    /*
+     * too late , pLastRfd in use ( or NULL ),
+     * in either case, EL bit has been read, and RNR condition will occur
+     */
+    uti596append( &uti596_softc.pSavedRfdQueue, pRfd); /* save it for RNR */
+ 
+    uti596_softc.pEndSavedQueue = pRfd;                /* reset end of saved queue */
+    uti596_softc.savedCount++;
+ 
+ 
+    return;
+  }
+ }
+ 
+ static void uti596_start(
+   struct ifnet *ifp
+ )
+ {
+   struct uti596_softc *sc = ifp->if_softc;
+ 
+   rtems_event_send (sc->txDaemonTid, START_TRANSMIT_EVENT);
+   ifp->if_flags |= IFF_OACTIVE;
+ }
+ 
+ void uti596_initialize_hardware(
+   struct uti596_softc *sc
+ )
+ {
+   int boguscnt = 1000;
+   rtems_isr_entry dummy;
+ 
+   printf("uti596_initialize_hardware\n");
+   
+ 
+   /* reset the board  */
+   i82596->port_upper = 0; 	/* Each Port access must consist of two 16-bit writes */
+   i82596->port_lower = 0;
+ 
+   /* allocate enough memory for the Scp block to be aligned on 16 bit boundary */
+   uti596_softc.pScp = (struct i596_scp *) calloc(1,sizeof(struct i596_scp) + 0xf);
+   					
+ #ifdef DBG_INIT
+   printk("initialize_hardware:Scp address initially %p\n", sc->pScp);
+ #endif
+   
+   /* align the block */
+   sc->pScp = (struct i596_scp *)
+     ((((int)uti596_softc.pScp) + 0xf) & 0xfffffff0);
+ 
+ #ifdef DBG_INIT
+   printk("initialize_hardware:change scp address to : %p\n",sc->pScp);
+ #endif
+ 
+   /* change the scp address */
+ #ifdef DBG_INIT
+   printk("Change the SCP address\n");
+ #endif
+ 
+   /* reset the board  */
+   i82596->port_upper = 0;
+   i82596->port_lower = 0;
+   
+   /* supply the Scp address */
+   i82596->port_upper = (( (int)sc->pScp) >> 16 ) & 0xffff;
+   i82596->port_lower = ((((int)sc->pScp) &  0xffff ));
+ 
+   /* This is linear mode, LOCK function is disabled  */
+ 
+   sc->pScp->sysbus = 0x00540000;
+   sc->pScp->iscp   = &sc->iscp;
+   sc->iscp.scb     = &sc->scb;
+   sc->iscp.stat    = 0x0001;
+ 
+   sc->pCmdHead     = sc->scb.pCmd = I596_NULL;
+ 
+ #ifdef DBG_596
+   printk("Starting i82596.\n");
+ #endif
+ 
+   /* Pass the scb address to the 596 */
+   i82596->chan_attn = 0;
+ 
+   while (sc->iscp.stat)
+     if (--boguscnt == 0)
+       {
+         printf("initialize_hardware: timed out with status %4.4lx\n",
+                sc->iscp.stat );
+         break;
+       }
+ 
+   /* clear the command word */
+   sc->scb.command = 0;
+   
+   /*
+    * Configure interrupt control in PCCchip2
+    */
+    
+   pccchip2->LANC_error		= 0xff;		/* clear status register */
+   pccchip2->LANC_int_ctl	= 0x5d;		/* lvl 5, enabled, edge-sensitive rising */
+   pccchip2->LANC_berr_ctl	= 0x5d;		/* bus error: lvl 5, enabled, snoop control
+   								 * will supply dirty data and leave dirty data
+   								 * on read access and sink any data on write
+   								 */
+   /* 
+    * Install the interrupt handler
+    * calls rtems_interrupt_catch
+    */  
+   dummy = (rtems_isr_entry) set_vector( uti596DynamicInterruptHandler, 0x57, 1 );
+   
+ 
+   /* Initialize the 82596 memory ( Transmit buffers ) */
+   uti596_initMem(sc);
+ 
+ #ifdef DBG_INIT
+   printk("After attach, status of board = 0x%x\n", sc->scb.status );
+ #endif
+ }
+ 
+ 
+ void uti596_reset_hardware(
+   struct uti596_softc *sc
+ )
+ {
+   int boguscnt = 1000;
+   rtems_status_code status_code;
+   struct i596_cmd *pCmd;
+ 
+ 
+   printf("uti596_reset_hardware\n");
+   pCmd = sc->pCmdHead;  /* This is a tx command for sure (99.99999%)  */
+ 
+   /* reset the board  */
+   i82596->port_upper = 0;
+   i82596->port_lower = 0;
+ 
+   if ( sc->pScp == NULL ) {
+     printf("Calloc scp\n");
+     uti596_softc.pScp = (struct i596_scp *) calloc(1,sizeof(struct i596_scp) + 0xf);
+   }
+ 
+ #ifdef DBG_RESET
+   printk("reset_hardware:Scp address %p\n", sc->pScp);
+ #endif
+   sc->pScp = (struct i596_scp *)
+     ((((int)uti596_softc.pScp) + 0xf) & 0xfffffff0);
+ 
+ #ifdef DBG_RESET
+   printk("reset_hardware:change scp address to : %p\n",sc->pScp);
+ #endif
+ 
+ 
+   /* change the scp address */
+ #ifdef DBG_RESET
+   printk("Change the SCP address\n");
+ #endif
+ 
+   /* reset the board  */
+   i82596->port_upper = 0;
+   i82596->port_lower = 0;
+   
+   /* supply the Scp address */
+   i82596->port_upper = (( (int)sc->pScp) >> 16 ) & 0xffff;
+   i82596->port_lower = ((((int)sc->pScp) &  0xffff )); 
+ 
+   /* This is linear mode, LOCK function is disabled  */
+ 
+   sc->pScp->sysbus = 0x00540000;
+   sc->pScp->iscp   = &sc->iscp;
+   sc->iscp.scb     = &sc->scb;
+   sc->iscp.stat    = 0x0001;
+ 
+   sc->pCmdHead     = sc->scb.pCmd = I596_NULL;
+   /*
+    * Wake the transmitter if needed.
+    */
+   if ( uti596_softc.txDaemonTid && pCmd != I596_NULL ){
+     printf("****RESET: wakes transmitter!\n");
+     status_code = rtems_event_send (uti596_softc.txDaemonTid,
+                            INTERRUPT_EVENT);
+ 
+     if ( status_code != RTEMS_SUCCESSFUL )
+       printk("****ERROR:Could NOT send event to tid 0x%x : %s\n",
+              uti596_softc.txDaemonTid, rtems_status_text (status_code) );
+   }
+ 
+ #ifdef DBG_596
+   printk("reset_hardware: starting i82596.\n");
+ #endif
+ 
+   /* Pass the scb address to the 596 */
+   i82596->chan_attn = 0;
+ 
+   while (sc->iscp.stat)
+     if (--boguscnt == 0)
+       {
+         printf("reset_hardware: timed out with status %4.4lx\n",
+                sc->iscp.stat );
+         break;
+       }
+ 
+   /* clear the command word */
+   sc->scb.command = 0;
+ 
+ #ifdef DBG_RESET
+   printk("After reset_hardware, status of board = 0x%x\n", sc->scb.status );
+ #endif
+ }
+ 
+ 
+ /***********************************************************************
+  *  Function:   uti596_initMem
+  *
+  *  Description:
+  *             creates the necessary descriptors for the
+  *             uti596 board, hooks the interrupt, and starts the board.
+  *             Assumes that interrupts are hooked.
+  *
+  *  Algorithm:
+  *
+  ***********************************************************************/
+ 
+ void uti596_initMem(
+   struct uti596_softc * sc
+ )
+ {
+     int i,count;
+     struct i596_tbd *pTbd;
+ 
+     sc->resetDone = 0; /* ??? */
+ 
+     /*
+      * Set up receive frame area (RFA)
+      */
+     i = uti596_initRFA( sc->rxBdCount );
+     if ( i < sc->rxBdCount  )
+       printf("init_rfd: only able to allocate %d receive frame descriptors\n", i);
+ 
+     sc->scb.pRfd =  sc->pBeginRFA;
+ 
+     /*
+      * Diagnose the health of the board
+      */
+     uti596Diagnose(1);
+ 
+     /*
+      * set up the i596 config command
+      */
+ #ifdef DBG_INIT
+     printk("Configuring\n");
+ #endif
+ 
+     sc->set_conf.cmd.command = CmdConfigure;
+     memcpy (sc->set_conf.data, uti596initSetup, 14);
+     uti596addPolledCmd( (struct i596_cmd *) &sc->set_conf);
+ 
+     /****
+     * POLL
+     ****/
+ 
+     count = 2000;
+     while( !( sc->set_conf.cmd.status & STAT_C ) && --count )
+       printf(".");
+ 
+     if ( count )
+       printf("Configure OK, count = %d\n",count);
+     else
+       printf("***Configure failed\n");
+ 
+     /*******/
+ 
+     /*
+      * Create the IA setup command
+      */
+ 
+ #ifdef DBG_INIT
+     printk("Setting Address\n");
+ #endif
+     sc->set_add.cmd.command = CmdSASetup;
+     for ( i=0; i<6; i++)
+       sc->set_add.data[i]=sc->arpcom.ac_enaddr[i];
+ 
+     sc->cmdOk = 0;
+     uti596addPolledCmd((struct i596_cmd *)&sc->set_add);
+         /*******/
+ 
+     count = 2000;
+     while( !(sc->set_add.cmd.status & STAT_C ) && --count)
+       printf(".");
+ 
+     if ( count )
+       printf ("Set Address OK, count= %d\n",count);
+     else
+       printf("Set Address Failed\n");
+     /*******/
+ 
+ #ifdef DBG_INIT
+     printk( "After initialization, status and command: 0x%x, 0x%x\n",
+             sc->scb.status, sc->scb.status);
+ 
+ #endif
+ 
+     /* initialize transmit buffer descriptors*/
+     sc->pLastUnkRFD = I596_NULL;
+     sc->pTxCmd         = (struct tx_cmd *) calloc (1,sizeof (struct tx_cmd) );
+     sc->pTbd           = (struct i596_tbd *) calloc (1,sizeof (struct i596_tbd) );
+     sc->pTxCmd -> pTbd = sc->pTbd;
+     sc->pTxCmd->cmd.command  = CMD_FLEX|CmdTx;
+     sc->pTxCmd->pad          = 0;
+     sc->pTxCmd->size         = 0; /* all bytes are in list of TBD's */
+ 
+     pTbd = sc->pTbd;
+ 
+     for ( i=0; i<sc->txBdCount; i++)
+       pTbd = pTbd -> next = (struct i596_tbd *) calloc (1,sizeof (struct i596_tbd) );
+ 
+     pTbd -> next = I596_NULL;
+ 
+     memset ( &sc->zeroes, 0, 64);
+ 
+ #ifdef DBG_596
+     printk( "After receiver start, status and command: 0x%x, 0x%x\n",
+             sc->scb.status, sc->scb.status);
+ #endif
+     printf("uti596_initMem allows ISR's\n");
+     sc->resetDone = 1; /* now need ISR  */
+ 
+ }
+ 
+ /***********************************************************************
+  *  Function:   uti596dump
+  *
+  *  Description: Dump 596 registers
+  *
+  *  Algorithm:
+  ***********************************************************************/
+ /* static */ int uti596dump(
+   char * pDumpArea
+ )
+ {
+   struct i596_dump dumpCmd;
+   int boguscnt = 25000000; /* over a second! */
+ 
+ #ifdef DBG_596
+   printk("uti596dump:\n");
+ #endif
+ 
+   dumpCmd.cmd.command = CmdDump;
+   dumpCmd.cmd.next    = I596_NULL;
+   dumpCmd.pData       = pDumpArea;
+   uti596_softc.cmdOk = 0;
+   uti596addCmd        ( (struct i596_cmd *)&dumpCmd);
+   while (1)
+     if ( --boguscnt == 0){
+       printf("Dump command was not processed within spin loop delay\n");
+       return 0;
+     }
+     else {
+       if ( uti596_softc.cmdOk )
+         return 1; /* successful completion */
+     }
+ }
+ 
+ 
+ /***********************************************************************
+  *  Function:   uti596_rxDaemon
+  *
+  *  Description: Receiver task
+  *
+  *  Algorithm: Extract the packet from an RFD, and place into an
+  *             mbuf chain.  Place the mbuf chain in the network task
+  *             queue. Assumes that the frame check sequence is removed
+  *             by the 82596.
+  *
+  ***********************************************************************/
+ 
+ /* static */ void uti596_rxDaemon(
+   void *arg
+ )
+ {
+   struct uti596_softc *sc = (struct uti596_softc *)arg;
+   struct ifnet *ifp = &sc->arpcom.ac_if;
+   struct mbuf *m;
+ 
+   struct i596_rfd *pRfd;
+   ISR_Level level;
+   int tid;
+   rtems_event_set events;
+   struct ether_header *eh;
+ 
+   int frames = 0;
+ 
+ #ifdef DBG_596
+   printk ("uti596_rxDaemon\n");
+   printk("&scb = %p, pRfd = %p\n", &sc->scb,sc->scb.pRfd);
+ #endif
+ 
+   rtems_task_ident (0, 0, &tid);
+ 
+ #ifdef DBG_596
+   printk("RX tid = 0x%x\n", tid);
+ #endif
+ 
+     for(;;) {
+       /*
+        * Wait for packet.
+        */
+ #ifdef DBG_596
+       printk("Receiver sleeps\n");
+ #endif
+ 
+       rtems_bsdnet_event_receive (INTERRUPT_EVENT,
+                                   RTEMS_WAIT|RTEMS_EVENT_ANY,
+                                   RTEMS_NO_TIMEOUT,
+                                   &events);
+ 
+ #ifdef DBG_596
+       printk("Receiver wakes\n");
+ #endif
+       /*
+        * While received frames are available. Note that the frame may be
+        * a fragment, so it is NOT a complete packet.
+        */
+       pRfd = uti596dequeue( &sc->pInboundFrameQueue);
+       while ( pRfd &&
+               pRfd != I596_NULL &&
+               pRfd -> stat & STAT_C )
+         {
+ 
+ #ifdef DEBUG_INIT
+           printk("\nReceived packet:\n");
+           print_eth( pRfd->data);
+ #endif
+           if ( pRfd->stat & STAT_OK){
+             /*   a good frame. Allocate an mbuf to take it from the queue */
+ 
+             int pkt_len = pRfd->count & 0x3fff; /* the actual # of bytes received */
+ 
+ #ifdef DBG_596
+             printk("Good frame, @%p, data @%p length %d\n", pRfd, pRfd -> data , pkt_len);
+ #endif
+             frames++;
+ 
+ 
+             /*
+              * Allocate an mbuf to give to the stack
+              * The format of the data portion of the RFD is:
+              * <ethernet header, payload>.
+              * The FRAME CHECK SEQUENCE / CRC is stripped by the uti596.
+              * This is to be optimized later.... should not have to memcopy!
+              */
+             MGETHDR(m, M_WAIT, MT_DATA);
+             MCLGET(m, M_WAIT);
+ 
+             m->m_pkthdr.rcvif = ifp;
+             /* move everything into an mbuf */
+             memcpy(m->m_data,
+                    pRfd->data,
+                    pkt_len);
+ 
+             m->m_len = m->m_pkthdr.len = pkt_len - sizeof(struct ether_header) - 4;
+ 
+             /* move the header to an mbuf */
+             eh = mtod (m, struct ether_header *);
+             m->m_data += sizeof(struct ether_header);
+ 
+ #ifdef DBG_596
+               printk("m->m_ext: %p pRfd -> data: %p\n",
+                      m->m_ext,  pRfd -> data);
+ #endif
+ #ifdef DEBUG_INIT_2
+             printk("mbuf contains:\n");
+             print_eth( (char *) (((int)m->m_data)-sizeof(struct ether_header)));
+             for ( i = 0; i<20; i++)
+               printk(".");
+ #endif
+             ether_input (ifp, eh, m);
+ 
+           } /* end if STAT_OK */
+ 
+           else {
+             /*
+              * A bad frame is present: Note that this could be the last RFD!
+              */
+ #ifdef DBG_596
+             printk("Bad frame\n");
+ #endif
+             /*
+              * FIX ME: use the statistics from the SCB
+              */
+             sc->stats.rx_errors++;
+             if ((sc->scb.pRfd->stat) & 0x0001)
+               sc->stats.collisions++;
+             if ((sc->scb.pRfd->stat) & 0x0080)
+               sc->stats.rx_length_errors++;
+             if ((sc->scb.pRfd->stat) & 0x0100)
+               sc->stats.rx_over_errors++;
+             if ((sc->scb.pRfd->stat) & 0x0200)
+               sc->stats.rx_fifo_errors++;
+             if ((sc->scb.pRfd->stat) & 0x0400)
+               sc->stats.rx_frame_errors++;
+             if ((sc->scb.pRfd->stat) & 0x0800)
+               sc->stats.rx_crc_errors++;
+             if ((sc->scb.pRfd->stat) & 0x1000)
+               sc->stats.rx_length_errors++;
+           }
+ 
+           UTI_596_ASSERT(pRfd != I596_NULL, "Supplying NULL RFD\n");
+ 
+ #ifdef DBG_SUPPLY_FD
+           printk("Supply FD Starting\n");
+ #endif
+           _ISR_Disable(level);
+           uti596supplyFD ( pRfd );   /* Return RFD to RFA. CAN WE REALLY?*/
+           _ISR_Enable(level);
+ #ifdef DBG_SUPPLY_FD
+           printk("Supply FD Complete\n");
+ #endif
+           pRfd = uti596dequeue( &sc->pInboundFrameQueue); /* grab next frame */
+ 
+         } /* end while */
+     } /* end for(;;)*/
+ 
+ #ifdef DBG_596
+     printk ("frames %d\n", frames);
+ #endif
+ }
+ 
+ 
+  /***********************************************************************
+   *  Function:   uti596clearListStatus
+   *
+   *  Description:
+   *             Clear the stat fields for all rfd's
+   *  Algorithm:
+   *
+   ***********************************************************************/
+ 
+ void uti596clearListStatus(
+   struct i596_rfd *pRfd
+ )
+ {
+ 
+   while ( pRfd != I596_NULL ) {
+     pRfd -> stat = 0;           /* clear the status field */
+     pRfd = pRfd-> next;
+   }
+ }
+ 
+ void uti596reset( void )
+ {
+    int i,count;
+    struct uti596_softc *sc = &uti596_softc;
+    /*   struct i596_rfd * pRfd; */
+ 
+ #ifdef DBG_RESET
+      printk ("reset: begins\n");
+ #endif
+ 
+   sc->resetDone = 0;
+ 
+   UTI_WAIT_COMMAND_ACCEPTED(10000, "reset: wait for previous command complete");
+ 
+   /* abort ALL of the current work */
+     /* FEB 17 REMOVED
+     >>>>>
+     sc->scb.command = CUC_ABORT | RX_ABORT;
+     i82596->chan_attn = 0;
+     UTI_WAIT_COMMAND_ACCEPTED(4000, "reset: abort requested");
+     <<<<<
+     */
+ 
+   uti596_reset_hardware(&uti596_softc); /* reset the ethernet hardware. must re-config */
+ 
+ #ifdef DBG_RESET
+   uti596Diagnose(1);
+ #endif
+ 
+   sc->set_conf.cmd.command = CmdConfigure;
+   memcpy (sc->set_conf.data, uti596initSetup, 14);
+   uti596addPolledCmd( (struct i596_cmd *) &sc->set_conf);
+ 
+   /****
+    * POLL
+    ****/
+ 
+   count = 2000;
+   while( !( sc->set_conf.cmd.status & STAT_C ) && --count )
+     printf(".");
+ 
+   if ( count )
+     printf("Configure OK, count = %d\n",count);
+   else
+     printf("***reset: Configure failed\n");
+ 
+   /*
+    * Create the IA setup command
+    */
+ 
+ #ifdef DBG_RESET
+   printk("reset: Setting Address\n");
+ #endif
+   sc->set_add.cmd.command = CmdSASetup;
+   for ( i=0; i<6; i++)
+     sc->set_add.data[i]=sc->arpcom.ac_enaddr[i];
+ 
+   sc->cmdOk = 0;
+   uti596addPolledCmd((struct i596_cmd *)&sc->set_add);
+ 
+   count = 2000;
+   while( !(sc->set_add.cmd.status & STAT_C ) && --count)
+     printf(".");
+ 
+   if ( count )
+     printf ("Reset Set Address OK, count= %d\n",count);
+   else
+     printf("Reset Set Address Failed\n");
+   /*******/
+ 
+   sc->pCmdHead = sc->pCmdTail = sc->scb.pCmd = I596_NULL; /* Feb 17. clear these out */
+ 
+ #ifdef DBG_RESET
+   printk( "After reset, status and command: 0x%x, 0x%x\n",
+           sc->scb.status, sc->scb.status);
+ 
+ #endif
+ 
+ 
+   /* restore the RFA */
+ 
+   /*dumpQ();*/
+ 
+   if ( sc->pLastUnkRFD != I596_NULL ) {
+     sc-> pEndRFA =  sc->pLastUnkRFD; /* The end position can be updated */
+     sc-> pLastUnkRFD = I596_NULL;
+   }
+ 
+   sc->pEndRFA->next = sc->pSavedRfdQueue;
+   if ( sc->pSavedRfdQueue != I596_NULL ) {
+     sc->pEndRFA = sc->pEndSavedQueue;
+     sc->pSavedRfdQueue = sc->pEndSavedQueue = I596_NULL;
+     sc -> countRFD = sc->rxBdCount ;
+   }
+ 
+   /*   if ( sc->pInboundFrameQueue != I596_NULL ){
+     do {
+       pRfd = sc->pInboundFrameQueue->next;
+       sc->pEndRFA -> next = sc->pInboundFrameQueue;
+       sc->pInboundFrameQueue = pRfd;
+      } while( pRfd != I596_NULL ) ;
+ 
+   }
+   */
+ 
+   sc->scb.pRfd =  sc->pBeginRFA; /* readdress the head of the RFA in the SCB */
+ 
+   uti596clearListStatus(sc->pBeginRFA );
+ 
+   /*  dumpQ();*/
+ 
+   printf("Reset:Starting NIC\n");
+   sc->scb.command = RX_START;
+   sc->started = 1;               /* we assume that the start works */
+   sc->resetDone = 1;             /* moved here from after channel attn. */
+   i82596->chan_attn = 0;
+   UTI_WAIT_COMMAND_ACCEPTED(4000, "reset");
+   printf("Reset:Start complete \n");
+   UTI_596_ASSERT(sc->pCmdHead == I596_NULL, "Reset: CMD not cleared\n");
+ 
+ 
+   /* uti596addCmd(&uti506_softc.nop); */ /* just for fun */
+ 
+ #ifdef DBG_RESET
+   printk("reset: complete\n");
+ #endif
+ }
+ 
+ 
+  /***********************************************************************
+   *  Function:   uti596addCmd
+   *
+   *  Description:
+   *             This routine adds a command onto the end of the
+   *             command chain
+   *
+   *  Algorithm:
+   *            Add the command to the end of and existing chain,
+   *            or start the chain and issue a CUC_START
+   *
+   *
+   ***********************************************************************/
+ 
+ /* static */ void uti596addCmd(
+   struct i596_cmd *pCmd
+ )
+ {
+      ISR_Level level;
+ 
+  #ifdef DBG_596
+      printk("Adding command 0x%x\n", pCmd -> command );
+  #endif
+ 
+ #ifdef DBG_ADD
+ 
+      switch ( pCmd -> command & 0x7 ){ /* check bottom 7 bits */
+      case CmdConfigure:
+        printk("ADD: Configure Command 0x%x\n", pCmd->command);
+        break;
+      case CmdSASetup:
+        printk("ADD: Set Address Command 0x%x\n", pCmd->command);
+        break;
+      case CmdMulticastList:
+        printk("ADD: Multi-cast list 0x%x\n", pCmd->command);
+        break;
+      case CmdNOp:
+         printk("ADD: NO op 0x%x\n", pCmd->command);
+         break;
+      case CmdTDR:
+         printk("ADD: TDR 0x%x\n", pCmd->command);
+         break;
+      case CmdDump:
+        printk("ADD: Dump 0x%x\n", pCmd->command);
+        break;
+      case CmdDiagnose:
+        printk("ADD: Diagnose 0x%x\n", pCmd->command);
+        break;
+      case CmdTx:
+        break;
+      default:
+        printk("****Unknown Command encountered 0x%x\n", pCmd->command);
+        break;
+      } /* end switch */
+ 
+ #endif
+ 
+      pCmd->status = 0;
+      pCmd->command |= (CMD_EOL | CMD_INTR ); /* all commands last in list & return an interrupt */
+ 
+      pCmd->next = I596_NULL;
+ 
+      _ISR_Disable(level);
+      if (uti596_softc.pCmdHead == I596_NULL)
+        {
+          uti596_softc.pCmdHead =
+            uti596_softc.pCmdTail =
+            uti596_softc.scb.pCmd = pCmd;
+ #ifdef DBG_596
+          printk("First Cmd\n");
+ #endif
+          UTI_WAIT_COMMAND_ACCEPTED(10000,"add command"); /* wait for acceptance of previous command */
+          /* CHANGED TO |= Mar. 27 4:20 pm, was just =. changed back jun 18 1998. The wait assures command = 0 */
+          uti596_softc.scb.command = CUC_START;
+          i82596->chan_attn = 0;
+      _ISR_Enable(level);
+        }
+      else
+        {
+ #ifdef DBG_596
+          printk("Chained Cmd\n");
+ #endif
+          uti596_softc.pCmdTail->next = pCmd;
+          uti596_softc.pCmdTail = pCmd;           /* added Jan 30 */
+      _ISR_Enable(level);
+        }
+ 
+ #ifdef DBG_596
+          printk("Scb status & command 0x%x 0x%x\n",
+                 uti596_softc.scb.status,
+                 uti596_softc.scb.command );
+ #endif
+ }
+ 
+ 
+  /***********************************************************************
+   *  Function:   uti596addPolledCmd
+   *
+   *  Description:
+   *             This routine issues a single command then polls for it's
+   *             completion.  TO BE CALLED FROM ISR ONLY
+   *
+   *  Algorithm:
+   *            Give the command to the driver. ( CUC_START is ALWAYS required )
+   *            Poll for completion.
+   *
+   ***********************************************************************/
+ 
+ void uti596addPolledCmd(
+   struct i596_cmd *pCmd
+ )
+ {
+ 
+  #ifdef DBG_596
+      printk("Adding command 0x%x\n", pCmd -> command );
+  #endif
+ 
+ #ifdef DBG_POLLED_CMD
+ 
+      switch ( pCmd -> command & 0x7 ){ /* check bottom 7 bits */
+      case CmdConfigure:
+        printk("PolledCMD: Configure Command 0x%x\n", pCmd->command);
+        break;
+      case CmdSASetup:
+        printk("PolledCMD: Set CMDress Command 0x%x\n", pCmd->command);
+        break;
+      case CmdMulticastList:
+        printk("PolledCMD: Multi-cast list 0x%x\n", pCmd->command);
+        break;
+      case CmdNOp:
+         printk("PolledCMD: NO op 0x%x\n", pCmd->command);
+         break;
+      case CmdTDR:
+         printk("PolledCMD: TDR 0x%x\n", pCmd->command);
+         break;
+      case CmdDump:
+        printk("PolledCMD: Dump 0x%x\n", pCmd->command);
+        break;
+      case CmdDiagnose:
+        printk("PolledCMD: Diagnose 0x%x\n", pCmd->command);
+        break;
+      case CmdTx:
+        break;
+      default:
+        printk("PolledCMD: ****Unknown Command encountered 0x%x\n", pCmd->command);
+        break;
+      } /* end switch */
+ 
+ #endif
+ 
+      pCmd->status = 0;
+      pCmd->command |=  CMD_EOL ; /* only command in list*/
+ 
+      pCmd->next = I596_NULL;
+ 
+      UTI_WAIT_COMMAND_ACCEPTED(10000,"Add Polled command: wait prev");
+ 
+      uti596_softc.pCmdHead = uti596_softc.pCmdTail = uti596_softc.scb.pCmd = pCmd;
+      uti596_softc.scb.command = CUC_START;
+      i82596->chan_attn = 0;
+ 
+      UTI_WAIT_COMMAND_ACCEPTED(10000,"Add Polled command: start");
+      uti596_softc.pCmdHead = uti596_softc.pCmdTail = uti596_softc.scb.pCmd = I596_NULL;
+ 
+ #ifdef DBG_POLLED_CMD
+      printk("Scb status & command 0x%x 0x%x\n",
+             uti596_softc.scb.status,
+             uti596_softc.scb.command );
+ #endif
+ }
+ 
+ /*
+  * Driver transmit daemon
+  */
+ void uti596_txDaemon(
+   void *arg
+ )
+ {
+   struct uti596_softc *sc = (struct uti596_softc *)arg;
+   struct ifnet *ifp = &sc->arpcom.ac_if;
+   struct mbuf *m;
+   rtems_event_set events;
+ 
+   for (;;) {
+    /*
+     * Wait for packet from stack
+     */
+     rtems_bsdnet_event_receive (START_TRANSMIT_EVENT,
+                                 RTEMS_EVENT_ANY | RTEMS_WAIT,
+                                 RTEMS_NO_TIMEOUT, &events);
+ 
+    /*
+     * Send packets till queue is empty.
+     * Ensure that irq is on before sending.
+     */
+     for (;;) {
+      /* Get the next mbuf chain to transmit. */
+       IF_DEQUEUE(&ifp->if_snd, m);
+       if (!m)
+         break;
+ 
+       send_packet (ifp, m); /* blocks */
+     }
+     ifp->if_flags &= ~IFF_OACTIVE; /* no more to send, mark output inactive  */
+   }
+ }
+ 
+ 
+ /*
+  * NIC reset daemon.
+  */
+ void uti596_resetDaemon(
+   void *arg
+ )
+ {
+   struct uti596_softc *sc = (struct uti596_softc *)arg;
+   rtems_event_set events;
+   rtems_time_of_day tm_struct;
+ 
+   /* struct ifnet *ifp = &sc->arpcom.ac_if; */
+ 
+   for (;;) {
+    /* Wait for reset event from ISR */
+     rtems_bsdnet_event_receive (NIC_RESET_EVENT,
+                                 RTEMS_EVENT_ANY | RTEMS_WAIT,
+                                 RTEMS_NO_TIMEOUT, &events);
+ 
+     rtems_clock_get(RTEMS_CLOCK_GET_TOD, &tm_struct);
+     printf("reset daemon: Resetting NIC @ %d:%d:%d \n",
+            tm_struct.hour, tm_struct.minute, tm_struct.second);
+ 
+     sc->stats.nic_reset_count++;
+     /* Reinitialize the LANC */
+     rtems_bsdnet_semaphore_obtain ();
+     uti596reset();
+     rtems_bsdnet_semaphore_release ();
+   }
+ }
+ 
+ 
+  /***********************************************************************
+   *  Function:   send_packet
+   *
+   *  Description: Send a raw ethernet packet
+   *
+   *  Algorithm:
+   *             increment some stats counters,
+   *             create the transmit command,
+   *             add the command to the CBL,
+   *             wait for event
+   *
+   ***********************************************************************/
+ 
+ void send_packet(
+   struct ifnet *ifp, struct mbuf *m
+ )
+ {
+   struct i596_tbd *pPrev = I596_NULL;
+   struct i596_tbd *pRemainingTbdList;
+   struct i596_tbd *pTbd;
+   struct mbuf *n, *input_m = m;
+ 
+   struct uti596_softc *sc = ifp->if_softc; /* is this available from ifp ?*/
+ 
+   struct mbuf *l = NULL;
+   unsigned int length = 0;
+   rtems_status_code status;
+   int bd_count = 0;
+   rtems_event_set events;
+ 
+  /*
+   * For all mbufs in the chain,
+   *  fill a transmit buffer descriptor
+   */
+   pTbd = sc->pTxCmd->pTbd;
+ 
+   do {
+     if (m->m_len) {
+       /*
+        * Fill in the buffer descriptor
+        */
+       length    += m->m_len;
+       pTbd->data = mtod (m, void *);
+       pTbd->size = m->m_len;
+       pPrev      = pTbd;
+       pTbd       = pTbd -> next;
+       l          = m;
+       m          = m->m_next;
+     }
+     else {
+       /*
+        * Just toss empty mbufs
+        */
+       MFREE (m, n);
+       m = n;
+       if (l != NULL)
+         l->m_next = m;
+     }
+   } while( m != NULL && ++bd_count < 16 );
+ 
+   /* This should never happen */
+   if ( bd_count == 16 ) {
+     printf("TX ERROR:Too many mbufs in the packet!!!\n");
+     printf("Must coalesce!\n");
+   }
+ 
+ 
+   if ( length < UTI_596_ETH_MIN_SIZE ) {
+     pTbd->data = sc->zeroes;       /* add padding to pTbd */
+     pTbd->size = UTI_596_ETH_MIN_SIZE - length; /* zeroes have no effect on the CRC */
+   }
+   else
+     pTbd = pPrev; /* Don't use pTbd in the send routine */
+ 
+   /*  Disconnect the packet from the list of Tbd's  */
+   pRemainingTbdList = pTbd->next;
+   pTbd->next  = I596_NULL;
+   pTbd->size |= UTI_596_END_OF_FRAME;
+ 
+ #ifdef DBG_RAW
+   printk("RAW:Add cmd and sleep\n");
+ #endif
+ 
+   sc->rawsndcnt++;
+ 
+ #ifdef DBG_RAW
+   printk ("sending packet\n");
+ #endif
+ 
+   /* Sending Zero length packet: shouldn't happen */
+   if (pTbd->size <= 0) return ;
+ 
+ #ifdef DEBUG_INIT_2
+   printk("\nTransmitter adds packet\n");
+   print_hdr    ( sc->pTxCmd->pTbd->data ); /* print the first part */
+   print_pkt    ( sc->pTxCmd->pTbd->next->data ); /* print the first part */
+   /*  print_echo(sc->pTxCmd->pTbd->data); */
+ #endif
+   /* add the command to the output command queue */
+   uti596addCmd ( (struct i596_cmd *) sc->pTxCmd );
+ 
+   /* sleep until the command has been processed or Timeout encountered. */
+   status= rtems_bsdnet_event_receive (INTERRUPT_EVENT,
+                                       RTEMS_WAIT|RTEMS_EVENT_ANY,
+                                       RTEMS_NO_TIMEOUT,
+                                       &events);
+ 
+   if ( status != RTEMS_SUCCESSFUL ) {
+     printf("Could not sleep %s\n", rtems_status_text(status));
+   }
+ 
+ #ifdef DBG_RAW
+   printk("RAW: wake\n");
+ #endif
+ 
+   sc->txInterrupts++;
+ 
+ #ifdef DEBUG_INIT
+   printk("\nTransmitter issued packet\n");
+   print_hdr    ( sc->pTxCmd->pTbd -> data ); /* print the first part */
+   print_pkt    ( sc->pTxCmd->pTbd ->next-> data ); /* print the first part */
+ #endif
+ 
+   if ( sc->pTxCmd -> cmd.status & STAT_OK )
+     sc->stats.tx_packets++;
+   else
+     {
+ #ifdef DBG_RAW
+       printk("******Driver Error 0x%x\n", sc->pTxCmd -> cmd.status );
+ #endif
+       sc->stats.tx_errors++;
+       if ( sc->pTxCmd->cmd.status  & 0x0020 )
+         sc->stats.tx_retries_exceeded++;
+       if (!(sc->pTxCmd->cmd.status & 0x0040))
+         sc->stats.tx_heartbeat_errors++;
+       if ( sc->pTxCmd->cmd.status  & 0x0400 )
+         sc->stats.tx_carrier_errors++;
+       if ( sc->pTxCmd->cmd.status  & 0x0800 )
+         sc->stats.collisions++;
+       if ( sc->pTxCmd->cmd.status  & 0x1000 )
+         sc->stats.tx_aborted_errors++;
+     } /* end if stat_ok */
+ 
+   /*
+    * Restore the transmited buffer descriptor chain.
+    */
+   pTbd -> next = pRemainingTbdList;
+ 
+   /*
+    * Free the mbufs used by the sender.
+    */
+   m = input_m;
+   while ( m != NULL ) {
+     MFREE(m,n);
+     m = n;
+   }
+ }
+ 
+ 
+  /***********************************************************************
+   *  Function:   print_eth
+   *
+   *  Description:
+   *              Print the contents of an ethernet packet header
+   *              CANNOT BE CALLED FROM ISR
+   *
+   *  Algorithm:
+   *            Print Destination, Src, and type of packet
+   *
+   ***********************************************************************/
+ 
+ /* static */ void print_eth(
+   unsigned char *add
+ )
+ {
+   int i;
+   short int length;
+ 
+   printk("Packet Location %p\n", add);
+ 
+   printk ("Dest  ");
+ 
+   for (i = 0; i < 6; i++)
+     printk(" %2.2X", add[i]);
+ 
+   printk ("\n");
+ 
+   printk ("Source");
+ 
+   for (i = 6; i < 12; i++)
+     printk(" %2.2X", add[i]);
+ 
+     printk ("\n");
+ 
+   printk ("frame type %2.2X%2.2X\n", add[12], add[13]);
+ 
+   if ( add[12] == 0x08 && add[13] == 0x06 ) { 
+     /* an ARP */
+     printk("Hardware type : %2.2X%2.2X\n", add[14],add[15]);
+     printk("Protocol type : %2.2X%2.2X\n", add[16],add[17]);
+     printk("Hardware size : %2.2X\n", add[18]);
+     printk("Protocol size : %2.2X\n", add[19]);
+     printk("op            : %2.2X%2.2X\n", add[20],add[21]);
+ 
+     printk("Sender Enet addr: ");
+ 
+     for ( i=0; i< 5 ; i++)
+       printk( "%x:", add[22 + i]);
+ 
+     printk("%x\n", add[27]);
+ 
+     printk("Sender IP addr: ");
+     for ( i=0; i< 3 ; i++)
+       printk( "%u.", add[28 + i]);
+ 
+     printk("%u\n", add[31]);
+ 
+     printk("Target Enet addr: ");
+     for ( i=0; i< 5 ; i++)
+       printk( "%x:", add[32 + i]);
+     printk("%x\n", add[37]);
+ 
+     printk("Target IP addr: ");
+ 
+     for ( i=0; i< 3 ; i++)
+       printk( "%u.", add[38 + i]);
+     printk("%u\n", add[41]);
+   }
+ 
+   if ( add[12] == 0x08 && add[13] == 0x00 ) { /* an IP packet */
+     printk("*********************IP HEADER******************\n");
+     printk("IP version/IPhdr length: %2.2X TOS: %2.2X\n", add[14] , add[15]);
+     printk("IP total length: %2.2X %2.2X, decimal %d\n", add[16], add[17], length = (add[16]<<8 | add[17] ));
+     printk("IP identification: %2.2X %2.2X, 3-bit flags and offset %2.2X %2.2X\n",
+             add[18],add[19], add[20], add[21]);
+     printk("IP TTL: %2.2X, protocol: %2.2X, checksum: %2.2X %2.2X \n",
+              add[22],add[23],add[24],add[25]);
+     printk("IP packet type: %2.2X code %2.2X\n", add[34],add[35]);
+ 
+     printk("Source IP address: ");
+     for ( i=0; i< 3 ; i++)
+       printk( "%u.", add[26 + i]);
+ 
+     printk("%u\n", add[29]);
+ 
+     printk("Destination IP address: ");
+     for ( i=0; i< 3 ; i++)
+       printk( "%u.", add[30 + i]);
+     printk("%u\n", add[33]);
+ 
+     /* printk("********************IP Packet Data*******************\n");
+     length -=20;
+     for ( i=0; i < length ; i++)
+       printk("0x%2.2x ", add[34+i]);
+     printk("\n");
+ 
+     printk("ICMP checksum: %2.2x %2.2x\n", add[36], add[37]);
+     printk("ICMP identifier: %2.2x %2.2x\n", add[38], add[39]);
+     printk("ICMP sequence nbr: %2.2x %2.2x\n", add[40], add[41]);
+     */
+   }
+ }
+ 
+ 
+ #ifdef DEBUG_INIT
+ 
+  /***********************************************************************
+   *  Function:   print_hdr
+   *
+   *  Description:
+   *              Print the contents of an ethernet packet header
+   *              CANNOT BE CALLED FROM ISR
+   *
+   *  Algorithm:
+   *            Print Destination, Src, and type of packet
+   *
+   ***********************************************************************/
+ 
+ /* static */ void print_hdr(
+   unsigned char *add
+ )
+ {
+   int i;
+   short int length;
+ 
+   printk("Header Location %p\n", add);
+ 
+   printk ("Dest  ");
+ 
+   for (i = 0; i < 6; i++)
+     printk(" %2.2X", add[i]);
+ 
+   printk ("\n");
+ 
+   printk ("Source");
+ 
+   for (i = 6; i < 12; i++)
+     printk(" %2.2X", add[i]);
+ 
+   printk ("\n");
+ 
+   printk ("frame type %2.2X%2.2X\n", add[12], add[13]);
+ }
+ 
+ 
+  /***********************************************************************
+   *  Function:   print_pkt
+   *
+   *  Description:
+   *              Print the contents of an ethernet packet header
+   *              CANNOT BE CALLED FROM ISR
+   *
+   *  Algorithm:
+   *            Print Destination, Src, and type of packet
+   *
+   ***********************************************************************/
+ 
+ /* static */ void print_pkt(
+   unsigned char *add
+ )
+ {
+   int i;
+   short int length;
+ 
+   printk("Data Location %p\n", add);
+ 
+   if ( add[0] == 0x08 && add[1] == 0x06 ) {
+     /* an ARP */
+     printk("Hardware type : %2.2X%2.2X\n", add[14],add[15]);
+     printk("Protocol type : %2.2X%2.2X\n", add[16],add[17]);
+     printk("Hardware size : %2.2X\n", add[18]);
+     printk("Protocol size : %2.2X\n", add[19]);
+     printk("op            : %2.2X%2.2X\n", add[20],add[21]);
+ 
+     printk("Sender Enet addr: ");
+ 
+     for ( i=0; i< 5 ; i++)
+       printk( "%x:", add[22 + i]);
+ 
+     printk("%x\n", add[27]);
+ 
+     printk("Sender IP addr: ");
+     for ( i=0; i< 3 ; i++)
+       printk( "%u.", add[28 + i]);
+ 
+     printk("%u\n", add[31]);
+ 
+     printk("Target Enet addr: ");
+     for ( i=0; i< 5 ; i++)
+       printk( "%x:", add[32 + i]);
+     printk("%x\n", add[37]);
+ 
+     printk("Target IP addr: ");
+ 
+     for ( i=0; i< 3 ; i++)
+       printk( "%u.", add[38 + i]);
+     printk("%u\n", add[41]);
+   }
+ 
+   if ( add[0] == 0x08 && add[1] == 0x00 ) {
+     /* an IP packet */
+     printk("*********************IP HEADER******************\n");
+     printk("IP version/IPhdr length: %2.2X TOS: %2.2X\n", add[14] , add[15]);
+     printk("IP total length: %2.2X %2.2X, decimal %d\n", add[16], add[17], length = (add[16]<<8 | add[17] ));
+     printk("IP identification: %2.2X %2.2X, 3-bit flags and offset %2.2X %2.2X\n",
+             add[18],add[19], add[20], add[21]);
+     printk("IP TTL: %2.2X, protocol: %2.2X, checksum: %2.2X %2.2X \n",
+             add[22],add[23],add[24],add[25]);
+     printk("IP packet type: %2.2X code %2.2X\n", add[34],add[35]);
+ 
+     printk("Source IP address: ");
+     for ( i=0; i< 3 ; i++)
+       printk( "%u.", add[26 + i]);
+ 
+     printk("%u\n", add[29]);
+ 
+     printk("Destination IP address: ");
+     for ( i=0; i< 3 ; i++)
+       printk( "%u.", add[30 + i]);
+     printk("%u\n", add[33]);
+ 
+     printk("********************IP Packet Data*******************\n");
+     length -=20;
+     for ( i=0; i < length ; i++)
+       printk("0x%2.2x ", add[34+i]);
+     printk("\n");
+ 
+     printk("ICMP checksum: %2.2x %2.2x\n", add[36], add[37]);
+     printk("ICMP identifier: %2.2x %2.2x\n", add[38], add[39]);
+     printk("ICMP sequence nbr: %2.2x %2.2x\n", add[40], add[41]);
+   }
+ }
+ 
+ 
+  /***********************************************************************
+   *  Function:   print_echo
+   *
+   *  Description:
+   *              Print the contents of an ethernet packet header
+   *              CANNOT BE CALLED FROM ISR
+   *
+   *  Algorithm:
+   *            Prints only echo packets
+   *
+   ***********************************************************************/
+ 
+ /* static */ void print_echo(
+   unsigned char *add
+ )
+ {
+   int i;
+   short int length;
+ 
+   if ( add[12] == 0x08 && add[13] == 0x00 ){ 
+     /* an IP packet */
+     printk("Packet Location %p\n", add);
+ 
+     printk ("Dest  ");
+ 
+     for (i = 0; i < 6; i++)
+       printk(" %2.2X", add[i]);
+ 
+     printk ("\n");
+       
+     printk ("Source");
+ 
+     for (i = 6; i < 12; i++)
+       printk(" %2.2X", add[i]);
+ 
+     printk ("\n");
+ 
+     printk ("frame type %2.2X%2.2X\n", add[12], add[13]);
+ 
+     printk("*********************IP HEADER******************\n");
+     printk("IP version/IPhdr length: %2.2X TOS: %2.2X\n", add[14] , add[15]);
+     printk("IP total length: %2.2X %2.2X, decimal %d\n", add[16], add[17], length = (add[16]<<8 | add[17] ));
+     printk("IP identification: %2.2X %2.2X, 3-bit flags and offset %2.2X %2.2X\n",
+             add[18],add[19], add[20], add[21]);
+     printk("IP TTL: %2.2X, protocol: %2.2X, checksum: %2.2X %2.2X \n",
+             add[22],add[23],add[24],add[25]);
+     printk("IP packet type: %2.2X code %2.2X\n", add[34],add[35]);
+ 
+     printk("Source IP address: ");
+     for ( i=0; i< 3 ; i++)
+       printk( "%u.", add[26 + i]);
+ 
+     printk("%u\n", add[29]);
+ 
+     printk("Destination IP address: ");
+     for ( i=0; i< 3 ; i++)
+       printk( "%u.", add[30 + i]);
+     printk("%u\n", add[33]);
+ 
+     printk("********************IP Packet Data*******************\n");
+     length -=20;
+     for ( i=0; i < length ; i++)
+       printk("0x%2.2x ", add[34+i]);
+     printk("\n");
+ 
+     printk("ICMP checksum: %2.2x %2.2x\n", add[36], add[37]);
+     printk("ICMP identifier: %2.2x %2.2x\n", add[38], add[39]);
+     printk("ICMP sequence nbr: %2.2x %2.2x\n", add[40], add[41]);
+   }
+ }
+ 
+ #endif
+ 
+  /***********************************************************************
+   *  Function:   uti596_attach
+   *
+   *  Description:
+   *              User requested attach of driver to hardware
+   *
+   *  Algorithm:
+   *
+   *              Check that the board is present
+   *              parse and store the command line parameters
+   *                 argv[0]: interface label, e.g., "uti596"
+   *                 argv[1]: maximum transmission unit, bytes, e.g., "1500"
+   *                 argv[2]: IP address (optional)
+   *              initialize required rx and tx buffers
+   *              hook interrupt
+   *              issue start command and some diagnostics
+   *              return
+   *
+   ***********************************************************************/
+ 
+ int uti596_attach(
+   struct rtems_bsdnet_ifconfig * pConfig
+ )
+ {
+   struct uti596_softc *sc = &uti596_softc;          /* soft config */
+   struct ifnet * ifp = &sc->arpcom.ac_if;
+ 
+ #ifdef DBG_ATTACH
+   printk("attach");
+ #endif
+ 
+ 
+   sc->started = 0; /* The NIC is not started yet */
+   sc->ioAddr = IO_ADDR;
+ 
+   /* Indicate to ULCS that this is initialized */
+   ifp->if_softc = sc;
+   sc -> pScp = NULL;
+ 
+   /* Assign the name */
+   ifp->if_name = "uti";
+ 
+   /* Assign the unit number */
+   ifp->if_unit = 1;
+ 
+   /* Assign mtu */
+   if ( pConfig -> mtu )
+     ifp->if_mtu = pConfig -> mtu;
+   else
+     ifp->if_mtu = ETHERMTU;
+ 
+ 
+ /* For now the ethernet address must be specified in networkconfig.h
+  * Change later so that it can be read in from BBRAM at $FFFC1F2C (6 bytes)
+  * mvme167 manual p. 1-47
+  */
+ 
+ 
+ /* 		Assign and possibly override the hw address
+   if ( !pConfig->hardware_address) { 
+   		Read the ethernet address from the board
+     for (i = 0; i < 8; i++)
+       inport_byte(NIC_ADDR+i,sc->arpcom.ac_enaddr[i] );
+   }
+   else {
+    		hwaddr override
+  */
+     memcpy (sc->arpcom.ac_enaddr, pConfig->hardware_address, ETHER_ADDR_LEN);
+ 
+ 
+ 
+   /* Test for valid hwaddr */
+   if(memcmp(sc->arpcom.ac_enaddr,"\xAA\x55\x01",3)!= 0)/* b0 of byte 0 != 0 => multicast */
+     return ENODEV;
+ 
+   /* Assign requested receive buffer descriptor count */
+   if (pConfig->rbuf_count)
+     sc->rxBdCount = pConfig->rbuf_count;
+   else
+     sc->rxBdCount = RX_BUF_COUNT;
+ 
+   /* Assign requested tx buffer descriptor count */
+   if (pConfig->xbuf_count)
+     sc->txBdCount = pConfig->xbuf_count;
+   else
+     sc->txBdCount = TX_BUF_COUNT * TX_BD_PER_BUF;
+ 
+   /* ignore_broadcast is an unused feature... accept broadcast */
+   /* sc->acceptBroadcast = !pConfig->ignore_broadcast; */
+ 
+   ifp->if_snd.ifq_maxlen = ifqmaxlen;
+   ifp->if_flags = IFF_BROADCAST | IFF_SIMPLEX;
+ 
+   /* to init_hardware */
+   sc->started = 1;
+   sc->pInboundFrameQueue = I596_NULL;
+ 
+ 
+   ifp->if_ioctl = uti596_ioctl;
+   ifp->if_init  = uti596_init;
+   ifp->if_start    = uti596_start;
+   ifp->if_output   = ether_output;
+ 
+   sc->scb.command = 0;
+ 
+   /*
+    * Attach the interface
+    */
+   if_attach (ifp);
+   ether_ifattach (ifp);
+   return 1;
+ }
+ 
+ 
+  /***********************************************************************
+   *  Function:   uti596DynamicInterruptHandler
+   *
+   *  Description:
+   *             This is the interrupt handler for the uti596 board
+   *
+   *  Algorithm:
+   *
+   ***********************************************************************/
+ 
+ /* static */ rtems_isr uti596DynamicInterruptHandler(
+   rtems_vector_number irq
+ )
+ {
+ #ifdef DEBUG_ISR
+   printk("I");
+ #endif
+ 
+  UTI_WAIT_COMMAND_ACCEPTED(20000, "****ERROR:on ISR entry");
+ 
+  scbStatus = uti596_softc.scb.status & 0xf000;
+ 
+  if ( scbStatus ) {
+    /* acknowledge interrupts */
+    
+    /* Write to the ICLR bit in the PCCchip2 control registers to clear
+     * the INT status bit. Clearing INT here *before* sending the CA signal
+     * to the 82596 should ensure that interrupts won't be lost.
+     */
+    
+     pccchip2->LANC_int_ctl |=0x08;
+     pccchip2->LANC_berr_ctl |=0x08;
+    
+    
+     /* printk("***INFO: ACK %x\n", scbStatus);*/
+    
+    
+     /* Send the CA signal to acknowledge interrupt */
+    
+     uti596_softc.scb.command = scbStatus;
+     i82596->chan_attn = 0;
+ 
+     if( uti596_softc.resetDone ) {
+       /* stack is attached */
+       UTI_WAIT_COMMAND_ACCEPTED(20000, "****ERROR:ACK");
+     }
+     else {
+       /* printk("***INFO: ACK'd w/o processing. status = %x\n", scbStatus); */
+       return;
+     }
+   }
+   else {
+     printk("\n***ERROR: Spurious interrupt. Resetting...\n");
+     uti596_softc.nic_reset = 1;
+   }
+ 
+   if ( (scbStatus & SCB_STAT_CX) && !(scbStatus & SCB_STAT_CNA) ){
+     printk_time();
+     printk("\n*****ERROR: Command Complete, and CNA available: 0x%x\nResetting...", scbStatus);
+     uti596_softc.nic_reset = 1;
+     return;
+   }
+ 
+   if ( !(scbStatus & SCB_STAT_CX) && (scbStatus & SCB_STAT_CNA) ) {
+     printk_time();
+     printk("\n*****ERROR: CNA, NO CX:0x%x\nResetting...",scbStatus);
+     uti596_softc.nic_reset = 1;
+     return;
+   }
+ 
+   if ( scbStatus & SCB_CUS_SUSPENDED ) {
+     printk_time();
+     printk("\n*****ERROR: Command unit suspended!:0x%x\nResetting...",scbStatus);
+     uti596_softc.nic_reset = 1;
+     return;
+   }
+ 
+   if ( scbStatus & RU_SUSPENDED  ) {
+     printk_time();
+     printk("\n*****ERROR: Receive unit suspended!:0x%x\nResetting...",scbStatus);
+     uti596_softc.nic_reset = 1;
+     return;
+   }
+ 
+   if ( scbStatus & SCB_STAT_RNR ) {
+     printk_time();
+     printk("\n*****WARNING: RNR %x\n",scbStatus);
+     printk("*****INFO: RFD cmd: %x status:%x\n",
+             uti596_softc.pBeginRFA -> cmd,
+             uti596_softc.pBeginRFA -> stat);
+   }
+ 
+  /*
+   * Receive Unit Control
+   */
+   if ( scbStatus & SCB_STAT_FR ) { /* a frame has been received */
+     uti596_softc.rxInterrupts++;
+   
+ #ifdef DBG_FR
+     printk("\nISR:FR\n");
+ #endif
+     if ( uti596_softc.pBeginRFA == I596_NULL ||
+          !( uti596_softc.pBeginRFA -> stat & STAT_C)) {
+      dump_scb();
+      uti596_softc.nic_reset = 1;
+     }
+     else {
+       while ( uti596_softc.pBeginRFA != I596_NULL &&
+            ( uti596_softc.pBeginRFA -> stat & STAT_C)) {
+ 
+ #ifdef DBG_ISR
+         printk("ISR:pBeginRFA != NULL\n");
+ #endif
+         count_rx ++;
+         if ( count_rx > 1)
+           printk("****WARNING: Received 2 frames on 1 interrupt \n");
+ 
+        /* Give Received Frame to the ULCS */
+         uti596_softc.countRFD--;
+ 
+         if ( uti596_softc.countRFD < 0 )
+           printk("Count < 0 !!!: count == %d, beginRFA = %p\n",
+                  uti596_softc.countRFD, uti596_softc.pBeginRFA);
+ 
+         uti596_softc.stats.rx_packets++;
+         pIsrRfd = uti596_softc.pBeginRFA -> next; /* the append destroys the link */
+         uti596append( &uti596_softc.pInboundFrameQueue , uti596_softc.pBeginRFA );
+ 
+        /*
+         * if we have just received the a frame int he last unknown RFD,
+         * then it is certain that the RFA is empty.
+         */
+         if ( uti596_softc.pLastUnkRFD == uti596_softc.pBeginRFA ) {
+           UTI_596_ASSERT(uti596_softc.pLastUnkRFD != I596_NULL,"****ERROR:LastUnk is NULL, begin ptr @ end!\n");
+           uti596_softc.pEndRFA = uti596_softc.pLastUnkRFD = I596_NULL;
+         }
+ 
+ #ifdef DBG_ISR
+         printk("Wake %#x\n",uti596_softc.rxDaemonTid);
+ #endif
+         sc = rtems_event_send(uti596_softc.rxDaemonTid, INTERRUPT_EVENT);
+         if ( sc != RTEMS_SUCCESSFUL )
+           rtems_panic("Can't notify rxDaemon: %s\n",
+                     rtems_status_text (sc));
+ #ifdef DBG_RAW_ISR
+         else
+           printk("Rx Wake: %#x\n",uti596_softc.rxDaemonTid);
+ #endif
+ 
+         uti596_softc.pBeginRFA = pIsrRfd;
+       } /* end while */
+     } /* end if */
+ 
+     if ( uti596_softc.pBeginRFA == I596_NULL ) {
+       /* adjust the pEndRFA to reflect an empty list */
+       if ( uti596_softc.pLastUnkRFD == I596_NULL && uti596_softc.countRFD != 0 )
+         printk("Last Unk is NULL, BeginRFA is null, and count == %d\n",
+                uti596_softc.countRFD);
+ 
+       uti596_softc.pEndRFA = I596_NULL;
+       if ( uti596_softc.countRFD != 0 ) {
+         printk("****ERROR:Count is %d, but begin ptr is NULL\n",
+                uti596_softc.countRFD );
+       }
+     }
+   } /* end if ( scbStatus & SCB_STAT_FR ) */
+ 
+  /* Check For Command Complete */
+   if (  scbStatus & SCB_STAT_CX ){
+ #ifdef DBG_ISR
+     printk("ISR:CU\n");
+ #endif
+ 
+     pIsrCmd = uti596_softc.pCmdHead;
+ 
+    /* For ALL completed commands */
+    if ( pIsrCmd !=  I596_NULL && pIsrCmd->status & STAT_C  ) {
+ 
+ #ifdef DBG_RAW_ISR
+        printk("ISR:pIsrCmd != NULL\n");
+ #endif
+ 
+       /* Adjust the command block list */
+       uti596_softc.pCmdHead = pIsrCmd -> next;
+ 
+      /*
+       * If there are MORE commands to process,
+       * the serialization in the raw routine has failed.
+       * ( Perhaps AddCmd is bad? )
+       */
+       UTI_596_ASSERT(uti596_softc.pCmdHead == I596_NULL,
+                      "****ERROR: command serialization failed\n");
+                     
+       /* What if the command did not complete OK? */
+       switch ( pIsrCmd->command & 0x7) {
+         case CmdConfigure:
+ 
+           /*      printk("****INFO:Configure OK\n"); */
+           uti596_softc.cmdOk = 1;
+           break;
+ 
+         case CmdDump:
+ #ifdef DBG_ISR
+           printk("dump!\n");
+ #endif
+           uti596_softc.cmdOk = 1;
+           break;
+ 
+         case CmdDiagnose:
+ #ifdef DBG_ISR
+           printk("diagnose!\n");
+ #endif
+           uti596_softc.cmdOk = 1;
+           break;
+ 
+         case CmdSASetup:
+           /* printk("****INFO:Set address interrupt\n"); */
+           if ( pIsrCmd -> status & STAT_OK )
+             uti596_softc.cmdOk = 1;
+           else
+             printk("****ERROR:SET ADD FAILED\n");
+           break;
+ 
+         case CmdTx:
+           UTI_596_ASSERT(uti596_softc.txDaemonTid, "****ERROR:Null txDaemonTid\n");
+ #ifdef DBG_ISR
+           printk("wake TX:0x%x\n",uti596_softc.txDaemonTid);
+ #endif
+           if ( uti596_softc.txDaemonTid ) {
+             /* Ensure that the transmitter is present */
+             sc = rtems_event_send (uti596_softc.txDaemonTid,
+                                  INTERRUPT_EVENT);
+ 
+             if ( sc != RTEMS_SUCCESSFUL )
+               printk("****ERROR:Could NOT send event to tid 0x%x : %s\n",
+                      uti596_softc.txDaemonTid, rtems_status_text (sc) );
+ #ifdef DBG_RAW_ISR
+             else
+               printk("****INFO:Tx wake: %#x\n",uti596_softc.txDaemonTid);
+ #endif
+           }
+           break;
+ 
+         case CmdMulticastList:
+           printk("***ERROR:Multicast?!\n");
+           pIsrCmd->next = I596_NULL;
+           break;
+ 
+         case CmdTDR:
+ 	        {
+ 	          unsigned long status = *( (unsigned long *)pIsrCmd)+1;
+ 	          printk("****ERROR:TDR?!\n");
+ 
+ 	          if (status & STAT_C) {
+ 	            /* mark the TDR command successful */
+ 	            uti596_softc.cmdOk = 1;
+ 	          }
+ 	          else {
+ 	            if (status & 0x4000)
+ 	              printk("****WARNING:Transceiver problem.\n");
+ 	            if (status & 0x2000)
+ 	              printk("****WARNING:Termination problem.\n");
+ 	            if (status & 0x1000)
+ 	              printk("****WARNING:Short circuit.\n");
+ 	            /* printk("****INFO:Time %ld.\n", status & 0x07ff); */
+ 	          }
+           }
+           break;
+ 
+         default:
+           /*
+            * This should never be reached
+           */
+           printk("CX but NO known command\n");
+       } /* end switch */
+ 
+       pIsrCmd = uti596_softc.pCmdHead; /* next command */
+       if ( pIsrCmd != I596_NULL )
+         printk("****WARNING: more commands in list, but no start to NIC\n");
+     } /* end if pIsrCmd != NULL && pIsrCmd->stat & STAT_C  */
+     else {
+       if ( pIsrCmd != I596_NULL ) { 
+         /* The command MAY be NULL from a RESET */
+         /* Reset the ethernet card, and wake the transmitter (if necessary) */
+         printk_time();
+         printk("****INFO: Request board reset ( tx )\n");
+         uti596_softc.nic_reset = 1;
+         if ( uti596_softc.txDaemonTid) {
+           /* Ensure that a transmitter is present */
+           sc = rtems_event_send (uti596_softc.txDaemonTid,
+                                  INTERRUPT_EVENT);
+           if ( sc != RTEMS_SUCCESSFUL )
+             printk("****ERROR:Could NOT send event to tid 0x%x : %s\n",uti596_softc.txDaemonTid, rtems_status_text (sc) );
+ #ifdef DBG_RAW_ISR
+           else
+             printk("****INFO:Tx wake: %#x\n",uti596_softc.txDaemonTid);
+ #endif
+         }
+       }
+     }
+   }  /* end if command complete */
+ 
+  /* if the receiver has stopped,
+   * check if this is a No Resources scenario,
+   * Try to add more RFD's ( no RBDs are used )
+   */
+   if ( uti596_softc.started ) {
+     if ( scbStatus & SCB_STAT_RNR ){
+ #ifdef DBG_ISR
+       printk("INFO:RNR: status %#x \n", uti596_softc.scb.status );
+ #endif
+      /*
+       * THE RECEIVER IS OFF!
+       */
+       if ( uti596_softc.pLastUnkRFD != I596_NULL  ) {
+         /* We have an unknown RFD, it is not inbound*/
+         if ( uti596_softc.pLastUnkRFD -> stat & (STAT_C | STAT_B )) /* in use */
+           uti596_softc.pEndRFA = uti596_softc.pLastUnkRFD;      /* update end */
+         else {
+          /*
+           *  It is NOT in use, and since RNR, we know EL bit of pEndRFA was read!
+           *  So, unlink it from the RFA and move it to the saved queue.
+           *  But pBegin can equal LastUnk!
+           */
+ 
+           if ( uti596_softc.pEndRFA != I596_NULL ) {
+             /* check added feb24. */
+ #ifdef DEBUG_RFA
+             if (uti596_softc.pEndRFA -> next != uti596_softc.pLastUnkRFD) {
+               printk("***ERROR:UNK: %p not end->next: %p, end: %p\n",
+                      uti596_softc.pLastUnkRFD,
+                      uti596_softc.pEndRFA -> next,
+                      uti596_softc.pEndRFA);
+               printk("***INFO:countRFD now %d\n",
+                      uti596_softc.countRFD);
+               printk("\n\n");
+             }
+ #endif
+             uti596_softc.pEndRFA -> next = I596_NULL;   /* added feb 16 */
+           }
+           uti596append( &uti596_softc.pSavedRfdQueue, uti596_softc.pLastUnkRFD );
+           uti596_softc.savedCount++;
+           uti596_softc.pEndSavedQueue = uti596_softc.pLastUnkRFD;
+           uti596_softc.countRFD--;                    /* It was not in the RFA */
+          /*
+           * The Begin pointer CAN advance this far. We must resynch the CPU side
+           * with the chip.
+           */
+           if ( uti596_softc.pBeginRFA == uti596_softc.pLastUnkRFD ) {
+ #ifdef DEBUG_RFA
+             if ( uti596_softc.countRFD != 0 ) {
+               printk("****INFO:About to set begin to NULL, with count == %d\n",
+                      uti596_softc.countRFD );
+               printk("\n\n");
+             }
+ #endif
+             uti596_softc.pBeginRFA = I596_NULL;
+             UTI_596_ASSERT(uti596_softc.countRFD == 0,
+                            "****ERROR:Count must be zero here!\n");
+           }
+         }
+         uti596_softc.pLastUnkRFD = I596_NULL;
+       } /* end if exists UnkRFD */
+ 
+      /*
+       * Append the saved queue to  the RFA.
+       * Any further RFD's being supplied will be added to
+       * this new list.
+       */
+       if ( uti596_softc.pSavedRfdQueue != I596_NULL ) {
+         /* entries to add */
+         if ( uti596_softc.pBeginRFA == I596_NULL ) {
+           /* add at beginning to list */
+ #ifdef DEBUG_RFA
+           if(uti596_softc.countRFD != 0) {
+             printk("****ERROR:Begin pointer is NULL, but count == %d\n",
+                    uti596_softc.countRFD);
+           }
+ #endif
+           uti596_softc.pBeginRFA      = uti596_softc.pSavedRfdQueue;
+           uti596_softc.pEndRFA        = uti596_softc.pEndSavedQueue;
+           uti596_softc.pSavedRfdQueue = uti596_softc.pEndSavedQueue = I596_NULL;  /* Reset the End */
+         }
+         else {
+ #ifdef DEBUG_RFA
+           if ( uti596_softc.countRFD <= 0) {
+             printk("****ERROR:Begin pointer is not NULL, but count == %d\n",
+                    uti596_softc.countRFD);
+           }
+ #endif
+           UTI_596_ASSERT( uti596_softc.pEndRFA != I596_NULL, "****WARNING: END RFA IS NULL\n");
+           UTI_596_ASSERT( uti596_softc.pEndRFA->next == I596_NULL, "****ERROR:END RFA -> next must be NULL\n");
+ 
+           uti596_softc.pEndRFA->next   = uti596_softc.pSavedRfdQueue;
+           uti596_softc.pEndRFA->cmd   &= ~CMD_EOL;      /* clear the end of list */
+           uti596_softc.pEndRFA         = uti596_softc.pEndSavedQueue;
+           uti596_softc.pSavedRfdQueue  = uti596_softc.pEndSavedQueue = I596_NULL; /* Reset the End */
+ #ifdef DEBUG_ISR
+           printk("count: %d, saved: %d \n",
+                  uti596_softc.countRFD,
+                  uti596_softc.savedCount);
+ #endif
+         }
+         /* printk("Isr: countRFD = %d\n",uti596_softc.countRFD); */
+         uti596_softc.countRFD += uti596_softc.savedCount;
+         /* printk("Isr: after countRFD = %d\n",uti596_softc.countRFD); */
+         uti596_softc.savedCount = 0;
+       }
+ 
+ #ifdef DBG_596_RFD
+       printk("The list starts here %p\n",uti596_softc.pBeginRFA );
+ #endif
+ 
+       if ( uti596_softc.countRFD > 1) {
+         printk_time();
+         printk("****INFO: pBeginRFA -> stat = 0x%x\n",uti596_softc.pBeginRFA -> stat);
+         printk("****INFO: pBeginRFA -> cmd = 0x%x\n",uti596_softc.pBeginRFA -> cmd);
+         uti596_softc.pBeginRFA -> stat = 0;
+         UTI_596_ASSERT(uti596_softc.scb.command == 0, "****ERROR:scb command must be zero\n");
+         uti596_softc.scb.pRfd = uti596_softc.pBeginRFA;
+         /* start RX here  */
+         printk("****INFO: ISR Starting receiver\n");
+         uti596_softc.scb.command = RX_START; /* should this also be CU start? */
+         i82596->chan_attn = 0;
+       }
+     } /* end stat_rnr */
+   } /* end if receiver started */
+ 
+ #ifdef DBG_ISR
+   printk("X\n");
+ #endif
+   count_rx=0;
+  
+  
+  /* Do this last, to ensure that the reset is called at the right time. */
+   if ( uti596_softc.nic_reset ) {
+     uti596_softc.nic_reset = 0;
+     sc = rtems_event_send(uti596_softc.resetDaemonTid, NIC_RESET_EVENT);
+     if ( sc != RTEMS_SUCCESSFUL )
+       rtems_panic ("Can't notify resetDaemon: %s\n", rtems_status_text (sc));
+   }
+   return;
+ }
+ 
+ 
+ /***********************************************************************
+  *  Function:   void uti596dequeue
+  *
+  *  Description:
+  *              removes an RFD from the received frame queue,
+  *
+  *  Algorithm:
+  *
+  ***********************************************************************/
+ 
+ struct i596_rfd * uti596dequeue(
+   struct i596_rfd ** ppQ
+ )
+ {
+   ISR_Level level;
+ 
+   struct i596_rfd * pRfd;
+   _ISR_Disable(level);
+ 
+   /* invalid address, or empty queue or emptied queue */
+   if( ppQ == NULL || *ppQ == NULL || *ppQ == I596_NULL) {
+     _ISR_Enable(level);
+      return I596_NULL;
+   }
+ 
+   pRfd = *ppQ;            /* The dequeued buffer           */
+   *ppQ = pRfd->next;      /* advance the queue pointer     */
+   pRfd->next = I596_NULL; /* unlink the rfd being returned */
+ 
+   _ISR_Enable(level);
+   return pRfd;
+ }
+ 
+ 
+ /***********************************************************************
+  *  Function:   void uti596append
+  *
+  *  Description:
+  *              adds an RFD to the end of the received frame queue,
+  *              for processing by the rxproc.
+  *              Also removes this RFD from the RFA
+  *
+  *  Algorithm:
+  *
+  ***********************************************************************/
+ 
+ void uti596append(
+   struct i596_rfd ** ppQ,
+   struct i596_rfd * pRfd
+ )
+ {
+ 
+   struct i596_rfd *p;
+ 
+   if ( pRfd != NULL && pRfd != I596_NULL) {
+     pRfd -> next = I596_NULL;
+     pRfd -> cmd |= CMD_EOL;    /* set EL bit */
+ 
+     if ( *ppQ == NULL || *ppQ == I596_NULL ) {
+       /* Empty or emptied */
+       *ppQ = pRfd;
+     }
+     else
+       {
+         for ( p=*ppQ; p -> next != I596_NULL; p=p->next)
+           ;
+ 
+         p->cmd &= ~CMD_EOL; /* Clear EL bit at end */
+         p->next = pRfd;
+       }
+   }
+   else
+     printf("Illegal attempt to append: %p\n", pRfd);
+ }
+ 
+ 
+ /***********************************************************************
+  *  Function:   uti596stop
+  *
+  *  Description:
+  *             stop the driver
+  *
+  *  Algorithm:
+  *             mark driver as not started,
+  *             mark transmitter as busy
+  *             abort any transmissions/receptions
+  *             clean-up all buffers ( RFD's et. al. )
+  *
+  *
+  *
+  *
+  ***********************************************************************/
+ 
+ /* static */ void uti596_stop(
+   struct uti596_softc *sc
+ )
+ {
+   sc->started  = 0;
+   printk("Stopping interface\n");
+   sc->scb.command = CUC_ABORT|RX_ABORT;
+   i82596->chan_attn = 0;
+ }
+ 
+ 
+ static int uti596_ioctl(
+   struct ifnet *ifp,
+   int command, caddr_t data
+ )
+ {
+   struct uti596_softc *sc = ifp->if_softc;
+   int error = 0;
+ 
+   switch (command) {
+     case SIOCGIFADDR:
+     case SIOCSIFADDR:
+       printk("SIOCSIFADDR\n");
+       ether_ioctl (ifp, command, data);
+       break;
+ 
+     case SIOCSIFFLAGS:
+       printk("SIOCSIFFLAGS\n");
+       switch (ifp->if_flags & (IFF_UP | IFF_RUNNING)) {
+         case IFF_RUNNING:
+           printk("IFF_RUNNING\n");
+           uti596_stop (sc);
+           break;
+ 
+         case IFF_UP:
+           printk("IFF_UP\n");
+           uti596_init (sc);
+           break;
+ 
+         case IFF_UP | IFF_RUNNING:
+           printk("IFF_UP and RUNNING\n");
+           uti596_stop (sc);
+           uti596_init (sc);
+           break;
+ 
+         default:
+           printk("default\n");
+           break;
+       }
+       break;
+ 
+     case SIO_RTEMS_SHOW_STATS:
+       printk("show stats\n");
+       uti596_stats (sc);
+       break;
+ 
+     /* FIXME: All sorts of multicast commands need to be added here! */
+     default:
+       printk("default: EINVAL\n");
+       error = EINVAL;
+       break;
+   }
+   
+   return error;
+ }
+ 
+ 
+ /***********************************************************************
+  *  Function:   uti596_stats
+  *
+  *  Description:
+  *             print out the collected data
+  *
+  *  Algorithm:
+  *            use printf
+  *
+  ***********************************************************************/
+ 
+ void uti596_stats(
+   struct uti596_softc *sc
+ )
+ {
+   printf("CPU Reports:\n");
+   printf ("  Tx raw send count:%-8lu",  sc->rawsndcnt);
+   printf ("  Rx Interrupts:%-8lu",  sc->rxInterrupts);
+   printf ("  Tx Interrupts:%-8lu\n",  sc->txInterrupts);
+   printf ("  Rx Packets:%-8u",  sc->stats.rx_packets);
+   printf ("  Tx Attempts:%-u\n",  sc->stats.tx_packets);
+ 
+   printf ("  Rx Dropped:%-8u",     sc->stats.rx_dropped);
+   printf ("  Rx IP Packets:%-8u",  sc->stats.rx_packets);
+   printf ("  Tx Errors:%-8u\n",      sc->stats.tx_errors);
+   printf ("  Tx aborted:%-8u",     sc->stats.tx_aborted_errors);
+   printf ("  Tx Dropped:%-8u\n",     sc->stats.tx_dropped);
+   printf ("  Tx IP packets:%-8u",  sc->stats.tx_packets);
+ 
+   printf ("  Collisions Detected:%-8u\n",  sc->stats.collisions);
+   printf ("  Tx Heartbeat Errors:%-8u",  sc->stats.tx_heartbeat_errors);
+   printf ("  Tx Carrier Errors:%-8u\n",    sc->stats.tx_carrier_errors);
+   printf ("  Tx Aborted Errors:%-8u",    sc->stats.tx_aborted_errors);
+   printf ("  Rx Length Errors:%-8u\n",     sc->stats.rx_length_errors);
+   printf ("  Rx Overrun Errors:%-8u",    sc->stats.rx_over_errors);
+   printf ("  Rx Fifo Errors:%-8u\n",       sc->stats.rx_fifo_errors);
+   printf ("  Rx Framing Errors:%-8u",    sc->stats.rx_frame_errors);
+   printf ("  Rx crc errors:%-8u\n",  sc->stats.rx_crc_errors);
+ 
+   printf ("  TX WAITS: %-8lu\n", sc->txRawWait);
+ 
+   printf ("  NIC resets: %-8u\n", sc->stats.nic_reset_count);
+ 
+   printf("  NIC reports\n");
+ 
+   dump_scb();
+ }
+ 
+ 
+ void dumpQ( void )
+ {
+   struct i596_rfd *pRfd;
+ 
+   printk("savedQ:\n");
+   
+   for( pRfd = uti596_softc.pSavedRfdQueue;
+        pRfd != I596_NULL;
+        pRfd = pRfd -> next)
+       printk("pRfd: %p, stat: 0x%x cmd: 0x%x\n",pRfd,pRfd -> stat,pRfd -> cmd);
+       
+   printk("Inbound:\n");
+   
+   for( pRfd = uti596_softc.pInboundFrameQueue;
+        pRfd != I596_NULL;
+        pRfd = pRfd -> next)
+     printk("pRfd: %p, stat: 0x%x cmd: 0x%x\n",pRfd,pRfd -> stat,pRfd -> cmd);
+     
+   printk("Last Unk: %p\n", uti596_softc.pLastUnkRFD );
+   
+   printk("RFA:\n");
+   
+   for( pRfd = uti596_softc.pBeginRFA;
+        pRfd != I596_NULL;
+        pRfd = pRfd -> next)
+     printk("pRfd: %p, stat: 0x%x cmd: 0x%x\n",pRfd,pRfd -> stat,pRfd -> cmd);
+ }
+ 
+ 
+ void uti596Diagnose(
+   int verbose
+ )
+ {
+   struct i596_cmd diagnose;
+   int count=10000;
+ 
+   diagnose.command = CmdDiagnose;
+   diagnose.status = 0;
+   uti596addPolledCmd(&diagnose);
+   while( !( diagnose.status & STAT_C ) && count ) {
+     if(verbose)
+       printk(".");
+     count --;
+   }
+   if(verbose)
+     printk("Status diagnostic: 0x%2.2x\n", diagnose.status);
+ }
+ 
+ 
+ void show_buffers (void)
+ {
+   struct i596_rfd *pRfd;
+ 
+   printk("82596 cmd: 0x%x, status: 0x%x RFA len: %d\n",
+          uti596_softc.scb.command,
+          uti596_softc.scb.status,
+          uti596_softc.countRFD);
+ 
+   printk("\nRFA: \n");
+   
+   for ( pRfd = uti596_softc.pBeginRFA;
+         pRfd != I596_NULL;
+         pRfd = pRfd->next)
+     printk("Frame @ %p, status: %2.2x, cmd: %2.2x\n",
+            pRfd, pRfd->stat, pRfd->cmd);
+ 
+   printk("\nInbound: \n");
+   
+   for ( pRfd = uti596_softc.pInboundFrameQueue;
+         pRfd != I596_NULL;
+         pRfd = pRfd->next)
+     printk("Frame @ %p, status: %2.2x, cmd: %2.2x\n",
+            pRfd, pRfd->stat, pRfd->cmd);
+ 
+ 
+   printk("\nSaved: \n");
+   
+   for ( pRfd = uti596_softc.pSavedRfdQueue;
+         pRfd != I596_NULL;
+         pRfd = pRfd->next)
+     printk("Frame @ %p, status: %2.2x, cmd: %2.2x\n",
+            pRfd, pRfd->stat, pRfd->cmd);
+            
+   printk("\nUnknown: %p\n",uti596_softc.pLastUnkRFD);
+ }
+ 
+ 
+ void show_queues(void)
+ {
+   struct i596_rfd *pRfd;
+ 
+   printk("CMD: 0x%x, Status: 0x%x\n",
+          uti596_softc.scb.command,
+          uti596_softc.scb.status);
+          printk("saved Q\n");
+ 
+   for ( pRfd = uti596_softc.pSavedRfdQueue;
+         pRfd != I596_NULL &&
+         pRfd != NULL;
+         pRfd = pRfd->next)
+     printk("0x%p\n", pRfd);
+ 
+   printk("End saved Q 0x%p\n", uti596_softc.pEndSavedQueue);
+ 
+   printk("\nRFA:\n");
+   
+   for ( pRfd = uti596_softc.pBeginRFA;
+         pRfd != I596_NULL &&
+         pRfd != NULL;
+         pRfd = pRfd->next)
+     printk("0x%p\n", pRfd);
+ 
+   printk("uti596_softc.pEndRFA: %p\n",uti596_softc.pEndRFA);
+ }
+ 
+ 
+ void uti596_init(
+   void * arg
+ )
+ {
+   struct uti596_softc  *sc = arg;
+   struct ifnet *ifp = &sc->arpcom.ac_if;
+ 
+   if (sc->txDaemonTid == 0) {
+     uti596_initialize_hardware(sc);
+ 
+     /* Start driver tasks */
+     sc->txDaemonTid = rtems_bsdnet_newproc ("UTtx", 2*4096, uti596_txDaemon, sc);
+     sc->rxDaemonTid = rtems_bsdnet_newproc ("UTrx", 2*4096, uti596_rxDaemon, sc);
+     sc->resetDaemonTid = rtems_bsdnet_newproc ("UTrt", 2*4096,
+                                    uti596_resetDaemon, sc);
+ 
+ #ifdef DBG_INIT
+     printk("After attach, status of board = 0x%x\n", sc->scb.status );
+ #endif
+ 
+   }
+ 
+   /*
+    * Enable receiver
+    */
+   UTI_WAIT_COMMAND_ACCEPTED(4000, "init:Before RX_START");
+   sc->scb.pRfd = sc -> pBeginRFA;
+   sc->scb.command = RX_START;
+   i82596->chan_attn = 0;
+   UTI_WAIT_COMMAND_ACCEPTED(4000, "init:RX_START");
+   /*
+    * Tell the world that we're running.
+    */
+   ifp->if_flags |= IFF_RUNNING;
+ }
+ 
+ 
+ void dump_scb( void )
+ {
+   printk("status 0x%x\n",uti596_softc.scb.status);
+   printk("command 0x%x\n",uti596_softc.scb.command);
+   printk("cmd 0x%x\n",(int)uti596_softc.scb.pCmd);
+   printk("rfd 0x%x\n",(int)uti596_softc.scb.pRfd);
+   printk("crc_err 0x%x\n",uti596_softc.scb.crc_err);
+   printk("align_err 0x%x\n",uti596_softc.scb.align_err);
+   printk("resource_err 0x%x\n",uti596_softc.scb.resource_err );
+   printk("over_err 0x%x\n",uti596_softc.scb.over_err);
+   printk("rcvdt_err 0x%x\n",uti596_softc.scb.rcvdt_err);
+   printk("short_err 0x%x\n",uti596_softc.scb.short_err);
+   printk("t_on 0x%x\n",uti596_softc.scb.t_on);
+   printk("t_off 0x%x\n",uti596_softc.scb.t_off);
+ }
+ 
+ void printk_time( void )
+ {
+   rtems_time_of_day tm_struct;
+ 
+   rtems_clock_get(RTEMS_CLOCK_GET_TOD, &tm_struct);
+   printk("Current time: %d:%d:%d \n",
+          tm_struct.hour,
+          tm_struct.minute,
+          tm_struct.second);
+ }
\ No newline at end of file
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/network/uti596.h rtems/c/src/lib/libbsp/m68k/mvme167/network/uti596.h
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/network/uti596.h	Wed Dec 31 19:00:00 1969
--- rtems/c/src/lib/libbsp/m68k/mvme167/network/uti596.h	Wed Aug 18 15:13:44 1999
***************
*** 0 ****
--- 1,293 ----
+ 
+ /* uti596.h: Contains the defines and structures used by the uti596 driver */
+ 
+ /*
+  * EII: March 11: Created v. 0.0
+  *      Jan 12/98 Added STAT bits, s11-=s5 and max_colls.
+  *
+  *  $Id: uti596.h,v 1.1.1.1 1999/08/05 15:36:46 gauthier Exp $
+  */
+ 
+ #ifndef UTI596_H
+ #define UTI596_H
+ #include <rtems/error.h>
+ #include <rtems/rtems_bsdnet.h>
+ 
+ #include <sys/param.h>
+ #include <sys/mbuf.h>
+ #include <sys/socket.h>
+ #include <sys/sockio.h>
+ 
+ #include <net/if.h>
+ 
+ #include <netinet/in.h>
+ #include <netinet/if_ether.h>
+ 
+ /* Ethernet statistics */
+ 
+ struct enet_statistics{
+   int	rx_packets;			/* total packets received	*/
+   int	tx_packets;			/* total packets transmitted	*/
+   int	rx_errors;			/* bad packets received		*/
+   int	tx_errors;			/* packet transmit problems	*/
+   int	rx_dropped;			/* no space in buffers          */
+   int	tx_dropped;			/*                              */
+   int   tx_retries_exceeded;              /* excessive retries            */
+   int	multicast;			/* multicast packets received	*/
+   int	collisions;
+ 
+   /* detailed rx_errors: */
+   int	rx_length_errors;
+   int	rx_over_errors;			/* receiver ring buff overflow	*/
+   int	rx_crc_errors;			/* recved pkt with crc error	*/
+   int	rx_frame_errors;		/* recv'd frame alignment error */
+   int	rx_fifo_errors;			/* recv'r fifo overrun		*/
+   int	rx_missed_errors;		/* receiver missed packet	*/
+ 
+   /* detailed tx_errors */
+   int	tx_aborted_errors;
+   int	tx_carrier_errors;
+   int	tx_fifo_errors;
+   int	tx_heartbeat_errors;
+   int	tx_window_errors;
+ 
+   /* NIC reset errors */
+   int   nic_reset_count;      /* The number of times uti596reset() has been called. */
+ };
+ 
+ 
+ 
+ enum commands {
+   CmdNOp           = 0, 
+   CmdSASetup       = 1, 
+   CmdConfigure     = 2, 
+   CmdMulticastList = 3,
+   CmdTx            = 4, 
+   CmdTDR           = 5, 
+   CmdDump          = 6, 
+   CmdDiagnose      = 7
+ };
+ 
+ 
+ #define UTI596_MUTEX   1
+ 
+ 
+ #define CMD_EOL		0x8000	/* The last command of the list, stop. */
+ #define CMD_SUSP	0x4000	/* Suspend after doing cmd. */
+ #define CMD_INTR	0x2000	/* Interrupt after doing cmd. */
+ 
+ #define CMD_FLEX	0x0008	/* Enable flexible memory model */
+ 
+ #define SCB_STAT_CX     0x8000  /* Cmd completes with 'I' bit set */
+ #define SCB_STAT_FR     0x4000  /* Frame Received                 */
+ #define SCB_STAT_CNA    0x2000  /* Cmd unit Not Active            */
+ #define SCB_STAT_RNR    0x1000  /* Receiver Not Ready             */
+ 
+ #define SCB_CUS_SUSPENDED 0x0100
+ #define SCB_CUS_ACTIVE    0x0200
+ 
+ 
+ #define STAT_C		0x8000	/* Set to 1 after execution              */
+ #define STAT_B		0x4000	/* 1 : Cmd being executed, 0 : Cmd done. */
+ #define STAT_OK		0x2000	/* 1: Command executed ok 0 : Error      */
+ #define STAT_A          0x1000  /* command has been aborted              */
+ 
+ #define STAT_S11        0x0800
+ #define STAT_S10        0x0400
+ #define STAT_S9         0x0200
+ #define STAT_S8         0x0100
+ #define STAT_S7         0x0080
+ #define STAT_S6         0x0040
+ #define STAT_S5         0x0020
+ #define STAT_MAX_COLLS  0x000F
+ 
+ 
+ #define RBD_STAT_P      0x4000  /* prefetch */
+ #define RBD_STAT_F      0x4000  /* used */
+ 
+ #define	 CUC_START	0x0100
+ #define	 CUC_RESUME	0x0200
+ #define	 CUC_SUSPEND    0x0300
+ #define	 CUC_ABORT	0x0400
+ #define	 RX_START	0x0010
+ #define	 RX_RESUME	0x0020
+ #define	 RX_SUSPEND	0x0030
+ #define	 RX_ABORT	0x0040
+ 
+ #define  RU_SUSPENDED    0x0010
+ #define  RU_NO_RESOURCES 0x0020
+ #define  RU_READY        0x0040
+ 
+ 
+ #define IO_ADDR         0x360
+ #define PORT_ADDR       IO_ADDR
+ #define CHAN_ATTN       PORT_ADDR + 4
+ #define NIC_ADDR        PORT_ADDR + 8
+ 
+ struct i596_cmd {
+     volatile unsigned short status;
+     volatile unsigned short command;
+     struct i596_cmd *next;
+ };
+ 
+ #define I596_NULL ( ( void * ) 0xffffffff)
+ #define UTI_596_END_OF_FRAME		0x8000
+ #define SIZE_MASK	0x3fff
+ 
+ /*
+  * Transmit buffer Descriptor
+  */
+ 
+ struct i596_tbd {
+     unsigned short size;
+     unsigned short pad;
+     struct i596_tbd *next;
+     char *data; 
+ };
+ 
+ /*
+  * Receive buffer Descriptor
+  */
+ 
+ struct i596_rbd {
+     unsigned short count;
+     unsigned short offset;
+     struct i596_rbd *next;
+     char           *data; 
+     unsigned short size;
+     unsigned short pad;
+ };
+ 
+ /*
+  * Transmit Command Structure
+  */
+ struct tx_cmd {
+     struct i596_cmd cmd;
+     struct i596_tbd *pTbd;
+     unsigned short size;
+     unsigned short pad;
+ } ;
+ 
+ 
+ /*
+  * Receive Frame Descriptor
+  */
+ struct i596_rfd {
+     volatile unsigned short stat;
+     volatile unsigned short cmd;
+     struct i596_rfd *next;
+     struct i596_rbd *pRbd; 
+     unsigned short count;
+     unsigned short size;
+     char data [1532 ];    
+ } ;
+ 
+ 
+ struct i596_dump {
+   struct i596_cmd cmd;
+   char * pData;
+ };
+ 
+ struct i596_set_add {
+   struct i596_cmd cmd;
+   char   data[8];
+ };
+ 
+ struct i596_configure {
+   struct i596_cmd cmd;
+   char   data[16];
+ };
+ 
+ struct i596_nop {
+   struct i596_cmd cmd;
+ };
+ 
+ struct i596_tdr {
+   struct i596_cmd cmd;
+   unsigned int data;
+ };
+ 
+ #define RX_RING_SIZE 8
+ 
+ /*
+  * System Control Block
+  */
+ struct i596_scb {
+     volatile unsigned short status;
+     volatile unsigned short command;
+     struct i596_cmd *pCmd;
+     struct i596_rfd *pRfd;
+     volatile unsigned long crc_err;
+     volatile unsigned long align_err;
+     volatile unsigned long resource_err;
+     volatile unsigned long over_err;
+     volatile unsigned long rcvdt_err;
+     volatile unsigned long short_err;
+     volatile unsigned short t_on;
+     volatile unsigned short t_off;
+ };
+ 
+ 
+ /* 
+  * Intermediate System Control Block
+  */
+ struct i596_iscp {
+     volatile unsigned long stat;
+     struct i596_scb *scb;
+ } ;
+ /*
+  * System Control Parameters
+  */
+ struct i596_scp {
+     unsigned long sysbus;
+     unsigned long pad;
+     struct i596_iscp *iscp;
+ } ;
+ 
+ struct uti596_softc {
+   struct arpcom                 arpcom;
+   struct i596_scp              *pScp;
+   struct i596_iscp              iscp;
+   struct i596_scb               scb;
+   struct i596_set_add           set_add;
+   struct i596_configure         set_conf;
+   struct i596_tdr               tdr;
+   struct i596_nop               nop;               
+   unsigned long                 stat;
+   struct tx_cmd                *pTxCmd;
+   struct i596_tbd              *pTbd;
+ 
+   int                   ioAddr;
+ 
+   struct i596_rfd     *pBeginRFA;
+   struct i596_rfd     *pEndRFA;
+   struct i596_rfd     *pLastUnkRFD;
+   struct i596_rbd     *pLastUnkRBD;
+   struct i596_rfd     *pEndSavedQueue;
+   struct i596_cmd     *pCmdHead;
+   struct i596_cmd     *pCmdTail;  /* unneeded, as chaining not used, but implemented */
+ 
+   rtems_id		rxDaemonTid;
+   rtems_id		txDaemonTid;
+   rtems_id		resetDaemonTid;
+ 
+   struct enet_statistics stats;
+   int                  started;
+   unsigned long        rxInterrupts;
+   unsigned long        txInterrupts;
+   volatile int         cmdOk;
+   int                  resetDone;
+   unsigned long	       txRawWait;
+   struct i596_rfd     *pInboundFrameQueue;
+   short int            rxBdCount;
+   short int            txBdCount;
+   short int            countRFD;
+   short int            savedCount;
+   struct i596_rfd     *pSavedRfdQueue;
+   rtems_name           semaphore_name;
+   rtems_id             semaphore_id;
+   char                 zeroes[64];
+   unsigned long        rawsndcnt;
+   int                  nic_reset; /* flag is for requesting that ISR issue a reset quest */
+ } ;
+ #endif
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/start/Makefile.am rtems/c/src/lib/libbsp/m68k/mvme167/start/Makefile.am
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/start/Makefile.am	Fri Feb 25 09:50:41 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/start/Makefile.am	Thu Feb 10 10:19:24 2000
***************
*** 1,5 ****
  ## 
! ## $Id: Makefile.am,v 1.1.2.1 2000/02/25 14:50:41 joel Exp $
  ## 
  
  AUTOMAKE_OPTIONS = foreign 1.4
--- 1,5 ----
  ## 
! ## $Id: Makefile.am,v 1.1.1.1 2000/02/10 15:19:24 cotton Exp $
  ## 
  
  AUTOMAKE_OPTIONS = foreign 1.4
***************
*** 25,31 ****
  
  TMPINSTALL_FILES += $(PROJECT_RELEASE)/lib/start$(LIB_VARIANT).o
  
! all: $(ARCH) $(OBJS) $(PGM) $(TMPINSTALL_FILES)
  
  .PRECIOUS: $(PGM)
  
--- 25,31 ----
  
  TMPINSTALL_FILES += $(PROJECT_RELEASE)/lib/start$(LIB_VARIANT).o
  
! all-local: $(ARCH) $(OBJS) $(PGM) $(TMPINSTALL_FILES)
  
  .PRECIOUS: $(PGM)
  
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/start/Makefile.in rtems/c/src/lib/libbsp/m68k/mvme167/start/Makefile.in
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/start/Makefile.in	Tue Feb 29 09:21:59 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/start/Makefile.in	Thu Mar  2 12:59:02 2000
***************
*** 65,74 ****
  host_triplet = @host@
  target_alias = @target_alias@
  target_triplet = @target@
! CC = @CC@
! CC_FOR_TARGET = @CC_FOR_TARGET@
! CPP = @CPP@
! GCCSED = @GCCSED@
  MAINT = @MAINT@
  MAKEINFO = @MAKEINFO@
  PACKAGE = @PACKAGE@
--- 65,71 ----
  host_triplet = @host@
  target_alias = @target_alias@
  target_triplet = @target@
! INSTALL_CHANGE = @INSTALL_CHANGE@
  MAINT = @MAINT@
  MAKEINFO = @MAKEINFO@
  PACKAGE = @PACKAGE@
***************
*** 159,165 ****
  install: install-am
  uninstall-am:
  uninstall: uninstall-am
! all-am: Makefile
  all-redirect: all-am
  install-strip:
  	$(MAKE) $(AM_MAKEFLAGS) INSTALL_STRIP_FLAG=-s install
--- 156,162 ----
  install: install-am
  uninstall-am:
  uninstall: uninstall-am
! all-am: Makefile all-local
  all-redirect: all-am
  install-strip:
  	$(MAKE) $(AM_MAKEFLAGS) INSTALL_STRIP_FLAG=-s install
***************
*** 196,202 ****
  .PHONY: tags distdir info-am info dvi-am dvi check check-am \
  installcheck-am installcheck install-exec-am install-exec \
  install-data-am install-data install-am install uninstall-am uninstall \
! all-redirect all-am all installdirs mostlyclean-generic \
  distclean-generic clean-generic maintainer-clean-generic clean \
  mostlyclean distclean maintainer-clean
  
--- 193,199 ----
  .PHONY: tags distdir info-am info dvi-am dvi check check-am \
  installcheck-am installcheck install-exec-am install-exec \
  install-data-am install-data install-am install uninstall-am uninstall \
! all-local all-redirect all-am all installdirs mostlyclean-generic \
  distclean-generic clean-generic maintainer-clean-generic clean \
  mostlyclean distclean maintainer-clean
  
***************
*** 223,246 ****
  $(PROJECT_RELEASE)/lib/start$(LIB_VARIANT).o: $(PGM)
  	$(INSTALL_DATA) $< $@
  
! all: $(ARCH) $(OBJS) $(PGM) $(TMPINSTALL_FILES)
  
  .PRECIOUS: $(PGM)
  
  debug-am:
- 	$(MAKE) $(AM_MAKEFLAGS) "ARCH=o-debug" \
-       "CFLAGS_DEBUG=$(CFLAGS_DEBUG_V)" \
-       "CFLAGS_OPTIMIZE=$(CFLAGS_DEBUG_OPTIMIZE_V)" \
-       "LDFLAGS_DEBUG=$(LDFLAGS_DEBUG_V)" $(TARGET_VA)
- 
  debug: debug-am
  .PHONY: debug debug-am
  
  profile-am:
- 	$(MAKE) $(AM_MAKEFLAGS) "ARCH=o-profile" \
-       "CFLAGS_PROFILE=$(CFLAGS_PROFILE_V)" \
-       "LDFLAGS_PROFILE=$(LDFLAGS_PROFILE_V)" $(TARGET_VA)
- 
  profile: profile-am
  .PHONY: profile profile-am
  
--- 220,234 ----
  $(PROJECT_RELEASE)/lib/start$(LIB_VARIANT).o: $(PGM)
  	$(INSTALL_DATA) $< $@
  
! all-local: $(ARCH) $(OBJS) $(PGM) $(TMPINSTALL_FILES)
  
  .PRECIOUS: $(PGM)
  
  debug-am:
  debug: debug-am
  .PHONY: debug debug-am
  
  profile-am:
  profile: profile-am
  .PHONY: profile profile-am
  
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/startup/Makefile.am rtems/c/src/lib/libbsp/m68k/mvme167/startup/Makefile.am
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/startup/Makefile.am	Fri Feb 25 09:50:41 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/startup/Makefile.am	Fri Feb 18 13:08:04 2000
***************
*** 1,5 ****
  ## 
! ## $Id: Makefile.am,v 1.1.2.1 2000/02/25 14:50:41 joel Exp $
  ## 
  
  AUTOMAKE_OPTIONS = foreign 1.4
--- 1,5 ----
  ## 
! ## $Id: Makefile.am,v 1.2 2000/02/18 18:08:04 cotton Exp $
  ## 
  
  AUTOMAKE_OPTIONS = foreign 1.4
***************
*** 32,47 ****
  $(PROJECT_RELEASE)/lib/linkcmds: linkcmds
  	$(INSTALL_DATA) $< $@
  
! $(PROJECT_RELEASE)/lib/elflinkcmds: elflinkcmds
! 	$(INSTALL_DATA) $< $@
! 
! TMPINSTALL_FILES += $(PROJECT_RELEASE)/lib/linkcmds \
!     $(PROJECT_RELEASE)/lib/elflinkcmds
  
! all: $(ARCH) $(OBJS) $(PGM) $(TMPINSTALL_FILES)
  
  .PRECIOUS: $(PGM)
  
! EXTRA_DIST = bspclean.c bspstart.c elflinkcmds linkcmds page_table.c
  
  include $(top_srcdir)/../../../../../../automake/local.am
--- 32,43 ----
  $(PROJECT_RELEASE)/lib/linkcmds: linkcmds
  	$(INSTALL_DATA) $< $@
  
! TMPINSTALL_FILES += $(PROJECT_RELEASE)/lib/linkcmds
  
! all-local: $(ARCH) $(OBJS) $(PGM) $(TMPINSTALL_FILES)
  
  .PRECIOUS: $(PGM)
  
! EXTRA_DIST = bspclean.c bspstart.c linkcmds page_table.c
  
  include $(top_srcdir)/../../../../../../automake/local.am
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/startup/Makefile.in rtems/c/src/lib/libbsp/m68k/mvme167/startup/Makefile.in
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/startup/Makefile.in	Tue Feb 29 09:21:59 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/startup/Makefile.in	Thu Mar  2 12:59:02 2000
***************
*** 65,74 ****
  host_triplet = @host@
  target_alias = @target_alias@
  target_triplet = @target@
! CC = @CC@
! CC_FOR_TARGET = @CC_FOR_TARGET@
! CPP = @CPP@
! GCCSED = @GCCSED@
  MAINT = @MAINT@
  MAKEINFO = @MAKEINFO@
  PACKAGE = @PACKAGE@
--- 65,71 ----
  host_triplet = @host@
  target_alias = @target_alias@
  target_triplet = @target@
! INSTALL_CHANGE = @INSTALL_CHANGE@
  MAINT = @MAINT@
  MAKEINFO = @MAKEINFO@
  PACKAGE = @PACKAGE@
***************
*** 98,105 ****
  
  OBJS = $(C_O_FILES)
  
! TMPINSTALL_FILES = $(PROJECT_RELEASE)/lib $(PROJECT_RELEASE)/lib/linkcmds     $(PROJECT_RELEASE)/lib/elflinkcmds
! 
  
  #
  # (OPTIONAL) Add local stuff here using +=
--- 95,101 ----
  
  OBJS = $(C_O_FILES)
  
! TMPINSTALL_FILES = $(PROJECT_RELEASE)/lib $(PROJECT_RELEASE)/lib/linkcmds
  
  #
  # (OPTIONAL) Add local stuff here using +=
***************
*** 109,115 ****
  
  AM_CPPFLAGS =  -DUSE_INIT_FINI
  
! EXTRA_DIST = bspclean.c bspstart.c elflinkcmds linkcmds page_table.c
  mkinstalldirs = $(SHELL) $(top_srcdir)/../../../../../../mkinstalldirs
  CONFIG_CLEAN_FILES = 
  DIST_COMMON =  Makefile.am Makefile.in
--- 105,111 ----
  
  AM_CPPFLAGS =  -DUSE_INIT_FINI
  
! EXTRA_DIST = bspclean.c bspstart.c linkcmds page_table.c
  mkinstalldirs = $(SHELL) $(top_srcdir)/../../../../../../mkinstalldirs
  CONFIG_CLEAN_FILES = 
  DIST_COMMON =  Makefile.am Makefile.in
***************
*** 171,177 ****
  install: install-am
  uninstall-am:
  uninstall: uninstall-am
! all-am: Makefile
  all-redirect: all-am
  install-strip:
  	$(MAKE) $(AM_MAKEFLAGS) INSTALL_STRIP_FLAG=-s install
--- 167,173 ----
  install: install-am
  uninstall-am:
  uninstall: uninstall-am
! all-am: Makefile all-local
  all-redirect: all-am
  install-strip:
  	$(MAKE) $(AM_MAKEFLAGS) INSTALL_STRIP_FLAG=-s install
***************
*** 208,214 ****
  .PHONY: tags distdir info-am info dvi-am dvi check check-am \
  installcheck-am installcheck install-exec-am install-exec \
  install-data-am install-data install-am install uninstall-am uninstall \
! all-redirect all-am all installdirs mostlyclean-generic \
  distclean-generic clean-generic maintainer-clean-generic clean \
  mostlyclean distclean maintainer-clean
  
--- 204,210 ----
  .PHONY: tags distdir info-am info dvi-am dvi check check-am \
  installcheck-am installcheck install-exec-am install-exec \
  install-data-am install-data install-am install uninstall-am uninstall \
! all-local all-redirect all-am all installdirs mostlyclean-generic \
  distclean-generic clean-generic maintainer-clean-generic clean \
  mostlyclean distclean maintainer-clean
  
***************
*** 234,260 ****
  $(PROJECT_RELEASE)/lib/linkcmds: linkcmds
  	$(INSTALL_DATA) $< $@
  
! $(PROJECT_RELEASE)/lib/elflinkcmds: elflinkcmds
! 	$(INSTALL_DATA) $< $@
! 
! all: $(ARCH) $(OBJS) $(PGM) $(TMPINSTALL_FILES)
  
  .PRECIOUS: $(PGM)
  
  debug-am:
- 	$(MAKE) $(AM_MAKEFLAGS) "ARCH=o-debug" \
-       "CFLAGS_DEBUG=$(CFLAGS_DEBUG_V)" \
-       "CFLAGS_OPTIMIZE=$(CFLAGS_DEBUG_OPTIMIZE_V)" \
-       "LDFLAGS_DEBUG=$(LDFLAGS_DEBUG_V)" $(TARGET_VA)
- 
  debug: debug-am
  .PHONY: debug debug-am
  
  profile-am:
- 	$(MAKE) $(AM_MAKEFLAGS) "ARCH=o-profile" \
-       "CFLAGS_PROFILE=$(CFLAGS_PROFILE_V)" \
-       "LDFLAGS_PROFILE=$(LDFLAGS_PROFILE_V)" $(TARGET_VA)
- 
  profile: profile-am
  .PHONY: profile profile-am
  
--- 230,244 ----
  $(PROJECT_RELEASE)/lib/linkcmds: linkcmds
  	$(INSTALL_DATA) $< $@
  
! all-local: $(ARCH) $(OBJS) $(PGM) $(TMPINSTALL_FILES)
  
  .PRECIOUS: $(PGM)
  
  debug-am:
  debug: debug-am
  .PHONY: debug debug-am
  
  profile-am:
  profile: profile-am
  .PHONY: profile profile-am
  
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/startup/bspstart.c rtems/c/src/lib/libbsp/m68k/mvme167/startup/bspstart.c
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/startup/bspstart.c	Thu Jan 13 15:45:07 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/startup/bspstart.c	Tue Mar  7 08:46:23 2000
***************
*** 81,87 ****
  {
    extern void *_WorkspaceBase;
    extern m68k_isr_entry M68Kvec[];
-   extern void    *_WorkspaceBase;
    
    void M68KFPSPInstallExceptionHandlers (void);
    
--- 81,86 ----
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/startup/linkcmds rtems/c/src/lib/libbsp/m68k/mvme167/startup/linkcmds
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/startup/linkcmds	Thu Jan 13 15:45:07 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/startup/linkcmds	Fri Mar  3 13:54:16 2000
***************
*** 17,23 ****
   */
  
  /* These are not really needed here */
! /* OUTPUT_FORMAT("elf32-m68k") */
  OUTPUT_ARCH(m68k)
  ENTRY(_start)
  
--- 17,23 ----
   */
  
  /* These are not really needed here */
! OUTPUT_FORMAT("elf32-m68k")
  OUTPUT_ARCH(m68k)
  ENTRY(_start)
  
***************
*** 26,32 ****
   */
  _RamBase = 0x00800000;
  _RamSize = DEFINED(_RamSize) ? _RamSize : 4M;
! _HeapSize = DEFINED(_HeapSize) ? _HeapSize : 0x10000;
  _StackSize = DEFINED(_StackSize) ? _StackSize : 0x1000;
  
  MEMORY
--- 26,32 ----
   */
  _RamBase = 0x00800000;
  _RamSize = DEFINED(_RamSize) ? _RamSize : 4M;
! _HeapSize = DEFINED(_HeapSize) ? _HeapSize : 0x300000;
  _StackSize = DEFINED(_StackSize) ? _StackSize : 0x1000;
  
  MEMORY
***************
*** 42,144 ****
  
  SECTIONS
  {
! 	ram : {
! 		. = .;
! 	} >ram
! 
!         /*
!          * Text, data and bss segments
!          */
!         .text : {
!                 *(.text)
! 
! 		/*
! 		 * C++ constructors/destructors
! 		 */
! 		*(.gnu.linkonce.t.*)
! 
! 		/*
! 		 * Initialization and finalization code.
!      		 *
!      		 * Various files can provide initialization and finalization
! 		 * functions.  crtbegin.o and crtend.o are two instances. The
! 		 * body of these functions are in .init and .fini sections. We
! 		 * accumulate the bodies here, and prepend function prologues
! 		 * from crti.o and function epilogues from crtn.o. crti.o must
! 		 * be linked first; crtn.o must be linked last.  Because these
! 		 * are wildcards, it doesn't matter if the user does not
! 		 * actually link against crti.o and crtn.o; the linker won't
! 		 * look for a file to match a wildcard.  The wildcard also
! 		 * means that it doesn't matter which directory crti.o and
! 		 * crtn.o are in. 
! 		 */
! 		PROVIDE (_init = .);
! 		*crti.o(.init)
! 		*(.init)
! 		*crtn.o(.init)
! 		PROVIDE (_fini = .);
! 		*crti.o(.fini)
! 		*(.fini)
! 		*crtn.o(.fini)
! 
! 		/*
! 		 * C++ constructors/destructors
!      		 *
!      		 * gcc uses crtbegin.o to find the start of the constructors
! 		 * and destructors so we make sure it is first.  Because this
! 		 * is a wildcard, it doesn't matter if the user does not
! 		 * actually link against crtbegin.o; the linker won't look for
! 		 * a file to match a wildcard.  The wildcard also means that
! 		 * it doesn't matter which directory crtbegin.o is in. The
! 		 * constructor and destructor list are terminated in
! 		 * crtend.o.  The same comments apply to it.
! 		 */
! 		. = ALIGN (16);
! 		*crtbegin.o(.ctors)
! 		*(.ctors)
! 		*crtend.o(.ctors)
! 		*crtbegin.o(.dtors)
! 		*(.dtors)
! 		*crtend.o(.dtors)
! 
! 		/*
! 		 * Exception frame info
! 		 */
! 		. = ALIGN (16);
! 		*(.eh_frame)
! 
! 		/*
! 		 * Read-only data
! 		 */
! 		. = ALIGN (16);
! 		_rodata_start = . ;
! 		*(.rodata)
! 		*(.gnu.linkonce.r*)
! 
!                  . = ALIGN (16);
!                 PROVIDE (_etext = .);
!         } >ram
!         .data : {
!                 PROVIDE (_copy_start = .);
!                 *(.data)
! 		*(.gnu.linkonce.d*)
! 		*(.gcc_except_table)
!                 . = ALIGN (16);
!                 PROVIDE (_edata = .);
!                 PROVIDE (_copy_end = .);
!         } >ram
!         .bss : {
!                 _clear_start = .;
!                 *(.bss)
!                 *(COMMON)
!                 . = ALIGN (16);
!                 PROVIDE (end = .);
! 
!                 . += _StackSize;
!                 . = ALIGN (16);
!                 _stack_init = .;
!                 _clear_end = .;
! 
!                 _WorkspaceBase = .;
!         } >ram
  }
--- 42,185 ----
  
  SECTIONS
  {
!  /*
!   * Text, data and bss segments
!   */
!   .text : {
!     *(.text)
! 
!     /*
!      * C++ constructors/destructors
!      */
!     *(.gnu.linkonce.t.*)
! 
!     /*
!      * Initialization and finalization code.
!      *
!      * Various files can provide initialization and finalization
!      * functions.  crtbegin.o and crtend.o are two instances. The
!      * body of these functions are in .init and .fini sections. We
!      * accumulate the bodies here, and prepend function prologues
!      * from crti.o and function epilogues from crtn.o. crti.o must
!      * be linked first; crtn.o must be linked last.  Because these
!      * are wildcards, it doesn't matter if the user does not
!      * actually link against crti.o and crtn.o; the linker won't
!      * look for a file to match a wildcard.  The wildcard also
!      * means that it doesn't matter which directory crti.o and
!      * crtn.o are in. 
!      */
!     PROVIDE (_init = .);
!     *crti.o(.init)
!     *(.init)
!     *crtn.o(.init)
!     
!     PROVIDE (_fini = .);
!     *crti.o(.fini)
!     *(.fini)
!     *crtn.o(.fini)
! 
!     /*
!      * C++ constructors/destructors
!      *
!      * gcc uses crtbegin.o to find the start of the constructors
!      * and destructors so we make sure it is first.  Because this
!      * is a wildcard, it doesn't matter if the user does not
!      * actually link against crtbegin.o; the linker won't look for
!      * a file to match a wildcard.  The wildcard also means that
!      * it doesn't matter which directory crtbegin.o is in. The
!      * constructor and destructor list are terminated in
!      * crtend.o.  The same comments apply to it.
!      */
!     . = ALIGN (16);
!     *crtbegin.o(.ctors)
!     *(.ctors)
!     *crtend.o(.ctors)
!     
!     *crtbegin.o(.dtors)
!     *(.dtors)
!     *crtend.o(.dtors)
! 
!     /*
!      * Exception frame info
!      */
!     . = ALIGN (16);
!     *(.eh_frame)
! 
!     /*
!      * Read-only data
!      */
!     . = ALIGN (16);
!     PROVIDE(_rodata_start = . );
!     *(.rodata)
!     *(.gnu.linkonce.r*)
!     PROVIDE(_erodata = . );
! 
!     . = ALIGN (16);
!     PROVIDE (_etext = .);
!   } >ram
!   
!   .data : {
!     PROVIDE (_copy_start = .);
!     *(.data)
!     *(.gnu.linkonce.d*)
!     *(.gcc_except_table)
!     . = ALIGN (16);
!     PROVIDE (_edata = .);
!     PROVIDE (_copy_end = .);
!   } >ram
!   
!  .bss : {
!     _clear_start = .;
!     *(.bss)
!     *(COMMON)
!     . = ALIGN (16);
!     PROVIDE (end = .);
! 
!     . += _StackSize;
!     . = ALIGN (16);
!     _stack_init = .;
!     _clear_end = .;
! 
!     _WorkspaceBase = .;
!   } >ram
! 
!   /* Stabs debugging sections.  */
!   .stab 0 : { *(.stab) }
!   .stabstr 0 : { *(.stabstr) }
!   .stab.excl 0 : { *(.stab.excl) }
!   .stab.exclstr 0 : { *(.stab.exclstr) }
!   .stab.index 0 : { *(.stab.index) }
!   .stab.indexstr 0 : { *(.stab.indexstr) }
!   .comment 0 : { *(.comment) }
!   
!   /* DWARF debug sections.
!      Symbols in the DWARF debugging sections are relative to the beginning
!      of the section so we begin them at 0.  */
!   /* DWARF 1 */
!   .debug          0 : { *(.debug) }
!   .line           0 : { *(.line) }
!   
!   /* GNU DWARF 1 extensions */
!   .debug_srcinfo  0 : { *(.debug_srcinfo) }
!   .debug_sfnames  0 : { *(.debug_sfnames) }
!   
!   /* DWARF 1.1 and DWARF 2 */
!   .debug_aranges  0 : { *(.debug_aranges) }
!   .debug_pubnames 0 : { *(.debug_pubnames) }
!   
!   /* DWARF 2 */
!   .debug_info     0 : { *(.debug_info) }
!   .debug_abbrev   0 : { *(.debug_abbrev) }
!   .debug_line     0 : { *(.debug_line) }
!   .debug_frame    0 : { *(.debug_frame) }
!   .debug_str      0 : { *(.debug_str) }
!   .debug_loc      0 : { *(.debug_loc) }
!   .debug_macinfo  0 : { *(.debug_macinfo) }
!   
!   /* SGI/MIPS DWARF 2 extensions */
!   .debug_weaknames 0 : { *(.debug_weaknames) }
!   .debug_funcnames 0 : { *(.debug_funcnames) }
!   .debug_typenames 0 : { *(.debug_typenames) }
!   .debug_varnames  0 : { *(.debug_varnames) }
!   /* These must appear regardless of  .  */
  }
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/timer/Makefile.am rtems/c/src/lib/libbsp/m68k/mvme167/timer/Makefile.am
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/timer/Makefile.am	Fri Feb 25 09:50:41 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/timer/Makefile.am	Thu Feb 10 10:19:25 2000
***************
*** 1,5 ****
  ## 
! ## $Id: Makefile.am,v 1.1.2.1 2000/02/25 14:50:41 joel Exp $
  ## 
  
  AUTOMAKE_OPTIONS = foreign 1.4
--- 1,5 ----
  ## 
! ## $Id: Makefile.am,v 1.1.1.1 2000/02/10 15:19:25 cotton Exp $
  ## 
  
  AUTOMAKE_OPTIONS = foreign 1.4
***************
*** 26,32 ****
  
  # the .rel file built here will be put into libbsp.a by ../wrapup/Makefile
  
! all: $(ARCH) $(OBJS) $(PGM)
  
  .PRECIOUS: $(PGM)
  
--- 26,32 ----
  
  # the .rel file built here will be put into libbsp.a by ../wrapup/Makefile
  
! all-local: $(ARCH) $(OBJS) $(PGM)
  
  .PRECIOUS: $(PGM)
  
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/timer/Makefile.in rtems/c/src/lib/libbsp/m68k/mvme167/timer/Makefile.in
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/timer/Makefile.in	Tue Feb 29 09:21:59 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/timer/Makefile.in	Thu Mar  2 12:59:03 2000
***************
*** 66,75 ****
  host_triplet = @host@
  target_alias = @target_alias@
  target_triplet = @target@
! CC = @CC@
! CC_FOR_TARGET = @CC_FOR_TARGET@
! CPP = @CPP@
! GCCSED = @GCCSED@
  MAINT = @MAINT@
  MAKEINFO = @MAKEINFO@
  PACKAGE = @PACKAGE@
--- 66,72 ----
  host_triplet = @host@
  target_alias = @target_alias@
  target_triplet = @target@
! INSTALL_CHANGE = @INSTALL_CHANGE@
  MAINT = @MAINT@
  MAKEINFO = @MAKEINFO@
  PACKAGE = @PACKAGE@
***************
*** 163,169 ****
  install: install-am
  uninstall-am:
  uninstall: uninstall-am
! all-am: Makefile
  all-redirect: all-am
  install-strip:
  	$(MAKE) $(AM_MAKEFLAGS) INSTALL_STRIP_FLAG=-s install
--- 160,166 ----
  install: install-am
  uninstall-am:
  uninstall: uninstall-am
! all-am: Makefile all-local
  all-redirect: all-am
  install-strip:
  	$(MAKE) $(AM_MAKEFLAGS) INSTALL_STRIP_FLAG=-s install
***************
*** 200,206 ****
  .PHONY: tags distdir info-am info dvi-am dvi check check-am \
  installcheck-am installcheck install-exec-am install-exec \
  install-data-am install-data install-am install uninstall-am uninstall \
! all-redirect all-am all installdirs mostlyclean-generic \
  distclean-generic clean-generic maintainer-clean-generic clean \
  mostlyclean distclean maintainer-clean
  
--- 197,203 ----
  .PHONY: tags distdir info-am info dvi-am dvi check check-am \
  installcheck-am installcheck install-exec-am install-exec \
  install-data-am install-data install-am install uninstall-am uninstall \
! all-local all-redirect all-am all installdirs mostlyclean-generic \
  distclean-generic clean-generic maintainer-clean-generic clean \
  mostlyclean distclean maintainer-clean
  
***************
*** 229,252 ****
  
  # the .rel file built here will be put into libbsp.a by ../wrapup/Makefile
  
! all: $(ARCH) $(OBJS) $(PGM)
  
  .PRECIOUS: $(PGM)
  
  debug-am:
- 	$(MAKE) $(AM_MAKEFLAGS) "ARCH=o-debug" \
-       "CFLAGS_DEBUG=$(CFLAGS_DEBUG_V)" \
-       "CFLAGS_OPTIMIZE=$(CFLAGS_DEBUG_OPTIMIZE_V)" \
-       "LDFLAGS_DEBUG=$(LDFLAGS_DEBUG_V)" $(TARGET_VA)
- 
  debug: debug-am
  .PHONY: debug debug-am
  
  profile-am:
- 	$(MAKE) $(AM_MAKEFLAGS) "ARCH=o-profile" \
-       "CFLAGS_PROFILE=$(CFLAGS_PROFILE_V)" \
-       "LDFLAGS_PROFILE=$(LDFLAGS_PROFILE_V)" $(TARGET_VA)
- 
  profile: profile-am
  .PHONY: profile profile-am
  
--- 226,240 ----
  
  # the .rel file built here will be put into libbsp.a by ../wrapup/Makefile
  
! all-local: $(ARCH) $(OBJS) $(PGM)
  
  .PRECIOUS: $(PGM)
  
  debug-am:
  debug: debug-am
  .PHONY: debug debug-am
  
  profile-am:
  profile: profile-am
  .PHONY: profile profile-am
  
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/times rtems/c/src/lib/libbsp/m68k/mvme167/times
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/times	Wed Dec 31 19:00:00 1969
--- rtems/c/src/lib/libbsp/m68k/mvme167/times	Tue Mar  7 14:22:39 2000
***************
*** 0 ****
--- 1,367 ----
+ #
+ #  Timing Test Suite Results for the MBX860-002
+ #
+ #  $Id: times,v 1.1 2000/03/07 19:22:39 gauthier Exp $
+ #
+ 
+ Board: MVME167
+ CPU:   MC68040
+ Clock Speed: 25 MHz
+ Memory Configuration: 4MB DRAM, data/instruction caches on, copyback mode
+ Wait States:
+ 
+ Times Reported in: microseconds
+ Timer Source: VME Tick Timer 1
+ 
+ 
+ *** TIME TEST 1 ***
+ rtems_semaphore_create 24
+ rtems_semaphore_delete 22
+ rtems_semaphore_obtain: available 8
+ rtems_semaphore_obtain: not available -- NO_WAIT 8
+ rtems_semaphore_release: no waiting tasks 11
+ *** END OF TEST 1 ***
+ 
+ 
+ *** TIME TEST 2 ***
+ rtems_semaphore_obtain: not available -- caller blocks 36
+ *** END OF TEST 2 ***
+ 
+ 
+ *** TIME TEST 3 ***
+ rtems_semaphore_release: task readied -- preempts caller 28
+ *** END OF TEST 3 ***
+ 
+ 
+ *** TIME TEST 4 ***
+ rtems_task_restart: blocked task -- preempts caller 57
+ rtems_task_restart: ready task -- preempts caller 53
+ rtems_semaphore_release: task readied -- returns to caller 16
+ rtems_task_create 67
+ rtems_task_start 21
+ rtems_task_restart: suspended task -- returns to caller 27
+ rtems_task_delete: suspended task 59
+ rtems_task_restart: ready task -- returns to caller 28
+ rtems_task_restart: blocked task -- returns to caller 35
+ rtems_task_delete: blocked task 60
+ *** END OF TEST 4 ***
+ 
+ 
+ *** TIME TEST 5 ***
+ rtems_task_suspend: calling task 26
+ rtems_task_resume: task readied -- preempts caller 23
+ *** END OF TEST 5 ***
+ 
+ 
+ *** TIME TEST 6 ***
+ rtems_task_restart: calling task 26
+ rtems_task_suspend: returns to caller 11
+ rtems_task_resume: task readied -- returns to caller 12
+ rtems_task_delete: ready task 61
+ *** END OF TEST 6 ***
+ 
+ 
+ *** TIME TEST 7 ***
+ rtems_task_restart: suspended task -- preempts caller 44
+ *** END OF TEST 7 ***
+ 
+ *** TIME TEST 8 ***
+ rtems_task_set_priority: obtain current priority 7
+ rtems_task_set_priority: returns to caller 16
+ rtems_task_mode: obtain current mode 4
+ rtems_task_mode: no reschedule 5
+ rtems_task_mode: reschedule -- returns to caller 11
+ rtems_task_mode: reschedule -- preempts caller 29
+ rtems_task_set_note 7
+ rtems_task_get_note 7
+ rtems_clock_set 21
+ rtems_clock_get 0
+ *** END OF TEST 8 ***
+ 
+ 
+ *** TIME TEST 9 ***
+ rtems_message_queue_create 89
+ rtems_message_queue_send: no waiting tasks 18
+ rtems_message_queue_urgent: no waiting tasks 18
+ rtems_message_queue_receive: available 18
+ rtems_message_queue_flush: no messages flushed 6
+ rtems_message_queue_flush: messages flushed 8
+ rtems_message_queue_delete 31
+ *** END OF TEST 9 ***
+ 
+ 
+ *** TIME TEST 10 ***
+ rtems_message_queue_receive: not available -- NO_WAIT 9
+ rtems_message_queue_receive: not available -- caller blocks 37
+ *** END OF TEST 10 ***
+ 
+ 
+ *** TIME TEST 11 ***
+ rtems_message_queue_send: task readied -- preempts caller 34
+ *** END OF TEST 11 ***
+ 
+ 
+ *** TIME TEST 12 ***
+ rtems_message_queue_send: task readied -- returns to caller 22
+ *** END OF TEST 12 ***
+ 
+ 
+ *** TIME TEST 13 ***
+ rtems_message_queue_urgent: task readied -- preempts caller 35
+ *** END OF TEST 13 ***
+ 
+ 
+ *** TIME TEST 14 ***
+ rtems_message_queue_urgent: task readied -- returns to caller 22
+ *** END OF TEST 14 ***
+ 
+ 
+ *** TIME TEST 15 ***
+ rtems_event_receive: obtain current events -1
+ rtems_event_receive: not available -- NO_WAIT 5
+ rtems_event_receive: not available -- caller blocks 30
+ rtems_event_send: no task readied 7
+ rtems_event_receive: available 10
+ rtems_event_send: task readied -- returns to caller 17
+ *** END OF TEST 15 ***
+ 
+ 
+ *** TIME TEST 16 ***
+ rtems_event_send: task readied -- preempts caller 30
+ *** END OF TEST 16 ***
+ 
+ 
+ *** TIME TEST 17 ***
+ rtems_task_set_priority: preempts caller 36
+ *** END OF TEST 17 ***
+ 
+ 
+ *** TIME TEST 18 ***
+ rtems_task_delete: calling task 79
+ *** END OF TEST 18 ***
+ 
+ 
+ *** TIME TEST 19 ***
+ rtems_signal_catch 5
+ rtems_signal_send: returns to caller 15
+ rtems_signal_send: signal to self 24
+ exit ASR overhead: returns to calling task 22
+ exit ASR overhead: returns to preempting task 25
+ *** END OF TEST 19 ***
+ 
+ 
+ *** TIME TEST 20 ***
+ rtems_partition_create 30
+ rtems_region_create 26
+ rtems_partition_get_buffer: available 13
+ rtems_partition_get_buffer: not available 8
+ rtems_partition_return_buffer 15
+ rtems_partition_delete 14
+ rtems_region_get_segment: available 14
+ rtems_region_get_segment: not available -- NO_WAIT 17
+ rtems_region_return_segment: no waiting tasks 15
+ rtems_region_get_segment: not available -- caller blocks 51
+ rtems_region_return_segment: task readied -- preempts caller 60
+ rtems_region_return_segment: task readied -- returns to caller 33
+ rtems_region_delete 14
+ rtems_io_initialize 0
+ rtems_io_open 0
+ rtems_io_close 0
+ rtems_io_read 0
+ rtems_io_write 0
+ rtems_io_control 0
+ *** END OF TEST 20 ***
+ 
+ 
+ *** TIME TEST 21 ***
+ rtems_task_ident 118
+ rtems_message_queue_ident 115
+ rtems_semaphore_ident 132
+ rtems_partition_ident 115
+ rtems_region_ident 117
+ rtems_port_ident 115
+ rtems_timer_ident 116
+ rtems_rate_monotonic_ident 115
+ *** END OF TEST 21 ***
+ 
+ 
+ *** TIME TEST 22 ***
+ rtems_message_queue_broadcast: task readied -- returns to caller 31
+ rtems_message_queue_broadcast: no waiting tasks 12
+ rtems_message_queue_broadcast: task readied -- preempts caller 39
+ *** END OF TEST 22 ***
+ 
+ 
+ *** TIME TEST 23 ***
+ rtems_timer_create 9
+ rtems_timer_fire_after: inactive 17
+ rtems_timer_fire_after: active 18
+ rtems_timer_cancel: active 9
+ rtems_timer_cancel: inactive 8
+ rtems_timer_reset: inactive 16
+ rtems_timer_reset: active 17
+ rtems_timer_fire_when: inactive 22
+ rtems_timer_fire_when: active 23
+ rtems_timer_delete: active 14
+ rtems_timer_delete: inactive 12
+ rtems_task_wake_when 38
+ *** END OF TEST 23 ***
+ 
+ 
+ *** TIME TEST 24 ***
+ rtems_task_wake_after: yield -- returns to caller 5
+ rtems_task_wake_after: yields -- preempts caller 22
+ *** END OF TEST 24 ***
+ 
+ 
+ *** TIME TEST 25 ***
+ rtems_clock_tick 7
+ *** END OF TEST 25 ***
+ 
+ 
+ *** TIME TEST 26 ***
+ _ISR_Disable 1
+ _ISR_Flash 0
+ _ISR_Enable 0
+ _Thread_Disable_dispatch 0
+ _Thread_Enable_dispatch 3
+ _Thread_Set_state 8
+ _Thread_Disptach (NO FP) 19
+ context switch: no floating point contexts 13
+ context switch: self 2
+ context switch: to another task 3
+ fp context switch: restore 1st FP task 15
+ fp context switch: save idle, restore initialized 5
+ fp context switch: save idle, restore idle 16
+ fp context switch: save initialized, restore initialized 5
+ _Thread_Resume 8
+ _Thread_Unblock 6
+ _Thread_Ready 6
+ _Thread_Get 2
+ _Semaphore_Get 2
+ _Thread_Get: invalid id 0
+ *** END OF TEST 26 ***
+ 
+ 
+ *** TIME TEST 27 ***
+ interrupt entry overhead: returns to interrupted task 8
+ interrupt exit overhead: returns to interrupted task 2
+ interrupt entry overhead: returns to nested interrupt 5
+ interrupt exit overhead: returns to nested interrupt 1
+ interrupt entry overhead: returns to preempting task 7
+ interrupt exit overhead: returns to preempting task 30
+ *** END OF TEST 27 ***
+ 
+ 
+ *** TIME TEST 28 ***
+ rtems_port_create 14
+ rtems_port_external_to_internal 5
+ rtems_port_internal_to_external 5
+ rtems_port_delete 16
+ *** END OF TEST 28 ***
+ 
+ 
+ *** TIME TEST 29 ***
+ rtems_rate_monotonic_create 17
+ rtems_rate_monotonic_period: initiate period -- returns to caller 23
+ rtems_rate_monotonic_period: obtain status 11
+ rtems_rate_monotonic_cancel 15
+ rtems_rate_monotonic_delete: inactive 21
+ rtems_rate_monotonic_delete: active 18
+ rtems_rate_monotonic_period: conclude periods -- caller blocks 25
+ *** END OF TEST 29 ***
+ 
+ 
+ *** INITIAL TIMING TEST RESULTS ***
+ 
+ *** TIME CHECKER ***
+ Units may not be in microseconds for this test!!!
+ 3 87999
+ 4 12001
+ Total time = 312001
+ Average time = 3
+ <pause>
+ NULL timer stopped at 4
+ LOOP (1000) timer stopped at 645
+ LOOP (10000) timer stopped at 6405
+ LOOP (50000) timer stopped at 30020
+ LOOP (100000) timer stopped at 60034
+ *** END OF TIME CHECKER ***
+ 
+ 
+ *** TIME TEST OVERHEAD ***
+ rtems_initialize_executive 0
+ rtems_shutdown_executive 0
+ rtems_task_create 1
+ rtems_task_ident 0
+ rtems_task_start 1
+ rtems_task_restart 0
+ rtems_task_delete 0
+ rtems_task_suspend 0
+ rtems_task_resume 0
+ rtems_task_set_priority 0
+ rtems_task_mode 0
+ rtems_task_get_note 0
+ rtems_task_set_note 0
+ rtems_task_wake_when 1
+ rtems_task_wake_after 0
+ rtems_interrupt_catch 0
+ rtems_clock_get 1
+ rtems_clock_set 1
+ rtems_clock_tick 0
+ <pause>
+ rtems_timer_create 0
+ rtems_timer_delete 0
+ rtems_timer_ident 0
+ rtems_timer_fire_after 0
+ rtems_timer_fire_when 1
+ rtems_timer_reset 0
+ rtems_timer_cancel 0
+ rtems_semaphore_create 1
+ rtems_semaphore_delete 0
+ rtems_semaphore_ident 0
+ rtems_semaphore_obtain 0
+ rtems_semaphore_release 0
+ rtems_message_queue_create 1
+ rtems_message_queue_ident 0
+ rtems_message_queue_delete 0
+ rtems_message_queue_send 0
+ rtems_message_queue_urgent 0
+ rtems_message_queue_broadcast 0
+ rtems_message_queue_receive 0
+ rtems_message_queue_flush 0
+ <pause>
+ rtems_event_send 0
+ rtems_event_receive 0
+ rtems_signal_catch 0
+ rtems_signal_send 0
+ rtems_partition_create 1
+ rtems_partition_ident 0
+ rtems_partition_delete 0
+ rtems_partition_get_buffer 0
+ rtems_partition_return_buffer 0
+ rtems_region_create 1
+ rtems_region_ident 0
+ rtems_region_delete 0
+ rtems_region_get_segment 1
+ rtems_region_return_segment 0
+ rtems_port_create 1
+ rtems_port_ident 0
+ rtems_port_delete 0
+ rtems_port_external_to_internal 0
+ rtems_port_internal_to_external 0
+ <pause>
+ rtems_io_initialize 1
+ rtems_io_open 1
+ rtems_io_close 1
+ rtems_io_read 1
+ rtems_io_write 1
+ rtems_io_control 1
+ rtems_fatal_error_occurred 0
+ rtems_rate_monotonic_create 0
+ rtems_rate_monotonic_ident 0
+ rtems_rate_monotonic_delete 0
+ rtems_rate_monotonic_cancel 0
+ rtems_rate_monotonic_period 0
+ rtems_multiprocessing_announce 0
+ *** END OF TIME OVERHEAD ***
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/wrapup/Makefile.am rtems/c/src/lib/libbsp/m68k/mvme167/wrapup/Makefile.am
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/wrapup/Makefile.am	Fri Feb 25 09:50:41 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/wrapup/Makefile.am	Thu Feb 10 10:19:26 2000
***************
*** 1,5 ****
  ## 
! ## $Id: Makefile.am,v 1.1.2.1 2000/02/25 14:50:41 joel Exp $
  ## 
  
  AUTOMAKE_OPTIONS = foreign 1.4
--- 1,5 ----
  ## 
! ## $Id: Makefile.am,v 1.1.1.1 2000/02/10 15:19:26 cotton Exp $
  ## 
  
  AUTOMAKE_OPTIONS = foreign 1.4
***************
*** 28,34 ****
  
  TMPINSTALL_FILES += $(PROJECT_RELEASE)/lib/libbsp$(LIB_VARIANT).a
  
! all: $(ARCH) $(OBJS) $(LIB) $(TMPINSTALL_FILES)
  
  .PRECIOUS: $(LIB)
  
--- 28,34 ----
  
  TMPINSTALL_FILES += $(PROJECT_RELEASE)/lib/libbsp$(LIB_VARIANT).a
  
! all-local: $(ARCH) $(OBJS) $(LIB) $(TMPINSTALL_FILES)
  
  .PRECIOUS: $(LIB)
  
diff -c -r -x CVS -P rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/wrapup/Makefile.in rtems/c/src/lib/libbsp/m68k/mvme167/wrapup/Makefile.in
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/wrapup/Makefile.in	Tue Feb 29 09:21:59 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/wrapup/Makefile.in	Thu Mar  2 12:59:03 2000
***************
*** 66,75 ****
  host_triplet = @host@
  target_alias = @target_alias@
  target_triplet = @target@
! CC = @CC@
! CC_FOR_TARGET = @CC_FOR_TARGET@
! CPP = @CPP@
! GCCSED = @GCCSED@
  MAINT = @MAINT@
  MAKEINFO = @MAKEINFO@
  PACKAGE = @PACKAGE@
--- 66,72 ----
  host_triplet = @host@
  target_alias = @target_alias@
  target_triplet = @target@
! INSTALL_CHANGE = @INSTALL_CHANGE@
  MAINT = @MAINT@
  MAKEINFO = @MAKEINFO@
  PACKAGE = @PACKAGE@
***************
*** 159,165 ****
  install: install-am
  uninstall-am:
  uninstall: uninstall-am
! all-am: Makefile
  all-redirect: all-am
  install-strip:
  	$(MAKE) $(AM_MAKEFLAGS) INSTALL_STRIP_FLAG=-s install
--- 156,162 ----
  install: install-am
  uninstall-am:
  uninstall: uninstall-am
! all-am: Makefile all-local
  all-redirect: all-am
  install-strip:
  	$(MAKE) $(AM_MAKEFLAGS) INSTALL_STRIP_FLAG=-s install
***************
*** 196,202 ****
  .PHONY: tags distdir info-am info dvi-am dvi check check-am \
  installcheck-am installcheck install-exec-am install-exec \
  install-data-am install-data install-am install uninstall-am uninstall \
! all-redirect all-am all installdirs mostlyclean-generic \
  distclean-generic clean-generic maintainer-clean-generic clean \
  mostlyclean distclean maintainer-clean
  
--- 193,199 ----
  .PHONY: tags distdir info-am info dvi-am dvi check check-am \
  installcheck-am installcheck install-exec-am install-exec \
  install-data-am install-data install-am install uninstall-am uninstall \
! all-local all-redirect all-am all installdirs mostlyclean-generic \
  distclean-generic clean-generic maintainer-clean-generic clean \
  mostlyclean distclean maintainer-clean
  
***************
*** 226,249 ****
  $(PROJECT_RELEASE)/lib/libbsp$(LIB_VARIANT).a: $(LIB)
  	$(INSTALL_DATA) $< $@
  
! all: $(ARCH) $(OBJS) $(LIB) $(TMPINSTALL_FILES)
  
  .PRECIOUS: $(LIB)
  
  debug-am:
- 	$(MAKE) $(AM_MAKEFLAGS) "ARCH=o-debug" \
-       "CFLAGS_DEBUG=$(CFLAGS_DEBUG_V)" \
-       "CFLAGS_OPTIMIZE=$(CFLAGS_DEBUG_OPTIMIZE_V)" \
-       "LDFLAGS_DEBUG=$(LDFLAGS_DEBUG_V)" $(TARGET_VA)
- 
  debug: debug-am
  .PHONY: debug debug-am
  
  profile-am:
- 	$(MAKE) $(AM_MAKEFLAGS) "ARCH=o-profile" \
-       "CFLAGS_PROFILE=$(CFLAGS_PROFILE_V)" \
-       "LDFLAGS_PROFILE=$(LDFLAGS_PROFILE_V)" $(TARGET_VA)
- 
  profile: profile-am
  .PHONY: profile profile-am
  
--- 223,237 ----
  $(PROJECT_RELEASE)/lib/libbsp$(LIB_VARIANT).a: $(LIB)
  	$(INSTALL_DATA) $< $@
  
! all-local: $(ARCH) $(OBJS) $(LIB) $(TMPINSTALL_FILES)
  
  .PRECIOUS: $(LIB)
  
  debug-am:
  debug: debug-am
  .PHONY: debug debug-am
  
  profile-am:
  profile: profile-am
  .PHONY: profile profile-am
  
diff -c -r -x CVS -P rtems-4.5.0-beta1c/make/custom/mvme167.cfg rtems/make/custom/mvme167.cfg
*** rtems-4.5.0-beta1c/make/custom/mvme167.cfg	Wed Jan 12 11:08:57 2000
--- rtems/make/custom/mvme167.cfg	Thu Mar  2 19:20:25 2000
***************
*** 4,9 ****
--- 4,12 ----
  #  $Id: mvme167.cfg,v 1.5 2000/01/12 16:08:57 joel Exp $
  #
  
+ # THIS BSP USES ELF IMAGES. IT WILL NOT WORK WITH COFF UNLESS CHANGES
+ # ARE MADE TO THE LINKCMDS FILE.
+ 
  RTEMS_CPU=m68k
  RTEMS_CPU_MODEL=m68040
  
***************
*** 14,23 ****
  
  #
  #  This contains the compiler options necessary to select the CPU model
! #  and (hopefully) optimize for it. 
  #
  
! CPU_CFLAGS = -m68040
  
  # optimize flag: typically -O, could use -O4 or -fast
  # -O4 is ok for RTEMS
--- 17,28 ----
  
  #
  #  This contains the compiler options necessary to select the CPU model
! #  and (hopefully) optimize for it.  We also specify the BSP during compilation.
! #  This should really get its own flag, but it works here.
  #
  
! CPU_CFLAGS = -m68040 -DRTEMS_BSP=$(RTEMS_BSP)
! CFLAGS_DEBUG_V += -ggdb
  
  # optimize flag: typically -O, could use -O4 or -fast
  # -O4 is ok for RTEMS
***************
*** 33,43 ****
--- 38,58 ----
  #
  #  RTEMS_DEBUG (RTEMS)
  #     If defined, debug checks in RTEMS and support library code are enabled.
+ #
+ #  CD2401_INT_LEVEL
+ #	  Interrupt level for the CD2401.
+ #
+ #  CD2401_POLLED_IO
+ #	  0 for interrupt-driven, 1 for polled I/O.
  
  define make-target-options
  	@echo "/* #define NDEBUG 1 */ "                     >>$@
  	@echo "#define RTEMS_TEST_NO_PAUSE 1"               >>$@
  	@echo "/* #define RTEMS_DEBUG  1 */"                >>$@
+ 	@echo "#define CD2401_INT_LEVEL 1"                  >>$@
+ 	@echo "#define CD2401_POLLED_IO 1"                  >>$@
+ 	
+ 	
  endef
  
  # Here is the rule to actually build a $(ARCH)/foo.exe
***************
*** 71,84 ****
  define make-exe
  	$(LD) $(LDFLAGS) -N -T $(LINKCMDS) -o $(basename $@).exe \
  	    $(START_FILE) $(LINK_OBJS) --start-group $(LINK_LIBS) --end-group
! 	$(NM) -g -n $(basename $@).exe > $(basename $@).num
  	$(SIZE) $(basename $@).exe
  endef
  else
  define make-exe
! 	$(CC) $(CPPFLAGS) $(CFLAGS) $(CFLAGS_LD) -o $(basename $@).exe \
  	    $(LINK_OBJS) $(LINK_LIBS)
  	$(NM) -g -n $(basename $@).exe > $(basename $@).nm
  	$(SIZE) $(basename $@).exe
  endef
  endif
--- 86,101 ----
  define make-exe
  	$(LD) $(LDFLAGS) -N -T $(LINKCMDS) -o $(basename $@).exe \
  	    $(START_FILE) $(LINK_OBJS) --start-group $(LINK_LIBS) --end-group
! 	$(NM) -g -n $(basename $@).exe > $(basename $@).nm
! 	$(STRIP) -o $(basename $@) $@
  	$(SIZE) $(basename $@).exe
  endef
  else
  define make-exe
! 	$(CC) $(CFLAGS) $(XLDFLAGS) -o $(basename $@).exe \
  	    $(LINK_OBJS) $(LINK_LIBS)
  	$(NM) -g -n $(basename $@).exe > $(basename $@).nm
+ 	$(STRIP) -o $(basename $@) $@
  	$(SIZE) $(basename $@).exe
  endef
  endif
diff -c -N rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/startup/elflinkcmds rtems/c/src/lib/libbsp/m68k/mvme167/startup/elflinkcmds
*** rtems-4.5.0-beta1c/c/src/lib/libbsp/m68k/mvme167/startup/elflinkcmds	Thu Jan 13 15:45:07 2000
--- rtems/c/src/lib/libbsp/m68k/mvme167/startup/elflinkcmds	Wed Dec 31 19:00:00 1969
***************
*** 1,214 ****
- /*
-  *  This file contains directives for the GNU linker which are specific
-  *  to the Motorola MVME167 board. This linker script produces ELF
-  *  executables.
-  *
-  *  Copyright (c) 1999, National Research Council of Canada.
-  *  Some of this material was copied from binutils-2.9.4 linker scripts,
-  *  and is therefore likely to be copyrighted by the Free Software
-  *  Foundation, even though explicit copyright notices did not appear in
-  *  those files.
-  *
-  *  The license and distribution terms for this file may be
-  *  found in the file LICENSE in this distribution or at
-  *  http://www.OARcorp.com/rtems/license.html.
-  *
-  *  $Id: elflinkcmds,v 1.2 2000/01/13 20:45:07 joel Exp $
-  */
- 
- /* These are not really needed here */
- OUTPUT_FORMAT("elf32-m68k")
- OUTPUT_ARCH(m68k)
- ENTRY(_start)
- 
- /*
-  * Declare some sizes.
-  */
- _HeapSize = DEFINED(_HeapSize) ? _HeapSize : 0x10000;
- _StackSize = DEFINED(_StackSize) ? _StackSize : 0x1000;
- 
- MEMORY
- {
-   /*  The location of RAM is the address space is configurable.
-       This is where we put one board. The base address should be
-       passed as a parameter when building multiprocessor images
-       where each board resides at a different address. */
-   ram  : org = 0x00800000, l = 4M
-   rom  : org = 0xFF800000, l = 4M
-   sram : org = 0xFFE00000, l = 128K
- }
- 
- SECTIONS
- {
-   /* 
-    * We want the entry point to be the first thing in memory.
-    * Merge all read-only data into the .text section.
-    */
-   .text 0x00800000 :
-   {
-     text_start = . ;
-     
-     *(.text)
-     *(.text.*)
-     *(.stub)
- 
-     /* C++ constructors/destructors */
-     *(.gnu.linkonce.t*)
-    
-     /* Initialization and finalization code.
-      *
-      * Various files can provide initialization and finalization functions.
-      * crtbegin.o and crtend.o are two instances. The body of these functions
-      * are in .init and .fini sections. We accumulate the bodies here, and
-      * prepend function prologues from crti.o and function epilogues from
-      * crtn.o. crti.o must be linked first; crtn.o must be linked last.
-      * Because these are wildcards, it doesn't matter if the user does not
-      * actually link against crti.o and crtn.o; the linker won't look for a
-      * file to match a wildcard.  The wildcard also means that it doesn't
-      * matter which directory crti.o and crtn.o are in. 
-      */
-     PROVIDE (_init = .);
-     *crti.o(.init)
-     *(.init)
-     *crtn.o(.init)
-     
-     PROVIDE (_fini = .);
-     *crti.o(.fini)
-     *(.fini)
-     *crtn.o(.init)
-     
-     . = ALIGN (16);
-     
-     /* C++ constructors and destructors for static objects.
-      *
-      * gcc uses crtbegin.o to find the start of the constructors and
-      * destructors so we make sure it is first.  Because this is a wildcard,
-      * it doesn't matter if the user does not actually link against
-      * crtbegin.o; the linker won't look for a file to match a wildcard.  The
-      * wildcard also means that it doesn't matter which directory crtbegin.o
-      * is in. The constructor and destructor list are terminated in crtend.o.
-      * The same comments apply to it.
-      */
-     PROVIDE (__CTOR_LIST__ = .);
-     *crtbegin.o(.ctors)
-     *(.ctors)
-     *crtend.o(.ctors)
-     PROVIDE (__CTOR_END__ = .);
- 
-     PROVIDE (__DTOR_LIST__ = .);
-     *crtbegin.o(.dtors)
-     *(.dtors)
-     *crtend.o(.dtors)
-     PROVIDE (__DTOR_END__ = .);
-     
-     . = ALIGN (16);
-     
-     /* Exception frame info */
-     *(.eh_frame)
-     
-     . = ALIGN (16);
- 
-     /* Do we have any of these with egcs-1.x and higher? */
-     *(.gcc_exc)
-     
-     . = ALIGN (16);
- 		
-     _rodata_start = . ;
-     *(.rodata)
-     *(.rodata.*)
-     *(.gnu.linkonce.r*)
-     *(.rodata1)    
-     _erodata = .;
- 
-     _etext = .;
-     PROVIDE (etext = .);
-        
-   } >ram =0x4e75
-  
-   . = ALIGN (16);
-   
-   .data :
-   {
-     data_start = .;
-     
-     *(.data)
-     *(.data.*)
-     *(.data1)
-     *(.sdata)
-     *(.gnu.linkonce.d*)
-     *(.gcc_except_table)
-     
-     . = ALIGN (16); 
-     _edata = .;
-     PROVIDE (edata = .); 
-   } >ram
- 
-   .bss :
-   {
-     bss_start = .;
-     *(.dynbss)
-     *(.bss)
-     *(COMMON)
-     *(.sbss)
-     *(.scommon)  
-     
-     . = ALIGN (16);
-     _end = .;
-     PROVIDE (end = .); 
-   } >ram
- 
-   _HeapStart	= .;
-   . += HeapSize;	/* XXX -- Old gld can't	handle this	*/
-   _HeapEnd = .;
-   _StackStart = .;
-   . += _StackSize;	/* XXX -- Old gld can't	handle this	*/
-   /* . +=	0x10000; */	/* HeapSize	for	old	gld	*/
-   /* . +=	0x1000;	 */	/* _StackSize for old gld */
-   . =	ALIGN (16);
-   _StackEnd = .;
-   stack_init = .;
-   clear_end =	.;
- 
-   _WorkspaceBase	= .;
- 
-   /* Stabs debugging sections.  */
-   .stab 0 : { *(.stab) }
-   .stabstr 0 : { *(.stabstr) }
-   .stab.excl 0 : { *(.stab.excl) }
-   .stab.exclstr 0 : { *(.stab.exclstr) }
-   .stab.index 0 : { *(.stab.index) }
-   .stab.indexstr 0 : { *(.stab.indexstr) }
-   .comment 0 : { *(.comment) }
-   
-   /* DWARF debug sections.
-      Symbols in the DWARF debugging sections are relative to the beginning
-      of the section so we begin them at 0.  */
-   /* DWARF 1 */
-   .debug          0 : { *(.debug) }
-   .line           0 : { *(.line) }
-   
-   /* GNU DWARF 1 extensions */
-   .debug_srcinfo  0 : { *(.debug_srcinfo) }
-   .debug_sfnames  0 : { *(.debug_sfnames) }
-   
-   /* DWARF 1.1 and DWARF 2 */
-   .debug_aranges  0 : { *(.debug_aranges) }
-   .debug_pubnames 0 : { *(.debug_pubnames) }
-   
-   /* DWARF 2 */
-   .debug_info     0 : { *(.debug_info) }
-   .debug_abbrev   0 : { *(.debug_abbrev) }
-   .debug_line     0 : { *(.debug_line) }
-   .debug_frame    0 : { *(.debug_frame) }
-   .debug_str      0 : { *(.debug_str) }
-   .debug_loc      0 : { *(.debug_loc) }
-   .debug_macinfo  0 : { *(.debug_macinfo) }
-   
-   /* SGI/MIPS DWARF 2 extensions */
-   .debug_weaknames 0 : { *(.debug_weaknames) }
-   .debug_funcnames 0 : { *(.debug_funcnames) }
-   .debug_typenames 0 : { *(.debug_typenames) }
-   .debug_varnames  0 : { *(.debug_varnames) }
-   /* These must appear regardless of  .  */
- }
- 
--- 0 ----


More information about the users mailing list