This is the mail archive of the ecos-patches@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

PPC - New platform AdderII


Index: ChangeLog
===================================================================
RCS file: /misc/cvsfiles/ecos/packages/ChangeLog,v
retrieving revision 1.103
diff -u -5 -p -r1.103 ChangeLog
--- ChangeLog	18 Mar 2003 13:10:01 -0000	1.103
+++ ChangeLog	24 Mar 2003 21:49:54 -0000
@@ -1,5 +1,9 @@
+2003-03-24  Gary Thomas  <gary at mlbassoc dot com>
+
+	* ecos.db: New platform - Analogue & Micro AdderII (PPC852T)
+
 2003-03-18  Mark Salter  <msalter at redhat dot com>
 
         * ecos.db: Add support for XScale IXP425, IXDP425, GRG.
 
 2003-03-05  John Dallaway  <jld at ecoscentric dot com>
Index: NEWS
===================================================================
RCS file: /misc/cvsfiles/ecos/packages/NEWS,v
retrieving revision 1.68
diff -u -5 -p -r1.68 NEWS
--- NEWS	18 Mar 2003 13:10:01 -0000	1.68
+++ NEWS	24 Mar 2003 21:36:32 -0000
@@ -1,5 +1,6 @@
+* New port for Analogue & Micro Adder-II (PPC 852T) boards
 * New ports for Intel XScale IXP425 boards (IXDP425 and Generic Residential
   Gateway).
 * SNMP code now works with the FreeBSD stack
 * Simple Network Time Protocol (SNTP) client contributed by Andrew Lunn.
 * Added port for NMI uE250 (ARM Xscale PXA250) platform, contributed 
Index: ecos.db
===================================================================
RCS file: /misc/cvsfiles/ecos/packages/ecos.db,v
retrieving revision 1.92
diff -u -5 -p -r1.92 ecos.db
--- ecos.db	18 Mar 2003 13:10:01 -0000	1.92
+++ ecos.db	24 Mar 2003 21:38:52 -0000
@@ -550,20 +550,10 @@ package CYGPKG_DEVS_FLASH_VIPER {
         description "
            This package contains hardware support for FLASH memory
 	   on the A&M PowerPC/8xx VIPER platform."
 }
 
