Skip to content
Snippets Groups Projects
Commit f4b6f45d authored by Wolfgang Denk's avatar Wolfgang Denk
Browse files

Merge branch 'master' of git://git.denx.de/u-boot-ixp

parents a87fb1b3 930590f3
No related branches found
No related tags found
No related merge requests found
Showing with 49 additions and 46 deletions
...@@ -3021,8 +3021,7 @@ Some configuration options can be set using Environment Variables: ...@@ -3021,8 +3021,7 @@ Some configuration options can be set using Environment Variables:
Useful on scripts which control the retry operation Useful on scripts which control the retry operation
themselves. themselves.
npe_ucode - see CONFIG_IXP4XX_NPE_EXT_UCOD npe_ucode - set load address for the NPE microcode
if set load address for the NPE microcode
tftpsrcport - If this is set, the value is used for TFTP's tftpsrcport - If this is set, the value is used for TFTP's
UDP source port. UDP source port.
......
...@@ -26,10 +26,14 @@ include $(TOPDIR)/config.mk ...@@ -26,10 +26,14 @@ include $(TOPDIR)/config.mk
LIB = $(obj)lib$(CPU).a LIB = $(obj)lib$(CPU).a
START = start.o START = start.o
COBJS = serial.o interrupts.o cpu.o timer.o pci.o COBJS-y += cpu.o
COBJS-y += interrupts.o
SRCS := $(START:.o=.S) $(SOBJS:.o=.S) $(COBJS:.o=.c) ifndef CONFIG_USE_IRQ
OBJS := $(addprefix $(obj),$(SOBJS) $(COBJS)) COBJS-y += timer.o
endif
SRCS := $(START:.o=.S) $(SOBJS-y:.o=.S) $(COBJS-y:.o=.c)
OBJS := $(addprefix $(obj),$(SOBJS-y) $(COBJS-y))
START := $(addprefix $(obj),$(START)) START := $(addprefix $(obj),$(START))
all: $(obj).depend $(START) $(LIB) all: $(obj).depend $(START) $(LIB)
......
...@@ -86,9 +86,6 @@ int cpu_init (void) ...@@ -86,9 +86,6 @@ int cpu_init (void)
FIQ_STACK_START = IRQ_STACK_START - CONFIG_STACKSIZE_IRQ; FIQ_STACK_START = IRQ_STACK_START - CONFIG_STACKSIZE_IRQ;
#endif #endif
#if defined(CONFIG_CMD_PCI) || defined (CONFIG_PCI)
pci_init();
#endif
return 0; return 0;
} }
......
...@@ -133,20 +133,14 @@ typedef struct ...@@ -133,20 +133,14 @@ typedef struct
*/ */
static IxNpeDlImageMgrStats ixNpeDlImageMgrStats; static IxNpeDlImageMgrStats ixNpeDlImageMgrStats;
/* default image */
#ifdef CONFIG_IXP4XX_NPE_EXT_UCODE_BASE
static UINT32 *IxNpeMicroCodeImageLibrary = (UINT32 *)CONFIG_IXP4XX_NPE_EXT_UCODE_BASE;
#else
static UINT32 *IxNpeMicroCodeImageLibrary = (UINT32 *)IxNpeMicrocode_array;
#endif
static UINT32* getIxNpeMicroCodeImageLibrary(void) static UINT32* getIxNpeMicroCodeImageLibrary(void)
{ {
char *s; char *s;
if ((s = getenv("npe_ucode")) != NULL) if ((s = getenv("npe_ucode")) != NULL)
return (UINT32*) simple_strtoul(s, NULL, 16); return (UINT32*) simple_strtoul(s, NULL, 16);
else else
return IxNpeMicroCodeImageLibrary; return NULL;
} }
/* /*
...@@ -422,7 +416,7 @@ ixNpeDlImageMgrSignatureCheck (UINT32 *microCodeImageLibrary) ...@@ -422,7 +416,7 @@ ixNpeDlImageMgrSignatureCheck (UINT32 *microCodeImageLibrary)
(IxNpeDlImageMgrImageLibraryHeader *) microCodeImageLibrary; (IxNpeDlImageMgrImageLibraryHeader *) microCodeImageLibrary;
BOOL result = TRUE; BOOL result = TRUE;
if (header->signature != IX_NPEDL_IMAGEMGR_SIGNATURE) if (!header || header->signature != IX_NPEDL_IMAGEMGR_SIGNATURE)
{ {
result = FALSE; result = FALSE;
ixNpeDlImageMgrStats.invalidSignature++; ixNpeDlImageMgrStats.invalidSignature++;
...@@ -643,6 +637,11 @@ ixNpeDlImageMgrImageFind ( ...@@ -643,6 +637,11 @@ ixNpeDlImageMgrImageFind (
} }
#else #else
imageLibrary = getIxNpeMicroCodeImageLibrary(); imageLibrary = getIxNpeMicroCodeImageLibrary();
if (imageLibrary == NULL)
{
printf ("npe: ERROR, no Microcode found in memory\n");
return IX_FAIL;
}
#endif /* IX_NPEDL_READ_MICROCODE_FROM_FILE */ #endif /* IX_NPEDL_READ_MICROCODE_FROM_FILE */
} }
......
...@@ -25,11 +25,11 @@ include $(TOPDIR)/config.mk ...@@ -25,11 +25,11 @@ include $(TOPDIR)/config.mk
LIB := $(obj)libnpe.a LIB := $(obj)libnpe.a
LOCAL_CFLAGS += -I$(TOPDIR)/cpu/ixp/npe/include -DCONFIG_IXP425_COMPONENT_ETHDB LOCAL_CFLAGS += -I$(TOPDIR)/cpu/ixp/npe/include -DCONFIG_IXP425_COMPONENT_ETHDB -D__linux
CFLAGS += $(LOCAL_CFLAGS) CFLAGS += $(LOCAL_CFLAGS)
HOST_CFLAGS += $(LOCAL_CFLAGS) HOST_CFLAGS += $(LOCAL_CFLAGS)
COBJS := npe.o \ COBJS-$(CONFIG_IXP4XX_NPE) := npe.o \
miiphy.o \ miiphy.o \
IxOsalBufferMgt.o \ IxOsalBufferMgt.o \
IxOsalIoMem.o \ IxOsalIoMem.o \
...@@ -79,17 +79,13 @@ COBJS := npe.o \ ...@@ -79,17 +79,13 @@ COBJS := npe.o \
IxNpeMhSolicitedCbMgr.o \ IxNpeMhSolicitedCbMgr.o \
IxNpeMhUnsolicitedCbMgr.o IxNpeMhUnsolicitedCbMgr.o
ifndef CONFIG_IXP4XX_NPE_EXT_UCODE_BASE SRCS := $(SOBJS:.o=.S) $(COBJS-y:.o=.c)
COBJS += IxNpeMicrocode.o OBJS := $(addprefix $(obj),$(COBJS-y))
endif SOBJS := $(addprefix $(obj),$(SOBJS))
SRCS := $(START:.o=.S) $(SOBJS:.o=.S) $(COBJS:.o=.c)
OBJS := $(addprefix $(obj),$(SOBJS) $(COBJS))
START := $(addprefix $(obj),$(START))
all: $(LIB) all: $(LIB)
$(LIB): $(OBJS) $(LIB): $(obj).depend $(OBJS)
$(AR) $(ARFLAGS) $@ $(OBJS) $(AR) $(ARFLAGS) $@ $(OBJS)
######################################################################### #########################################################################
......
...@@ -44,8 +44,6 @@ ...@@ -44,8 +44,6 @@
#include <npe.h> #include <npe.h>
#ifdef CONFIG_IXP4XX_NPE
static IxQMgrDispatcherFuncPtr qDispatcherFunc = NULL; static IxQMgrDispatcherFuncPtr qDispatcherFunc = NULL;
static int npe_exists[NPE_NUM_PORTS]; static int npe_exists[NPE_NUM_PORTS];
static int npe_used[NPE_NUM_PORTS]; static int npe_used[NPE_NUM_PORTS];
...@@ -690,5 +688,3 @@ int npe_initialize(bd_t * bis) ...@@ -690,5 +688,3 @@ int npe_initialize(bd_t * bis)
return 1; return 1;
} }
#endif /* CONFIG_IXP4XX_NPE */
...@@ -32,7 +32,6 @@ ...@@ -32,7 +32,6 @@
#include <common.h> #include <common.h>
#include <asm/arch/ixp425.h> #include <asm/arch/ixp425.h>
#ifndef CONFIG_USE_IRQ
ulong get_timer (ulong base) ulong get_timer (ulong base)
{ {
return get_timer_masked () - base; return get_timer_masked () - base;
...@@ -80,4 +79,3 @@ ulong get_timer_masked (void) ...@@ -80,4 +79,3 @@ ulong get_timer_masked (void)
} }
return (reload_constant - current); return (reload_constant - current);
} }
#endif /* #ifndef CONFIG_USE_IRQ */
...@@ -27,6 +27,7 @@ LIB := $(obj)libpci.a ...@@ -27,6 +27,7 @@ LIB := $(obj)libpci.a
COBJS-$(CONFIG_FSL_PCI_INIT) += fsl_pci_init.o COBJS-$(CONFIG_FSL_PCI_INIT) += fsl_pci_init.o
COBJS-$(CONFIG_PCI) += pci.o pci_auto.o pci_indirect.o COBJS-$(CONFIG_PCI) += pci.o pci_auto.o pci_indirect.o
COBJS-$(CONFIG_IXP_PCI) += pci_ixp.o
COBJS-$(CONFIG_SH4_PCI) += pci_sh4.o COBJS-$(CONFIG_SH4_PCI) += pci_sh4.o
COBJS-$(CONFIG_SH7751_PCI) +=pci_sh7751.o COBJS-$(CONFIG_SH7751_PCI) +=pci_sh7751.o
COBJS-$(CONFIG_SH7780_PCI) +=pci_sh7780.o COBJS-$(CONFIG_SH7780_PCI) +=pci_sh7780.o
......
...@@ -24,9 +24,6 @@ ...@@ -24,9 +24,6 @@
#include <common.h> #include <common.h>
#ifdef CONFIG_PCI
#include <asm/processor.h> #include <asm/processor.h>
#include <asm/io.h> #include <asm/io.h>
#include <pci.h> #include <pci.h>
...@@ -572,4 +569,3 @@ pci_dev_t pci_find_devices (struct pci_device_id * ids, int devNo) ...@@ -572,4 +569,3 @@ pci_dev_t pci_find_devices (struct pci_device_id * ids, int devNo)
} }
return -1; return -1;
} }
#endif /* CONFIG_PCI */
...@@ -32,6 +32,7 @@ COBJS-y += ns16550.o ...@@ -32,6 +32,7 @@ COBJS-y += ns16550.o
COBJS-$(CONFIG_DRIVER_S3C4510_UART) += s3c4510b_uart.o COBJS-$(CONFIG_DRIVER_S3C4510_UART) += s3c4510b_uart.o
COBJS-$(CONFIG_S3C64XX) += s3c64xx.o COBJS-$(CONFIG_S3C64XX) += s3c64xx.o
COBJS-y += serial.o COBJS-y += serial.o
COBJS-$(CONFIG_IXP_SERIAL) += serial_ixp.o
COBJS-$(CONFIG_MAX3100_SERIAL) += serial_max3100.o COBJS-$(CONFIG_MAX3100_SERIAL) += serial_max3100.o
COBJS-$(CONFIG_PL010_SERIAL) += serial_pl01x.o COBJS-$(CONFIG_PL010_SERIAL) += serial_pl01x.o
COBJS-$(CONFIG_PL011_SERIAL) += serial_pl01x.o COBJS-$(CONFIG_PL011_SERIAL) += serial_pl01x.o
......
File moved
...@@ -39,6 +39,7 @@ ...@@ -39,6 +39,7 @@
#define CONFIG_DISPLAY_CPUINFO 1 #define CONFIG_DISPLAY_CPUINFO 1
#define CONFIG_DISPLAY_BOARDINFO 1 #define CONFIG_DISPLAY_BOARDINFO 1
#define CONFIG_IXP_SERIAL
#define CONFIG_SYS_IXP425_CONSOLE IXP425_UART2 #define CONFIG_SYS_IXP425_CONSOLE IXP425_UART2
#define CONFIG_BAUDRATE 115200 #define CONFIG_BAUDRATE 115200
#define CONFIG_BOOTDELAY 3 #define CONFIG_BOOTDELAY 3
...@@ -172,8 +173,6 @@ ...@@ -172,8 +173,6 @@
/* include IXP4xx NPE support */ /* include IXP4xx NPE support */
#define CONFIG_IXP4XX_NPE 1 #define CONFIG_IXP4XX_NPE 1
/* use separate flash sector with ucode images */
#define CONFIG_IXP4XX_NPE_EXT_UCODE_BASE 0x50040000
#define CONFIG_NET_MULTI 1 #define CONFIG_NET_MULTI 1
/* NPE0 PHY address */ /* NPE0 PHY address */
#define CONFIG_PHY_ADDR 0 #define CONFIG_PHY_ADDR 0
...@@ -208,6 +207,7 @@ ...@@ -208,6 +207,7 @@
#define CONFIG_SYS_USE_PPCENV 1 #define CONFIG_SYS_USE_PPCENV 1
#define CONFIG_EXTRA_ENV_SETTINGS \ #define CONFIG_EXTRA_ENV_SETTINGS \
"npe_ucode=50040000\0" \
"mtd=IXP4XX-Flash.0:256k(uboot),64k(ucode),1152k(linux),-(root)\0" \ "mtd=IXP4XX-Flash.0:256k(uboot),64k(ucode),1152k(linux),-(root)\0" \
"kerneladdr=50050000\0" \ "kerneladdr=50050000\0" \
"rootaddr=50170000\0" \ "rootaddr=50170000\0" \
......
...@@ -32,6 +32,7 @@ ...@@ -32,6 +32,7 @@
#define CONFIG_DISPLAY_CPUINFO 1 #define CONFIG_DISPLAY_CPUINFO 1
#define CONFIG_DISPLAY_BOARDINFO 1 #define CONFIG_DISPLAY_BOARDINFO 1
#define CONFIG_IXP_SERIAL
#define CONFIG_SYS_IXP425_CONSOLE IXP425_UART2 #define CONFIG_SYS_IXP425_CONSOLE IXP425_UART2
#define CONFIG_BAUDRATE 115200 #define CONFIG_BAUDRATE 115200
#define CONFIG_BOOTDELAY 5 #define CONFIG_BOOTDELAY 5
...@@ -147,8 +148,6 @@ ...@@ -147,8 +148,6 @@
/* include IXP4xx NPE support */ /* include IXP4xx NPE support */
#define CONFIG_IXP4XX_NPE 1 #define CONFIG_IXP4XX_NPE 1
/* use separate flash sector with ucode images */
#define CONFIG_IXP4XX_NPE_EXT_UCODE_BASE 0x50040000
#define CONFIG_NET_MULTI 1 #define CONFIG_NET_MULTI 1
/* NPE0 PHY address */ /* NPE0 PHY address */
#define CONFIG_PHY_ADDR 0x00 #define CONFIG_PHY_ADDR 0x00
...@@ -185,6 +184,7 @@ ...@@ -185,6 +184,7 @@
#define CONFIG_SYS_USE_PPCENV 1 #define CONFIG_SYS_USE_PPCENV 1
#define CONFIG_EXTRA_ENV_SETTINGS \ #define CONFIG_EXTRA_ENV_SETTINGS \
"npe_ucode=50040000\0" \
"mtd=IXP4XX-Flash.0:256k(uboot),64k(ucode),1152k(linux),-(root)\0" \ "mtd=IXP4XX-Flash.0:256k(uboot),64k(ucode),1152k(linux),-(root)\0" \
"kerneladdr=50050000\0" \ "kerneladdr=50050000\0" \
"rootaddr=50170000\0" \ "rootaddr=50170000\0" \
......
...@@ -32,6 +32,7 @@ ...@@ -32,6 +32,7 @@
#define CONFIG_DISPLAY_CPUINFO 1 #define CONFIG_DISPLAY_CPUINFO 1
#define CONFIG_DISPLAY_BOARDINFO 1 #define CONFIG_DISPLAY_BOARDINFO 1
#define CONFIG_IXP_SERIAL
#define CONFIG_SYS_IXP425_CONSOLE IXP425_UART2 #define CONFIG_SYS_IXP425_CONSOLE IXP425_UART2
#define CONFIG_BAUDRATE 115200 #define CONFIG_BAUDRATE 115200
#define CONFIG_BOOTDELAY 3 #define CONFIG_BOOTDELAY 3
...@@ -146,8 +147,6 @@ ...@@ -146,8 +147,6 @@
/* include IXP4xx NPE support */ /* include IXP4xx NPE support */
#define CONFIG_IXP4XX_NPE 1 #define CONFIG_IXP4XX_NPE 1
/* use separate flash sector with ucode images */
#define CONFIG_IXP4XX_NPE_EXT_UCODE_BASE 0x50040000
#define CONFIG_NET_MULTI 1 #define CONFIG_NET_MULTI 1
/* NPE0 PHY address */ /* NPE0 PHY address */
...@@ -185,6 +184,7 @@ ...@@ -185,6 +184,7 @@
#define CONFIG_SYS_USE_PPCENV 1 #define CONFIG_SYS_USE_PPCENV 1
#define CONFIG_EXTRA_ENV_SETTINGS \ #define CONFIG_EXTRA_ENV_SETTINGS \
"npe_ucode=50040000\0" \
"mtd=IXP4XX-Flash.0:256k(uboot),64k(ucode),1152k(linux),-(root)\0" \ "mtd=IXP4XX-Flash.0:256k(uboot),64k(ucode),1152k(linux),-(root)\0" \
"kerneladdr=50050000\0" \ "kerneladdr=50050000\0" \
"rootaddr=50170000\0" \ "rootaddr=50170000\0" \
......
...@@ -32,6 +32,7 @@ ...@@ -32,6 +32,7 @@
#define CONFIG_DISPLAY_CPUINFO 1 #define CONFIG_DISPLAY_CPUINFO 1
#define CONFIG_DISPLAY_BOARDINFO 1 #define CONFIG_DISPLAY_BOARDINFO 1
#define CONFIG_IXP_SERIAL
#define CONFIG_SYS_IXP425_CONSOLE IXP425_UART1 #define CONFIG_SYS_IXP425_CONSOLE IXP425_UART1
#define CONFIG_BAUDRATE 115200 #define CONFIG_BAUDRATE 115200
#define CONFIG_BOOTDELAY 3 #define CONFIG_BOOTDELAY 3
...@@ -149,8 +150,6 @@ ...@@ -149,8 +150,6 @@
/* include IXP4xx NPE support */ /* include IXP4xx NPE support */
#define CONFIG_IXP4XX_NPE 1 #define CONFIG_IXP4XX_NPE 1
/* use separate flash sector with ucode images */
#define CONFIG_IXP4XX_NPE_EXT_UCODE_BASE 0x51000000
#define CONFIG_NET_MULTI 1 #define CONFIG_NET_MULTI 1
/* NPE0 PHY address */ /* NPE0 PHY address */
...@@ -181,6 +180,7 @@ ...@@ -181,6 +180,7 @@
#define CONFIG_ENV_ADDR (PHYS_FLASH_1 + 0x3f000) #define CONFIG_ENV_ADDR (PHYS_FLASH_1 + 0x3f000)
#define CONFIG_EXTRA_ENV_SETTINGS \ #define CONFIG_EXTRA_ENV_SETTINGS \
"npe_ucode=51000000\0" \
"mtd=IXP4XX-Flash.0:252k(uboot),4k(uboot_env);" \ "mtd=IXP4XX-Flash.0:252k(uboot),4k(uboot_env);" \
"IXP4XX-Flash.1:128k(ucode),1280k(linux),-(root)\0" \ "IXP4XX-Flash.1:128k(ucode),1280k(linux),-(root)\0" \
"kerneladdr=51020000\0" \ "kerneladdr=51020000\0" \
......
...@@ -73,6 +73,7 @@ ...@@ -73,6 +73,7 @@
#define CONFIG_PCI #define CONFIG_PCI
#define CONFIG_IXP_PCI
#define CONFIG_NET_MULTI #define CONFIG_NET_MULTI
#define CONFIG_EEPRO100 #define CONFIG_EEPRO100
...@@ -134,6 +135,7 @@ ...@@ -134,6 +135,7 @@
/* /*
* select serial console configuration * select serial console configuration
*/ */
#define CONFIG_IXP_SERIAL
#define CONFIG_SYS_IXP425_CONSOLE IXP425_UART1 /* we use UART1 for console */ #define CONFIG_SYS_IXP425_CONSOLE IXP425_UART1 /* we use UART1 for console */
/* /*
......
...@@ -72,6 +72,7 @@ ...@@ -72,6 +72,7 @@
/* allow to overwrite serial and ethaddr */ /* allow to overwrite serial and ethaddr */
#define CONFIG_ENV_OVERWRITE #define CONFIG_ENV_OVERWRITE
#define CONFIG_IXP_SERIAL
#define CONFIG_BAUDRATE 115200 #define CONFIG_BAUDRATE 115200
#define CONFIG_SYS_IXP425_CONSOLE IXP425_UART1 /* we use UART1 for console */ #define CONFIG_SYS_IXP425_CONSOLE IXP425_UART1 /* we use UART1 for console */
......
...@@ -68,6 +68,7 @@ ...@@ -68,6 +68,7 @@
/* allow to overwrite serial and ethaddr */ /* allow to overwrite serial and ethaddr */
#define CONFIG_ENV_OVERWRITE #define CONFIG_ENV_OVERWRITE
#define CONFIG_IXP_SERIAL
#define CONFIG_BAUDRATE 115200 #define CONFIG_BAUDRATE 115200
#define CONFIG_SYS_IXP425_CONSOLE IXP425_UART1 /* we use UART1 for console */ #define CONFIG_SYS_IXP425_CONSOLE IXP425_UART1 /* we use UART1 for console */
......
...@@ -221,6 +221,15 @@ static int init_func_i2c (void) ...@@ -221,6 +221,15 @@ static int init_func_i2c (void)
} }
#endif #endif
#if defined(CONFIG_CMD_PCI) || defined (CONFIG_PCI)
#include <pci.h>
static int arm_pci_init(void)
{
pci_init();
return 0;
}
#endif /* CONFIG_CMD_PCI || CONFIG_PCI */
/* /*
* Breathe some life into the board... * Breathe some life into the board...
* *
...@@ -267,6 +276,9 @@ init_fnc_t *init_sequence[] = { ...@@ -267,6 +276,9 @@ init_fnc_t *init_sequence[] = {
init_func_i2c, init_func_i2c,
#endif #endif
dram_init, /* configure available RAM banks */ dram_init, /* configure available RAM banks */
#if defined(CONFIG_CMD_PCI) || defined (CONFIG_PCI)
arm_pci_init,
#endif
display_dram_config, display_dram_config,
NULL, NULL,
}; };
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment