# HG changeset patch # User msalter # Date 1048731260 0 # Node ID 597965679adf594c0975a8781f7010572a9be8c4 # Parent 4f1b647b74e00b892ffb5c3d94671f6174b4e901 ixdp425 tweak diff --git a/packages/hal/arm/xscale/ixdp425/current/ChangeLog b/packages/hal/arm/xscale/ixdp425/current/ChangeLog --- a/packages/hal/arm/xscale/ixdp425/current/ChangeLog +++ b/packages/hal/arm/xscale/ixdp425/current/ChangeLog @@ -1,3 +1,10 @@ +2003-03-26 Mark Salter + + * 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 * misc/redboot_ROM.ecm: Fix linux exec address. diff --git a/packages/hal/arm/xscale/ixdp425/current/include/hal_plf_ints.h b/packages/hal/arm/xscale/ixdp425/current/include/hal_plf_ints.h --- a/packages/hal/arm/xscale/ixdp425/current/include/hal_plf_ints.h +++ b/packages/hal/arm/xscale/ixdp425/current/include/hal_plf_ints.h @@ -10,7 +10,7 @@ //####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 @@ -57,6 +57,9 @@ // 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 diff --git a/packages/hal/arm/xscale/ixdp425/current/src/ixdp425_misc.c b/packages/hal/arm/xscale/ixdp425/current/src/ixdp425_misc.c --- a/packages/hal/arm/xscale/ixdp425/current/src/ixdp425_misc.c +++ b/packages/hal/arm/xscale/ixdp425/current/src/ixdp425_misc.c @@ -8,7 +8,7 @@ //####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 @@ -75,10 +75,28 @@ 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); } // ------------------------------------------------------------------------