This is the mail archive of the
ecos-patches@sources.redhat.com
mailing list for the eCos project.
MPC852T - restructure parallel port initializations
- From: Gary Thomas <gary at mlbassoc dot com>
- To: eCos patches <ecos-patches at ecos dot sourceware dot org>
- Date: Thu, 16 Sep 2004 17:24:41 -0600
- Subject: MPC852T - restructure parallel port initializations
- Organization: MLB Associates
--
Gary Thomas <gary@mlbassoc.com>
MLB Associates
Index: hal/powerpc/adder/current/ChangeLog
===================================================================
RCS file: /misc/cvsfiles/ecos/packages/hal/powerpc/adder/current/ChangeLog,v
retrieving revision 1.16
diff -u -5 -p -r1.16 ChangeLog
--- hal/powerpc/adder/current/ChangeLog 21 Dec 2003 13:41:17 -0000 1.16
+++ hal/powerpc/adder/current/ChangeLog 16 Sep 2004 23:22:41 -0000
@@ -1,5 +1,11 @@
+2004-09-16 Gary Thomas <gary@mlbassoc.com>
+
+ * src/hal_aux.c (hal_platform_init): Move parallel port initializations
+ from variant here (comment says they are required re: errata, but no
+ supporting documentation is known)
+
2003-12-21 Gary Thomas <gary@mlbassoc.com>
* src/adder.S: Only clear caches on non-RAM startup modes. This fixes
some problems when using network debug connections (messing with the
caches seems to confuse the CPM)
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.4
diff -u -5 -p -r1.4 hal_aux.c
--- hal/powerpc/adder/current/src/hal_aux.c 16 Apr 2003 16:04:22 -0000 1.4
+++ hal/powerpc/adder/current/src/hal_aux.c 16 Sep 2004 23:22:43 -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, 2003 Gary Thomas
+// Copyright (C) 2002, 2003, 2004 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.
//
@@ -91,10 +91,24 @@ hal_platform_init(void)
eppc->pip_pbdir |= 0x0000400E;
eppc->pip_pbdat = 0x00004000;
#endif
#if defined(CYGHWR_HAL_POWERPC_ADDER_II)
+
+#if defined(CYGHWR_HAL_POWERPC_MPC8XX_852T)
+ // Special settings - according to manual errata
+ eppc->pio_papar &= ~0xffffffff; // PA manatory settings
+ eppc->pio_padir |= 0xffffffff;
+
+ eppc->pip_pbpar &= ~0x0003ff07; // PB29..31 AS GPIO
+ eppc->pip_pbdir |= 0x0003ff07;
+ eppc->pip_pbdat = 0x00010007;
+
+ eppc->pio_pcpar &= ~0xffffffff; // PC manatory settings
+ eppc->pio_pcdir |= 0xffffffff;
+#endif
+
eppc->pip_pbpar &= ~0x00000007; // PB29..31 AS GPIO for LEDS
eppc->pip_pbdir |= 0x00000007;
eppc->pip_pbdat |= 0x00000007;
#endif
Index: hal/powerpc/mpc8xx/current/ChangeLog
===================================================================
RCS file: /misc/cvsfiles/ecos/packages/hal/powerpc/mpc8xx/current/ChangeLog,v
retrieving revision 1.35
diff -u -5 -p -r1.35 ChangeLog
--- hal/powerpc/mpc8xx/current/ChangeLog 22 Apr 2004 15:26:50 -0000 1.35
+++ hal/powerpc/mpc8xx/current/ChangeLog 16 Sep 2004 23:23:28 -0000
@@ -1,5 +1,10 @@
+2004-09-16 Gary Thomas <gary@mlbassoc.com>
+
+ * src/var_misc.c (hal_variant_init): Remove [possibly incorrect]
+ parallel port initializations - leave them to the platform.
+
2004-04-22 Jani Monoses <jani@iv.ro>
* cdl/hal_powerpc_mpc8xx.cdl :
Invoke tail with stricter syntax that works in latest coreutils.
Index: hal/powerpc/mpc8xx/current/src/var_misc.c
===================================================================
RCS file: /misc/cvsfiles/ecos/packages/hal/powerpc/mpc8xx/current/src/var_misc.c,v
retrieving revision 1.16
diff -u -5 -p -r1.16 var_misc.c
--- hal/powerpc/mpc8xx/current/src/var_misc.c 19 Aug 2003 17:29:47 -0000 1.16
+++ hal/powerpc/mpc8xx/current/src/var_misc.c 16 Sep 2004 23:23:28 -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, 2003 Gary Thomas
+// Copyright (C) 2002, 2003, 2004 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.
//
@@ -64,33 +64,17 @@
//--------------------------------------------------------------------------
void
hal_variant_init(void)
{
-#if defined(CYGHWR_HAL_POWERPC_MPC8XX_852T)
- volatile EPPC *eppc = (volatile EPPC *)eppc_base();
-#endif
// Disable serialization
{
cyg_uint32 ictrl;
CYGARC_MFSPR (ICTRL, ictrl);
ictrl |= ICTRL_NOSERSHOW;
CYGARC_MTSPR (ICTRL, ictrl);
}
-
-#if defined(CYGHWR_HAL_POWERPC_MPC8XX_852T)
- // Special settings - according to manual errata
- eppc->pio_papar &= ~0xffffffff; // PA manatory settings
- eppc->pio_padir |= 0xffffffff;
-
- eppc->pip_pbpar &= ~0x0003ff07; // PB29..31 AS GPIO
- eppc->pip_pbdir |= 0x0003ff07;
- eppc->pip_pbdat = 0x00010007;
-
- eppc->pio_pcpar &= ~0xffffffff; // PC manatory settings
- eppc->pio_pcdir |= 0xffffffff;
-#endif
#ifndef CYGSEM_HAL_USE_ROM_MONITOR
// Reset CPM
_mpc8xx_reset_cpm();
#endif