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]

ixdp425 tweak


Index: hal/arm/xscale/ixdp425/current/ChangeLog
===================================================================
RCS file: /cvs/ecos/ecos/packages/hal/arm/xscale/ixdp425/current/ChangeLog,v
retrieving revision 1.1
diff -u -p -5 -r1.1 ChangeLog
--- hal/arm/xscale/ixdp425/current/ChangeLog	18 Mar 2003 13:10:03 -0000	1.1
+++ hal/arm/xscale/ixdp425/current/ChangeLog	27 Mar 2003 02:05:47 -0000
@@ -1,5 +1,12 @@
+2003-03-26  Mark Salter  <msalter at redhat dot com>
+
+	* src/ixdp425_misc.c (plf_hardware_init): Set up NPE PHY chip
+	selects and clocks.
+
+	* include/hal_plf_ints.h: Define interrupts for NPE PHYs.
+
 2003-02-22  Mark Salter  <msalter at redhat dot com>
 
 	* misc/redboot_ROM.ecm: Fix linux exec address.
 	* misc/redboot_RAM.ecm: Ditto
 
Index: hal/arm/xscale/ixdp425/current/include/hal_plf_ints.h
===================================================================
RCS file: /cvs/ecos/ecos/packages/hal/arm/xscale/ixdp425/current/include/hal_plf_ints.h,v
retrieving revision 1.1
diff -u -p -5 -r1.1 hal_plf_ints.h
--- hal/arm/xscale/ixdp425/current/include/hal_plf_ints.h	18 Mar 2003 13:10:03 -0000	1.1
+++ hal/arm/xscale/ixdp425/current/include/hal_plf_ints.h	27 Mar 2003 02:05:47 -0000
@@ -8,11 +8,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) 1998, 1999, 2000, 2001, 2002, 2003 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.
 //
@@ -54,10 +54,13 @@
 //
 //==========================================================================
 
 // start with variant ints
 #include CYGBLD_HAL_VAR_INTS_H
+
+#define CYGNUM_HAL_INTERRUPT_NPEB_PHY CYGNUM_HAL_INTERRUPT_GPIO4
+#define CYGNUM_HAL_INTERRUPT_NPEC_PHY CYGNUM_HAL_INTERRUPT_GPIO5
 
 // NB: Commented out because of errata on reset function of watchdog timer
 //
 #if 0
 #define HAL_PLATFORM_RESET()                                          \
Index: hal/arm/xscale/ixdp425/current/src/ixdp425_misc.c
===================================================================
RCS file: /cvs/ecos/ecos/packages/hal/arm/xscale/ixdp425/current/src/ixdp425_misc.c,v
retrieving revision 1.1
diff -u -p -5 -r1.1 ixdp425_misc.c
--- hal/arm/xscale/ixdp425/current/src/ixdp425_misc.c	18 Mar 2003 13:10:04 -0000	1.1
+++ hal/arm/xscale/ixdp425/current/src/ixdp425_misc.c	27 Mar 2003 02:06:19 -0000
@@ -6,11 +6,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) 1998, 1999, 2000, 2001, 2002, 2003 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.
 //
@@ -73,13 +73,31 @@
 //
 
 void
 plf_hardware_init(void)
 {
+    // GPIO(15) used for ENET clock
+    HAL_GPIO_OUTPUT_ENABLE(15);
+    *IXP425_GPCLKR |= GPCLKR_CLK1_ENABLE;
+    *IXP425_GPCLKR |= GPCLKR_CLK1_PCLK2;
+
+    // ENET-0 IRQ line
+    HAL_GPIO_OUTPUT_DISABLE(4);
+    HAL_INTERRUPT_CONFIGURE(CYGNUM_HAL_INTERRUPT_GPIO4, 1, 0);
+
+    // ENET-1 IRQ line
+    HAL_GPIO_OUTPUT_DISABLE(5);
+    HAL_INTERRUPT_CONFIGURE(CYGNUM_HAL_INTERRUPT_GPIO5, 1, 0);
+
 #ifdef CYGPKG_IO_PCI
     extern void hal_plf_pci_init(void);
     hal_plf_pci_init();
 #endif
+
+    *IXP425_EXP_CS4 = (EXP_ADDR_T(3) | EXP_SETUP_T(3) | EXP_STROBE_T(15) | EXP_HOLD_T(3) | \
+		       EXP_RECOVERY_T(15) | EXP_SZ_512 | EXP_WR_EN | EXP_CS_EN);
+    *IXP425_EXP_CS5 = (EXP_ADDR_T(3) | EXP_SETUP_T(3) | EXP_STROBE_T(15) | EXP_HOLD_T(3) | \
+		       EXP_RECOVERY_T(15) | EXP_SZ_512 | EXP_WR_EN | EXP_CS_EN);
 }
 
 // ------------------------------------------------------------------------
 // EOF ixdp425_misc.c


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