-package CYGPKG_DEVS_FLASH_POWERPC_ADDER {
-	alias 		{ "FLASH memory support for A&M Adder PowerPC/85x" flash_adder }
-	directory	devs/flash/powerpc/adder
-	script		flash_adder.cdl
-	hardware
-        description "
-           This package contains hardware support for FLASH memory
-	   on the A&M PowerPC/8xx ADDER platform."
-}
-
 package CYGPKG_DEVS_FLASH_MN10300_STB {
 	alias 		{ "FLASH memory support for Matsushita MN10300 STB" flash_stb }
 	directory	devs/flash/mn10300/stb
 	script		flash_stb.cdl
 	hardware
@@ -1338,18 +1328,10 @@ package CYGPKG_DEVS_ETH_POWERPC_VIPER {
 	directory	devs/eth/powerpc/viper
 	script		viper_eth_drivers.cdl
         description     "Ethernet driver specifics for A&M Viper (MPC8xxT) based boards."
 }
 
-package CYGPKG_DEVS_ETH_POWERPC_ADDER {
-	alias 		{ "A&M Adder ethernet driver" adder_eth_driver }
-	hardware
-	directory	devs/eth/powerpc/adder
-	script		adder_eth_drivers.cdl
-        description     "Ethernet driver specifics for A&M Adder (MPC85x) based boards."
-}
-
 package CYGPKG_DEVS_ETH_INTEL_I82559 {
 	alias 		{ "Intel 82559 ethernet driver"
 			   devs_eth_intel_i82559 i82559_eth_driver }
 	hardware
 	directory	devs/eth/intel/i82559
@@ -2754,20 +2736,10 @@ package CYGPKG_HAL_POWERPC_VIPER {
         description "
             The VIPER HAL package provides the support needed to run
             eCos on a A&M VIPER board equipped with a PowerPC processor."
 }
 
-package CYGPKG_HAL_POWERPC_ADDER {
-	alias		{ "A&M Adder PPC85x board" hal_powerpc_adder powerpc_adder_hal }
-	directory	hal/powerpc/adder
-	script		hal_powerpc_adder.cdl
-	hardware
-        description "
-            The ADDER HAL package provides the support needed to run
-            eCos on a A&M ADDER board equipped with a PowerPC processor."
-}
-
 package CYGPKG_HAL_POWERPC_TS6 {
 	alias		{ "Delphi TigerSHARC-6 board" hal_powerpc_ts6 powerpc_ts6_hal }
 	directory	hal/powerpc/ts6
 	script		hal_powerpc_ts6.cdl
 	hardware
@@ -2787,20 +2759,18 @@ package CYGPKG_HAL_POWERPC_VADS {
             eCos on a Motorola MPC8260 VADS board equipped with a
             PowerPC processor."
 }
 
 package CYGPKG_HAL_QUICC {
-	alias		{ "Motorola MBX860/821 QUICC support" hal_quicc quicc_hal quicc }
+	alias		{ "Motorola MPC8xx QUICC support" hal_quicc quicc_hal quicc }
 	directory	hal/powerpc/quicc
 	script		hal_powerpc_quicc.cdl
 	hardware
         description "
             The QUICC package provides some of the support needed
-            to run eCos on a Motorola MBX board, using the QUICC
-            feature of the MPC860 and MPC821 CPUs.
-            Currently only serial IO via SMC1 is provided by
-            this package."
+            to run eCos on a Motorola MPC8xx processors, using the QUICC
+            communications subsystem."
 }
 
 package CYGPKG_HAL_POWERPC_SIM {
 	alias		{ "PowerPC simulator" hal_powerpc_sim powerpc_sim_hal }
 	directory	hal/powerpc/sim
@@ -4122,27 +4092,10 @@ target viper {
         description "
             The viper target provides the packages needed to run
             eCos on a A&M Viper PPC860 board."
 }
 
-target adder {
-        alias		{ "A&M Adder PPC850 board" adder850 }
-	packages        { CYGPKG_HAL_POWERPC
-                          CYGPKG_HAL_POWERPC_MPC8xx
-                          CYGPKG_HAL_POWERPC_ADDER
-                          CYGPKG_HAL_QUICC 
-                          CYGPKG_DEVS_FLASH_POWERPC_ADDER
-                          CYGPKG_DEVS_FLASH_AMD_AM29XXXXX
-                          CYGPKG_DEVS_ETH_POWERPC_QUICC
-                          CYGPKG_DEVS_ETH_POWERPC_ADDER
-                          CYGPKG_IO_SERIAL_POWERPC_QUICC_SMC
-        }
-        description "
-            The adder target provides the packages needed to run
-            eCos on a A&M Adder PPC850 board."
-}
-
 target psim {
 	alias		{ "PowerPC simulator" ppc_sim powerpc_sim }
 	packages        { CYGPKG_HAL_POWERPC
                           CYGPKG_HAL_POWERPC_PPC60x
                           CYGPKG_HAL_POWERPC_SIM
@@ -4542,10 +4495,11 @@ target calm32_ceb {
         }
         description "
            The calm32_ceb target provides the packages needed to run
            eCos on the CalmRISC32 Core Evaluation Board."
 }
+
 # --------------------------------------------------------------------------
 
 package CYGPKG_HAL_POWERPC_TS1000 {
 	alias		{ "Allied Telesyn TS1000 board" hal_powerpc_ts1000 }
 	directory	hal/powerpc/ts1000
@@ -4635,6 +4589,80 @@ target uE250 {
                    CYGPKG_DEVS_ETH_ARM_XSCALE_UE250
         }
         description "
         The uE250 target provides the packages needed to run
         eCos on an NMI uEngine uE250 board."
+}
+
+# --------------------------------------------------------------------------
+
+package CYGPKG_HAL_POWERPC_ADDER {
+	alias		{ "A&M Adder PPC85x board" hal_powerpc_adder powerpc_adder_hal }
+	directory	hal/powerpc/adder
+	script		hal_powerpc_adder.cdl
+	hardware
+        description "
+            The ADDER HAL package provides the support needed to run
+            eCos on a A&M ADDER board equipped with a PowerPC processor."
+}
+
+package CYGPKG_DEVS_FLASH_POWERPC_ADDER {
+	alias 		{ "FLASH memory support for A&M Adder PowerPC/85x" flash_adder }
+	directory	devs/flash/powerpc/adder
+	script		flash_adder.cdl
+	hardware
+        description "
+           This package contains hardware support for FLASH memory
+	   on the A&M PowerPC/8xx ADDER platforms."
+}
+
+package CYGPKG_DEVS_ETH_POWERPC_ADDER {
+	alias 		{ "A&M Adder ethernet driver" adder_eth_driver }
+	hardware
+	directory	devs/eth/powerpc/adder
+	script		adder_eth_drivers.cdl
+        description     "Ethernet driver specifics for A&M Adder (MPC85x) based boards."
+}
+
+package CYGPKG_DEVS_ETH_POWERPC_ADDERII {
+        alias           { "A&M AdderII ethernet driver" adderII_eth_driver }
+        hardware
+        directory       devs/eth/powerpc/adderII
+        script          adderII_eth_drivers.cdl
+        description     "Ethernet driver specifics for A&M AdderII (MPC852T) based boards."
+}
+
+target adder {
+        alias		{ "A&M Adder PPC850 board" adder850 }
+	packages        { CYGPKG_HAL_POWERPC
+                          CYGPKG_HAL_POWERPC_MPC8xx
+                          CYGPKG_HAL_POWERPC_ADDER
+                          CYGPKG_HAL_QUICC 
+                          CYGPKG_DEVS_FLASH_POWERPC_ADDER
+                          CYGPKG_DEVS_FLASH_AMD_AM29XXXXX
+                          CYGPKG_DEVS_ETH_POWERPC_QUICC
+                          CYGPKG_DEVS_ETH_POWERPC_ADDER
+                          CYGPKG_IO_SERIAL_POWERPC_QUICC_SMC
+        }
+        enable { CYGHWR_HAL_POWERPC_ADDER_I }
+        description "
+            The adder target provides the packages needed to run
+            eCos on a A&M Adder PPC850 board."
+}
+
+target adderII {
+        alias		{ "A&M Adder PPC852T board" adder852T }
+	packages        { CYGPKG_HAL_POWERPC
+                          CYGPKG_HAL_POWERPC_MPC8xx
+                          CYGPKG_HAL_POWERPC_ADDER
+                          CYGPKG_HAL_QUICC 
+                          CYGPKG_DEVS_FLASH_POWERPC_ADDER
+                          CYGPKG_DEVS_FLASH_AMD_AM29XXXXX
+                          CYGPKG_DEVS_ETH_POWERPC_FEC
+                          CYGPKG_DEVS_ETH_POWERPC_ADDERII
+                          CYGPKG_IO_SERIAL_POWERPC_QUICC_SMC
+        }
+        enable { CYGHWR_HAL_POWERPC_ADDER_II }
+        description "
+            The adderII target provides the packages needed to run
+            eCos on a A&M Adder PPC852T board."
 }
Index: devs/eth/powerpc/adder/current/ChangeLog
===================================================================
RCS file: /misc/cvsfiles/ecos/packages/devs/eth/powerpc/adder/current/ChangeLog,v
retrieving revision 1.1
diff -u -5 -p -r1.1 ChangeLog
--- devs/eth/powerpc/adder/current/ChangeLog	25 Nov 2002 23:19:25 -0000	1.1
+++ devs/eth/powerpc/adder/current/ChangeLog	24 Mar 2003 21:50:51 -0000
@@ -1,5 +1,10 @@
+2003-03-24  Gary Thomas  <gary at mlbassoc dot com>
+
+	* cdl/adder_eth_drivers.cdl: Make sure this builds only for
+	the original Adder (PPC850)
+
 2002-11-25  Gary Thomas  <gthomas at ecoscentric dot com>
 
 	* src/adder_eth.c: 
 	* include/adder_eth.inl: 
 	* cdl/adder_eth_drivers.cdl: New package - platform specifics for
Index: devs/eth/powerpc/adder/current/cdl/adder_eth_drivers.cdl
===================================================================
RCS file: /misc/cvsfiles/ecos/packages/devs/eth/powerpc/adder/current/cdl/adder_eth_drivers.cdl,v
retrieving revision 1.1
diff -u -5 -p -r1.1 adder_eth_drivers.cdl
--- devs/eth/powerpc/adder/current/cdl/adder_eth_drivers.cdl	25 Nov 2002 23:18:41 -0000	1.1
+++ devs/eth/powerpc/adder/current/cdl/adder_eth_drivers.cdl	24 Mar 2003 21:50:52 -0000
@@ -7,11 +7,11 @@
 #====================================================================
 #####ECOSGPLCOPYRIGHTBEGIN####
 ## -------------------------------------------
 ## This file is part of eCos, the Embedded Configurable Operating System.
 ## Copyright (C) 1998, 1999, 2000, 2001, 2002 Red Hat, Inc.
-## Copyright (C) 2002 Gary Thomas
+## Copyright (C) 2002, 2003 Gary Thomas
 ##
 ## eCos is free software; you can redistribute it and/or modify it under
 ## the terms of the GNU General Public License as published by the Free
 ## Software Foundation; either version 2 or (at your option) any later version.
 ##
@@ -59,10 +59,11 @@ cdl_package CYGPKG_DEVS_ETH_POWERPC_ADDE
     active_if	  CYGPKG_HAL_POWERPC 
     active_if	  CYGPKG_HAL_POWERPC_MPC8xx
     active_if	  CYGPKG_HAL_POWERPC_ADDER
 
     requires      CYGPKG_DEVS_ETH_POWERPC_QUICC
+    requires      CYGHWR_HAL_POWERPC_ADDER_I
 
     compile       adder_eth.c
 
     include_dir   cyg/io
     define_proc {
Index: devs/eth/powerpc/adderII/current/ChangeLog
===================================================================
RCS file: devs/eth/powerpc/adderII/current/ChangeLog
diff -N devs/eth/powerpc/adderII/current/ChangeLog
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ devs/eth/powerpc/adderII/current/ChangeLog	24 Mar 2003 21:51:19 -0000
@@ -0,0 +1,49 @@
+2003-03-24  Gary Thomas  <gary at mlbassoc dot com>
+
+	* include/adderII_eth.inl: 
+	* cdl/adderII_eth_drivers.cdl: New package - ethernet support on
+	AdderII using FEC.
+
+2002-09-03  Gary Thomas  <gary at mlbassoc dot com>
+
+	* include/viper_eth.inl: 
+	* cdl/viper_eth_drivers.cdl: New package - platform specifics for
+	PowerPC/FEC ethernet driver.
+
+//===========================================================================
+//####ECOSGPLCOPYRIGHTBEGIN####
+// -------------------------------------------
+// This file is part of eCos, the Embedded Configurable Operating System.
+// Copyright (C) 1998, 1999, 2000, 2001, 2002 Red Hat, Inc.
+//
+// eCos is free software; you can redistribute it and/or modify it under
+// the terms of the GNU General Public License as published by the Free
+// Software Foundation; either version 2 or (at your option) any later version.
+//
+// eCos is distributed in the hope that it will be useful, but WITHOUT ANY
+// WARRANTY; without even the implied warranty of MERCHANTABILITY or
+// FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+// for more details.
+//
+// You should have received a copy of the GNU General Public License along
+// with eCos; if not, write to the Free Software Foundation, Inc.,
+// 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+//
+// As a special exception, if other files instantiate templates or use macros
+// or inline functions from this file, or you compile this file and link it
+// with other works to produce a work based on this file, this file does not
+// by itself cause the resulting work to be covered by the GNU General Public
+// License. However the source code for this file must still be made available
+// in accordance with section (3) of the GNU General Public License.
+//
+// This exception does not invalidate any other reasons why a work based on
+// this file might be covered by the GNU General Public License.
+//
+// Alternative licenses for eCos may be arranged by contacting Red Hat, Inc.
+// at http://sources.redhat.com/ecos/ecos-license/
+// -------------------------------------------
+//####ECOSGPLCOPYRIGHTEND####
+//===========================================================================
+	
+	
+
Index: devs/eth/powerpc/adderII/current/cdl/adderII_eth_drivers.cdl
===================================================================
RCS file: devs/eth/powerpc/adderII/current/cdl/adderII_eth_drivers.cdl
diff -N devs/eth/powerpc/adderII/current/cdl/adderII_eth_drivers.cdl
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ devs/eth/powerpc/adderII/current/cdl/adderII_eth_drivers.cdl	24 Mar 2003 19:48:16 -0000
@@ -0,0 +1,70 @@
+#====================================================================
+#
+#      adderII_eth_drivers.cdl
+#
+#      Hardware specifics for A&M Adder-II ethernet
+#
+#====================================================================
+#####ECOSGPLCOPYRIGHTBEGIN####
+## -------------------------------------------
+## This file is part of eCos, the Embedded Configurable Operating System.
+## Copyright (C) 1998, 1999, 2000, 2001, 2002 Red Hat, Inc.
+## Copyright (C) 2002, 2003 Gary Thomas
+##
+## eCos is free software; you can redistribute it and/or modify it under
+## the terms of the GNU General Public License as published by the Free
+## Software Foundation; either version 2 or (at your option) any later version.
+##
+## eCos is distributed in the hope that it will be useful, but WITHOUT ANY
+## WARRANTY; without even the implied warranty of MERCHANTABILITY or
+## FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+## for more details.
+##
+## You should have received a copy of the GNU General Public License along
+## with eCos; if not, write to the Free Software Foundation, Inc.,
+## 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+##
+## As a special exception, if other files instantiate templates or use macros
+## or inline functions from this file, or you compile this file and link it
+## with other works to produce a work based on this file, this file does not
+## by itself cause the resulting work to be covered by the GNU General Public
+## License. However the source code for this file must still be made available
+## in accordance with section (3) of the GNU General Public License.
+##
+## This exception does not invalidate any other reasons why a work based on
+## this file might be covered by the GNU General Public License.
+##
+## Alternative licenses for eCos may be arranged by contacting Red Hat, Inc.
+## at http://sources.redhat.com/ecos/ecos-license/
+## -------------------------------------------
+#####ECOSGPLCOPYRIGHTEND####
+# ====================================================================
+######DESCRIPTIONBEGIN####
+#
+# Author(s):      gthomas, hmt
+# Original data:  gthomas
+# Contributors:   gthomas, F.Robbins
+# Date:           2003-03-17
+#
+#####DESCRIPTIONEND####
+#
+#====================================================================
+
+cdl_package CYGPKG_DEVS_ETH_POWERPC_ADDERII {
+    display       "A&M AdderII (MPC852T) ethernet support"
+    description   "Hardware specifics for A&M AdderII ethernet"
+
+    parent        CYGPKG_IO_ETH_DRIVERS
+    active_if	  CYGPKG_IO_ETH_DRIVERS
+    active_if	  CYGPKG_HAL_POWERPC 
+    active_if	  CYGPKG_HAL_POWERPC_MPC8xx
+
+    requires      CYGPKG_DEVS_ETH_POWERPC_FEC
+    requires      CYGHWR_HAL_POWERPC_ADDER_II
+
+    include_dir   cyg/io
+
+    define_proc {
+        puts $::cdl_system_header "#define CYGDAT_DEVS_FEC_ETH_INL <cyg/io/adderII_eth.inl>"
+    }
+}
Index: devs/eth/powerpc/adderII/current/include/adderII_eth.inl
===================================================================
RCS file: devs/eth/powerpc/adderII/current/include/adderII_eth.inl
diff -N devs/eth/powerpc/adderII/current/include/adderII_eth.inl
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ devs/eth/powerpc/adderII/current/include/adderII_eth.inl	24 Mar 2003 19:53:11 -0000
@@ -0,0 +1,79 @@
+#ifndef CYGONCE_DEVS_ADDERII_ETH_INL
+#define CYGONCE_DEVS_ADDERII_ETH_INL
+//==========================================================================
+//
+//      adderii_eth.inl
+//
+//      Hardware specifics for A&M AdderII ethernet support
+//
+//==========================================================================
+//####ECOSGPLCOPYRIGHTBEGIN####
+// -------------------------------------------
+// This file is part of eCos, the Embedded Configurable Operating System.
+// Copyright (C) 1998, 1999, 2000, 2001, 2002 Red Hat, Inc.
+// Copyright (C) 2002, 2003 Gary Thomas
+//
+// eCos is free software; you can redistribute it and/or modify it under
+// the terms of the GNU General Public License as published by the Free
+// Software Foundation; either version 2 or (at your option) any later version.
+//
+// eCos is distributed in the hope that it will be useful, but WITHOUT ANY
+// WARRANTY; without even the implied warranty of MERCHANTABILITY or
+// FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+// for more details.
+//
+// You should have received a copy of the GNU General Public License along
+// with eCos; if not, write to the Free Software Foundation, Inc.,
+// 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+//
+// As a special exception, if other files instantiate templates or use macros
+// or inline functions from this file, or you compile this file and link it
+// with other works to produce a work based on this file, this file does not
+// by itself cause the resulting work to be covered by the GNU General Public
+// License. However the source code for this file must still be made available
+// in accordance with section (3) of the GNU General Public License.
+//
+// This exception does not invalidate any other reasons why a work based on
+// this file might be covered by the GNU General Public License.
+//
+// Alternative licenses for eCos may be arranged by contacting Red Hat, Inc.
+// at http://sources.redhat.com/ecos/ecos-license/
+// -------------------------------------------
+//####ECOSGPLCOPYRIGHTEND####
+//==========================================================================
+//#####DESCRIPTIONBEGIN####
+//
+// Author(s):    gthomas
+// Contributors: gthomas,F.Robbins
+// Date:         2002-09-03
+// Purpose:      
+// Description:  
+//              
+//####DESCRIPTIONEND####
+//
+//==========================================================================
+
+
+extern int  _adder_get_leds(void);
+extern void _adder_set_leds(int);
+
+#define _get_led()  _adder_get_leds()
+#define _set_led(v) _adder_set_leds(v)
+
+#define LED_TxACTIVE  1
+#define LED_RxACTIVE  2
+#define LED_IntACTIVE 3
+
+// Interrupt generated by device
+#define FEC_ETH_INT CYGNUM_HAL_INTERRUPT_SIU_LVL1
+// Address of PHY (transceiver) device
+#define FEC_ETH_PHY 0
+
+// Reset the PHY - analagous to hardware reset
+#define FEC_ETH_RESET_PHY()                                     \
+    eppc->pip_pbdat &= ~0x00010000;  /* Reset PHY chip pb15 */       \
+    CYGACC_CALL_IF_DELAY_US(10000);  /* 10ms */                 \
+    eppc->pip_pbdat |= 0x00010000;   /* Enable PHY chip pb15 */
+
+#endif  // CYGONCE_DEVS_ADDERII_ETH_INL
+// ------------------------------------------------------------------------
Index: devs/eth/powerpc/viper/current/ChangeLog
===================================================================
RCS file: /misc/cvsfiles/ecos/packages/devs/eth/powerpc/viper/current/ChangeLog,v
retrieving revision 1.1
diff -u -5 -p -r1.1 ChangeLog
--- devs/eth/powerpc/viper/current/ChangeLog	3 Sep 2002 16:56:14 -0000	1.1
+++ devs/eth/powerpc/viper/current/ChangeLog	24 Mar 2003 21:51:50 -0000
@@ -1,5 +1,10 @@
+2003-03-24  Gary Thomas  <gary at mlbassoc dot com>
+
+	* cdl/viper_eth_drivers.cdl: Add constraint to make sure this is
+	only used with a Viper board.
+
 2002-09-03  Gary Thomas  <gary at mlbassoc dot com>
 
 	* include/viper_eth.inl: 
 	* cdl/viper_eth_drivers.cdl: New package - platform specifics for
 	PowerPC/FEC ethernet driver.
Index: devs/eth/powerpc/viper/current/cdl/viper_eth_drivers.cdl
===================================================================
RCS file: /misc/cvsfiles/ecos/packages/devs/eth/powerpc/viper/current/cdl/viper_eth_drivers.cdl,v
retrieving revision 1.1
diff -u -5 -p -r1.1 viper_eth_drivers.cdl
--- devs/eth/powerpc/viper/current/cdl/viper_eth_drivers.cdl	3 Sep 2002 16:56:14 -0000	1.1
+++ devs/eth/powerpc/viper/current/cdl/viper_eth_drivers.cdl	24 Mar 2003 21:51:51 -0000
@@ -7,11 +7,11 @@
 #====================================================================
 #####ECOSGPLCOPYRIGHTBEGIN####
 ## -------------------------------------------
 ## This file is part of eCos, the Embedded Configurable Operating System.
 ## Copyright (C) 1998, 1999, 2000, 2001, 2002 Red Hat, Inc.
-## Copyright (C) 2002 Gary Thomas
+## Copyright (C) 2002, 2003 Gary Thomas
 ##
 ## eCos is free software; you can redistribute it and/or modify it under
 ## the terms of the GNU General Public License as published by the Free
 ## Software Foundation; either version 2 or (at your option) any later version.
 ##
@@ -56,10 +56,12 @@ cdl_package CYGPKG_DEVS_ETH_POWERPC_VIPE
 
     parent        CYGPKG_IO_ETH_DRIVERS
     active_if	  CYGPKG_IO_ETH_DRIVERS
     active_if	  CYGPKG_HAL_POWERPC 
     active_if	  CYGPKG_HAL_POWERPC_MPC8xx
+
+    requires      CYGPKG_DEVS_ETH_POWERPC_FEC
 
     include_dir   cyg/io
 
     define_proc {
         puts $::cdl_system_header "#define CYGDAT_DEVS_FEC_ETH_INL <cyg/io/viper_eth.inl>"
Index: hal/powerpc/adder/current/ChangeLog
===================================================================
RCS file: /misc/cvsfiles/ecos/packages/hal/powerpc/adder/current/ChangeLog,v
retrieving revision 1.7
diff -u -5 -p -r1.7 ChangeLog
--- hal/powerpc/adder/current/ChangeLog	23 Mar 2003 16:22:13 -0000	1.7
+++ hal/powerpc/adder/current/ChangeLog	24 Mar 2003 21:54:15 -0000
@@ -1,5 +1,16 @@
+2003-03-24  Gary Thomas  <gary at mlbassoc dot com>
+
+	* misc/redboot_ROMRAM.ecm: Remove.
+
+	* misc/adder_redboot_ROMRAM.ecm: 
+	* misc/adderII_redboot_ROMRAM.ecm: New file(s), distinguish platforms.
+
+	* src/hal_aux.c: 
+	* src/adder.S: 
+	* cdl/hal_powerpc_adder.cdl: Update to support new platform - AdderII.
+
 2003-03-23  Gary Thomas  <gary at mlbassoc dot com>
 
 	* cdl/hal_powerpc_adder.cdl: New option for setting processor type.
 
 2003-03-20  Gary Thomas  <gary at mlbassoc dot com>
Index: hal/powerpc/adder/current/cdl/hal_powerpc_adder.cdl
===================================================================
RCS file: /misc/cvsfiles/ecos/packages/hal/powerpc/adder/current/cdl/hal_powerpc_adder.cdl,v
retrieving revision 1.4
diff -u -5 -p -r1.4 hal_powerpc_adder.cdl
--- hal/powerpc/adder/current/cdl/hal_powerpc_adder.cdl	23 Mar 2003 16:22:13 -0000	1.4
+++ hal/powerpc/adder/current/cdl/hal_powerpc_adder.cdl	24 Mar 2003 21:35:35 -0000
@@ -63,24 +63,56 @@ cdl_package CYGPKG_HAL_POWERPC_ADDER {
     compile       hal_diag.c hal_aux.c adder.S
 
     implements    CYGINT_HAL_DEBUG_GDB_STUBS
     implements    CYGINT_HAL_DEBUG_GDB_STUBS_BREAK
     implements    CYGINT_HAL_VIRTUAL_VECTOR_SUPPORT
-    implements    CYGNUM_HAL_QUICC_SMC2
-    implements    CYGNUM_HAL_QUICC_SCC3
-
-    requires      { CYGHWR_HAL_POWERPC_MPC8XX == "850" }
 
     define_proc {
         puts $::cdl_system_header "#define CYGBLD_HAL_TARGET_H   <pkgconf/hal_powerpc_mpc8xx.h>"
         puts $::cdl_system_header "#define CYGBLD_HAL_PLATFORM_H <pkgconf/hal_powerpc_adder.h>"
-
-	puts $::cdl_header "#define HAL_PLATFORM_CPU    \"PowerPC 850\""
-        puts $::cdl_header "#define HAL_PLATFORM_BOARD  \"A&M ADDER\""
         puts $::cdl_header "#define HAL_PLATFORM_EXTRA  \"\""
     }
 
+    cdl_component CYGPKG_HAL_POWERPC_ADDER_MODEL {
+        display       "Adder model"
+        requires      CYGHWR_HAL_POWERPC_ADDER_I | CYGHWR_HAL_POWERPC_ADDER_II
+        default_value 1
+        no_define
+        description "
+           The sub-options of this component define the model of Adder"
+
+        cdl_option  CYGHWR_HAL_POWERPC_ADDER_I {
+            display       "Adder-I with 850"
+            requires      !CYGHWR_HAL_POWERPC_ADDER_II
+            requires      { CYGHWR_HAL_POWERPC_MPC8XX == "850" }
+            default_value 0
+            implements    CYGNUM_HAL_QUICC_SMC2
+            implements    CYGNUM_HAL_QUICC_SCC3
+            define_proc {
+                puts $::cdl_header "#define HAL_PLATFORM_CPU    \"PowerPC 850\""
+                puts $::cdl_header "#define HAL_PLATFORM_BOARD  \"A&M ADDER\""
+            }
+            description "
+                Select this model for an Adder with the PPC850 processor."
+        }
+
+        cdl_option  CYGHWR_HAL_POWERPC_ADDER_II {
+            display       "Adder-I with 852T"
+            requires      !CYGHWR_HAL_POWERPC_ADDER_I
+            requires      { CYGHWR_HAL_POWERPC_MPC8XX == "852T" }
+            default_value 0
+            implements    CYGNUM_HAL_QUICC_SMC1
+#            implements    CYGNUM_HAL_QUICC_SCC3
+            define_proc {
+                puts $::cdl_header "#define HAL_PLATFORM_CPU    \"PowerPC 852T\""
+                puts $::cdl_header "#define HAL_PLATFORM_BOARD  \"A&M AdderII\""
+            }
+            description "
+                Select this model for an Adder with the PPC852T processor."
+        }
+    }
+
     cdl_component CYG_HAL_STARTUP {
         display       "Startup type"
         flavor        data
         legal_values  {"RAM" "ROM" "ROMRAM"}
         default_value {"RAM"}
@@ -88,18 +120,20 @@ cdl_package CYGPKG_HAL_POWERPC_ADDER {
 	define -file system.h CYG_HAL_STARTUP
         description   "
            This option is used to control where the application program will
            run, either from RAM or ROM (flash) memory.  ROM based applications
            must be self contained, while RAM applications will typically assume
-           the existence of a debug environment, such as GDB stubs."
+           the existence of a debug environment, such as RedBoot or GDB stubs."
     }
 
     cdl_option CYGHWR_HAL_POWERPC_BOARD_SPEED {
         display          "Development board clock speed (MHz)"
         flavor           data
-        legal_values     { 47 }
-        default_value    47
+        legal_values     { 47 48 50 100 }
+        default_value    { (CYGHWR_HAL_POWERPC_ADDER_I ? 47 : 48) }
+        requires         { (CYGHWR_HAL_POWERPC_ADDER_I && (CYGHWR_HAL_POWERPC_BOARD_SPEED == 47)) ||
+                           (CYGHWR_HAL_POWERPC_ADDER_II && (CYGHWR_HAL_POWERPC_BOARD_SPEED != 47)) }
         description      "
            ADDER Development Boards have various system clock speeds
            depending on the processor fitted.  Select the clock speed
            appropriate for your board so that the system can set the serial
            baud rate correctly, amongst other things."
@@ -199,10 +233,11 @@ cdl_package CYGPKG_HAL_POWERPC_ADDER {
     }
 
     cdl_component CYGPKG_HAL_POWERPC_ADDER_OPTIONS {
         display "ADDER build options"
         flavor  none
+        no_define
         description   "
 	    Package specific build options including control over
 	    compiler flags used only in building this package,
 	    and details of which tests are built."
 
Index: hal/powerpc/adder/current/misc/adderII_redboot_ROMRAM.ecm
===================================================================
RCS file: hal/powerpc/adder/current/misc/adderII_redboot_ROMRAM.ecm
diff -N hal/powerpc/adder/current/misc/adderII_redboot_ROMRAM.ecm
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ hal/powerpc/adder/current/misc/adderII_redboot_ROMRAM.ecm	24 Mar 2003 21:41:11 -0000
@@ -0,0 +1,118 @@
+cdl_savefile_version 1;
+cdl_savefile_command cdl_savefile_version {};
+cdl_savefile_command cdl_savefile_command {};
+cdl_savefile_command cdl_configuration { description hardware template package };
+cdl_savefile_command cdl_package { value_source user_value wizard_value inferred_value };
+cdl_savefile_command cdl_component { value_source user_value wizard_value inferred_value };
+cdl_savefile_command cdl_option { value_source user_value wizard_value inferred_value };
+cdl_savefile_command cdl_interface { value_source user_value wizard_value inferred_value };
+
+cdl_configuration eCos {
+    description "" ;
+    hardware    adderII ;
+    template    redboot ;
+    package -hardware CYGPKG_HAL_POWERPC current ;
+    package -hardware CYGPKG_HAL_POWERPC_MPC8xx current ;
+    package -hardware CYGPKG_HAL_POWERPC_ADDER current ;
+    package -hardware CYGPKG_HAL_QUICC current ;
+    package -hardware CYGPKG_DEVS_FLASH_POWERPC_ADDER current ;
+    package -hardware CYGPKG_DEVS_FLASH_AMD_AM29XXXXX current ;
+    package -hardware CYGPKG_DEVS_ETH_POWERPC_FEC current ;
+    package -hardware CYGPKG_DEVS_ETH_POWERPC_ADDERII current ;
+    package -hardware CYGPKG_IO_SERIAL_POWERPC_QUICC_SMC current ;
+    package -template CYGPKG_HAL current ;
+    package -template CYGPKG_INFRA current ;
+    package -template CYGPKG_REDBOOT current ;
+    package -template CYGPKG_ISOINFRA current ;
+    package -template CYGPKG_LIBC_STRING current ;
+    package -template CYGPKG_NS_DNS current ;
+    package -template CYGPKG_CRC current ;
+    package CYGPKG_IO_FLASH current ;
+    package CYGPKG_IO_ETH_DRIVERS current ;
+};
+
+cdl_option CYGFUN_LIBC_STRING_BSD_FUNCS {
+    inferred_value 0
+};
+
+cdl_option CYGNUM_HAL_COMMON_INTERRUPTS_STACK_SIZE {
+    user_value 4096
+};
+
+cdl_option CYGDBG_HAL_COMMON_INTERRUPTS_SAVE_MINIMUM_CONTEXT {
+    user_value 0
+};
+
+cdl_option CYGDBG_HAL_COMMON_CONTEXT_SAVE_MINIMUM {
+    inferred_value 0
+};
+
+cdl_option CYGDBG_HAL_DEBUG_GDB_INCLUDE_STUBS {
+    inferred_value 1
+};
+
+cdl_option CYGSEM_HAL_ROM_MONITOR {
+    inferred_value 1
+};
+
+cdl_component CYGHWR_HAL_POWERPC_MPC8XX {
+    inferred_value 852T
+};
+
+cdl_option CYGHWR_HAL_POWERPC_ADDER_II {
+    user_value 1
+};
+
+cdl_component CYG_HAL_STARTUP {
+    user_value ROMRAM
+};
+
+cdl_component CYGBLD_BUILD_REDBOOT {
+    user_value 1
+};
+
+cdl_option CYGBLD_REDBOOT_MIN_IMAGE_SIZE {
+    user_value 0x00030000
+};
+
+cdl_option CYGOPT_REDBOOT_FIS_REDBOOT_BACKUP {
+    user_value 0
+};
+
+cdl_option CYGSEM_REDBOOT_FLASH_COMBINED_FIS_AND_CONFIG {
+    user_value 1
+};
+
+cdl_option CYGBLD_ISO_STRTOK_R_HEADER {
+    inferred_value 1 <cyg/libc/string/string.h>
+};
+
+cdl_option CYGBLD_ISO_STRING_LOCALE_FUNCS_HEADER {
+    inferred_value 1 <cyg/libc/string/string.h>
+};
+
+cdl_option CYGBLD_ISO_STRING_BSD_FUNCS_HEADER {
+    inferred_value 1 <cyg/libc/string/bsdstring.h>
+};
+
+cdl_option CYGBLD_ISO_STRING_MEMFUNCS_HEADER {
+    inferred_value 1 <cyg/libc/string/string.h>
+};
+
+cdl_option CYGBLD_ISO_STRING_STRFUNCS_HEADER {
+    inferred_value 1 <cyg/libc/string/string.h>
+};
+
+cdl_option CYGBLD_ISO_DNS_HEADER {
+    inferred_value 1 <cyg/ns/dns/dns.h>
+};
+
+cdl_option CYGPKG_NS_DNS_BUILD {
+    inferred_value 0
+};
+
+cdl_option CYGHWR_DEVS_FLASH_AMD_AM29LV320D {
+    inferred_value 1
+};
+
+
Index: hal/powerpc/adder/current/misc/adder_redboot_ROMRAM.ecm
===================================================================
RCS file: hal/powerpc/adder/current/misc/adder_redboot_ROMRAM.ecm
diff -N hal/powerpc/adder/current/misc/adder_redboot_ROMRAM.ecm
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ hal/powerpc/adder/current/misc/adder_redboot_ROMRAM.ecm	24 Mar 2003 21:42:22 -0000
@@ -0,0 +1,118 @@
+cdl_savefile_version 1;
+cdl_savefile_command cdl_savefile_version {};
+cdl_savefile_command cdl_savefile_command {};
+cdl_savefile_command cdl_configuration { description hardware template package };
+cdl_savefile_command cdl_package { value_source user_value wizard_value inferred_value };
+cdl_savefile_command cdl_component { value_source user_value wizard_value inferred_value };
+cdl_savefile_command cdl_option { value_source user_value wizard_value inferred_value };
+cdl_savefile_command cdl_interface { value_source user_value wizard_value inferred_value };
+
+cdl_configuration eCos {
+    description "" ;
+    hardware    adder ;
+    template    redboot ;
+    package -hardware CYGPKG_HAL_POWERPC current ;
+    package -hardware CYGPKG_HAL_POWERPC_MPC8xx current ;
+    package -hardware CYGPKG_HAL_POWERPC_ADDER current ;
+    package -hardware CYGPKG_HAL_QUICC current ;
+    package -hardware CYGPKG_DEVS_FLASH_POWERPC_ADDER current ;
+    package -hardware CYGPKG_DEVS_FLASH_AMD_AM29XXXXX current ;
+    package -hardware CYGPKG_DEVS_ETH_POWERPC_QUICC current ;
+    package -hardware CYGPKG_DEVS_ETH_POWERPC_ADDER current ;
+    package -hardware CYGPKG_IO_SERIAL_POWERPC_QUICC_SMC current ;
+    package -template CYGPKG_HAL current ;
+    package -template CYGPKG_INFRA current ;
+    package -template CYGPKG_REDBOOT current ;
+    package -template CYGPKG_ISOINFRA current ;
+    package -template CYGPKG_LIBC_STRING current ;
+    package -template CYGPKG_NS_DNS current ;
+    package -template CYGPKG_CRC current ;
+    package CYGPKG_IO_FLASH current ;
+    package CYGPKG_IO_ETH_DRIVERS current ;
+};
+
+cdl_option CYGFUN_LIBC_STRING_BSD_FUNCS {
+    inferred_value 0
+};
+
+cdl_option CYGNUM_HAL_COMMON_INTERRUPTS_STACK_SIZE {
+    user_value 4096
+};
+
+cdl_option CYGDBG_HAL_COMMON_INTERRUPTS_SAVE_MINIMUM_CONTEXT {
+    user_value 0
+};
+
+cdl_option CYGDBG_HAL_COMMON_CONTEXT_SAVE_MINIMUM {
+    inferred_value 0
+};
+
+cdl_option CYGDBG_HAL_DEBUG_GDB_INCLUDE_STUBS {
+    inferred_value 1
+};
+
+cdl_option CYGSEM_HAL_ROM_MONITOR {
+    inferred_value 1
+};
+
+cdl_component CYGHWR_HAL_POWERPC_MPC8XX {
+    inferred_value 850
+};
+
+cdl_option CYGHWR_HAL_POWERPC_ADDER_I {
+    inferred_value 1
+};
+
+cdl_component CYG_HAL_STARTUP {
+    user_value ROMRAM
+};
+
+cdl_component CYGBLD_BUILD_REDBOOT {
+    user_value 1
+};
+
+cdl_option CYGBLD_REDBOOT_MIN_IMAGE_SIZE {
+    user_value 0x00030000
+};
+
+cdl_option CYGOPT_REDBOOT_FIS_REDBOOT_BACKUP {
+    user_value 0
+};
+
+cdl_option CYGSEM_REDBOOT_FLASH_COMBINED_FIS_AND_CONFIG {
+    user_value 1
+};
+
+cdl_option CYGBLD_ISO_STRTOK_R_HEADER {
+    inferred_value 1 <cyg/libc/string/string.h>
+};
+
+cdl_option CYGBLD_ISO_STRING_LOCALE_FUNCS_HEADER {
+    inferred_value 1 <cyg/libc/string/string.h>
+};
+
+cdl_option CYGBLD_ISO_STRING_BSD_FUNCS_HEADER {
+    inferred_value 1 <cyg/libc/string/bsdstring.h>
+};
+
+cdl_option CYGBLD_ISO_STRING_MEMFUNCS_HEADER {
+    inferred_value 1 <cyg/libc/string/string.h>
+};
+
+cdl_option CYGBLD_ISO_STRING_STRFUNCS_HEADER {
+    inferred_value 1 <cyg/libc/string/string.h>
+};
+
+cdl_option CYGBLD_ISO_DNS_HEADER {
+    inferred_value 1 <cyg/ns/dns/dns.h>
+};
+
+cdl_option CYGPKG_NS_DNS_BUILD {
+    inferred_value 0
+};
+
+cdl_option CYGHWR_DEVS_FLASH_AMD_AM29LV320D {
+    inferred_value 1
+};
+
+
Index: hal/powerpc/adder/current/misc/redboot_ROMRAM.ecm
===================================================================
RCS file: hal/powerpc/adder/current/misc/redboot_ROMRAM.ecm
diff -N hal/powerpc/adder/current/misc/redboot_ROMRAM.ecm
--- hal/powerpc/adder/current/misc/redboot_ROMRAM.ecm	23 Mar 2003 16:22:13 -0000	1.3
+++ /dev/null	1 Jan 1970 00:00:00 -0000
@@ -1,114 +0,0 @@
-cdl_savefile_version 1;
-cdl_savefile_command cdl_savefile_version {};
-cdl_savefile_command cdl_savefile_command {};
-cdl_savefile_command cdl_configuration { description hardware template package };
-cdl_savefile_command cdl_package { value_source user_value wizard_value inferred_value };
-cdl_savefile_command cdl_component { value_source user_value wizard_value inferred_value };
-cdl_savefile_command cdl_option { value_source user_value wizard_value inferred_value };
-cdl_savefile_command cdl_interface { value_source user_value wizard_value inferred_value };
-
-cdl_configuration eCos {
-    description "" ;
-    hardware    adder ;
-    template    redboot ;
-    package -hardware CYGPKG_HAL_POWERPC current ;
-    package -hardware CYGPKG_HAL_POWERPC_MPC8xx current ;
-    package -hardware CYGPKG_HAL_POWERPC_ADDER current ;
-    package -hardware CYGPKG_HAL_QUICC current ;
-    package -hardware CYGPKG_DEVS_FLASH_POWERPC_ADDER current ;
-    package -hardware CYGPKG_DEVS_FLASH_AMD_AM29XXXXX current ;
-    package -hardware CYGPKG_DEVS_ETH_POWERPC_QUICC current ;
-    package -hardware CYGPKG_DEVS_ETH_POWERPC_ADDER current ;
-    package -hardware CYGPKG_IO_SERIAL_POWERPC_QUICC_SMC current ;
-    package -template CYGPKG_HAL current ;
-    package -template CYGPKG_INFRA current ;
-    package -template CYGPKG_REDBOOT current ;
-    package -template CYGPKG_ISOINFRA current ;
-    package -template CYGPKG_LIBC_STRING current ;
-    package -template CYGPKG_NS_DNS current ;
-    package -template CYGPKG_CRC current ;
-    package CYGPKG_IO_FLASH current ;
-    package CYGPKG_IO_ETH_DRIVERS current ;
-};
-
-cdl_option CYGFUN_LIBC_STRING_BSD_FUNCS {
-    inferred_value 0
-};
-
-cdl_option CYGNUM_HAL_COMMON_INTERRUPTS_STACK_SIZE {
-    user_value 4096
-};
-
-cdl_option CYGDBG_HAL_COMMON_INTERRUPTS_SAVE_MINIMUM_CONTEXT {
-    user_value 0
-};
-
-cdl_option CYGDBG_HAL_COMMON_CONTEXT_SAVE_MINIMUM {
-    inferred_value 0
-};
-
-cdl_option CYGDBG_HAL_DEBUG_GDB_INCLUDE_STUBS {
-    inferred_value 1
-};
-
-cdl_option CYGSEM_HAL_ROM_MONITOR {
-    inferred_value 1
-};
-
-cdl_component CYGHWR_HAL_POWERPC_MPC8XX {
-    inferred_value 850
-};
-
-cdl_component CYG_HAL_STARTUP {
-    user_value ROMRAM
-};
-
-cdl_component CYGBLD_BUILD_REDBOOT {
-    user_value 1
-};
-
-cdl_option CYGBLD_REDBOOT_MIN_IMAGE_SIZE {
-    user_value 0x00030000
-};
-
-cdl_option CYGOPT_REDBOOT_FIS_REDBOOT_BACKUP {
-    user_value 0
-};
-
-cdl_option CYGSEM_REDBOOT_FLASH_COMBINED_FIS_AND_CONFIG {
-    user_value 1
-};
-
-cdl_option CYGBLD_ISO_STRTOK_R_HEADER {
-    inferred_value 1 <cyg/libc/string/string.h>
-};
-
-cdl_option CYGBLD_ISO_STRING_LOCALE_FUNCS_HEADER {
-    inferred_value 1 <cyg/libc/string/string.h>
-};
-
-cdl_option CYGBLD_ISO_STRING_BSD_FUNCS_HEADER {
-    inferred_value 1 <cyg/libc/string/bsdstring.h>
-};
-
-cdl_option CYGBLD_ISO_STRING_MEMFUNCS_HEADER {
-    inferred_value 1 <cyg/libc/string/string.h>
-};
-
-cdl_option CYGBLD_ISO_STRING_STRFUNCS_HEADER {
-    inferred_value 1 <cyg/libc/string/string.h>
-};
-
-cdl_option CYGBLD_ISO_DNS_HEADER {
-    inferred_value 1 <cyg/ns/dns/dns.h>
-};
-
-cdl_option CYGPKG_NS_DNS_BUILD {
-    inferred_value 0
-};
-
-cdl_option CYGHWR_DEVS_FLASH_AMD_AM29LV320D {
-    inferred_value 1
-};
-
-
Index: hal/powerpc/adder/current/src/adder.S
===================================================================
RCS file: /misc/cvsfiles/ecos/packages/hal/powerpc/adder/current/src/adder.S,v
retrieving revision 1.1
diff -u -5 -p -r1.1 adder.S
--- hal/powerpc/adder/current/src/adder.S	25 Nov 2002 23:18:44 -0000	1.1
+++ hal/powerpc/adder/current/src/adder.S	24 Mar 2003 21:38:56 -0000
@@ -7,11 +7,11 @@
 ##=============================================================================
 #####ECOSGPLCOPYRIGHTBEGIN####
 ## -------------------------------------------
 ## This file is part of eCos, the Embedded Configurable Operating System.
 ## Copyright (C) 1998, 1999, 2000, 2001, 2002 Red Hat, Inc.
-## Copyright (C) 2002 Gary Thomas
+## Copyright (C) 2002, 2003 Gary Thomas
 ##
 ## eCos is free software; you can redistribute it and/or modify it under
 ## the terms of the GNU General Public License as published by the Free
 ## Software Foundation; either version 2 or (at your option) any later version.
 ##
@@ -243,30 +243,26 @@ FUNC_START( hal_hardware_init )
 
 //        
 // PTA field is (System Clock in MHz * Refresh rate in us) / Prescale
 // e.g.  ((14*3.6864)*62.5)/32 => 100.8 => 101        
 //                
+#if defined(CYGHWR_HAL_POWERPC_MPC8XX_852T)
+#if (CYGHWR_HAL_POWERPC_BOARD_SPEED == 48)
+#define PLPRCR_VALUE 0x32594000 // MFI=9 MFN=6 MFD=9 PDF=0 S=1 OSCLK=10MEG
+#define MAMR_PTA 93 //sysclk * 62.5e-6 /32
+#endif
+#if (CYGHWR_HAL_POWERPC_BOARD_SPEED == 50)
+#define PLPRCR_VALUE 0xD05A4000 // MFI=10 MFN=0 MFD=1 PDF=0 S=1 OSCLK=10MEG
+#define MAMR_PTA 97 //sysclk * 62.5e-6 /32
+#endif
+#else        
 #if (CYGHWR_HAL_POWERPC_BOARD_SPEED == 47)
-#define PLPRCR_PTX 0x00C // (47MHz/3.6864MHz)-1
+#define PLPRCR_VALUE 0x00C04000 // MFI=9 MFN=6 MFD=9 PDF=0 S=1 OSCLK=10MEG
 #define MAMR_PTA 94        
 #endif        
-#if (CYGHWR_HAL_POWERPC_BOARD_SPEED == 51)
-#define PLPRCR_PTX 0x00D // (51.6MHz/3.6864MHz)-1
-#define MAMR_PTA 101
-#endif        
-#if (CYGHWR_HAL_POWERPC_BOARD_SPEED == 55)
-#define PLPRCR_PTX 0x00E // (55.3MHz/3.6864MHz)-1
-#define MAMR_PTA 108
-#endif        
-#if (CYGHWR_HAL_POWERPC_BOARD_SPEED == 59)
-#define PLPRCR_PTX 0x00F // (58.9MHz/3.6864MHz)-1
-#define MAMR_PTA 116
-#endif        
-#if (CYGHWR_HAL_POWERPC_BOARD_SPEED == 63)
-#define PLPRCR_PTX 0x010 // (62.7MHz/3.6864MHz)-1
-#define MAMR_PTA 123
-#endif        
+#endif
+
 //#define MAMR_PTA (((((((PLPRCR_PTX+1)*3686400)*625)/10000000)+31)/32)&0xFF)
         lwi     r3,0x00802114|(MAMR_PTA<<24)
         stw	r3,MAMR(r4)
         stw	r3,MBMR(r4)
 
@@ -362,11 +358,12 @@ FUNC_START( hal_hardware_init )
 // 	Field CSR (bit 24) = 0
 // 	Field LOLRE (bit 25) = 0
 // 	Field FIOPD (bit 26) = 0
 // 	Field Reserved (bits 27-31) = 0
 	 */
-	lwi	r3,0x04000|(PLPRCR_PTX<<20)
+//	lwi	r3,0x04000|(PLPRCR_PTX<<20)
+	lwi	r3,PLPRCR_VALUE
 	stw	r3,PLPRCR(r4)
 
 	lwi	r3,0x40000
 	mtctr	r3
 10:	nop
@@ -429,11 +426,10 @@ FUNC_START( hal_hardware_init )
         addi    r6,r6,4
         addi    r7,r7,4
         cmplw   r7,r8
         bne     10b
 #endif                
-
 	blr
 FUNC_END( hal_hardware_init )
 

 #ifdef CYGPRI_DO_PROGRAM_UPMS
Index: hal/powerpc/adder/current/src/hal_aux.c
===================================================================
RCS file: /misc/cvsfiles/ecos/packages/hal/powerpc/adder/current/src/hal_aux.c,v
retrieving revision 1.2
diff -u -5 -p -r1.2 hal_aux.c
--- hal/powerpc/adder/current/src/hal_aux.c	23 Mar 2003 01:56:20 -0000	1.2
+++ hal/powerpc/adder/current/src/hal_aux.c	24 Mar 2003 21:53:38 -0000
@@ -7,11 +7,11 @@
 //=============================================================================
 //####ECOSGPLCOPYRIGHTBEGIN####
 // -------------------------------------------
 // This file is part of eCos, the Embedded Configurable Operating System.
 // Copyright (C) 1998, 1999, 2000, 2001, 2002 Red Hat, Inc.
-// Copyright (C) 2002 Gary Thomas
+// Copyright (C) 2002, 2003 Gary Thomas
 //
 // eCos is free software; you can redistribute it and/or modify it under
 // the terms of the GNU General Public License as published by the Free
 // Software Foundation; either version 2 or (at your option) any later version.
 //
@@ -93,10 +93,11 @@ hal_platform_init(void)
     hal_if_init();
 
     _adder_set_leds(0x1);
 }
 
+#ifdef CYGHWR_HAL_POWERPC_ADDER_I
 void
 _adder_set_leds(int pat)
 {
     volatile EPPC *eppc = (volatile EPPC *)eppc_base();
 
@@ -108,7 +109,26 @@ _adder_get_leds(void)
 {
     volatile EPPC *eppc = (volatile EPPC *)eppc_base();
 
     return ((eppc->pip_pbdat & 0x0000000E) >> 1);
 }
+#endif
+
+#ifdef CYGHWR_HAL_POWERPC_ADDER_II
+void
+_adder_set_leds(int pat)
+{
+    volatile EPPC *eppc = (volatile EPPC *)eppc_base();
+
+    eppc->pip_pbdat = (eppc->pip_pbdat & ~0x00000007) |(~(pat&0x0007) );
+}
+
+int
+_adder_get_leds(void)
+{
+    volatile EPPC *eppc = (volatile EPPC *)eppc_base();
+
+    return ((~(eppc->pip_pbdat & 0x00000007)) & 0x0007 );
+}
+#endif
 
 // EOF hal_aux.c


-- 
------------------------------------------------------------
Gary Thomas                 |
MLB Associates              |  Consulting for the
+1 (970) 229-1963           |    Embedded world
http://www.mlbassoc.com/    |
email: <gary at mlbassoc dot com>  |
gpg: http://www.chez-thomas.org/gary/gpg_key.asc
------------------------------------------------------------


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]