From 6ae987b688c82aa1852b5a7bb691b7138c3ebd51 Mon Sep 17 00:00:00 2001 From: Sergey Lapin Date: Thu, 4 Dec 2008 00:22:21 +0300 Subject: u-boot_git: updated rev for afeb9260 --- packages/u-boot/u-boot_git.bb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/u-boot/u-boot_git.bb b/packages/u-boot/u-boot_git.bb index a496c043ca..ec973c45ff 100644 --- a/packages/u-boot/u-boot_git.bb +++ b/packages/u-boot/u-boot_git.bb @@ -1,5 +1,5 @@ require u-boot.inc -PR ="r20" +PR ="r21" SRC_URI = "git://www.denx.de/git/u-boot.git;protocol=git " SRCREV_davinci-sffsdr = "4b50cd12a3b3c644153c4cf393f4a4c12289e5aa" @@ -7,7 +7,7 @@ SRCREV_davinci-dvevm = "4b50cd12a3b3c644153c4cf393f4a4c12289e5aa" SRCREV_akita = "9bf86baaa3b35b25baa2d664e2f7f6cafad689ee" SRCREV_spitz = "9bf86baaa3b35b25baa2d664e2f7f6cafad689ee" SRCREV_c7x0 = "9bf86baaa3b35b25baa2d664e2f7f6cafad689ee" -SRCREV_afeb9260 = "d9d8c7c696dec370ca714c03beb6e79d4c90bd5e" +SRCREV_afeb9260 = "2077e348c2a84901022ad95311b47b70361e6daa" SRC_URI_beagleboard = "git://www.sakoman.net/git/u-boot-omap3.git;branch=omap3;protocol=git" SRCREV_beagleboard = "1e329ec630b31803ee191d2ee335214662b5bfea" -- cgit v1.2.3 From dde71280ca0a91bd8393590f1fa07251645dc21b Mon Sep 17 00:00:00 2001 From: Sergey Lapin Date: Thu, 4 Dec 2008 01:28:47 +0300 Subject: linux_2.6.28: made source fetchable after Koen's fix --- ...ffers-implementation-from-atmel-to-fix-TX.patch | 310 +++++ .../afeb9260/0003-RS-485-mode-of-USART1.patch | 41 + .../linux-2.6.27+2.6.28-rc6/afeb9260/defconfig | 1256 ++++++++++++++++++++ ...ffers-implementation-from-atmel-to-fix-TX.patch | 310 ----- .../afeb9260/0003-RS-485-mode-of-USART1.patch | 41 - .../linux-2.6.27+2.6.28rc6/afeb9260/defconfig | 1256 -------------------- packages/linux/linux_2.6.28-rc6.bb | 6 +- 7 files changed, 1610 insertions(+), 1610 deletions(-) create mode 100644 packages/linux/linux-2.6.27+2.6.28-rc6/afeb9260/0002-SRAM-TX-buffers-implementation-from-atmel-to-fix-TX.patch create mode 100644 packages/linux/linux-2.6.27+2.6.28-rc6/afeb9260/0003-RS-485-mode-of-USART1.patch create mode 100644 packages/linux/linux-2.6.27+2.6.28-rc6/afeb9260/defconfig delete mode 100644 packages/linux/linux-2.6.27+2.6.28rc6/afeb9260/0002-SRAM-TX-buffers-implementation-from-atmel-to-fix-TX.patch delete mode 100644 packages/linux/linux-2.6.27+2.6.28rc6/afeb9260/0003-RS-485-mode-of-USART1.patch delete mode 100644 packages/linux/linux-2.6.27+2.6.28rc6/afeb9260/defconfig diff --git a/packages/linux/linux-2.6.27+2.6.28-rc6/afeb9260/0002-SRAM-TX-buffers-implementation-from-atmel-to-fix-TX.patch b/packages/linux/linux-2.6.27+2.6.28-rc6/afeb9260/0002-SRAM-TX-buffers-implementation-from-atmel-to-fix-TX.patch new file mode 100644 index 0000000000..9a280d666a --- /dev/null +++ b/packages/linux/linux-2.6.27+2.6.28-rc6/afeb9260/0002-SRAM-TX-buffers-implementation-from-atmel-to-fix-TX.patch @@ -0,0 +1,310 @@ +From 856f17b89eb0e943d36f36d0c760e1226db9d716 Mon Sep 17 00:00:00 2001 +From: Sergey Lapin +Date: Fri, 4 Jul 2008 01:52:39 +0400 +Subject: [PATCH] SRAM TX buffers implementation from atmel to fix TX underrun errors + +Signed-off-by: Sergey Lapin +--- + arch/arm/mach-at91/at91sam9260_devices.c | 7 ++ + drivers/net/Kconfig | 6 ++ + drivers/net/macb.c | 108 ++++++++++++++++++++++-------- + drivers/net/macb.h | 7 ++- + 4 files changed, 99 insertions(+), 29 deletions(-) + +diff --git a/arch/arm/mach-at91/at91sam9260_devices.c b/arch/arm/mach-at91/at91sam9260_devices.c +index f5fec0a..681cd40 100644 +--- a/arch/arm/mach-at91/at91sam9260_devices.c ++++ b/arch/arm/mach-at91/at91sam9260_devices.c +@@ -141,6 +141,13 @@ static struct resource eth_resources[] = { + .end = AT91SAM9260_ID_EMAC, + .flags = IORESOURCE_IRQ, + }, ++#if defined(CONFIG_MACB_TX_SRAM) ++ [2] = { ++ .start = AT91SAM9260_SRAM1_BASE, ++ .end = AT91SAM9260_SRAM1_BASE + AT91SAM9260_SRAM1_SIZE - 1, ++ .flags = IORESOURCE_MEM, ++ }, ++#endif + }; + + static struct platform_device at91sam9260_eth_device = { +diff --git a/drivers/net/Kconfig b/drivers/net/Kconfig +index 8a03875..a9a46a8 100644 +--- a/drivers/net/Kconfig ++++ b/drivers/net/Kconfig +@@ -218,6 +218,12 @@ config MACB + To compile this driver as a module, choose M here: the module + will be called macb. + ++config MACB_TX_SRAM ++ bool "Use internal SRAM for EMAC (Ethernet) transmit buffers" ++ depends on (ARCH_AT91SAM9263 || ARCH_AT91SAM9260) && MACB ++ help ++ Select this if you are using internal SRAM for EMAC transmit buffers. ++ + source "drivers/net/arm/Kconfig" + + config AX88796 +diff --git a/drivers/net/macb.c b/drivers/net/macb.c +index daba82b..55063dc 100644 +--- a/drivers/net/macb.c ++++ b/drivers/net/macb.c +@@ -33,22 +33,27 @@ + /* Make the IP header word-aligned (the ethernet header is 14 bytes) */ + #define RX_OFFSET 2 + +-#define TX_RING_SIZE 128 +-#define DEF_TX_RING_PENDING (TX_RING_SIZE - 1) +-#define TX_RING_BYTES (sizeof(struct dma_desc) * TX_RING_SIZE) ++#define TX_MAX_PKT_SIZE 1536 ++#define TX_DEFAULT_RING_SIZE 128 ++#define DEF_TX_RING_PENDING(bp) ((bp)->tx_ring_size - 1) ++ ++#define TX_RING_BYTES(bp) (sizeof(struct dma_desc) * \ ++ (bp)->tx_ring_size) + + #define TX_RING_GAP(bp) \ +- (TX_RING_SIZE - (bp)->tx_pending) ++ ((bp)->tx_ring_size - (bp)->tx_pending) ++ + #define TX_BUFFS_AVAIL(bp) \ + (((bp)->tx_tail <= (bp)->tx_head) ? \ + (bp)->tx_tail + (bp)->tx_pending - (bp)->tx_head : \ + (bp)->tx_tail - (bp)->tx_head - TX_RING_GAP(bp)) +-#define NEXT_TX(n) (((n) + 1) & (TX_RING_SIZE - 1)) + +-#define NEXT_RX(n) (((n) + 1) & (RX_RING_SIZE - 1)) ++#define NEXT_TX(bp, n) (((n) + 1) % ((bp)->tx_ring_size)) ++#define NEXT_RX(n) (((n) + 1) % (RX_RING_SIZE)) ++ + + /* minimum number of free TX descriptors before waking up TX process */ +-#define MACB_TX_WAKEUP_THRESH (TX_RING_SIZE / 4) ++#define MACB_TX_WAKEUP_THRESH(bp) ((bp)->tx_ring_size / 4) + + #define MACB_RX_INT_FLAGS (MACB_BIT(RCOMP) | MACB_BIT(RXUBR) \ + | MACB_BIT(ISR_ROVR)) +@@ -316,11 +321,11 @@ static void macb_tx(struct macb *bp) + head = bp->tx_head; + + /*Mark all the buffer as used to avoid sending a lost buffer*/ +- for (i = 0; i < TX_RING_SIZE; i++) ++ for (i = 0; i < bp->tx_ring_size; i++) + bp->tx_ring[i].ctrl = MACB_BIT(TX_USED); + + /* free transmit buffer in upper layer*/ +- for (tail = bp->tx_tail; tail != head; tail = NEXT_TX(tail)) { ++ for (tail = bp->tx_tail; tail != head; tail = NEXT_TX(bp, tail)) { + struct ring_info *rp = &bp->tx_skb[tail]; + struct sk_buff *skb = rp->skb; + +@@ -346,7 +351,7 @@ static void macb_tx(struct macb *bp) + return; + + head = bp->tx_head; +- for (tail = bp->tx_tail; tail != head; tail = NEXT_TX(tail)) { ++ for (tail = bp->tx_tail; tail != head; tail = NEXT_TX(bp, tail)) { + struct ring_info *rp = &bp->tx_skb[tail]; + struct sk_buff *skb = rp->skb; + u32 bufstat; +@@ -371,7 +376,7 @@ static void macb_tx(struct macb *bp) + + bp->tx_tail = tail; + if (netif_queue_stopped(bp->dev) && +- TX_BUFFS_AVAIL(bp) > MACB_TX_WAKEUP_THRESH) ++ TX_BUFFS_AVAIL(bp) > MACB_TX_WAKEUP_THRESH(bp)) + netif_wake_queue(bp->dev); + } + +@@ -401,6 +406,7 @@ static int macb_rx_frame(struct macb *bp, unsigned int first_frag, + } + + skb_reserve(skb, RX_OFFSET); ++ skb->dev = bp->dev; + skb->ip_summed = CHECKSUM_NONE; + skb_put(skb, len); + +@@ -637,8 +643,15 @@ static int macb_start_xmit(struct sk_buff *skb, struct net_device *dev) + + entry = bp->tx_head; + dev_dbg(&bp->pdev->dev, "Allocated ring entry %u\n", entry); +- mapping = dma_map_single(&bp->pdev->dev, skb->data, ++ if (bp->smem_start) { ++ mapping = bp->tx_ring[entry].addr; ++ memcpy(bp->tx_buffers + entry * TX_MAX_PKT_SIZE, ++ skb->data, len); ++ } else { ++ mapping = dma_map_single(&bp->pdev->dev, skb->data, + len, DMA_TO_DEVICE); ++ bp->tx_ring[entry].addr = mapping; ++ } + bp->tx_skb[entry].skb = skb; + bp->tx_skb[entry].mapping = mapping; + dev_dbg(&bp->pdev->dev, "Mapped skb data %p to DMA addr %08lx\n", +@@ -646,14 +659,13 @@ static int macb_start_xmit(struct sk_buff *skb, struct net_device *dev) + + ctrl = MACB_BF(TX_FRMLEN, len); + ctrl |= MACB_BIT(TX_LAST); +- if (entry == (TX_RING_SIZE - 1)) ++ if (entry == (bp->tx_ring_size - 1)) + ctrl |= MACB_BIT(TX_WRAP); + +- bp->tx_ring[entry].addr = mapping; + bp->tx_ring[entry].ctrl = ctrl; + wmb(); + +- entry = NEXT_TX(entry); ++ entry = NEXT_TX(bp, entry); + bp->tx_head = entry; + + macb_writel(bp, NCR, macb_readl(bp, NCR) | MACB_BIT(TSTART)); +@@ -680,7 +692,8 @@ static void macb_free_consistent(struct macb *bp) + bp->rx_ring = NULL; + } + if (bp->tx_ring) { +- dma_free_coherent(&bp->pdev->dev, TX_RING_BYTES, ++ if (!bp->smem_start) ++ dma_free_coherent(&bp->pdev->dev, TX_RING_BYTES(bp), + bp->tx_ring, bp->tx_ring_dma); + bp->tx_ring = NULL; + } +@@ -690,13 +703,16 @@ static void macb_free_consistent(struct macb *bp) + bp->rx_buffers, bp->rx_buffers_dma); + bp->rx_buffers = NULL; + } ++ ++ if (bp->smem_start && bp->tx_ring_dma) ++ release_mem_region(bp->tx_ring_dma, bp->smem_size); + } + + static int macb_alloc_consistent(struct macb *bp) + { + int size; + +- size = TX_RING_SIZE * sizeof(struct ring_info); ++ size = bp->tx_ring_size * sizeof(struct ring_info); + bp->tx_skb = kmalloc(size, GFP_KERNEL); + if (!bp->tx_skb) + goto out_err; +@@ -710,14 +726,30 @@ static int macb_alloc_consistent(struct macb *bp) + "Allocated RX ring of %d bytes at %08lx (mapped %p)\n", + size, (unsigned long)bp->rx_ring_dma, bp->rx_ring); + +- size = TX_RING_BYTES; +- bp->tx_ring = dma_alloc_coherent(&bp->pdev->dev, size, ++ if (bp->smem_start) { ++ if (request_mem_region(bp->smem_start, ++ bp->smem_size, "macb")) { ++ bp->tx_ring_dma = bp->smem_start; ++ } ++ bp->tx_ring = ioremap(bp->tx_ring_dma, bp->smem_size); ++ if (bp->tx_ring) { ++ bp->tx_buffers_dma = bp->tx_ring_dma + ++ TX_RING_BYTES(bp); ++ bp->tx_buffers = (char *) bp->tx_ring + ++ TX_RING_BYTES(bp); ++ } ++ } ++ ++ if (!bp->tx_ring) { ++ size = TX_RING_BYTES(bp); ++ bp->tx_ring = dma_alloc_coherent(&bp->pdev->dev, size, + &bp->tx_ring_dma, GFP_KERNEL); +- if (!bp->tx_ring) +- goto out_err; +- dev_dbg(&bp->pdev->dev, +- "Allocated TX ring of %d bytes at %08lx (mapped %p)\n", +- size, (unsigned long)bp->tx_ring_dma, bp->tx_ring); ++ if (!bp->tx_ring) ++ goto out_err; ++ dev_dbg(&bp->pdev->dev, ++ "Allocated TX ring of %d bytes at %08lx (mapped %p)\n", ++ size, (unsigned long)bp->tx_ring_dma, bp->tx_ring); ++ } + + size = RX_RING_SIZE * RX_BUFFER_SIZE; + bp->rx_buffers = dma_alloc_coherent(&bp->pdev->dev, size, +@@ -748,11 +780,14 @@ static void macb_init_rings(struct macb *bp) + } + bp->rx_ring[RX_RING_SIZE - 1].addr |= MACB_BIT(RX_WRAP); + +- for (i = 0; i < TX_RING_SIZE; i++) { +- bp->tx_ring[i].addr = 0; ++ for (i = 0; i < bp->tx_ring_size; i++) { ++ bp->tx_ring[i].addr = (bp->smem_start) ? ++ bp->tx_buffers_dma + i * TX_MAX_PKT_SIZE : 0; + bp->tx_ring[i].ctrl = MACB_BIT(TX_USED); ++ bp->tx_ring[i].addr = (u32) (bp->tx_buffers_dma + ++ (i * TX_MAX_PKT_SIZE)); + } +- bp->tx_ring[TX_RING_SIZE - 1].ctrl |= MACB_BIT(TX_WRAP); ++ bp->tx_ring[bp->tx_ring_size - 1].ctrl |= MACB_BIT(TX_WRAP); + + bp->rx_tail = bp->tx_head = bp->tx_tail = 0; + } +@@ -1090,6 +1125,7 @@ static int __init macb_probe(struct platform_device *pdev) + { + struct eth_platform_data *pdata; + struct resource *regs; ++ struct resource *smem; + struct net_device *dev; + struct macb *bp; + struct phy_device *phydev; +@@ -1201,7 +1237,23 @@ static int __init macb_probe(struct platform_device *pdev) + macb_writel(bp, USRIO, MACB_BIT(MII)); + #endif + +- bp->tx_pending = DEF_TX_RING_PENDING; ++ /* Check mem region for TX buffers */ ++ smem = platform_get_resource(pdev, IORESOURCE_MEM, 1); ++ if (smem) { ++ bp->smem_start = smem->start; ++ bp->smem_size = smem->end - smem->start + 1; ++ bp->tx_ring_size = bp->smem_size / (TX_MAX_PKT_SIZE + ++ sizeof(struct dma_desc)); ++ } ++ ++ /* if ring_size == 0 then mem is too ++ small and use standard memory */ ++ if (!bp->tx_ring_size) { ++ bp->smem_start = 0; ++ bp->tx_ring_size = TX_DEFAULT_RING_SIZE; ++ } ++ ++ bp->tx_pending = DEF_TX_RING_PENDING(bp); + + err = register_netdev(dev); + if (err) { +diff --git a/drivers/net/macb.h b/drivers/net/macb.h +index 57b85ac..faa5a9d 100644 +--- a/drivers/net/macb.h ++++ b/drivers/net/macb.h +@@ -364,11 +364,15 @@ struct macb { + unsigned int rx_tail; + struct dma_desc *rx_ring; + void *rx_buffers; +- ++ void *tx_buffers; ++ unsigned int tx_ring_size; + unsigned int tx_head, tx_tail; + struct dma_desc *tx_ring; + struct ring_info *tx_skb; + ++ unsigned int smem_start; ++ unsigned int smem_size; ++ + spinlock_t lock; + struct platform_device *pdev; + struct clk *pclk; +@@ -381,6 +385,7 @@ struct macb { + dma_addr_t rx_ring_dma; + dma_addr_t tx_ring_dma; + dma_addr_t rx_buffers_dma; ++ dma_addr_t tx_buffers_dma; + + unsigned int rx_pending, tx_pending; + +-- +1.5.4.1 + diff --git a/packages/linux/linux-2.6.27+2.6.28-rc6/afeb9260/0003-RS-485-mode-of-USART1.patch b/packages/linux/linux-2.6.27+2.6.28-rc6/afeb9260/0003-RS-485-mode-of-USART1.patch new file mode 100644 index 0000000000..e60088794f --- /dev/null +++ b/packages/linux/linux-2.6.27+2.6.28-rc6/afeb9260/0003-RS-485-mode-of-USART1.patch @@ -0,0 +1,41 @@ +From 5374be6a8f2644e33e436b1864188442e1b2c156 Mon Sep 17 00:00:00 2001 +From: Sergey Lapin +Date: Fri, 4 Jul 2008 01:53:23 +0400 +Subject: [PATCH] RS-485 mode of USART1 + +Signed-off-by: Sergey Lapin +--- + drivers/serial/atmel_serial.c | 9 ++++++++- + 1 files changed, 8 insertions(+), 1 deletions(-) + +diff --git a/drivers/serial/atmel_serial.c b/drivers/serial/atmel_serial.c +index 1fee12c..20ced47 100644 +--- a/drivers/serial/atmel_serial.c ++++ b/drivers/serial/atmel_serial.c +@@ -233,8 +233,12 @@ static void atmel_set_mctrl(struct uart_port *port, u_int mctrl) + mode = UART_GET_MR(port) & ~ATMEL_US_CHMODE; + if (mctrl & TIOCM_LOOP) + mode |= ATMEL_US_CHMODE_LOC_LOOP; +- else ++ else { ++ if (port->mapbase == AT91SAM9260_BASE_US1) ++ mode |= ATMEL_US_USMODE_RS485; ++ + mode |= ATMEL_US_CHMODE_NORMAL; ++ } + UART_PUT_MR(port, mode); + } + +@@ -1094,6 +1098,9 @@ static void atmel_set_termios(struct uart_port *port, struct ktermios *termios, + /* disable receiver and transmitter */ + UART_PUT_CR(port, ATMEL_US_TXDIS | ATMEL_US_RXDIS); + ++ if (port->mapbase == AT91SAM9260_BASE_US1) ++ mode |= ATMEL_US_USMODE_RS485; ++ + /* set the parity, stop bits and data size */ + UART_PUT_MR(port, mode); + +-- +1.5.4.1 + diff --git a/packages/linux/linux-2.6.27+2.6.28-rc6/afeb9260/defconfig b/packages/linux/linux-2.6.27+2.6.28-rc6/afeb9260/defconfig new file mode 100644 index 0000000000..eed8512d99 --- /dev/null +++ b/packages/linux/linux-2.6.27+2.6.28-rc6/afeb9260/defconfig @@ -0,0 +1,1256 @@ +# +# Automatically generated make config: don't edit +# Linux kernel version: 2.6.27-rc2 +# Thu Aug 7 22:03:55 2008 +# +CONFIG_ARM=y +CONFIG_SYS_SUPPORTS_APM_EMULATION=y +CONFIG_GENERIC_GPIO=y +CONFIG_GENERIC_TIME=y +CONFIG_GENERIC_CLOCKEVENTS=y +CONFIG_MMU=y +# CONFIG_NO_IOPORT is not set +CONFIG_GENERIC_HARDIRQS=y +CONFIG_STACKTRACE_SUPPORT=y +CONFIG_HAVE_LATENCYTOP_SUPPORT=y +CONFIG_LOCKDEP_SUPPORT=y +CONFIG_TRACE_IRQFLAGS_SUPPORT=y +CONFIG_HARDIRQS_SW_RESEND=y +CONFIG_GENERIC_IRQ_PROBE=y +CONFIG_RWSEM_GENERIC_SPINLOCK=y +# CONFIG_ARCH_HAS_ILOG2_U32 is not set +# CONFIG_ARCH_HAS_ILOG2_U64 is not set +CONFIG_GENERIC_HWEIGHT=y +CONFIG_GENERIC_CALIBRATE_DELAY=y +CONFIG_ARCH_SUPPORTS_AOUT=y +CONFIG_ZONE_DMA=y +CONFIG_GENERIC_HARDIRQS_NO__DO_IRQ=y +CONFIG_VECTORS_BASE=0xffff0000 +CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" + +# +# General setup +# +CONFIG_EXPERIMENTAL=y +CONFIG_BROKEN_ON_SMP=y +CONFIG_LOCK_KERNEL=y +CONFIG_INIT_ENV_ARG_LIMIT=32 +CONFIG_LOCALVERSION="" +# CONFIG_LOCALVERSION_AUTO is not set +CONFIG_SWAP=y +CONFIG_SYSVIPC=y +CONFIG_SYSVIPC_SYSCTL=y +# CONFIG_POSIX_MQUEUE is not set +# CONFIG_BSD_PROCESS_ACCT is not set +# CONFIG_TASKSTATS is not set +# CONFIG_AUDIT is not set +# CONFIG_IKCONFIG is not set +CONFIG_LOG_BUF_SHIFT=14 +# CONFIG_CGROUPS is not set +# CONFIG_GROUP_SCHED is not set +CONFIG_SYSFS_DEPRECATED=y +CONFIG_SYSFS_DEPRECATED_V2=y +# CONFIG_RELAY is not set +CONFIG_NAMESPACES=y +# CONFIG_UTS_NS is not set +# CONFIG_IPC_NS is not set +# CONFIG_USER_NS is not set +# CONFIG_PID_NS is not set +CONFIG_BLK_DEV_INITRD=y +CONFIG_INITRAMFS_SOURCE="" +CONFIG_CC_OPTIMIZE_FOR_SIZE=y +CONFIG_SYSCTL=y +# CONFIG_EMBEDDED is not set +CONFIG_UID16=y +CONFIG_SYSCTL_SYSCALL=y +CONFIG_SYSCTL_SYSCALL_CHECK=y +CONFIG_KALLSYMS=y +# CONFIG_KALLSYMS_ALL is not set +# CONFIG_KALLSYMS_EXTRA_PASS is not set +CONFIG_HOTPLUG=y +CONFIG_PRINTK=y +CONFIG_BUG=y +CONFIG_ELF_CORE=y +CONFIG_COMPAT_BRK=y +CONFIG_BASE_FULL=y +CONFIG_FUTEX=y +CONFIG_ANON_INODES=y +CONFIG_EPOLL=y +CONFIG_SIGNALFD=y +CONFIG_TIMERFD=y +CONFIG_EVENTFD=y +CONFIG_SHMEM=y +CONFIG_VM_EVENT_COUNTERS=y +CONFIG_SLAB=y +# CONFIG_SLUB is not set +# CONFIG_SLOB is not set +# CONFIG_PROFILING is not set +# CONFIG_MARKERS is not set +CONFIG_HAVE_OPROFILE=y +# CONFIG_KPROBES is not set +# CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS is not set +# CONFIG_HAVE_IOREMAP_PROT is not set +CONFIG_HAVE_KPROBES=y +CONFIG_HAVE_KRETPROBES=y +# CONFIG_HAVE_ARCH_TRACEHOOK is not set +# CONFIG_HAVE_DMA_ATTRS is not set +# CONFIG_USE_GENERIC_SMP_HELPERS is not set +CONFIG_HAVE_CLK=y +CONFIG_PROC_PAGE_MONITOR=y +CONFIG_HAVE_GENERIC_DMA_COHERENT=y +CONFIG_SLABINFO=y +CONFIG_RT_MUTEXES=y +# CONFIG_TINY_SHMEM is not set +CONFIG_BASE_SMALL=0 +CONFIG_MODULES=y +# CONFIG_MODULE_FORCE_LOAD is not set +CONFIG_MODULE_UNLOAD=y +# CONFIG_MODULE_FORCE_UNLOAD is not set +# CONFIG_MODVERSIONS is not set +# CONFIG_MODULE_SRCVERSION_ALL is not set +CONFIG_KMOD=y +CONFIG_BLOCK=y +# CONFIG_LBD is not set +# CONFIG_BLK_DEV_IO_TRACE is not set +# CONFIG_LSF is not set +# CONFIG_BLK_DEV_BSG is not set +# CONFIG_BLK_DEV_INTEGRITY is not set + +# +# IO Schedulers +# +CONFIG_IOSCHED_NOOP=y +CONFIG_IOSCHED_AS=y +# CONFIG_IOSCHED_DEADLINE is not set +# CONFIG_IOSCHED_CFQ is not set +CONFIG_DEFAULT_AS=y +# CONFIG_DEFAULT_DEADLINE is not set +# CONFIG_DEFAULT_CFQ is not set +# CONFIG_DEFAULT_NOOP is not set +CONFIG_DEFAULT_IOSCHED="anticipatory" +CONFIG_CLASSIC_RCU=y + +# +# System Type +# +# CONFIG_ARCH_AAEC2000 is not set +# CONFIG_ARCH_INTEGRATOR is not set +# CONFIG_ARCH_REALVIEW is not set +# CONFIG_ARCH_VERSATILE is not set +CONFIG_ARCH_AT91=y +# CONFIG_ARCH_CLPS7500 is not set +# CONFIG_ARCH_CLPS711X is not set +# CONFIG_ARCH_EBSA110 is not set +# CONFIG_ARCH_EP93XX is not set +# CONFIG_ARCH_FOOTBRIDGE is not set +# CONFIG_ARCH_NETX is not set +# CONFIG_ARCH_H720X is not set +# CONFIG_ARCH_IMX is not set +# CONFIG_ARCH_IOP13XX is not set +# CONFIG_ARCH_IOP32X is not set +# CONFIG_ARCH_IOP33X is not set +# CONFIG_ARCH_IXP23XX is not set +# CONFIG_ARCH_IXP2000 is not set +# CONFIG_ARCH_IXP4XX is not set +# CONFIG_ARCH_L7200 is not set +# CONFIG_ARCH_KIRKWOOD is not set +# CONFIG_ARCH_KS8695 is not set +# CONFIG_ARCH_NS9XXX is not set +# CONFIG_ARCH_LOKI is not set +# CONFIG_ARCH_MV78XX0 is not set +# CONFIG_ARCH_MXC is not set +# CONFIG_ARCH_ORION5X is not set +# CONFIG_ARCH_PNX4008 is not set +# CONFIG_ARCH_PXA is not set +# CONFIG_ARCH_RPC is not set +# CONFIG_ARCH_SA1100 is not set +# CONFIG_ARCH_S3C2410 is not set +# CONFIG_ARCH_SHARK is not set +# CONFIG_ARCH_LH7A40X is not set +# CONFIG_ARCH_DAVINCI is not set +# CONFIG_ARCH_OMAP is not set +# CONFIG_ARCH_MSM7X00A is not set + +# +# Boot options +# + +# +# Power management +# + +# +# Atmel AT91 System-on-Chip +# +# CONFIG_ARCH_AT91RM9200 is not set +CONFIG_ARCH_AT91SAM9260=y +# CONFIG_ARCH_AT91SAM9261 is not set +# CONFIG_ARCH_AT91SAM9263 is not set +# CONFIG_ARCH_AT91SAM9RL is not set +# CONFIG_ARCH_AT91SAM9G20 is not set +# CONFIG_ARCH_AT91CAP9 is not set +# CONFIG_ARCH_AT91X40 is not set +CONFIG_AT91_PMC_UNIT=y + +# +# AT91SAM9260 Variants +# +# CONFIG_ARCH_AT91SAM9260_SAM9XE is not set + +# +# AT91SAM9260 / AT91SAM9XE Board Type +# +# CONFIG_MACH_AT91SAM9260EK is not set +# CONFIG_MACH_CAM60 is not set +# CONFIG_MACH_SAM9_L9260 is not set +CONFIG_MACH_AFEB9260=y +# CONFIG_MACH_USB_A9260 is not set +# CONFIG_MACH_QIL_A9260 is not set + +# +# AT91 Board Options +# + +# +# AT91 Feature Selections +# +CONFIG_AT91_PROGRAMMABLE_CLOCKS=y +CONFIG_AT91_TIMER_HZ=100 +CONFIG_AT91_EARLY_DBGU=y +# CONFIG_AT91_EARLY_USART0 is not set +# CONFIG_AT91_EARLY_USART1 is not set +# CONFIG_AT91_EARLY_USART2 is not set +# CONFIG_AT91_EARLY_USART3 is not set +# CONFIG_AT91_EARLY_USART4 is not set +# CONFIG_AT91_EARLY_USART5 is not set + +# +# Processor Type +# +CONFIG_CPU_32=y +CONFIG_CPU_ARM926T=y +CONFIG_CPU_32v5=y +CONFIG_CPU_ABRT_EV5TJ=y +CONFIG_CPU_PABRT_NOIFAR=y +CONFIG_CPU_CACHE_VIVT=y +CONFIG_CPU_COPY_V4WB=y +CONFIG_CPU_TLB_V4WBI=y +CONFIG_CPU_CP15=y +CONFIG_CPU_CP15_MMU=y + +# +# Processor Features +# +CONFIG_ARM_THUMB=y +# CONFIG_CPU_ICACHE_DISABLE is not set +# CONFIG_CPU_DCACHE_DISABLE is not set +# CONFIG_CPU_DCACHE_WRITETHROUGH is not set +# CONFIG_CPU_CACHE_ROUND_ROBIN is not set +# CONFIG_OUTER_CACHE is not set + +# +# Bus support +# +# CONFIG_PCI_SYSCALL is not set +# CONFIG_ARCH_SUPPORTS_MSI is not set +# CONFIG_PCCARD is not set + +# +# Kernel Features +# +# CONFIG_TICK_ONESHOT is not set +# CONFIG_NO_HZ is not set +# CONFIG_HIGH_RES_TIMERS is not set +CONFIG_GENERIC_CLOCKEVENTS_BUILD=y +CONFIG_PREEMPT=y +CONFIG_HZ=100 +CONFIG_AEABI=y +CONFIG_OABI_COMPAT=y +# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set +CONFIG_SELECT_MEMORY_MODEL=y +CONFIG_FLATMEM_MANUAL=y +# CONFIG_DISCONTIGMEM_MANUAL is not set +# CONFIG_SPARSEMEM_MANUAL is not set +CONFIG_FLATMEM=y +CONFIG_FLAT_NODE_MEM_MAP=y +# CONFIG_SPARSEMEM_STATIC is not set +# CONFIG_SPARSEMEM_VMEMMAP_ENABLE is not set +CONFIG_PAGEFLAGS_EXTENDED=y +CONFIG_SPLIT_PTLOCK_CPUS=4096 +# CONFIG_RESOURCES_64BIT is not set +CONFIG_ZONE_DMA_FLAG=1 +CONFIG_BOUNCE=y +CONFIG_VIRT_TO_BUS=y +# CONFIG_LEDS is not set +CONFIG_ALIGNMENT_TRAP=y + +# +# Boot options +# +CONFIG_ZBOOT_ROM_TEXT=0x0 +CONFIG_ZBOOT_ROM_BSS=0x0 +CONFIG_CMDLINE="mem=64M console=ttyS0,115200 initrd=0x21100000,3145728 root=/dev/ram0 rw" +# CONFIG_XIP_KERNEL is not set +# CONFIG_KEXEC is not set + +# +# Floating point emulation +# + +# +# At least one emulation must be selected +# +CONFIG_FPE_NWFPE=y +# CONFIG_FPE_NWFPE_XP is not set +# CONFIG_FPE_FASTFPE is not set +# CONFIG_VFP is not set + +# +# Userspace binary formats +# +CONFIG_BINFMT_ELF=y +# CONFIG_BINFMT_AOUT is not set +# CONFIG_BINFMT_MISC is not set + +# +# Power management options +# +# CONFIG_PM is not set +CONFIG_ARCH_SUSPEND_POSSIBLE=y +CONFIG_NET=y + +# +# Networking options +# +CONFIG_PACKET=y +# CONFIG_PACKET_MMAP is not set +CONFIG_UNIX=y +# CONFIG_NET_KEY is not set +CONFIG_INET=y +# CONFIG_IP_MULTICAST is not set +# CONFIG_IP_ADVANCED_ROUTER is not set +CONFIG_IP_FIB_HASH=y +CONFIG_IP_PNP=y +# CONFIG_IP_PNP_DHCP is not set +CONFIG_IP_PNP_BOOTP=y +# CONFIG_IP_PNP_RARP is not set +# CONFIG_NET_IPIP is not set +# CONFIG_NET_IPGRE is not set +# CONFIG_ARPD is not set +# CONFIG_SYN_COOKIES is not set +# CONFIG_INET_AH is not set +# CONFIG_INET_ESP is not set +# CONFIG_INET_IPCOMP is not set +# CONFIG_INET_XFRM_TUNNEL is not set +# CONFIG_INET_TUNNEL is not set +# CONFIG_INET_XFRM_MODE_TRANSPORT is not set +# CONFIG_INET_XFRM_MODE_TUNNEL is not set +# CONFIG_INET_XFRM_MODE_BEET is not set +# CONFIG_INET_LRO is not set +CONFIG_INET_DIAG=y +CONFIG_INET_TCP_DIAG=y +# CONFIG_TCP_CONG_ADVANCED is not set +CONFIG_TCP_CONG_CUBIC=y +CONFIG_DEFAULT_TCP_CONG="cubic" +# CONFIG_TCP_MD5SIG is not set +# CONFIG_IPV6 is not set +# CONFIG_NETWORK_SECMARK is not set +# CONFIG_NETFILTER is not set +# CONFIG_IP_DCCP is not set +# CONFIG_IP_SCTP is not set +# CONFIG_TIPC is not set +# CONFIG_ATM is not set +# CONFIG_BRIDGE is not set +# CONFIG_VLAN_8021Q is not set +# CONFIG_DECNET is not set +# CONFIG_LLC2 is not set +# CONFIG_IPX is not set +# CONFIG_ATALK is not set +# CONFIG_X25 is not set +# CONFIG_LAPB is not set +# CONFIG_ECONET is not set +# CONFIG_WAN_ROUTER is not set +# CONFIG_NET_SCHED is not set + +# +# Network testing +# +# CONFIG_NET_PKTGEN is not set +# CONFIG_HAMRADIO is not set +# CONFIG_CAN is not set +# CONFIG_IRDA is not set +# CONFIG_BT is not set +# CONFIG_AF_RXRPC is not set + +# +# Wireless +# +# CONFIG_CFG80211 is not set +# CONFIG_WIRELESS_EXT is not set +# CONFIG_MAC80211 is not set +# CONFIG_IEEE80211 is not set +# CONFIG_RFKILL is not set +# CONFIG_NET_9P is not set + +# +# Device Drivers +# + +# +# Generic Driver Options +# +CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" +CONFIG_STANDALONE=y +CONFIG_PREVENT_FIRMWARE_BUILD=y +CONFIG_FW_LOADER=y +CONFIG_FIRMWARE_IN_KERNEL=y +CONFIG_EXTRA_FIRMWARE="" +# CONFIG_DEBUG_DRIVER is not set +# CONFIG_DEBUG_DEVRES is not set +# CONFIG_SYS_HYPERVISOR is not set +# CONFIG_CONNECTOR is not set +CONFIG_MTD=y +# CONFIG_MTD_DEBUG is not set +# CONFIG_MTD_CONCAT is not set +CONFIG_MTD_PARTITIONS=y +# CONFIG_MTD_REDBOOT_PARTS is not set +# CONFIG_MTD_CMDLINE_PARTS is not set +# CONFIG_MTD_AFS_PARTS is not set +# CONFIG_MTD_AR7_PARTS is not set + +# +# User Modules And Translation Layers +# +CONFIG_MTD_CHAR=y +CONFIG_MTD_BLKDEVS=y +CONFIG_MTD_BLOCK=y +# CONFIG_FTL is not set +# CONFIG_NFTL is not set +# CONFIG_INFTL is not set +# CONFIG_RFD_FTL is not set +# CONFIG_SSFDC is not set +# CONFIG_MTD_OOPS is not set + +# +# RAM/ROM/Flash chip drivers +# +# CONFIG_MTD_CFI is not set +# CONFIG_MTD_JEDECPROBE is not set +CONFIG_MTD_MAP_BANK_WIDTH_1=y +CONFIG_MTD_MAP_BANK_WIDTH_2=y +CONFIG_MTD_MAP_BANK_WIDTH_4=y +# CONFIG_MTD_MAP_BANK_WIDTH_8 is not set +# CONFIG_MTD_MAP_BANK_WIDTH_16 is not set +# CONFIG_MTD_MAP_BANK_WIDTH_32 is not set +CONFIG_MTD_CFI_I1=y +CONFIG_MTD_CFI_I2=y +# CONFIG_MTD_CFI_I4 is not set +# CONFIG_MTD_CFI_I8 is not set +# CONFIG_MTD_RAM is not set +# CONFIG_MTD_ROM is not set +# CONFIG_MTD_ABSENT is not set + +# +# Mapping drivers for chip access +# +# CONFIG_MTD_COMPLEX_MAPPINGS is not set +# CONFIG_MTD_PLATRAM is not set + +# +# Self-contained MTD device drivers +# +CONFIG_MTD_DATAFLASH=y +# CONFIG_MTD_M25P80 is not set +# CONFIG_MTD_SLRAM is not set +# CONFIG_MTD_PHRAM is not set +# CONFIG_MTD_MTDRAM is not set +# CONFIG_MTD_BLOCK2MTD is not set + +# +# Disk-On-Chip Device Drivers +# +# CONFIG_MTD_DOC2000 is not set +# CONFIG_MTD_DOC2001 is not set +# CONFIG_MTD_DOC2001PLUS is not set +CONFIG_MTD_NAND=y +# CONFIG_MTD_NAND_VERIFY_WRITE is not set +# CONFIG_MTD_NAND_ECC_SMC is not set +# CONFIG_MTD_NAND_MUSEUM_IDS is not set +CONFIG_MTD_NAND_IDS=y +# CONFIG_MTD_NAND_DISKONCHIP is not set +CONFIG_MTD_NAND_ATMEL=y +# CONFIG_MTD_NAND_ATMEL_ECC_HW is not set +CONFIG_MTD_NAND_ATMEL_ECC_SOFT=y +# CONFIG_MTD_NAND_ATMEL_ECC_NONE is not set +# CONFIG_MTD_NAND_NANDSIM is not set +# CONFIG_MTD_NAND_PLATFORM is not set +# CONFIG_MTD_ALAUDA is not set +# CONFIG_MTD_ONENAND is not set + +# +# UBI - Unsorted block images +# +# CONFIG_MTD_UBI is not set +# CONFIG_PARPORT is not set +CONFIG_BLK_DEV=y +# CONFIG_BLK_DEV_COW_COMMON is not set +# CONFIG_BLK_DEV_LOOP is not set +# CONFIG_BLK_DEV_NBD is not set +# CONFIG_BLK_DEV_UB is not set +CONFIG_BLK_DEV_RAM=y +CONFIG_BLK_DEV_RAM_COUNT=16 +CONFIG_BLK_DEV_RAM_SIZE=8192 +# CONFIG_BLK_DEV_XIP is not set +# CONFIG_CDROM_PKTCDVD is not set +# CONFIG_ATA_OVER_ETH is not set +CONFIG_MISC_DEVICES=y +# CONFIG_ATMEL_PWM is not set +# CONFIG_ATMEL_TCLIB is not set +# CONFIG_EEPROM_93CX6 is not set +CONFIG_ATMEL_SSC=y +# CONFIG_ENCLOSURE_SERVICES is not set +CONFIG_HAVE_IDE=y +# CONFIG_IDE is not set + +# +# SCSI device support +# +# CONFIG_RAID_ATTRS is not set +CONFIG_SCSI=y +CONFIG_SCSI_DMA=y +# CONFIG_SCSI_TGT is not set +# CONFIG_SCSI_NETLINK is not set +CONFIG_SCSI_PROC_FS=y + +# +# SCSI support type (disk, tape, CD-ROM) +# +CONFIG_BLK_DEV_SD=y +# CONFIG_CHR_DEV_ST is not set +# CONFIG_CHR_DEV_OSST is not set +# CONFIG_BLK_DEV_SR is not set +# CONFIG_CHR_DEV_SG is not set +# CONFIG_CHR_DEV_SCH is not set + +# +# Some SCSI devices (e.g. CD jukebox) support multiple LUNs +# +CONFIG_SCSI_MULTI_LUN=y +# CONFIG_SCSI_CONSTANTS is not set +# CONFIG_SCSI_LOGGING is not set +# CONFIG_SCSI_SCAN_ASYNC is not set +CONFIG_SCSI_WAIT_SCAN=m + +# +# SCSI Transports +# +# CONFIG_SCSI_SPI_ATTRS is not set +# CONFIG_SCSI_FC_ATTRS is not set +# CONFIG_SCSI_ISCSI_ATTRS is not set +# CONFIG_SCSI_SAS_LIBSAS is not set +# CONFIG_SCSI_SRP_ATTRS is not set +CONFIG_SCSI_LOWLEVEL=y +# CONFIG_ISCSI_TCP is not set +# CONFIG_SCSI_DEBUG is not set +# CONFIG_SCSI_DH is not set +# CONFIG_ATA is not set +# CONFIG_MD is not set +CONFIG_NETDEVICES=y +# CONFIG_DUMMY is not set +# CONFIG_BONDING is not set +# CONFIG_MACVLAN is not set +# CONFIG_EQUALIZER is not set +# CONFIG_TUN is not set +# CONFIG_VETH is not set +CONFIG_PHYLIB=y + +# +# MII PHY device drivers +# +# CONFIG_MARVELL_PHY is not set +# CONFIG_DAVICOM_PHY is not set +# CONFIG_QSEMI_PHY is not set +# CONFIG_LXT_PHY is not set +# CONFIG_CICADA_PHY is not set +# CONFIG_VITESSE_PHY is not set +# CONFIG_SMSC_PHY is not set +# CONFIG_BROADCOM_PHY is not set +# CONFIG_ICPLUS_PHY is not set +# CONFIG_REALTEK_PHY is not set +# CONFIG_FIXED_PHY is not set +# CONFIG_MDIO_BITBANG is not set +CONFIG_NET_ETHERNET=y +CONFIG_MII=y +CONFIG_MACB=y +CONFIG_MACB_TX_SRAM=y +# CONFIG_AX88796 is not set +# CONFIG_SMC91X is not set +# CONFIG_DM9000 is not set +# CONFIG_ENC28J60 is not set +# CONFIG_IBM_NEW_EMAC_ZMII is not set +# CONFIG_IBM_NEW_EMAC_RGMII is not set +# CONFIG_IBM_NEW_EMAC_TAH is not set +# CONFIG_IBM_NEW_EMAC_EMAC4 is not set +# CONFIG_B44 is not set +# CONFIG_NETDEV_1000 is not set +# CONFIG_NETDEV_10000 is not set + +# +# Wireless LAN +# +# CONFIG_WLAN_PRE80211 is not set +# CONFIG_WLAN_80211 is not set +# CONFIG_IWLWIFI_LEDS is not set + +# +# USB Network Adapters +# +# CONFIG_USB_CATC is not set +# CONFIG_USB_KAWETH is not set +# CONFIG_USB_PEGASUS is not set +# CONFIG_USB_RTL8150 is not set +# CONFIG_USB_USBNET is not set +# CONFIG_WAN is not set +# CONFIG_PPP is not set +# CONFIG_SLIP is not set +# CONFIG_NETCONSOLE is not set +# CONFIG_NETPOLL is not set +# CONFIG_NET_POLL_CONTROLLER is not set +# CONFIG_ISDN is not set + +# +# Input device support +# +CONFIG_INPUT=y +# CONFIG_INPUT_FF_MEMLESS is not set +# CONFIG_INPUT_POLLDEV is not set + +# +# Userland interfaces +# +CONFIG_INPUT_MOUSEDEV=y +# CONFIG_INPUT_MOUSEDEV_PSAUX is not set +CONFIG_INPUT_MOUSEDEV_SCREEN_X=1024 +CONFIG_INPUT_MOUSEDEV_SCREEN_Y=768 +# CONFIG_INPUT_JOYDEV is not set +# CONFIG_INPUT_EVDEV is not set +# CONFIG_INPUT_EVBUG is not set + +# +# Input Device Drivers +# +# CONFIG_INPUT_KEYBOARD is not set +# CONFIG_INPUT_MOUSE is not set +# CONFIG_INPUT_JOYSTICK is not set +# CONFIG_INPUT_TABLET is not set +# CONFIG_INPUT_TOUCHSCREEN is not set +# CONFIG_INPUT_MISC is not set + +# +# Hardware I/O ports +# +# CONFIG_SERIO is not set +# CONFIG_GAMEPORT is not set + +# +# Character devices +# +CONFIG_VT=y +CONFIG_CONSOLE_TRANSLATIONS=y +CONFIG_VT_CONSOLE=y +CONFIG_HW_CONSOLE=y +# CONFIG_VT_HW_CONSOLE_BINDING is not set +CONFIG_DEVKMEM=y +# CONFIG_SERIAL_NONSTANDARD is not set + +# +# Serial drivers +# +# CONFIG_SERIAL_8250 is not set + +# +# Non-8250 serial port support +# +CONFIG_SERIAL_ATMEL=y +CONFIG_SERIAL_ATMEL_CONSOLE=y +CONFIG_SERIAL_ATMEL_PDC=y +# CONFIG_SERIAL_ATMEL_TTYAT is not set +CONFIG_SERIAL_CORE=y +CONFIG_SERIAL_CORE_CONSOLE=y +CONFIG_UNIX98_PTYS=y +CONFIG_LEGACY_PTYS=y +CONFIG_LEGACY_PTY_COUNT=256 +# CONFIG_IPMI_HANDLER is not set +# CONFIG_HW_RANDOM is not set +# CONFIG_NVRAM is not set +# CONFIG_R3964 is not set +# CONFIG_RAW_DRIVER is not set +# CONFIG_TCG_TPM is not set +CONFIG_I2C=y +CONFIG_I2C_BOARDINFO=y +CONFIG_I2C_CHARDEV=y +CONFIG_I2C_ALGOBIT=y + +# +# I2C Hardware Bus support +# + +# +# I2C system bus drivers (mostly embedded / system-on-chip) +# +CONFIG_I2C_GPIO=y +# CONFIG_I2C_OCORES is not set +# CONFIG_I2C_SIMTEC is not set + +# +# External I2C/SMBus adapter drivers +# +# CONFIG_I2C_PARPORT_LIGHT is not set +# CONFIG_I2C_TAOS_EVM is not set +# CONFIG_I2C_TINY_USB is not set + +# +# Other I2C/SMBus bus drivers +# +# CONFIG_I2C_PCA_PLATFORM is not set +# CONFIG_I2C_STUB is not set + +# +# Miscellaneous I2C Chip support +# +# CONFIG_DS1682 is not set +# CONFIG_AT24 is not set +# CONFIG_SENSORS_EEPROM is not set +# CONFIG_SENSORS_PCF8574 is not set +# CONFIG_PCF8575 is not set +# CONFIG_SENSORS_PCA9539 is not set +# CONFIG_SENSORS_PCF8591 is not set +# CONFIG_SENSORS_MAX6875 is not set +# CONFIG_SENSORS_TSL2550 is not set +# CONFIG_I2C_DEBUG_CORE is not set +# CONFIG_I2C_DEBUG_ALGO is not set +# CONFIG_I2C_DEBUG_BUS is not set +# CONFIG_I2C_DEBUG_CHIP is not set +CONFIG_SPI=y +CONFIG_SPI_DEBUG=y +CONFIG_SPI_MASTER=y + +# +# SPI Master Controller Drivers +# +CONFIG_SPI_ATMEL=y +# CONFIG_SPI_BITBANG is not set + +# +# SPI Protocol Masters +# +# CONFIG_SPI_AT25 is not set +CONFIG_SPI_SPIDEV=y +# CONFIG_SPI_TLE62X0 is not set +# CONFIG_W1 is not set +# CONFIG_POWER_SUPPLY is not set +# CONFIG_HWMON is not set +CONFIG_WATCHDOG=y +CONFIG_WATCHDOG_NOWAYOUT=y + +# +# Watchdog Device Drivers +# +# CONFIG_SOFT_WATCHDOG is not set + +# +# USB-based Watchdog Cards +# +# CONFIG_USBPCWATCHDOG is not set + +# +# Sonics Silicon Backplane +# +CONFIG_SSB_POSSIBLE=y +# CONFIG_SSB is not set + +# +# Multifunction device drivers +# +# CONFIG_MFD_CORE is not set +# CONFIG_MFD_SM501 is not set +# CONFIG_HTC_PASIC3 is not set + +# +# Multimedia devices +# + +# +# Multimedia core support +# +# CONFIG_VIDEO_DEV is not set +# CONFIG_DVB_CORE is not set +# CONFIG_VIDEO_MEDIA is not set + +# +# Multimedia drivers +# +# CONFIG_DAB is not set + +# +# Graphics support +# +# CONFIG_VGASTATE is not set +# CONFIG_VIDEO_OUTPUT_CONTROL is not set +# CONFIG_FB is not set +# CONFIG_BACKLIGHT_LCD_SUPPORT is not set + +# +# Display device support +# +# CONFIG_DISPLAY_SUPPORT is not set + +# +# Console display driver support +# +# CONFIG_VGA_CONSOLE is not set +CONFIG_DUMMY_CONSOLE=y +# CONFIG_SOUND is not set +CONFIG_HID_SUPPORT=y +CONFIG_HID=y +# CONFIG_HID_DEBUG is not set +# CONFIG_HIDRAW is not set + +# +# USB Input Devices +# +# CONFIG_USB_HID is not set + +# +# USB HID Boot Protocol drivers +# +# CONFIG_USB_KBD is not set +# CONFIG_USB_MOUSE is not set +CONFIG_USB_SUPPORT=y +CONFIG_USB_ARCH_HAS_HCD=y +CONFIG_USB_ARCH_HAS_OHCI=y +# CONFIG_USB_ARCH_HAS_EHCI is not set +CONFIG_USB=y +# CONFIG_USB_DEBUG is not set +# CONFIG_USB_ANNOUNCE_NEW_DEVICES is not set + +# +# Miscellaneous USB options +# +CONFIG_USB_DEVICEFS=y +CONFIG_USB_DEVICE_CLASS=y +# CONFIG_USB_DYNAMIC_MINORS is not set +# CONFIG_USB_OTG is not set + +# +# USB Host Controller Drivers +# +# CONFIG_USB_C67X00_HCD is not set +# CONFIG_USB_ISP116X_HCD is not set +# CONFIG_USB_ISP1760_HCD is not set +CONFIG_USB_OHCI_HCD=y +# CONFIG_USB_OHCI_BIG_ENDIAN_DESC is not set +# CONFIG_USB_OHCI_BIG_ENDIAN_MMIO is not set +CONFIG_USB_OHCI_LITTLE_ENDIAN=y +# CONFIG_USB_SL811_HCD is not set +# CONFIG_USB_R8A66597_HCD is not set + +# +# USB Device Class drivers +# +# CONFIG_USB_ACM is not set +# CONFIG_USB_PRINTER is not set +# CONFIG_USB_WDM is not set + +# +# NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' +# + +# +# may also be needed; see USB_STORAGE Help for more information +# +CONFIG_USB_STORAGE=y +# CONFIG_USB_STORAGE_DEBUG is not set +# CONFIG_USB_STORAGE_DATAFAB is not set +# CONFIG_USB_STORAGE_FREECOM is not set +# CONFIG_USB_STORAGE_ISD200 is not set +# CONFIG_USB_STORAGE_DPCM is not set +# CONFIG_USB_STORAGE_USBAT is not set +# CONFIG_USB_STORAGE_SDDR09 is not set +# CONFIG_USB_STORAGE_SDDR55 is not set +# CONFIG_USB_STORAGE_JUMPSHOT is not set +# CONFIG_USB_STORAGE_ALAUDA is not set +# CONFIG_USB_STORAGE_ONETOUCH is not set +# CONFIG_USB_STORAGE_KARMA is not set +# CONFIG_USB_STORAGE_CYPRESS_ATACB is not set +# CONFIG_USB_LIBUSUAL is not set + +# +# USB Imaging devices +# +# CONFIG_USB_MDC800 is not set +# CONFIG_USB_MICROTEK is not set +CONFIG_USB_MON=y + +# +# USB port drivers +# +# CONFIG_USB_SERIAL is not set + +# +# USB Miscellaneous drivers +# +# CONFIG_USB_EMI62 is not set +# CONFIG_USB_EMI26 is not set +# CONFIG_USB_ADUTUX is not set +# CONFIG_USB_AUERSWALD is not set +# CONFIG_USB_RIO500 is not set +# CONFIG_USB_LEGOTOWER is not set +# CONFIG_USB_LCD is not set +# CONFIG_USB_BERRY_CHARGE is not set +# CONFIG_USB_LED is not set +# CONFIG_USB_CYPRESS_CY7C63 is not set +# CONFIG_USB_CYTHERM is not set +# CONFIG_USB_PHIDGET is not set +# CONFIG_USB_IDMOUSE is not set +# CONFIG_USB_FTDI_ELAN is not set +# CONFIG_USB_APPLEDISPLAY is not set +# CONFIG_USB_LD is not set +# CONFIG_USB_TRANCEVIBRATOR is not set +# CONFIG_USB_IOWARRIOR is not set +# CONFIG_USB_TEST is not set +# CONFIG_USB_ISIGHTFW is not set +CONFIG_USB_GADGET=y +# CONFIG_USB_GADGET_DEBUG is not set +# CONFIG_USB_GADGET_DEBUG_FILES is not set +CONFIG_USB_GADGET_SELECTED=y +# CONFIG_USB_GADGET_AMD5536UDC is not set +# CONFIG_USB_GADGET_ATMEL_USBA is not set +# CONFIG_USB_GADGET_FSL_USB2 is not set +# CONFIG_USB_GADGET_NET2280 is not set +# CONFIG_USB_GADGET_PXA25X is not set +# CONFIG_USB_GADGET_M66592 is not set +# CONFIG_USB_GADGET_PXA27X is not set +# CONFIG_USB_GADGET_GOKU is not set +# CONFIG_USB_GADGET_LH7A40X is not set +# CONFIG_USB_GADGET_OMAP is not set +# CONFIG_USB_GADGET_S3C2410 is not set +CONFIG_USB_GADGET_AT91=y +CONFIG_USB_AT91=y +# CONFIG_USB_GADGET_DUMMY_HCD is not set +# CONFIG_USB_GADGET_DUALSPEED is not set +CONFIG_USB_ZERO=m +# CONFIG_USB_ETH is not set +CONFIG_USB_GADGETFS=m +CONFIG_USB_FILE_STORAGE=m +# CONFIG_USB_FILE_STORAGE_TEST is not set +CONFIG_USB_G_SERIAL=m +# CONFIG_USB_MIDI_GADGET is not set +# CONFIG_USB_G_PRINTER is not set +# CONFIG_USB_CDC_COMPOSITE is not set +# CONFIG_MMC is not set +# CONFIG_NEW_LEDS is not set +CONFIG_RTC_LIB=y +CONFIG_RTC_CLASS=y +CONFIG_RTC_HCTOSYS=y +CONFIG_RTC_HCTOSYS_DEVICE="rtc0" +CONFIG_RTC_DEBUG=y + +# +# RTC interfaces +# +CONFIG_RTC_INTF_SYSFS=y +CONFIG_RTC_INTF_PROC=y +CONFIG_RTC_INTF_DEV=y +# CONFIG_RTC_INTF_DEV_UIE_EMUL is not set +# CONFIG_RTC_DRV_TEST is not set + +# +# I2C RTC drivers +# +# CONFIG_RTC_DRV_DS1307 is not set +# CONFIG_RTC_DRV_DS1374 is not set +# CONFIG_RTC_DRV_DS1672 is not set +# CONFIG_RTC_DRV_MAX6900 is not set +# CONFIG_RTC_DRV_RS5C372 is not set +# CONFIG_RTC_DRV_ISL1208 is not set +# CONFIG_RTC_DRV_X1205 is not set +# CONFIG_RTC_DRV_PCF8563 is not set +# CONFIG_RTC_DRV_PCF8583 is not set +# CONFIG_RTC_DRV_M41T80 is not set +# CONFIG_RTC_DRV_S35390A is not set +CONFIG_RTC_DRV_FM3130=y + +# +# SPI RTC drivers +# +# CONFIG_RTC_DRV_M41T94 is not set +# CONFIG_RTC_DRV_DS1305 is not set +# CONFIG_RTC_DRV_MAX6902 is not set +# CONFIG_RTC_DRV_R9701 is not set +# CONFIG_RTC_DRV_RS5C348 is not set + +# +# Platform RTC drivers +# +# CONFIG_RTC_DRV_CMOS is not set +# CONFIG_RTC_DRV_DS1511 is not set +# CONFIG_RTC_DRV_DS1553 is not set +# CONFIG_RTC_DRV_DS1742 is not set +# CONFIG_RTC_DRV_STK17TA8 is not set +# CONFIG_RTC_DRV_M48T86 is not set +# CONFIG_RTC_DRV_M48T59 is not set +# CONFIG_RTC_DRV_V3020 is not set + +# +# on-CPU RTC drivers +# +# CONFIG_RTC_DRV_AT91SAM9 is not set +# CONFIG_DMADEVICES is not set + +# +# Voltage and Current regulators +# +# CONFIG_REGULATOR is not set +# CONFIG_REGULATOR_FIXED_VOLTAGE is not set +# CONFIG_REGULATOR_VIRTUAL_CONSUMER is not set +# CONFIG_REGULATOR_BQ24022 is not set +# CONFIG_UIO is not set + +# +# File systems +# +CONFIG_EXT2_FS=y +# CONFIG_EXT2_FS_XATTR is not set +# CONFIG_EXT2_FS_XIP is not set +CONFIG_EXT3_FS=y +CONFIG_EXT3_FS_XATTR=y +# CONFIG_EXT3_FS_POSIX_ACL is not set +# CONFIG_EXT3_FS_SECURITY is not set +# CONFIG_EXT4DEV_FS is not set +CONFIG_JBD=y +CONFIG_FS_MBCACHE=y +# CONFIG_REISERFS_FS is not set +# CONFIG_JFS_FS is not set +# CONFIG_FS_POSIX_ACL is not set +# CONFIG_XFS_FS is not set +# CONFIG_OCFS2_FS is not set +CONFIG_DNOTIFY=y +CONFIG_INOTIFY=y +CONFIG_INOTIFY_USER=y +# CONFIG_QUOTA is not set +# CONFIG_AUTOFS_FS is not set +# CONFIG_AUTOFS4_FS is not set +# CONFIG_FUSE_FS is not set + +# +# CD-ROM/DVD Filesystems +# +# CONFIG_ISO9660_FS is not set +# CONFIG_UDF_FS is not set + +# +# DOS/FAT/NT Filesystems +# +CONFIG_FAT_FS=y +# CONFIG_MSDOS_FS is not set +CONFIG_VFAT_FS=y +CONFIG_FAT_DEFAULT_CODEPAGE=437 +CONFIG_FAT_DEFAULT_IOCHARSET="iso8859-1" +# CONFIG_NTFS_FS is not set + +# +# Pseudo filesystems +# +CONFIG_PROC_FS=y +CONFIG_PROC_SYSCTL=y +CONFIG_SYSFS=y +CONFIG_TMPFS=y +# CONFIG_TMPFS_POSIX_ACL is not set +# CONFIG_HUGETLB_PAGE is not set +# CONFIG_CONFIGFS_FS is not set + +# +# Miscellaneous filesystems +# +# CONFIG_ADFS_FS is not set +# CONFIG_AFFS_FS is not set +# CONFIG_HFS_FS is not set +# CONFIG_HFSPLUS_FS is not set +# CONFIG_BEFS_FS is not set +# CONFIG_BFS_FS is not set +# CONFIG_EFS_FS is not set +CONFIG_JFFS2_FS=y +CONFIG_JFFS2_FS_DEBUG=0 +CONFIG_JFFS2_FS_WRITEBUFFER=y +# CONFIG_JFFS2_FS_WBUF_VERIFY is not set +# CONFIG_JFFS2_SUMMARY is not set +# CONFIG_JFFS2_FS_XATTR is not set +# CONFIG_JFFS2_COMPRESSION_OPTIONS is not set +CONFIG_JFFS2_ZLIB=y +# CONFIG_JFFS2_LZO is not set +CONFIG_JFFS2_RTIME=y +# CONFIG_JFFS2_RUBIN is not set +CONFIG_CRAMFS=y +# CONFIG_VXFS_FS is not set +# CONFIG_MINIX_FS is not set +# CONFIG_OMFS_FS is not set +# CONFIG_HPFS_FS is not set +# CONFIG_QNX4FS_FS is not set +# CONFIG_ROMFS_FS is not set +# CONFIG_SYSV_FS is not set +# CONFIG_UFS_FS is not set +CONFIG_NETWORK_FILESYSTEMS=y +CONFIG_NFS_FS=y +CONFIG_NFS_V3=y +# CONFIG_NFS_V3_ACL is not set +# CONFIG_NFS_V4 is not set +CONFIG_ROOT_NFS=y +# CONFIG_NFSD is not set +CONFIG_LOCKD=y +CONFIG_LOCKD_V4=y +CONFIG_NFS_COMMON=y +CONFIG_SUNRPC=y +# CONFIG_RPCSEC_GSS_KRB5 is not set +# CONFIG_RPCSEC_GSS_SPKM3 is not set +# CONFIG_SMB_FS is not set +# CONFIG_CIFS is not set +# CONFIG_NCP_FS is not set +# CONFIG_CODA_FS is not set +# CONFIG_AFS_FS is not set + +# +# Partition Types +# +# CONFIG_PARTITION_ADVANCED is not set +CONFIG_MSDOS_PARTITION=y +CONFIG_NLS=y +CONFIG_NLS_DEFAULT="iso8859-1" +CONFIG_NLS_CODEPAGE_437=y +# CONFIG_NLS_CODEPAGE_737 is not set +# CONFIG_NLS_CODEPAGE_775 is not set +CONFIG_NLS_CODEPAGE_850=y +# CONFIG_NLS_CODEPAGE_852 is not set +# CONFIG_NLS_CODEPAGE_855 is not set +# CONFIG_NLS_CODEPAGE_857 is not set +# CONFIG_NLS_CODEPAGE_860 is not set +# CONFIG_NLS_CODEPAGE_861 is not set +# CONFIG_NLS_CODEPAGE_862 is not set +# CONFIG_NLS_CODEPAGE_863 is not set +# CONFIG_NLS_CODEPAGE_864 is not set +# CONFIG_NLS_CODEPAGE_865 is not set +# CONFIG_NLS_CODEPAGE_866 is not set +# CONFIG_NLS_CODEPAGE_869 is not set +# CONFIG_NLS_CODEPAGE_936 is not set +# CONFIG_NLS_CODEPAGE_950 is not set +# CONFIG_NLS_CODEPAGE_932 is not set +# CONFIG_NLS_CODEPAGE_949 is not set +# CONFIG_NLS_CODEPAGE_874 is not set +# CONFIG_NLS_ISO8859_8 is not set +# CONFIG_NLS_CODEPAGE_1250 is not set +# CONFIG_NLS_CODEPAGE_1251 is not set +# CONFIG_NLS_ASCII is not set +CONFIG_NLS_ISO8859_1=y +# CONFIG_NLS_ISO8859_2 is not set +# CONFIG_NLS_ISO8859_3 is not set +# CONFIG_NLS_ISO8859_4 is not set +# CONFIG_NLS_ISO8859_5 is not set +# CONFIG_NLS_ISO8859_6 is not set +# CONFIG_NLS_ISO8859_7 is not set +# CONFIG_NLS_ISO8859_9 is not set +# CONFIG_NLS_ISO8859_13 is not set +# CONFIG_NLS_ISO8859_14 is not set +# CONFIG_NLS_ISO8859_15 is not set +# CONFIG_NLS_KOI8_R is not set +# CONFIG_NLS_KOI8_U is not set +# CONFIG_NLS_UTF8 is not set +# CONFIG_DLM is not set + +# +# Kernel hacking +# +# CONFIG_PRINTK_TIME is not set +CONFIG_ENABLE_WARN_DEPRECATED=y +CONFIG_ENABLE_MUST_CHECK=y +CONFIG_FRAME_WARN=1024 +# CONFIG_MAGIC_SYSRQ is not set +# CONFIG_UNUSED_SYMBOLS is not set +# CONFIG_DEBUG_FS is not set +# CONFIG_HEADERS_CHECK is not set +CONFIG_DEBUG_KERNEL=y +# CONFIG_DEBUG_SHIRQ is not set +CONFIG_DETECT_SOFTLOCKUP=y +# CONFIG_BOOTPARAM_SOFTLOCKUP_PANIC is not set +CONFIG_BOOTPARAM_SOFTLOCKUP_PANIC_VALUE=0 +CONFIG_SCHED_DEBUG=y +# CONFIG_SCHEDSTATS is not set +# CONFIG_TIMER_STATS is not set +# CONFIG_DEBUG_OBJECTS is not set +# CONFIG_DEBUG_SLAB is not set +CONFIG_DEBUG_PREEMPT=y +# CONFIG_DEBUG_RT_MUTEXES is not set +# CONFIG_RT_MUTEX_TESTER is not set +# CONFIG_DEBUG_SPINLOCK is not set +# CONFIG_DEBUG_MUTEXES is not set +# CONFIG_DEBUG_LOCK_ALLOC is not set +# CONFIG_PROVE_LOCKING is not set +# CONFIG_LOCK_STAT is not set +# CONFIG_DEBUG_SPINLOCK_SLEEP is not set +# CONFIG_DEBUG_LOCKING_API_SELFTESTS is not set +# CONFIG_DEBUG_KOBJECT is not set +CONFIG_DEBUG_BUGVERBOSE=y +CONFIG_DEBUG_INFO=y +# CONFIG_DEBUG_VM is not set +# CONFIG_DEBUG_WRITECOUNT is not set +CONFIG_DEBUG_MEMORY_INIT=y +# CONFIG_DEBUG_LIST is not set +# CONFIG_DEBUG_SG is not set +CONFIG_FRAME_POINTER=y +# CONFIG_BOOT_PRINTK_DELAY is not set +# CONFIG_RCU_TORTURE_TEST is not set +# CONFIG_BACKTRACE_SELF_TEST is not set +# CONFIG_FAULT_INJECTION is not set +# CONFIG_LATENCYTOP is not set +CONFIG_HAVE_FTRACE=y +CONFIG_HAVE_DYNAMIC_FTRACE=y +# CONFIG_FTRACE is not set +# CONFIG_IRQSOFF_TRACER is not set +# CONFIG_PREEMPT_TRACER is not set +# CONFIG_SCHED_TRACER is not set +# CONFIG_CONTEXT_SWITCH_TRACER is not set +# CONFIG_SAMPLES is not set +CONFIG_HAVE_ARCH_KGDB=y +# CONFIG_KGDB is not set +CONFIG_DEBUG_USER=y +# CONFIG_DEBUG_ERRORS is not set +# CONFIG_DEBUG_STACK_USAGE is not set +CONFIG_DEBUG_LL=y +# CONFIG_DEBUG_ICEDCC is not set + +# +# Security options +# +# CONFIG_KEYS is not set +# CONFIG_SECURITY is not set +# CONFIG_SECURITY_FILE_CAPABILITIES is not set +# CONFIG_CRYPTO is not set + +# +# Library routines +# +CONFIG_BITREVERSE=y +# CONFIG_GENERIC_FIND_FIRST_BIT is not set +# CONFIG_GENERIC_FIND_NEXT_BIT is not set +# CONFIG_CRC_CCITT is not set +# CONFIG_CRC16 is not set +CONFIG_CRC_T10DIF=y +# CONFIG_CRC_ITU_T is not set +CONFIG_CRC32=y +# CONFIG_CRC7 is not set +# CONFIG_LIBCRC32C is not set +CONFIG_ZLIB_INFLATE=y +CONFIG_ZLIB_DEFLATE=y +CONFIG_PLIST=y +CONFIG_HAS_IOMEM=y +CONFIG_HAS_IOPORT=y +CONFIG_HAS_DMA=y diff --git a/packages/linux/linux-2.6.27+2.6.28rc6/afeb9260/0002-SRAM-TX-buffers-implementation-from-atmel-to-fix-TX.patch b/packages/linux/linux-2.6.27+2.6.28rc6/afeb9260/0002-SRAM-TX-buffers-implementation-from-atmel-to-fix-TX.patch deleted file mode 100644 index 9a280d666a..0000000000 --- a/packages/linux/linux-2.6.27+2.6.28rc6/afeb9260/0002-SRAM-TX-buffers-implementation-from-atmel-to-fix-TX.patch +++ /dev/null @@ -1,310 +0,0 @@ -From 856f17b89eb0e943d36f36d0c760e1226db9d716 Mon Sep 17 00:00:00 2001 -From: Sergey Lapin -Date: Fri, 4 Jul 2008 01:52:39 +0400 -Subject: [PATCH] SRAM TX buffers implementation from atmel to fix TX underrun errors - -Signed-off-by: Sergey Lapin ---- - arch/arm/mach-at91/at91sam9260_devices.c | 7 ++ - drivers/net/Kconfig | 6 ++ - drivers/net/macb.c | 108 ++++++++++++++++++++++-------- - drivers/net/macb.h | 7 ++- - 4 files changed, 99 insertions(+), 29 deletions(-) - -diff --git a/arch/arm/mach-at91/at91sam9260_devices.c b/arch/arm/mach-at91/at91sam9260_devices.c -index f5fec0a..681cd40 100644 ---- a/arch/arm/mach-at91/at91sam9260_devices.c -+++ b/arch/arm/mach-at91/at91sam9260_devices.c -@@ -141,6 +141,13 @@ static struct resource eth_resources[] = { - .end = AT91SAM9260_ID_EMAC, - .flags = IORESOURCE_IRQ, - }, -+#if defined(CONFIG_MACB_TX_SRAM) -+ [2] = { -+ .start = AT91SAM9260_SRAM1_BASE, -+ .end = AT91SAM9260_SRAM1_BASE + AT91SAM9260_SRAM1_SIZE - 1, -+ .flags = IORESOURCE_MEM, -+ }, -+#endif - }; - - static struct platform_device at91sam9260_eth_device = { -diff --git a/drivers/net/Kconfig b/drivers/net/Kconfig -index 8a03875..a9a46a8 100644 ---- a/drivers/net/Kconfig -+++ b/drivers/net/Kconfig -@@ -218,6 +218,12 @@ config MACB - To compile this driver as a module, choose M here: the module - will be called macb. - -+config MACB_TX_SRAM -+ bool "Use internal SRAM for EMAC (Ethernet) transmit buffers" -+ depends on (ARCH_AT91SAM9263 || ARCH_AT91SAM9260) && MACB -+ help -+ Select this if you are using internal SRAM for EMAC transmit buffers. -+ - source "drivers/net/arm/Kconfig" - - config AX88796 -diff --git a/drivers/net/macb.c b/drivers/net/macb.c -index daba82b..55063dc 100644 ---- a/drivers/net/macb.c -+++ b/drivers/net/macb.c -@@ -33,22 +33,27 @@ - /* Make the IP header word-aligned (the ethernet header is 14 bytes) */ - #define RX_OFFSET 2 - --#define TX_RING_SIZE 128 --#define DEF_TX_RING_PENDING (TX_RING_SIZE - 1) --#define TX_RING_BYTES (sizeof(struct dma_desc) * TX_RING_SIZE) -+#define TX_MAX_PKT_SIZE 1536 -+#define TX_DEFAULT_RING_SIZE 128 -+#define DEF_TX_RING_PENDING(bp) ((bp)->tx_ring_size - 1) -+ -+#define TX_RING_BYTES(bp) (sizeof(struct dma_desc) * \ -+ (bp)->tx_ring_size) - - #define TX_RING_GAP(bp) \ -- (TX_RING_SIZE - (bp)->tx_pending) -+ ((bp)->tx_ring_size - (bp)->tx_pending) -+ - #define TX_BUFFS_AVAIL(bp) \ - (((bp)->tx_tail <= (bp)->tx_head) ? \ - (bp)->tx_tail + (bp)->tx_pending - (bp)->tx_head : \ - (bp)->tx_tail - (bp)->tx_head - TX_RING_GAP(bp)) --#define NEXT_TX(n) (((n) + 1) & (TX_RING_SIZE - 1)) - --#define NEXT_RX(n) (((n) + 1) & (RX_RING_SIZE - 1)) -+#define NEXT_TX(bp, n) (((n) + 1) % ((bp)->tx_ring_size)) -+#define NEXT_RX(n) (((n) + 1) % (RX_RING_SIZE)) -+ - - /* minimum number of free TX descriptors before waking up TX process */ --#define MACB_TX_WAKEUP_THRESH (TX_RING_SIZE / 4) -+#define MACB_TX_WAKEUP_THRESH(bp) ((bp)->tx_ring_size / 4) - - #define MACB_RX_INT_FLAGS (MACB_BIT(RCOMP) | MACB_BIT(RXUBR) \ - | MACB_BIT(ISR_ROVR)) -@@ -316,11 +321,11 @@ static void macb_tx(struct macb *bp) - head = bp->tx_head; - - /*Mark all the buffer as used to avoid sending a lost buffer*/ -- for (i = 0; i < TX_RING_SIZE; i++) -+ for (i = 0; i < bp->tx_ring_size; i++) - bp->tx_ring[i].ctrl = MACB_BIT(TX_USED); - - /* free transmit buffer in upper layer*/ -- for (tail = bp->tx_tail; tail != head; tail = NEXT_TX(tail)) { -+ for (tail = bp->tx_tail; tail != head; tail = NEXT_TX(bp, tail)) { - struct ring_info *rp = &bp->tx_skb[tail]; - struct sk_buff *skb = rp->skb; - -@@ -346,7 +351,7 @@ static void macb_tx(struct macb *bp) - return; - - head = bp->tx_head; -- for (tail = bp->tx_tail; tail != head; tail = NEXT_TX(tail)) { -+ for (tail = bp->tx_tail; tail != head; tail = NEXT_TX(bp, tail)) { - struct ring_info *rp = &bp->tx_skb[tail]; - struct sk_buff *skb = rp->skb; - u32 bufstat; -@@ -371,7 +376,7 @@ static void macb_tx(struct macb *bp) - - bp->tx_tail = tail; - if (netif_queue_stopped(bp->dev) && -- TX_BUFFS_AVAIL(bp) > MACB_TX_WAKEUP_THRESH) -+ TX_BUFFS_AVAIL(bp) > MACB_TX_WAKEUP_THRESH(bp)) - netif_wake_queue(bp->dev); - } - -@@ -401,6 +406,7 @@ static int macb_rx_frame(struct macb *bp, unsigned int first_frag, - } - - skb_reserve(skb, RX_OFFSET); -+ skb->dev = bp->dev; - skb->ip_summed = CHECKSUM_NONE; - skb_put(skb, len); - -@@ -637,8 +643,15 @@ static int macb_start_xmit(struct sk_buff *skb, struct net_device *dev) - - entry = bp->tx_head; - dev_dbg(&bp->pdev->dev, "Allocated ring entry %u\n", entry); -- mapping = dma_map_single(&bp->pdev->dev, skb->data, -+ if (bp->smem_start) { -+ mapping = bp->tx_ring[entry].addr; -+ memcpy(bp->tx_buffers + entry * TX_MAX_PKT_SIZE, -+ skb->data, len); -+ } else { -+ mapping = dma_map_single(&bp->pdev->dev, skb->data, - len, DMA_TO_DEVICE); -+ bp->tx_ring[entry].addr = mapping; -+ } - bp->tx_skb[entry].skb = skb; - bp->tx_skb[entry].mapping = mapping; - dev_dbg(&bp->pdev->dev, "Mapped skb data %p to DMA addr %08lx\n", -@@ -646,14 +659,13 @@ static int macb_start_xmit(struct sk_buff *skb, struct net_device *dev) - - ctrl = MACB_BF(TX_FRMLEN, len); - ctrl |= MACB_BIT(TX_LAST); -- if (entry == (TX_RING_SIZE - 1)) -+ if (entry == (bp->tx_ring_size - 1)) - ctrl |= MACB_BIT(TX_WRAP); - -- bp->tx_ring[entry].addr = mapping; - bp->tx_ring[entry].ctrl = ctrl; - wmb(); - -- entry = NEXT_TX(entry); -+ entry = NEXT_TX(bp, entry); - bp->tx_head = entry; - - macb_writel(bp, NCR, macb_readl(bp, NCR) | MACB_BIT(TSTART)); -@@ -680,7 +692,8 @@ static void macb_free_consistent(struct macb *bp) - bp->rx_ring = NULL; - } - if (bp->tx_ring) { -- dma_free_coherent(&bp->pdev->dev, TX_RING_BYTES, -+ if (!bp->smem_start) -+ dma_free_coherent(&bp->pdev->dev, TX_RING_BYTES(bp), - bp->tx_ring, bp->tx_ring_dma); - bp->tx_ring = NULL; - } -@@ -690,13 +703,16 @@ static void macb_free_consistent(struct macb *bp) - bp->rx_buffers, bp->rx_buffers_dma); - bp->rx_buffers = NULL; - } -+ -+ if (bp->smem_start && bp->tx_ring_dma) -+ release_mem_region(bp->tx_ring_dma, bp->smem_size); - } - - static int macb_alloc_consistent(struct macb *bp) - { - int size; - -- size = TX_RING_SIZE * sizeof(struct ring_info); -+ size = bp->tx_ring_size * sizeof(struct ring_info); - bp->tx_skb = kmalloc(size, GFP_KERNEL); - if (!bp->tx_skb) - goto out_err; -@@ -710,14 +726,30 @@ static int macb_alloc_consistent(struct macb *bp) - "Allocated RX ring of %d bytes at %08lx (mapped %p)\n", - size, (unsigned long)bp->rx_ring_dma, bp->rx_ring); - -- size = TX_RING_BYTES; -- bp->tx_ring = dma_alloc_coherent(&bp->pdev->dev, size, -+ if (bp->smem_start) { -+ if (request_mem_region(bp->smem_start, -+ bp->smem_size, "macb")) { -+ bp->tx_ring_dma = bp->smem_start; -+ } -+ bp->tx_ring = ioremap(bp->tx_ring_dma, bp->smem_size); -+ if (bp->tx_ring) { -+ bp->tx_buffers_dma = bp->tx_ring_dma + -+ TX_RING_BYTES(bp); -+ bp->tx_buffers = (char *) bp->tx_ring + -+ TX_RING_BYTES(bp); -+ } -+ } -+ -+ if (!bp->tx_ring) { -+ size = TX_RING_BYTES(bp); -+ bp->tx_ring = dma_alloc_coherent(&bp->pdev->dev, size, - &bp->tx_ring_dma, GFP_KERNEL); -- if (!bp->tx_ring) -- goto out_err; -- dev_dbg(&bp->pdev->dev, -- "Allocated TX ring of %d bytes at %08lx (mapped %p)\n", -- size, (unsigned long)bp->tx_ring_dma, bp->tx_ring); -+ if (!bp->tx_ring) -+ goto out_err; -+ dev_dbg(&bp->pdev->dev, -+ "Allocated TX ring of %d bytes at %08lx (mapped %p)\n", -+ size, (unsigned long)bp->tx_ring_dma, bp->tx_ring); -+ } - - size = RX_RING_SIZE * RX_BUFFER_SIZE; - bp->rx_buffers = dma_alloc_coherent(&bp->pdev->dev, size, -@@ -748,11 +780,14 @@ static void macb_init_rings(struct macb *bp) - } - bp->rx_ring[RX_RING_SIZE - 1].addr |= MACB_BIT(RX_WRAP); - -- for (i = 0; i < TX_RING_SIZE; i++) { -- bp->tx_ring[i].addr = 0; -+ for (i = 0; i < bp->tx_ring_size; i++) { -+ bp->tx_ring[i].addr = (bp->smem_start) ? -+ bp->tx_buffers_dma + i * TX_MAX_PKT_SIZE : 0; - bp->tx_ring[i].ctrl = MACB_BIT(TX_USED); -+ bp->tx_ring[i].addr = (u32) (bp->tx_buffers_dma + -+ (i * TX_MAX_PKT_SIZE)); - } -- bp->tx_ring[TX_RING_SIZE - 1].ctrl |= MACB_BIT(TX_WRAP); -+ bp->tx_ring[bp->tx_ring_size - 1].ctrl |= MACB_BIT(TX_WRAP); - - bp->rx_tail = bp->tx_head = bp->tx_tail = 0; - } -@@ -1090,6 +1125,7 @@ static int __init macb_probe(struct platform_device *pdev) - { - struct eth_platform_data *pdata; - struct resource *regs; -+ struct resource *smem; - struct net_device *dev; - struct macb *bp; - struct phy_device *phydev; -@@ -1201,7 +1237,23 @@ static int __init macb_probe(struct platform_device *pdev) - macb_writel(bp, USRIO, MACB_BIT(MII)); - #endif - -- bp->tx_pending = DEF_TX_RING_PENDING; -+ /* Check mem region for TX buffers */ -+ smem = platform_get_resource(pdev, IORESOURCE_MEM, 1); -+ if (smem) { -+ bp->smem_start = smem->start; -+ bp->smem_size = smem->end - smem->start + 1; -+ bp->tx_ring_size = bp->smem_size / (TX_MAX_PKT_SIZE + -+ sizeof(struct dma_desc)); -+ } -+ -+ /* if ring_size == 0 then mem is too -+ small and use standard memory */ -+ if (!bp->tx_ring_size) { -+ bp->smem_start = 0; -+ bp->tx_ring_size = TX_DEFAULT_RING_SIZE; -+ } -+ -+ bp->tx_pending = DEF_TX_RING_PENDING(bp); - - err = register_netdev(dev); - if (err) { -diff --git a/drivers/net/macb.h b/drivers/net/macb.h -index 57b85ac..faa5a9d 100644 ---- a/drivers/net/macb.h -+++ b/drivers/net/macb.h -@@ -364,11 +364,15 @@ struct macb { - unsigned int rx_tail; - struct dma_desc *rx_ring; - void *rx_buffers; -- -+ void *tx_buffers; -+ unsigned int tx_ring_size; - unsigned int tx_head, tx_tail; - struct dma_desc *tx_ring; - struct ring_info *tx_skb; - -+ unsigned int smem_start; -+ unsigned int smem_size; -+ - spinlock_t lock; - struct platform_device *pdev; - struct clk *pclk; -@@ -381,6 +385,7 @@ struct macb { - dma_addr_t rx_ring_dma; - dma_addr_t tx_ring_dma; - dma_addr_t rx_buffers_dma; -+ dma_addr_t tx_buffers_dma; - - unsigned int rx_pending, tx_pending; - --- -1.5.4.1 - diff --git a/packages/linux/linux-2.6.27+2.6.28rc6/afeb9260/0003-RS-485-mode-of-USART1.patch b/packages/linux/linux-2.6.27+2.6.28rc6/afeb9260/0003-RS-485-mode-of-USART1.patch deleted file mode 100644 index e60088794f..0000000000 --- a/packages/linux/linux-2.6.27+2.6.28rc6/afeb9260/0003-RS-485-mode-of-USART1.patch +++ /dev/null @@ -1,41 +0,0 @@ -From 5374be6a8f2644e33e436b1864188442e1b2c156 Mon Sep 17 00:00:00 2001 -From: Sergey Lapin -Date: Fri, 4 Jul 2008 01:53:23 +0400 -Subject: [PATCH] RS-485 mode of USART1 - -Signed-off-by: Sergey Lapin ---- - drivers/serial/atmel_serial.c | 9 ++++++++- - 1 files changed, 8 insertions(+), 1 deletions(-) - -diff --git a/drivers/serial/atmel_serial.c b/drivers/serial/atmel_serial.c -index 1fee12c..20ced47 100644 ---- a/drivers/serial/atmel_serial.c -+++ b/drivers/serial/atmel_serial.c -@@ -233,8 +233,12 @@ static void atmel_set_mctrl(struct uart_port *port, u_int mctrl) - mode = UART_GET_MR(port) & ~ATMEL_US_CHMODE; - if (mctrl & TIOCM_LOOP) - mode |= ATMEL_US_CHMODE_LOC_LOOP; -- else -+ else { -+ if (port->mapbase == AT91SAM9260_BASE_US1) -+ mode |= ATMEL_US_USMODE_RS485; -+ - mode |= ATMEL_US_CHMODE_NORMAL; -+ } - UART_PUT_MR(port, mode); - } - -@@ -1094,6 +1098,9 @@ static void atmel_set_termios(struct uart_port *port, struct ktermios *termios, - /* disable receiver and transmitter */ - UART_PUT_CR(port, ATMEL_US_TXDIS | ATMEL_US_RXDIS); - -+ if (port->mapbase == AT91SAM9260_BASE_US1) -+ mode |= ATMEL_US_USMODE_RS485; -+ - /* set the parity, stop bits and data size */ - UART_PUT_MR(port, mode); - --- -1.5.4.1 - diff --git a/packages/linux/linux-2.6.27+2.6.28rc6/afeb9260/defconfig b/packages/linux/linux-2.6.27+2.6.28rc6/afeb9260/defconfig deleted file mode 100644 index eed8512d99..0000000000 --- a/packages/linux/linux-2.6.27+2.6.28rc6/afeb9260/defconfig +++ /dev/null @@ -1,1256 +0,0 @@ -# -# Automatically generated make config: don't edit -# Linux kernel version: 2.6.27-rc2 -# Thu Aug 7 22:03:55 2008 -# -CONFIG_ARM=y -CONFIG_SYS_SUPPORTS_APM_EMULATION=y -CONFIG_GENERIC_GPIO=y -CONFIG_GENERIC_TIME=y -CONFIG_GENERIC_CLOCKEVENTS=y -CONFIG_MMU=y -# CONFIG_NO_IOPORT is not set -CONFIG_GENERIC_HARDIRQS=y -CONFIG_STACKTRACE_SUPPORT=y -CONFIG_HAVE_LATENCYTOP_SUPPORT=y -CONFIG_LOCKDEP_SUPPORT=y -CONFIG_TRACE_IRQFLAGS_SUPPORT=y -CONFIG_HARDIRQS_SW_RESEND=y -CONFIG_GENERIC_IRQ_PROBE=y -CONFIG_RWSEM_GENERIC_SPINLOCK=y -# CONFIG_ARCH_HAS_ILOG2_U32 is not set -# CONFIG_ARCH_HAS_ILOG2_U64 is not set -CONFIG_GENERIC_HWEIGHT=y -CONFIG_GENERIC_CALIBRATE_DELAY=y -CONFIG_ARCH_SUPPORTS_AOUT=y -CONFIG_ZONE_DMA=y -CONFIG_GENERIC_HARDIRQS_NO__DO_IRQ=y -CONFIG_VECTORS_BASE=0xffff0000 -CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" - -# -# General setup -# -CONFIG_EXPERIMENTAL=y -CONFIG_BROKEN_ON_SMP=y -CONFIG_LOCK_KERNEL=y -CONFIG_INIT_ENV_ARG_LIMIT=32 -CONFIG_LOCALVERSION="" -# CONFIG_LOCALVERSION_AUTO is not set -CONFIG_SWAP=y -CONFIG_SYSVIPC=y -CONFIG_SYSVIPC_SYSCTL=y -# CONFIG_POSIX_MQUEUE is not set -# CONFIG_BSD_PROCESS_ACCT is not set -# CONFIG_TASKSTATS is not set -# CONFIG_AUDIT is not set -# CONFIG_IKCONFIG is not set -CONFIG_LOG_BUF_SHIFT=14 -# CONFIG_CGROUPS is not set -# CONFIG_GROUP_SCHED is not set -CONFIG_SYSFS_DEPRECATED=y -CONFIG_SYSFS_DEPRECATED_V2=y -# CONFIG_RELAY is not set -CONFIG_NAMESPACES=y -# CONFIG_UTS_NS is not set -# CONFIG_IPC_NS is not set -# CONFIG_USER_NS is not set -# CONFIG_PID_NS is not set -CONFIG_BLK_DEV_INITRD=y -CONFIG_INITRAMFS_SOURCE="" -CONFIG_CC_OPTIMIZE_FOR_SIZE=y -CONFIG_SYSCTL=y -# CONFIG_EMBEDDED is not set -CONFIG_UID16=y -CONFIG_SYSCTL_SYSCALL=y -CONFIG_SYSCTL_SYSCALL_CHECK=y -CONFIG_KALLSYMS=y -# CONFIG_KALLSYMS_ALL is not set -# CONFIG_KALLSYMS_EXTRA_PASS is not set -CONFIG_HOTPLUG=y -CONFIG_PRINTK=y -CONFIG_BUG=y -CONFIG_ELF_CORE=y -CONFIG_COMPAT_BRK=y -CONFIG_BASE_FULL=y -CONFIG_FUTEX=y -CONFIG_ANON_INODES=y -CONFIG_EPOLL=y -CONFIG_SIGNALFD=y -CONFIG_TIMERFD=y -CONFIG_EVENTFD=y -CONFIG_SHMEM=y -CONFIG_VM_EVENT_COUNTERS=y -CONFIG_SLAB=y -# CONFIG_SLUB is not set -# CONFIG_SLOB is not set -# CONFIG_PROFILING is not set -# CONFIG_MARKERS is not set -CONFIG_HAVE_OPROFILE=y -# CONFIG_KPROBES is not set -# CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS is not set -# CONFIG_HAVE_IOREMAP_PROT is not set -CONFIG_HAVE_KPROBES=y -CONFIG_HAVE_KRETPROBES=y -# CONFIG_HAVE_ARCH_TRACEHOOK is not set -# CONFIG_HAVE_DMA_ATTRS is not set -# CONFIG_USE_GENERIC_SMP_HELPERS is not set -CONFIG_HAVE_CLK=y -CONFIG_PROC_PAGE_MONITOR=y -CONFIG_HAVE_GENERIC_DMA_COHERENT=y -CONFIG_SLABINFO=y -CONFIG_RT_MUTEXES=y -# CONFIG_TINY_SHMEM is not set -CONFIG_BASE_SMALL=0 -CONFIG_MODULES=y -# CONFIG_MODULE_FORCE_LOAD is not set -CONFIG_MODULE_UNLOAD=y -# CONFIG_MODULE_FORCE_UNLOAD is not set -# CONFIG_MODVERSIONS is not set -# CONFIG_MODULE_SRCVERSION_ALL is not set -CONFIG_KMOD=y -CONFIG_BLOCK=y -# CONFIG_LBD is not set -# CONFIG_BLK_DEV_IO_TRACE is not set -# CONFIG_LSF is not set -# CONFIG_BLK_DEV_BSG is not set -# CONFIG_BLK_DEV_INTEGRITY is not set - -# -# IO Schedulers -# -CONFIG_IOSCHED_NOOP=y -CONFIG_IOSCHED_AS=y -# CONFIG_IOSCHED_DEADLINE is not set -# CONFIG_IOSCHED_CFQ is not set -CONFIG_DEFAULT_AS=y -# CONFIG_DEFAULT_DEADLINE is not set -# CONFIG_DEFAULT_CFQ is not set -# CONFIG_DEFAULT_NOOP is not set -CONFIG_DEFAULT_IOSCHED="anticipatory" -CONFIG_CLASSIC_RCU=y - -# -# System Type -# -# CONFIG_ARCH_AAEC2000 is not set -# CONFIG_ARCH_INTEGRATOR is not set -# CONFIG_ARCH_REALVIEW is not set -# CONFIG_ARCH_VERSATILE is not set -CONFIG_ARCH_AT91=y -# CONFIG_ARCH_CLPS7500 is not set -# CONFIG_ARCH_CLPS711X is not set -# CONFIG_ARCH_EBSA110 is not set -# CONFIG_ARCH_EP93XX is not set -# CONFIG_ARCH_FOOTBRIDGE is not set -# CONFIG_ARCH_NETX is not set -# CONFIG_ARCH_H720X is not set -# CONFIG_ARCH_IMX is not set -# CONFIG_ARCH_IOP13XX is not set -# CONFIG_ARCH_IOP32X is not set -# CONFIG_ARCH_IOP33X is not set -# CONFIG_ARCH_IXP23XX is not set -# CONFIG_ARCH_IXP2000 is not set -# CONFIG_ARCH_IXP4XX is not set -# CONFIG_ARCH_L7200 is not set -# CONFIG_ARCH_KIRKWOOD is not set -# CONFIG_ARCH_KS8695 is not set -# CONFIG_ARCH_NS9XXX is not set -# CONFIG_ARCH_LOKI is not set -# CONFIG_ARCH_MV78XX0 is not set -# CONFIG_ARCH_MXC is not set -# CONFIG_ARCH_ORION5X is not set -# CONFIG_ARCH_PNX4008 is not set -# CONFIG_ARCH_PXA is not set -# CONFIG_ARCH_RPC is not set -# CONFIG_ARCH_SA1100 is not set -# CONFIG_ARCH_S3C2410 is not set -# CONFIG_ARCH_SHARK is not set -# CONFIG_ARCH_LH7A40X is not set -# CONFIG_ARCH_DAVINCI is not set -# CONFIG_ARCH_OMAP is not set -# CONFIG_ARCH_MSM7X00A is not set - -# -# Boot options -# - -# -# Power management -# - -# -# Atmel AT91 System-on-Chip -# -# CONFIG_ARCH_AT91RM9200 is not set -CONFIG_ARCH_AT91SAM9260=y -# CONFIG_ARCH_AT91SAM9261 is not set -# CONFIG_ARCH_AT91SAM9263 is not set -# CONFIG_ARCH_AT91SAM9RL is not set -# CONFIG_ARCH_AT91SAM9G20 is not set -# CONFIG_ARCH_AT91CAP9 is not set -# CONFIG_ARCH_AT91X40 is not set -CONFIG_AT91_PMC_UNIT=y - -# -# AT91SAM9260 Variants -# -# CONFIG_ARCH_AT91SAM9260_SAM9XE is not set - -# -# AT91SAM9260 / AT91SAM9XE Board Type -# -# CONFIG_MACH_AT91SAM9260EK is not set -# CONFIG_MACH_CAM60 is not set -# CONFIG_MACH_SAM9_L9260 is not set -CONFIG_MACH_AFEB9260=y -# CONFIG_MACH_USB_A9260 is not set -# CONFIG_MACH_QIL_A9260 is not set - -# -# AT91 Board Options -# - -# -# AT91 Feature Selections -# -CONFIG_AT91_PROGRAMMABLE_CLOCKS=y -CONFIG_AT91_TIMER_HZ=100 -CONFIG_AT91_EARLY_DBGU=y -# CONFIG_AT91_EARLY_USART0 is not set -# CONFIG_AT91_EARLY_USART1 is not set -# CONFIG_AT91_EARLY_USART2 is not set -# CONFIG_AT91_EARLY_USART3 is not set -# CONFIG_AT91_EARLY_USART4 is not set -# CONFIG_AT91_EARLY_USART5 is not set - -# -# Processor Type -# -CONFIG_CPU_32=y -CONFIG_CPU_ARM926T=y -CONFIG_CPU_32v5=y -CONFIG_CPU_ABRT_EV5TJ=y -CONFIG_CPU_PABRT_NOIFAR=y -CONFIG_CPU_CACHE_VIVT=y -CONFIG_CPU_COPY_V4WB=y -CONFIG_CPU_TLB_V4WBI=y -CONFIG_CPU_CP15=y -CONFIG_CPU_CP15_MMU=y - -# -# Processor Features -# -CONFIG_ARM_THUMB=y -# CONFIG_CPU_ICACHE_DISABLE is not set -# CONFIG_CPU_DCACHE_DISABLE is not set -# CONFIG_CPU_DCACHE_WRITETHROUGH is not set -# CONFIG_CPU_CACHE_ROUND_ROBIN is not set -# CONFIG_OUTER_CACHE is not set - -# -# Bus support -# -# CONFIG_PCI_SYSCALL is not set -# CONFIG_ARCH_SUPPORTS_MSI is not set -# CONFIG_PCCARD is not set - -# -# Kernel Features -# -# CONFIG_TICK_ONESHOT is not set -# CONFIG_NO_HZ is not set -# CONFIG_HIGH_RES_TIMERS is not set -CONFIG_GENERIC_CLOCKEVENTS_BUILD=y -CONFIG_PREEMPT=y -CONFIG_HZ=100 -CONFIG_AEABI=y -CONFIG_OABI_COMPAT=y -# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set -CONFIG_SELECT_MEMORY_MODEL=y -CONFIG_FLATMEM_MANUAL=y -# CONFIG_DISCONTIGMEM_MANUAL is not set -# CONFIG_SPARSEMEM_MANUAL is not set -CONFIG_FLATMEM=y -CONFIG_FLAT_NODE_MEM_MAP=y -# CONFIG_SPARSEMEM_STATIC is not set -# CONFIG_SPARSEMEM_VMEMMAP_ENABLE is not set -CONFIG_PAGEFLAGS_EXTENDED=y -CONFIG_SPLIT_PTLOCK_CPUS=4096 -# CONFIG_RESOURCES_64BIT is not set -CONFIG_ZONE_DMA_FLAG=1 -CONFIG_BOUNCE=y -CONFIG_VIRT_TO_BUS=y -# CONFIG_LEDS is not set -CONFIG_ALIGNMENT_TRAP=y - -# -# Boot options -# -CONFIG_ZBOOT_ROM_TEXT=0x0 -CONFIG_ZBOOT_ROM_BSS=0x0 -CONFIG_CMDLINE="mem=64M console=ttyS0,115200 initrd=0x21100000,3145728 root=/dev/ram0 rw" -# CONFIG_XIP_KERNEL is not set -# CONFIG_KEXEC is not set - -# -# Floating point emulation -# - -# -# At least one emulation must be selected -# -CONFIG_FPE_NWFPE=y -# CONFIG_FPE_NWFPE_XP is not set -# CONFIG_FPE_FASTFPE is not set -# CONFIG_VFP is not set - -# -# Userspace binary formats -# -CONFIG_BINFMT_ELF=y -# CONFIG_BINFMT_AOUT is not set -# CONFIG_BINFMT_MISC is not set - -# -# Power management options -# -# CONFIG_PM is not set -CONFIG_ARCH_SUSPEND_POSSIBLE=y -CONFIG_NET=y - -# -# Networking options -# -CONFIG_PACKET=y -# CONFIG_PACKET_MMAP is not set -CONFIG_UNIX=y -# CONFIG_NET_KEY is not set -CONFIG_INET=y -# CONFIG_IP_MULTICAST is not set -# CONFIG_IP_ADVANCED_ROUTER is not set -CONFIG_IP_FIB_HASH=y -CONFIG_IP_PNP=y -# CONFIG_IP_PNP_DHCP is not set -CONFIG_IP_PNP_BOOTP=y -# CONFIG_IP_PNP_RARP is not set -# CONFIG_NET_IPIP is not set -# CONFIG_NET_IPGRE is not set -# CONFIG_ARPD is not set -# CONFIG_SYN_COOKIES is not set -# CONFIG_INET_AH is not set -# CONFIG_INET_ESP is not set -# CONFIG_INET_IPCOMP is not set -# CONFIG_INET_XFRM_TUNNEL is not set -# CONFIG_INET_TUNNEL is not set -# CONFIG_INET_XFRM_MODE_TRANSPORT is not set -# CONFIG_INET_XFRM_MODE_TUNNEL is not set -# CONFIG_INET_XFRM_MODE_BEET is not set -# CONFIG_INET_LRO is not set -CONFIG_INET_DIAG=y -CONFIG_INET_TCP_DIAG=y -# CONFIG_TCP_CONG_ADVANCED is not set -CONFIG_TCP_CONG_CUBIC=y -CONFIG_DEFAULT_TCP_CONG="cubic" -# CONFIG_TCP_MD5SIG is not set -# CONFIG_IPV6 is not set -# CONFIG_NETWORK_SECMARK is not set -# CONFIG_NETFILTER is not set -# CONFIG_IP_DCCP is not set -# CONFIG_IP_SCTP is not set -# CONFIG_TIPC is not set -# CONFIG_ATM is not set -# CONFIG_BRIDGE is not set -# CONFIG_VLAN_8021Q is not set -# CONFIG_DECNET is not set -# CONFIG_LLC2 is not set -# CONFIG_IPX is not set -# CONFIG_ATALK is not set -# CONFIG_X25 is not set -# CONFIG_LAPB is not set -# CONFIG_ECONET is not set -# CONFIG_WAN_ROUTER is not set -# CONFIG_NET_SCHED is not set - -# -# Network testing -# -# CONFIG_NET_PKTGEN is not set -# CONFIG_HAMRADIO is not set -# CONFIG_CAN is not set -# CONFIG_IRDA is not set -# CONFIG_BT is not set -# CONFIG_AF_RXRPC is not set - -# -# Wireless -# -# CONFIG_CFG80211 is not set -# CONFIG_WIRELESS_EXT is not set -# CONFIG_MAC80211 is not set -# CONFIG_IEEE80211 is not set -# CONFIG_RFKILL is not set -# CONFIG_NET_9P is not set - -# -# Device Drivers -# - -# -# Generic Driver Options -# -CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" -CONFIG_STANDALONE=y -CONFIG_PREVENT_FIRMWARE_BUILD=y -CONFIG_FW_LOADER=y -CONFIG_FIRMWARE_IN_KERNEL=y -CONFIG_EXTRA_FIRMWARE="" -# CONFIG_DEBUG_DRIVER is not set -# CONFIG_DEBUG_DEVRES is not set -# CONFIG_SYS_HYPERVISOR is not set -# CONFIG_CONNECTOR is not set -CONFIG_MTD=y -# CONFIG_MTD_DEBUG is not set -# CONFIG_MTD_CONCAT is not set -CONFIG_MTD_PARTITIONS=y -# CONFIG_MTD_REDBOOT_PARTS is not set -# CONFIG_MTD_CMDLINE_PARTS is not set -# CONFIG_MTD_AFS_PARTS is not set -# CONFIG_MTD_AR7_PARTS is not set - -# -# User Modules And Translation Layers -# -CONFIG_MTD_CHAR=y -CONFIG_MTD_BLKDEVS=y -CONFIG_MTD_BLOCK=y -# CONFIG_FTL is not set -# CONFIG_NFTL is not set -# CONFIG_INFTL is not set -# CONFIG_RFD_FTL is not set -# CONFIG_SSFDC is not set -# CONFIG_MTD_OOPS is not set - -# -# RAM/ROM/Flash chip drivers -# -# CONFIG_MTD_CFI is not set -# CONFIG_MTD_JEDECPROBE is not set -CONFIG_MTD_MAP_BANK_WIDTH_1=y -CONFIG_MTD_MAP_BANK_WIDTH_2=y -CONFIG_MTD_MAP_BANK_WIDTH_4=y -# CONFIG_MTD_MAP_BANK_WIDTH_8 is not set -# CONFIG_MTD_MAP_BANK_WIDTH_16 is not set -# CONFIG_MTD_MAP_BANK_WIDTH_32 is not set -CONFIG_MTD_CFI_I1=y -CONFIG_MTD_CFI_I2=y -# CONFIG_MTD_CFI_I4 is not set -# CONFIG_MTD_CFI_I8 is not set -# CONFIG_MTD_RAM is not set -# CONFIG_MTD_ROM is not set -# CONFIG_MTD_ABSENT is not set - -# -# Mapping drivers for chip access -# -# CONFIG_MTD_COMPLEX_MAPPINGS is not set -# CONFIG_MTD_PLATRAM is not set - -# -# Self-contained MTD device drivers -# -CONFIG_MTD_DATAFLASH=y -# CONFIG_MTD_M25P80 is not set -# CONFIG_MTD_SLRAM is not set -# CONFIG_MTD_PHRAM is not set -# CONFIG_MTD_MTDRAM is not set -# CONFIG_MTD_BLOCK2MTD is not set - -# -# Disk-On-Chip Device Drivers -# -# CONFIG_MTD_DOC2000 is not set -# CONFIG_MTD_DOC2001 is not set -# CONFIG_MTD_DOC2001PLUS is not set -CONFIG_MTD_NAND=y -# CONFIG_MTD_NAND_VERIFY_WRITE is not set -# CONFIG_MTD_NAND_ECC_SMC is not set -# CONFIG_MTD_NAND_MUSEUM_IDS is not set -CONFIG_MTD_NAND_IDS=y -# CONFIG_MTD_NAND_DISKONCHIP is not set -CONFIG_MTD_NAND_ATMEL=y -# CONFIG_MTD_NAND_ATMEL_ECC_HW is not set -CONFIG_MTD_NAND_ATMEL_ECC_SOFT=y -# CONFIG_MTD_NAND_ATMEL_ECC_NONE is not set -# CONFIG_MTD_NAND_NANDSIM is not set -# CONFIG_MTD_NAND_PLATFORM is not set -# CONFIG_MTD_ALAUDA is not set -# CONFIG_MTD_ONENAND is not set - -# -# UBI - Unsorted block images -# -# CONFIG_MTD_UBI is not set -# CONFIG_PARPORT is not set -CONFIG_BLK_DEV=y -# CONFIG_BLK_DEV_COW_COMMON is not set -# CONFIG_BLK_DEV_LOOP is not set -# CONFIG_BLK_DEV_NBD is not set -# CONFIG_BLK_DEV_UB is not set -CONFIG_BLK_DEV_RAM=y -CONFIG_BLK_DEV_RAM_COUNT=16 -CONFIG_BLK_DEV_RAM_SIZE=8192 -# CONFIG_BLK_DEV_XIP is not set -# CONFIG_CDROM_PKTCDVD is not set -# CONFIG_ATA_OVER_ETH is not set -CONFIG_MISC_DEVICES=y -# CONFIG_ATMEL_PWM is not set -# CONFIG_ATMEL_TCLIB is not set -# CONFIG_EEPROM_93CX6 is not set -CONFIG_ATMEL_SSC=y -# CONFIG_ENCLOSURE_SERVICES is not set -CONFIG_HAVE_IDE=y -# CONFIG_IDE is not set - -# -# SCSI device support -# -# CONFIG_RAID_ATTRS is not set -CONFIG_SCSI=y -CONFIG_SCSI_DMA=y -# CONFIG_SCSI_TGT is not set -# CONFIG_SCSI_NETLINK is not set -CONFIG_SCSI_PROC_FS=y - -# -# SCSI support type (disk, tape, CD-ROM) -# -CONFIG_BLK_DEV_SD=y -# CONFIG_CHR_DEV_ST is not set -# CONFIG_CHR_DEV_OSST is not set -# CONFIG_BLK_DEV_SR is not set -# CONFIG_CHR_DEV_SG is not set -# CONFIG_CHR_DEV_SCH is not set - -# -# Some SCSI devices (e.g. CD jukebox) support multiple LUNs -# -CONFIG_SCSI_MULTI_LUN=y -# CONFIG_SCSI_CONSTANTS is not set -# CONFIG_SCSI_LOGGING is not set -# CONFIG_SCSI_SCAN_ASYNC is not set -CONFIG_SCSI_WAIT_SCAN=m - -# -# SCSI Transports -# -# CONFIG_SCSI_SPI_ATTRS is not set -# CONFIG_SCSI_FC_ATTRS is not set -# CONFIG_SCSI_ISCSI_ATTRS is not set -# CONFIG_SCSI_SAS_LIBSAS is not set -# CONFIG_SCSI_SRP_ATTRS is not set -CONFIG_SCSI_LOWLEVEL=y -# CONFIG_ISCSI_TCP is not set -# CONFIG_SCSI_DEBUG is not set -# CONFIG_SCSI_DH is not set -# CONFIG_ATA is not set -# CONFIG_MD is not set -CONFIG_NETDEVICES=y -# CONFIG_DUMMY is not set -# CONFIG_BONDING is not set -# CONFIG_MACVLAN is not set -# CONFIG_EQUALIZER is not set -# CONFIG_TUN is not set -# CONFIG_VETH is not set -CONFIG_PHYLIB=y - -# -# MII PHY device drivers -# -# CONFIG_MARVELL_PHY is not set -# CONFIG_DAVICOM_PHY is not set -# CONFIG_QSEMI_PHY is not set -# CONFIG_LXT_PHY is not set -# CONFIG_CICADA_PHY is not set -# CONFIG_VITESSE_PHY is not set -# CONFIG_SMSC_PHY is not set -# CONFIG_BROADCOM_PHY is not set -# CONFIG_ICPLUS_PHY is not set -# CONFIG_REALTEK_PHY is not set -# CONFIG_FIXED_PHY is not set -# CONFIG_MDIO_BITBANG is not set -CONFIG_NET_ETHERNET=y -CONFIG_MII=y -CONFIG_MACB=y -CONFIG_MACB_TX_SRAM=y -# CONFIG_AX88796 is not set -# CONFIG_SMC91X is not set -# CONFIG_DM9000 is not set -# CONFIG_ENC28J60 is not set -# CONFIG_IBM_NEW_EMAC_ZMII is not set -# CONFIG_IBM_NEW_EMAC_RGMII is not set -# CONFIG_IBM_NEW_EMAC_TAH is not set -# CONFIG_IBM_NEW_EMAC_EMAC4 is not set -# CONFIG_B44 is not set -# CONFIG_NETDEV_1000 is not set -# CONFIG_NETDEV_10000 is not set - -# -# Wireless LAN -# -# CONFIG_WLAN_PRE80211 is not set -# CONFIG_WLAN_80211 is not set -# CONFIG_IWLWIFI_LEDS is not set - -# -# USB Network Adapters -# -# CONFIG_USB_CATC is not set -# CONFIG_USB_KAWETH is not set -# CONFIG_USB_PEGASUS is not set -# CONFIG_USB_RTL8150 is not set -# CONFIG_USB_USBNET is not set -# CONFIG_WAN is not set -# CONFIG_PPP is not set -# CONFIG_SLIP is not set -# CONFIG_NETCONSOLE is not set -# CONFIG_NETPOLL is not set -# CONFIG_NET_POLL_CONTROLLER is not set -# CONFIG_ISDN is not set - -# -# Input device support -# -CONFIG_INPUT=y -# CONFIG_INPUT_FF_MEMLESS is not set -# CONFIG_INPUT_POLLDEV is not set - -# -# Userland interfaces -# -CONFIG_INPUT_MOUSEDEV=y -# CONFIG_INPUT_MOUSEDEV_PSAUX is not set -CONFIG_INPUT_MOUSEDEV_SCREEN_X=1024 -CONFIG_INPUT_MOUSEDEV_SCREEN_Y=768 -# CONFIG_INPUT_JOYDEV is not set -# CONFIG_INPUT_EVDEV is not set -# CONFIG_INPUT_EVBUG is not set - -# -# Input Device Drivers -# -# CONFIG_INPUT_KEYBOARD is not set -# CONFIG_INPUT_MOUSE is not set -# CONFIG_INPUT_JOYSTICK is not set -# CONFIG_INPUT_TABLET is not set -# CONFIG_INPUT_TOUCHSCREEN is not set -# CONFIG_INPUT_MISC is not set - -# -# Hardware I/O ports -# -# CONFIG_SERIO is not set -# CONFIG_GAMEPORT is not set - -# -# Character devices -# -CONFIG_VT=y -CONFIG_CONSOLE_TRANSLATIONS=y -CONFIG_VT_CONSOLE=y -CONFIG_HW_CONSOLE=y -# CONFIG_VT_HW_CONSOLE_BINDING is not set -CONFIG_DEVKMEM=y -# CONFIG_SERIAL_NONSTANDARD is not set - -# -# Serial drivers -# -# CONFIG_SERIAL_8250 is not set - -# -# Non-8250 serial port support -# -CONFIG_SERIAL_ATMEL=y -CONFIG_SERIAL_ATMEL_CONSOLE=y -CONFIG_SERIAL_ATMEL_PDC=y -# CONFIG_SERIAL_ATMEL_TTYAT is not set -CONFIG_SERIAL_CORE=y -CONFIG_SERIAL_CORE_CONSOLE=y -CONFIG_UNIX98_PTYS=y -CONFIG_LEGACY_PTYS=y -CONFIG_LEGACY_PTY_COUNT=256 -# CONFIG_IPMI_HANDLER is not set -# CONFIG_HW_RANDOM is not set -# CONFIG_NVRAM is not set -# CONFIG_R3964 is not set -# CONFIG_RAW_DRIVER is not set -# CONFIG_TCG_TPM is not set -CONFIG_I2C=y -CONFIG_I2C_BOARDINFO=y -CONFIG_I2C_CHARDEV=y -CONFIG_I2C_ALGOBIT=y - -# -# I2C Hardware Bus support -# - -# -# I2C system bus drivers (mostly embedded / system-on-chip) -# -CONFIG_I2C_GPIO=y -# CONFIG_I2C_OCORES is not set -# CONFIG_I2C_SIMTEC is not set - -# -# External I2C/SMBus adapter drivers -# -# CONFIG_I2C_PARPORT_LIGHT is not set -# CONFIG_I2C_TAOS_EVM is not set -# CONFIG_I2C_TINY_USB is not set - -# -# Other I2C/SMBus bus drivers -# -# CONFIG_I2C_PCA_PLATFORM is not set -# CONFIG_I2C_STUB is not set - -# -# Miscellaneous I2C Chip support -# -# CONFIG_DS1682 is not set -# CONFIG_AT24 is not set -# CONFIG_SENSORS_EEPROM is not set -# CONFIG_SENSORS_PCF8574 is not set -# CONFIG_PCF8575 is not set -# CONFIG_SENSORS_PCA9539 is not set -# CONFIG_SENSORS_PCF8591 is not set -# CONFIG_SENSORS_MAX6875 is not set -# CONFIG_SENSORS_TSL2550 is not set -# CONFIG_I2C_DEBUG_CORE is not set -# CONFIG_I2C_DEBUG_ALGO is not set -# CONFIG_I2C_DEBUG_BUS is not set -# CONFIG_I2C_DEBUG_CHIP is not set -CONFIG_SPI=y -CONFIG_SPI_DEBUG=y -CONFIG_SPI_MASTER=y - -# -# SPI Master Controller Drivers -# -CONFIG_SPI_ATMEL=y -# CONFIG_SPI_BITBANG is not set - -# -# SPI Protocol Masters -# -# CONFIG_SPI_AT25 is not set -CONFIG_SPI_SPIDEV=y -# CONFIG_SPI_TLE62X0 is not set -# CONFIG_W1 is not set -# CONFIG_POWER_SUPPLY is not set -# CONFIG_HWMON is not set -CONFIG_WATCHDOG=y -CONFIG_WATCHDOG_NOWAYOUT=y - -# -# Watchdog Device Drivers -# -# CONFIG_SOFT_WATCHDOG is not set - -# -# USB-based Watchdog Cards -# -# CONFIG_USBPCWATCHDOG is not set - -# -# Sonics Silicon Backplane -# -CONFIG_SSB_POSSIBLE=y -# CONFIG_SSB is not set - -# -# Multifunction device drivers -# -# CONFIG_MFD_CORE is not set -# CONFIG_MFD_SM501 is not set -# CONFIG_HTC_PASIC3 is not set - -# -# Multimedia devices -# - -# -# Multimedia core support -# -# CONFIG_VIDEO_DEV is not set -# CONFIG_DVB_CORE is not set -# CONFIG_VIDEO_MEDIA is not set - -# -# Multimedia drivers -# -# CONFIG_DAB is not set - -# -# Graphics support -# -# CONFIG_VGASTATE is not set -# CONFIG_VIDEO_OUTPUT_CONTROL is not set -# CONFIG_FB is not set -# CONFIG_BACKLIGHT_LCD_SUPPORT is not set - -# -# Display device support -# -# CONFIG_DISPLAY_SUPPORT is not set - -# -# Console display driver support -# -# CONFIG_VGA_CONSOLE is not set -CONFIG_DUMMY_CONSOLE=y -# CONFIG_SOUND is not set -CONFIG_HID_SUPPORT=y -CONFIG_HID=y -# CONFIG_HID_DEBUG is not set -# CONFIG_HIDRAW is not set - -# -# USB Input Devices -# -# CONFIG_USB_HID is not set - -# -# USB HID Boot Protocol drivers -# -# CONFIG_USB_KBD is not set -# CONFIG_USB_MOUSE is not set -CONFIG_USB_SUPPORT=y -CONFIG_USB_ARCH_HAS_HCD=y -CONFIG_USB_ARCH_HAS_OHCI=y -# CONFIG_USB_ARCH_HAS_EHCI is not set -CONFIG_USB=y -# CONFIG_USB_DEBUG is not set -# CONFIG_USB_ANNOUNCE_NEW_DEVICES is not set - -# -# Miscellaneous USB options -# -CONFIG_USB_DEVICEFS=y -CONFIG_USB_DEVICE_CLASS=y -# CONFIG_USB_DYNAMIC_MINORS is not set -# CONFIG_USB_OTG is not set - -# -# USB Host Controller Drivers -# -# CONFIG_USB_C67X00_HCD is not set -# CONFIG_USB_ISP116X_HCD is not set -# CONFIG_USB_ISP1760_HCD is not set -CONFIG_USB_OHCI_HCD=y -# CONFIG_USB_OHCI_BIG_ENDIAN_DESC is not set -# CONFIG_USB_OHCI_BIG_ENDIAN_MMIO is not set -CONFIG_USB_OHCI_LITTLE_ENDIAN=y -# CONFIG_USB_SL811_HCD is not set -# CONFIG_USB_R8A66597_HCD is not set - -# -# USB Device Class drivers -# -# CONFIG_USB_ACM is not set -# CONFIG_USB_PRINTER is not set -# CONFIG_USB_WDM is not set - -# -# NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' -# - -# -# may also be needed; see USB_STORAGE Help for more information -# -CONFIG_USB_STORAGE=y -# CONFIG_USB_STORAGE_DEBUG is not set -# CONFIG_USB_STORAGE_DATAFAB is not set -# CONFIG_USB_STORAGE_FREECOM is not set -# CONFIG_USB_STORAGE_ISD200 is not set -# CONFIG_USB_STORAGE_DPCM is not set -# CONFIG_USB_STORAGE_USBAT is not set -# CONFIG_USB_STORAGE_SDDR09 is not set -# CONFIG_USB_STORAGE_SDDR55 is not set -# CONFIG_USB_STORAGE_JUMPSHOT is not set -# CONFIG_USB_STORAGE_ALAUDA is not set -# CONFIG_USB_STORAGE_ONETOUCH is not set -# CONFIG_USB_STORAGE_KARMA is not set -# CONFIG_USB_STORAGE_CYPRESS_ATACB is not set -# CONFIG_USB_LIBUSUAL is not set - -# -# USB Imaging devices -# -# CONFIG_USB_MDC800 is not set -# CONFIG_USB_MICROTEK is not set -CONFIG_USB_MON=y - -# -# USB port drivers -# -# CONFIG_USB_SERIAL is not set - -# -# USB Miscellaneous drivers -# -# CONFIG_USB_EMI62 is not set -# CONFIG_USB_EMI26 is not set -# CONFIG_USB_ADUTUX is not set -# CONFIG_USB_AUERSWALD is not set -# CONFIG_USB_RIO500 is not set -# CONFIG_USB_LEGOTOWER is not set -# CONFIG_USB_LCD is not set -# CONFIG_USB_BERRY_CHARGE is not set -# CONFIG_USB_LED is not set -# CONFIG_USB_CYPRESS_CY7C63 is not set -# CONFIG_USB_CYTHERM is not set -# CONFIG_USB_PHIDGET is not set -# CONFIG_USB_IDMOUSE is not set -# CONFIG_USB_FTDI_ELAN is not set -# CONFIG_USB_APPLEDISPLAY is not set -# CONFIG_USB_LD is not set -# CONFIG_USB_TRANCEVIBRATOR is not set -# CONFIG_USB_IOWARRIOR is not set -# CONFIG_USB_TEST is not set -# CONFIG_USB_ISIGHTFW is not set -CONFIG_USB_GADGET=y -# CONFIG_USB_GADGET_DEBUG is not set -# CONFIG_USB_GADGET_DEBUG_FILES is not set -CONFIG_USB_GADGET_SELECTED=y -# CONFIG_USB_GADGET_AMD5536UDC is not set -# CONFIG_USB_GADGET_ATMEL_USBA is not set -# CONFIG_USB_GADGET_FSL_USB2 is not set -# CONFIG_USB_GADGET_NET2280 is not set -# CONFIG_USB_GADGET_PXA25X is not set -# CONFIG_USB_GADGET_M66592 is not set -# CONFIG_USB_GADGET_PXA27X is not set -# CONFIG_USB_GADGET_GOKU is not set -# CONFIG_USB_GADGET_LH7A40X is not set -# CONFIG_USB_GADGET_OMAP is not set -# CONFIG_USB_GADGET_S3C2410 is not set -CONFIG_USB_GADGET_AT91=y -CONFIG_USB_AT91=y -# CONFIG_USB_GADGET_DUMMY_HCD is not set -# CONFIG_USB_GADGET_DUALSPEED is not set -CONFIG_USB_ZERO=m -# CONFIG_USB_ETH is not set -CONFIG_USB_GADGETFS=m -CONFIG_USB_FILE_STORAGE=m -# CONFIG_USB_FILE_STORAGE_TEST is not set -CONFIG_USB_G_SERIAL=m -# CONFIG_USB_MIDI_GADGET is not set -# CONFIG_USB_G_PRINTER is not set -# CONFIG_USB_CDC_COMPOSITE is not set -# CONFIG_MMC is not set -# CONFIG_NEW_LEDS is not set -CONFIG_RTC_LIB=y -CONFIG_RTC_CLASS=y -CONFIG_RTC_HCTOSYS=y -CONFIG_RTC_HCTOSYS_DEVICE="rtc0" -CONFIG_RTC_DEBUG=y - -# -# RTC interfaces -# -CONFIG_RTC_INTF_SYSFS=y -CONFIG_RTC_INTF_PROC=y -CONFIG_RTC_INTF_DEV=y -# CONFIG_RTC_INTF_DEV_UIE_EMUL is not set -# CONFIG_RTC_DRV_TEST is not set - -# -# I2C RTC drivers -# -# CONFIG_RTC_DRV_DS1307 is not set -# CONFIG_RTC_DRV_DS1374 is not set -# CONFIG_RTC_DRV_DS1672 is not set -# CONFIG_RTC_DRV_MAX6900 is not set -# CONFIG_RTC_DRV_RS5C372 is not set -# CONFIG_RTC_DRV_ISL1208 is not set -# CONFIG_RTC_DRV_X1205 is not set -# CONFIG_RTC_DRV_PCF8563 is not set -# CONFIG_RTC_DRV_PCF8583 is not set -# CONFIG_RTC_DRV_M41T80 is not set -# CONFIG_RTC_DRV_S35390A is not set -CONFIG_RTC_DRV_FM3130=y - -# -# SPI RTC drivers -# -# CONFIG_RTC_DRV_M41T94 is not set -# CONFIG_RTC_DRV_DS1305 is not set -# CONFIG_RTC_DRV_MAX6902 is not set -# CONFIG_RTC_DRV_R9701 is not set -# CONFIG_RTC_DRV_RS5C348 is not set - -# -# Platform RTC drivers -# -# CONFIG_RTC_DRV_CMOS is not set -# CONFIG_RTC_DRV_DS1511 is not set -# CONFIG_RTC_DRV_DS1553 is not set -# CONFIG_RTC_DRV_DS1742 is not set -# CONFIG_RTC_DRV_STK17TA8 is not set -# CONFIG_RTC_DRV_M48T86 is not set -# CONFIG_RTC_DRV_M48T59 is not set -# CONFIG_RTC_DRV_V3020 is not set - -# -# on-CPU RTC drivers -# -# CONFIG_RTC_DRV_AT91SAM9 is not set -# CONFIG_DMADEVICES is not set - -# -# Voltage and Current regulators -# -# CONFIG_REGULATOR is not set -# CONFIG_REGULATOR_FIXED_VOLTAGE is not set -# CONFIG_REGULATOR_VIRTUAL_CONSUMER is not set -# CONFIG_REGULATOR_BQ24022 is not set -# CONFIG_UIO is not set - -# -# File systems -# -CONFIG_EXT2_FS=y -# CONFIG_EXT2_FS_XATTR is not set -# CONFIG_EXT2_FS_XIP is not set -CONFIG_EXT3_FS=y -CONFIG_EXT3_FS_XATTR=y -# CONFIG_EXT3_FS_POSIX_ACL is not set -# CONFIG_EXT3_FS_SECURITY is not set -# CONFIG_EXT4DEV_FS is not set -CONFIG_JBD=y -CONFIG_FS_MBCACHE=y -# CONFIG_REISERFS_FS is not set -# CONFIG_JFS_FS is not set -# CONFIG_FS_POSIX_ACL is not set -# CONFIG_XFS_FS is not set -# CONFIG_OCFS2_FS is not set -CONFIG_DNOTIFY=y -CONFIG_INOTIFY=y -CONFIG_INOTIFY_USER=y -# CONFIG_QUOTA is not set -# CONFIG_AUTOFS_FS is not set -# CONFIG_AUTOFS4_FS is not set -# CONFIG_FUSE_FS is not set - -# -# CD-ROM/DVD Filesystems -# -# CONFIG_ISO9660_FS is not set -# CONFIG_UDF_FS is not set - -# -# DOS/FAT/NT Filesystems -# -CONFIG_FAT_FS=y -# CONFIG_MSDOS_FS is not set -CONFIG_VFAT_FS=y -CONFIG_FAT_DEFAULT_CODEPAGE=437 -CONFIG_FAT_DEFAULT_IOCHARSET="iso8859-1" -# CONFIG_NTFS_FS is not set - -# -# Pseudo filesystems -# -CONFIG_PROC_FS=y -CONFIG_PROC_SYSCTL=y -CONFIG_SYSFS=y -CONFIG_TMPFS=y -# CONFIG_TMPFS_POSIX_ACL is not set -# CONFIG_HUGETLB_PAGE is not set -# CONFIG_CONFIGFS_FS is not set - -# -# Miscellaneous filesystems -# -# CONFIG_ADFS_FS is not set -# CONFIG_AFFS_FS is not set -# CONFIG_HFS_FS is not set -# CONFIG_HFSPLUS_FS is not set -# CONFIG_BEFS_FS is not set -# CONFIG_BFS_FS is not set -# CONFIG_EFS_FS is not set -CONFIG_JFFS2_FS=y -CONFIG_JFFS2_FS_DEBUG=0 -CONFIG_JFFS2_FS_WRITEBUFFER=y -# CONFIG_JFFS2_FS_WBUF_VERIFY is not set -# CONFIG_JFFS2_SUMMARY is not set -# CONFIG_JFFS2_FS_XATTR is not set -# CONFIG_JFFS2_COMPRESSION_OPTIONS is not set -CONFIG_JFFS2_ZLIB=y -# CONFIG_JFFS2_LZO is not set -CONFIG_JFFS2_RTIME=y -# CONFIG_JFFS2_RUBIN is not set -CONFIG_CRAMFS=y -# CONFIG_VXFS_FS is not set -# CONFIG_MINIX_FS is not set -# CONFIG_OMFS_FS is not set -# CONFIG_HPFS_FS is not set -# CONFIG_QNX4FS_FS is not set -# CONFIG_ROMFS_FS is not set -# CONFIG_SYSV_FS is not set -# CONFIG_UFS_FS is not set -CONFIG_NETWORK_FILESYSTEMS=y -CONFIG_NFS_FS=y -CONFIG_NFS_V3=y -# CONFIG_NFS_V3_ACL is not set -# CONFIG_NFS_V4 is not set -CONFIG_ROOT_NFS=y -# CONFIG_NFSD is not set -CONFIG_LOCKD=y -CONFIG_LOCKD_V4=y -CONFIG_NFS_COMMON=y -CONFIG_SUNRPC=y -# CONFIG_RPCSEC_GSS_KRB5 is not set -# CONFIG_RPCSEC_GSS_SPKM3 is not set -# CONFIG_SMB_FS is not set -# CONFIG_CIFS is not set -# CONFIG_NCP_FS is not set -# CONFIG_CODA_FS is not set -# CONFIG_AFS_FS is not set - -# -# Partition Types -# -# CONFIG_PARTITION_ADVANCED is not set -CONFIG_MSDOS_PARTITION=y -CONFIG_NLS=y -CONFIG_NLS_DEFAULT="iso8859-1" -CONFIG_NLS_CODEPAGE_437=y -# CONFIG_NLS_CODEPAGE_737 is not set -# CONFIG_NLS_CODEPAGE_775 is not set -CONFIG_NLS_CODEPAGE_850=y -# CONFIG_NLS_CODEPAGE_852 is not set -# CONFIG_NLS_CODEPAGE_855 is not set -# CONFIG_NLS_CODEPAGE_857 is not set -# CONFIG_NLS_CODEPAGE_860 is not set -# CONFIG_NLS_CODEPAGE_861 is not set -# CONFIG_NLS_CODEPAGE_862 is not set -# CONFIG_NLS_CODEPAGE_863 is not set -# CONFIG_NLS_CODEPAGE_864 is not set -# CONFIG_NLS_CODEPAGE_865 is not set -# CONFIG_NLS_CODEPAGE_866 is not set -# CONFIG_NLS_CODEPAGE_869 is not set -# CONFIG_NLS_CODEPAGE_936 is not set -# CONFIG_NLS_CODEPAGE_950 is not set -# CONFIG_NLS_CODEPAGE_932 is not set -# CONFIG_NLS_CODEPAGE_949 is not set -# CONFIG_NLS_CODEPAGE_874 is not set -# CONFIG_NLS_ISO8859_8 is not set -# CONFIG_NLS_CODEPAGE_1250 is not set -# CONFIG_NLS_CODEPAGE_1251 is not set -# CONFIG_NLS_ASCII is not set -CONFIG_NLS_ISO8859_1=y -# CONFIG_NLS_ISO8859_2 is not set -# CONFIG_NLS_ISO8859_3 is not set -# CONFIG_NLS_ISO8859_4 is not set -# CONFIG_NLS_ISO8859_5 is not set -# CONFIG_NLS_ISO8859_6 is not set -# CONFIG_NLS_ISO8859_7 is not set -# CONFIG_NLS_ISO8859_9 is not set -# CONFIG_NLS_ISO8859_13 is not set -# CONFIG_NLS_ISO8859_14 is not set -# CONFIG_NLS_ISO8859_15 is not set -# CONFIG_NLS_KOI8_R is not set -# CONFIG_NLS_KOI8_U is not set -# CONFIG_NLS_UTF8 is not set -# CONFIG_DLM is not set - -# -# Kernel hacking -# -# CONFIG_PRINTK_TIME is not set -CONFIG_ENABLE_WARN_DEPRECATED=y -CONFIG_ENABLE_MUST_CHECK=y -CONFIG_FRAME_WARN=1024 -# CONFIG_MAGIC_SYSRQ is not set -# CONFIG_UNUSED_SYMBOLS is not set -# CONFIG_DEBUG_FS is not set -# CONFIG_HEADERS_CHECK is not set -CONFIG_DEBUG_KERNEL=y -# CONFIG_DEBUG_SHIRQ is not set -CONFIG_DETECT_SOFTLOCKUP=y -# CONFIG_BOOTPARAM_SOFTLOCKUP_PANIC is not set -CONFIG_BOOTPARAM_SOFTLOCKUP_PANIC_VALUE=0 -CONFIG_SCHED_DEBUG=y -# CONFIG_SCHEDSTATS is not set -# CONFIG_TIMER_STATS is not set -# CONFIG_DEBUG_OBJECTS is not set -# CONFIG_DEBUG_SLAB is not set -CONFIG_DEBUG_PREEMPT=y -# CONFIG_DEBUG_RT_MUTEXES is not set -# CONFIG_RT_MUTEX_TESTER is not set -# CONFIG_DEBUG_SPINLOCK is not set -# CONFIG_DEBUG_MUTEXES is not set -# CONFIG_DEBUG_LOCK_ALLOC is not set -# CONFIG_PROVE_LOCKING is not set -# CONFIG_LOCK_STAT is not set -# CONFIG_DEBUG_SPINLOCK_SLEEP is not set -# CONFIG_DEBUG_LOCKING_API_SELFTESTS is not set -# CONFIG_DEBUG_KOBJECT is not set -CONFIG_DEBUG_BUGVERBOSE=y -CONFIG_DEBUG_INFO=y -# CONFIG_DEBUG_VM is not set -# CONFIG_DEBUG_WRITECOUNT is not set -CONFIG_DEBUG_MEMORY_INIT=y -# CONFIG_DEBUG_LIST is not set -# CONFIG_DEBUG_SG is not set -CONFIG_FRAME_POINTER=y -# CONFIG_BOOT_PRINTK_DELAY is not set -# CONFIG_RCU_TORTURE_TEST is not set -# CONFIG_BACKTRACE_SELF_TEST is not set -# CONFIG_FAULT_INJECTION is not set -# CONFIG_LATENCYTOP is not set -CONFIG_HAVE_FTRACE=y -CONFIG_HAVE_DYNAMIC_FTRACE=y -# CONFIG_FTRACE is not set -# CONFIG_IRQSOFF_TRACER is not set -# CONFIG_PREEMPT_TRACER is not set -# CONFIG_SCHED_TRACER is not set -# CONFIG_CONTEXT_SWITCH_TRACER is not set -# CONFIG_SAMPLES is not set -CONFIG_HAVE_ARCH_KGDB=y -# CONFIG_KGDB is not set -CONFIG_DEBUG_USER=y -# CONFIG_DEBUG_ERRORS is not set -# CONFIG_DEBUG_STACK_USAGE is not set -CONFIG_DEBUG_LL=y -# CONFIG_DEBUG_ICEDCC is not set - -# -# Security options -# -# CONFIG_KEYS is not set -# CONFIG_SECURITY is not set -# CONFIG_SECURITY_FILE_CAPABILITIES is not set -# CONFIG_CRYPTO is not set - -# -# Library routines -# -CONFIG_BITREVERSE=y -# CONFIG_GENERIC_FIND_FIRST_BIT is not set -# CONFIG_GENERIC_FIND_NEXT_BIT is not set -# CONFIG_CRC_CCITT is not set -# CONFIG_CRC16 is not set -CONFIG_CRC_T10DIF=y -# CONFIG_CRC_ITU_T is not set -CONFIG_CRC32=y -# CONFIG_CRC7 is not set -# CONFIG_LIBCRC32C is not set -CONFIG_ZLIB_INFLATE=y -CONFIG_ZLIB_DEFLATE=y -CONFIG_PLIST=y -CONFIG_HAS_IOMEM=y -CONFIG_HAS_IOPORT=y -CONFIG_HAS_DMA=y diff --git a/packages/linux/linux_2.6.28-rc6.bb b/packages/linux/linux_2.6.28-rc6.bb index c2c154d7f5..09738c9df9 100644 --- a/packages/linux/linux_2.6.28-rc6.bb +++ b/packages/linux/linux_2.6.28-rc6.bb @@ -1,8 +1,8 @@ require linux.inc -KERNEL_RELEASE = "2.6.28rc6" +KERNEL_RELEASE = "2.6.28-rc6" PV = "2.6.27+${KERNEL_RELEASE}" -PR = "r1" +PR = "r3" S = "${WORKDIR}/linux-${KERNEL_RELEASE}" @@ -10,7 +10,7 @@ S = "${WORKDIR}/linux-${KERNEL_RELEASE}" DEFAULT_PREFERENCE = "-1" DEFAULT_PREFERENCE_afeb9260 = "1" -SRC_URI = "${KERNELORG_MIRROR}/pub/linux/kernel/v2.6/testing/linux-${PV}.tar.bz2 \ +SRC_URI = "${KERNELORG_MIRROR}/pub/linux/kernel/v2.6/testing/linux-${KERNEL_RELEASE}.tar.bz2 \ file://defconfig" SRC_URI_append_afeb9260 = " \ -- cgit v1.2.3 From 43f56245179296e745ebe2ad7ae5dfc9f81809f1 Mon Sep 17 00:00:00 2001 From: Sergey Lapin Date: Sun, 7 Dec 2008 04:00:43 +0300 Subject: at91bootstrap: afeb9260 support, cleanup --- packages/at91bootstrap/at91bootstrap_2.3.bb | 43 -- packages/at91bootstrap/at91bootstrap_2.4.bb | 48 ++ .../files/0001-Generic-code-changes.patch | 781 +++++++++++++++++++++ .../0002-Making-image-directly-flashable.patch | 39 + .../files/0003-AFEB9260-board-support.patch | 665 ++++++++++++++++++ .../files/0004-AFEB9260-133-board-support.patch | 777 ++++++++++++++++++++ .../at91bootstrap/files/at91bootstrap-2.3.4.patch | 265 ------- 7 files changed, 2310 insertions(+), 308 deletions(-) delete mode 100644 packages/at91bootstrap/at91bootstrap_2.3.bb create mode 100644 packages/at91bootstrap/at91bootstrap_2.4.bb create mode 100644 packages/at91bootstrap/files/0001-Generic-code-changes.patch create mode 100644 packages/at91bootstrap/files/0002-Making-image-directly-flashable.patch create mode 100644 packages/at91bootstrap/files/0003-AFEB9260-board-support.patch create mode 100644 packages/at91bootstrap/files/0004-AFEB9260-133-board-support.patch delete mode 100644 packages/at91bootstrap/files/at91bootstrap-2.3.4.patch diff --git a/packages/at91bootstrap/at91bootstrap_2.3.bb b/packages/at91bootstrap/at91bootstrap_2.3.bb deleted file mode 100644 index 9b33ce5cc4..0000000000 --- a/packages/at91bootstrap/at91bootstrap_2.3.bb +++ /dev/null @@ -1,43 +0,0 @@ -DESCRIPTION = "at91bootstrap" -SRC_URI = "ftp://www.at91.com/pub/buildroot/${PN}-${PV}.tar.bz2 \ - file://at91bootstrap-${PV}.4.patch;patch=1 \ - " -PR = "r3" -SECTION = "bootloaders" - -AT91BOOTSTRAP_MACHINE = "at91sam9260ek" -AT91BOOTSTRAP_MACHINE ?= "${MACHINE}" -AT91BOOTSTRAP_FLAGS ?= "" -AT91BOOTSTRAP_MEMORY ?= "dataflash" - -AT91BOOTSTRAP_IMAGE = "at91bootstrap-${MACHINE}-${AT91BOOTSTRAP_MEMORY}-${PV}-${PR}.bin" -AT91BOOTSTRAP_SYMLINK = "at91bootstrap.bin" - -S = "${WORKDIR}/${PN}-${PV}" - -PACKAGE_ARCH = "${MACHINE_ARCH}" -EXTRA_OEMAKE = "CROSS_COMPILE=${TARGET_PREFIX} MEMORY=${AT91BOOTSTRAP_MEMORY}" - -do_compile () { - unset LDFLAGS - unset CFLAGS - unset CPPFLAGS - - rm -Rf ${S}/binaries - oe_runmake ${AT91BOOTSTRAP_MACHINE}_defconfig - oe_runmake AT91_CUSTOM_FLAGS="${AT91BOOTSTRAP_FLAGS}" -} - -do_deploy () { - install -d ${DEPLOY_DIR_IMAGE} - install ${S}/binaries/${AT91BOOTSTRAP_MACHINE}-${AT91BOOTSTRAP_MEMORY}boot-${PV}.bin \ - ${DEPLOY_DIR_IMAGE}/${AT91BOOTSTRAP_IMAGE} - package_stagefile_shell ${DEPLOY_DIR_IMAGE}/${AT91BOOTSTRAP_IMAGE} - cd ${DEPLOY_DIR_IMAGE} - rm -f ${AT91BOOTSTRAP_SYMLINK} - ln -sf ${AT91BOOTSTRAP_IMAGE} ${AT91BOOTSTRAP_SYMLINK} - package_stagefile_shell ${DEPLOY_DIR_IMAGE}/${AT91BOOTSTRAP_SYMLINK} -} - -do_deploy[dirs] = "${S}" -addtask deploy before do_build after do_compile diff --git a/packages/at91bootstrap/at91bootstrap_2.4.bb b/packages/at91bootstrap/at91bootstrap_2.4.bb new file mode 100644 index 0000000000..69c7d6c19b --- /dev/null +++ b/packages/at91bootstrap/at91bootstrap_2.4.bb @@ -0,0 +1,48 @@ +DESCRIPTION = "at91bootstrap" +SRC_URI = "ftp://www.at91.com/pub/buildroot/${PN}-${PV}.tar.bz2 \ + " +SRC_URI_append_afeb9260 = " file://0001-Generic-code-changes.patch;patch=1 \ + file://0002-Making-image-directly-flashable.patch;patch=1 \ + file://0003-AFEB9260-board-support.patch;patch=1 \ + file://0004-AFEB9260-133-board-support.patch;patch=1" + +PR = "r4" +SECTION = "bootloaders" + +AT91BOOTSTRAP_MACHINE ?= "${MACHINE}" +AT91BOOTSTRAP_FLAGS ?= "" +AT91BOOTSTRAP_MEMORY ?= "dataflash" + +AT91BOOTSTRAP_IMAGE = "at91bootstrap-${MACHINE}-${AT91BOOTSTRAP_MEMORY}-${PV}-${PR}.bin" +AT91BOOTSTRAP_SYMLINK = "at91bootstrap.bin" + +S = "${WORKDIR}/${PN}-${PV}" + +PACKAGE_ARCH = "${MACHINE_ARCH}" +EXTRA_OEMAKE = "CROSS_COMPILE=${TARGET_PREFIX} MEMORY=${AT91BOOTSTRAP_MEMORY}" + +do_compile () { + unset LDFLAGS + unset CFLAGS + unset CPPFLAGS + + rm -Rf ${S}/binaries + oe_runmake ${AT91BOOTSTRAP_MACHINE}_defconfig + oe_runmake AT91_CUSTOM_FLAGS="${AT91BOOTSTRAP_FLAGS}" + chmod +x ${S}/fixboot.py + ${S}/fixboot.py ${S}/binaries/${AT91BOOTSTRAP_MACHINE}-${AT91BOOTSTRAP_MEMORY}boot-${PV}.bin +} + +do_deploy () { + install -d ${DEPLOY_DIR_IMAGE} + install ${S}/binaries/${AT91BOOTSTRAP_MACHINE}-${AT91BOOTSTRAP_MEMORY}boot-${PV}.bin.fixboot \ + ${DEPLOY_DIR_IMAGE}/${AT91BOOTSTRAP_IMAGE} + package_stagefile_shell ${DEPLOY_DIR_IMAGE}/${AT91BOOTSTRAP_IMAGE} + cd ${DEPLOY_DIR_IMAGE} + rm -f ${AT91BOOTSTRAP_SYMLINK} + ln -sf ${AT91BOOTSTRAP_IMAGE} ${AT91BOOTSTRAP_SYMLINK} + package_stagefile_shell ${DEPLOY_DIR_IMAGE}/${AT91BOOTSTRAP_SYMLINK} +} + +do_deploy[dirs] = "${S}" +addtask deploy before do_build after do_compile diff --git a/packages/at91bootstrap/files/0001-Generic-code-changes.patch b/packages/at91bootstrap/files/0001-Generic-code-changes.patch new file mode 100644 index 0000000000..b48327767b --- /dev/null +++ b/packages/at91bootstrap/files/0001-Generic-code-changes.patch @@ -0,0 +1,781 @@ +From c73e4e2ebd5c818c8c1d70d0376d3b01630d97f4 Mon Sep 17 00:00:00 2001 +From: Sergey Lapin +Date: Sat, 6 Dec 2008 20:57:03 +0300 +Subject: [PATCH] Generic code changes + +* Thumb mode binary +* cp15 setting from assembler part +* removed some of unused code +* cloenup of code + +Signed-off-by: Sergey Lapin +--- + .config | 7 -- + Makefile | 11 ++-- + crt0_gnu.S | 7 ++ + driver/dataflash.c | 167 +++++++++++++++++++++++++++++++++++++++------------ + driver/debug.c | 46 ++++++++++++++ + driver/driver.mk | 2 +- + driver/gpio.c | 2 + + driver/nandflash.c | 5 +- + driver/sdramc.c | 27 +------- + include/debug.h | 18 ++++++ + include/nand_ids.h | 1 + + main.c | 167 +++++++++++++++++++++++++++++++++++++++++++++++++-- + 12 files changed, 376 insertions(+), 84 deletions(-) + delete mode 100644 .config + +diff --git a/.config b/.config +deleted file mode 100644 +index 85a177f..0000000 +--- a/.config ++++ /dev/null +@@ -1,7 +0,0 @@ +-BOARDNAME=at91sam9263ek +-BOARD=at91sam9263ek +-PROJECT=dataflash +-CONFIG_DATAFLASH=y +-SPI_MODE=SPI_MODE_0 +-SPI_BOOT=SPI_BOOT_CS0 +-SPI_CLK=5000000 +diff --git a/Makefile b/Makefile +index 5bed79d..475784e 100644 +--- a/Makefile ++++ b/Makefile +@@ -10,7 +10,7 @@ TOPDIR := $(CURDIR) + + VERSION:=2.4 + +-include .config ++-include .config + + ifeq ($(CONFIG_SPI_MODE),) + CONFIG_SPI_MODE=SPI_MODE_0 +@@ -58,15 +58,15 @@ endif + SRCS := $(COBJS-y:.o=.c) + OBJS := $(addprefix $(obj),$(SOBJS-y) $(COBJS-y)) + +-INCL=board/$(BOARD)/$(PROJECT) ++INCL=-Iboard/$(BOARD)/$(PROJECT) -Iboard/$(BOARD) + +-CPPFLAGS=-g -mcpu=arm9 -Os -Wall -D$(TARGET) \ +- -I$(INCL) -Iinclude \ ++CPPFLAGS=-g -march=armv5te -mtune=arm926ej-s -mthumb -mthumb-interwork -Os -Wall -D$(TARGET) \ ++ $(INCL) -Iinclude \ + -DTOP_OF_MEM=$(TOP_OF_MEMORY) \ + -D$(SPI_MODE) -D$(SPI_BOOT) -DSPI_CLK=$(SPI_CLK) \ + $(AT91_CUSTOM_FLAGS) + +-ASFLAGS=-g -mcpu=arm9 -Os -Wall -D$(TARGET) -I$(INCL) -Iinclude -DTOP_OF_MEM=$(TOP_OF_MEMORY) ++ASFLAGS=-g -mcpu=arm9 -Os -Wall -D$(TARGET) $(INCL) -Iinclude -DTOP_OF_MEM=$(TOP_OF_MEMORY) + + # Linker flags. + # -Wl,...: tell GCC to pass this to linker. +@@ -77,6 +77,7 @@ ASFLAGS=-g -mcpu=arm9 -Os -Wall -D$(TARGET) -I$(INCL) -Iinclude -DTOP_OF_MEM=$(T + LDFLAGS+=-nostartfiles -Map=result/$(BOOT_NAME).map --cref + #LDFLAGS+=-lc -lgcc + LDFLAGS+=-T elf32-littlearm.lds -Ttext $(LINK_ADDR) ++LDFLAGS+= --gc-sections + + all: binaries/$(BOOT_NAME).bin + +diff --git a/crt0_gnu.S b/crt0_gnu.S +index 4811eef..e8379d7 100644 +--- a/crt0_gnu.S ++++ b/crt0_gnu.S +@@ -115,6 +115,7 @@ _enable_mosc: + + /* Test if MCK == SLOW CLOCK */ + _switch_to_mosc: ++#if 0 + ldr r0,=AT91C_PMC_MCKR + ldr r1,=AT91C_PMC_CSS + ldr r2, [r0] +@@ -123,6 +124,9 @@ _switch_to_mosc: + cmp r1, r2 + /* No => Do nothing */ + bne _init_bss ++#else ++ ldr r0,=AT91C_PMC_MCKR ++#endif + /* Yes => Switch to the main oscillator */ + ldr r1,=AT91C_PMC_CSS_MAIN_CLK + ldr r2,=AT91C_PMC_PRES_CLK +@@ -147,6 +151,9 @@ _init_bss: + + /* Branch on C code Main function (with interworking) */ + _branch_main: ++ mrc p15, 0, r4, c1, c0, 0 ++ orr r4, #(1 << 12) ++ mcr p15, 0, r4, c1, c0, 0 + ldr r4, = main + mov lr, pc + bx r4 +diff --git a/driver/dataflash.c b/driver/dataflash.c +index baf7575..0f0388a 100644 +--- a/driver/dataflash.c ++++ b/driver/dataflash.c +@@ -59,6 +59,64 @@ static inline unsigned int read_spi(unsigned int offset) + return readl(offset + AT91C_BASE_SPI); + } + ++ ++static void msg_df_print(int i) ++{ ++ msg_print(MSG_DATAFLASH); ++ msg_print(MSG_SPACE); ++ msg_print(i); ++ msg_print(MSG_NEWLINE); ++} ++static void msg_df_detect(int i) ++{ ++ char * pn; ++ msg_print(MSG_DATAFLASH); ++ msg_print(MSG_SPACE); ++ msg_print(MSG_CODE); ++ msg_print(MSG_SPACE); ++ dbg_print_hex(i); ++ msg_print(MSG_AT45); ++ msg_print(MSG_DB); ++ switch(i) { ++ case AT45DB011B: ++ pn = "011B"; ++ break; ++ case AT45DB021B: ++ pn = "021B"; ++ break; ++ case AT45DB041B: ++ pn = "041B"; ++ break; ++ case AT45DB081B: ++ pn = "081B"; ++ break; ++ case AT45DB161B: ++ pn = "161B"; ++ break; ++ case AT45DB321B: ++ pn = "321B"; ++ break; ++ case AT45DB642: ++ pn = "642"; ++ break; ++ case AT45DB1282: ++ pn = "1282"; ++ break; ++ case AT45DB2562: ++ pn = "2562"; ++ break; ++ case AT45DB5122: ++ pn = "5122"; ++ break; ++ default: ++ pn = "????"; ++ break; ++ } ++ dbg_print(pn); ++ msg_print(MSG_SPACE); ++ msg_print(MSG_DETECTED); ++ msg_print(MSG_NEWLINE); ++} + /*------------------------------------------------------------------------------*/ + /* \fn df_spi_init */ + /* \brief Configure SPI */ +@@ -202,6 +260,42 @@ static char df_wait_ready(AT91PS_DF pDataFlash) + + return FAILURE; + } ++ ++void df_write( AT91PS_DF pDf, ++ unsigned int addr, ++ int size, unsigned long offset) ++{ ++ char rxBuffer[268]; ++ int i, j; ++ i = offset; ++ if(offset == 0) ++ *((unsigned long *)(addr + 0x14)) = size; ++ while(size > 0) { ++ for(j = 0; j< ((size >268) ? 268 : size); j++) ++ rxBuffer[j] = *((unsigned char *)(addr +i+j)); ++ df_page_write(pDf, rxBuffer, ((size <= AT91C_PAGE_SIZE(pDf)) ? size : AT91C_PAGE_SIZE(pDf)), i); ++ df_wait_ready(pDf); ++ i += AT91C_PAGE_SIZE(pDf); ++ size -= AT91C_PAGE_SIZE(pDf); ++ } ++#if 1 ++#define LONG_VAL(addr) *((unsigned long *)(addr)) ++ ++ for(j=0; j < 0x1000;j+=32) { ++ df_continuous_read(pDf, (char *)rxBuffer, 32, j); ++ for(i = 0; i < 32; i+=4) { ++ if(!(i & 4)) dbg_print_hex(i+j); ++ if(LONG_VAL(0x200000+i+j) == LONG_VAL(&rxBuffer[i])) ++ msg_print(MSG_SPACE); ++ else ++ msg_print(MSG_EXCLAMATION); ++ dbg_print_hex(LONG_VAL(&rxBuffer[i])); ++ if(i & 4) msg_print(MSG_NEWLINE); ++ } ++ } ++#endif ++} ++ + volatile int loop; + /*------------------------------------------------------------------------------*/ + /* \fn df_read */ +@@ -226,14 +320,14 @@ static int df_read( + dbg_print("."); + if(--page_counter <= 0) { + page_counter = 32; +- dbg_print("\r\n"); ++ msg_print(MSG_NEWLINE); + } + size -= SizeToRead; + addr += SizeToRead; + buffer += SizeToRead; + } else { + /* We got a timeout */ +- dbg_print("Timeout while waiting for dataflash ready\n"); ++ msg_df_print(MSG_TIMEOUT); + return FAILURE; + } + } +@@ -246,17 +340,18 @@ static int df_read( + /*----------------------------------------------------------------------*/ + static int df_download(AT91PS_DF pDf, unsigned int img_addr, unsigned int img_size, unsigned int img_dest) + { +- dbg_print(">Loading from Dataflash["); +- dbg_print_hex(img_addr); +- dbg_print("] to SDRAM["); +- dbg_print_hex(img_dest); +- dbg_print("]\r\n"); ++ msg_print(MSG_LOADING); ++ msg_print(MSG_SPACE); ++ msg_print(MSG_FROM); ++ msg_print(MSG_DATAFLASH); ++ msg_print_num(img_addr); + /* read bytes in the dataflash */ + if(df_read(pDf, img_addr,(unsigned char *)img_dest, img_size) == FAILURE) + return FAILURE; +- dbg_print("\r\n>Loading complete, ["); +- dbg_print_hex(IMG_SIZE); +- dbg_print("] bytes\r\n"); ++ msg_print(MSG_COMPLETE); ++ msg_print_num(img_size); ++ msg_print(MSG_BYTES); ++ msg_print(MSG_NEWLINE); + /* wait the dataflash ready status */ + return df_wait_ready(pDf); + } +@@ -288,7 +383,7 @@ static int df_init (AT91PS_DF pDf) + pDf->dfDescription.page_offset = 10; + + dfcode = df_probe (pDf); +- ++ msg_df_detect(dfcode); + switch (dfcode) + { + /* case AT45DB011B: +@@ -296,46 +391,41 @@ static int df_init (AT91PS_DF pDf) + pDf->dfDescription.pages_size = 264; + pDf->dfDescription.page_offset = 9; + break; +- ++*/ + case AT45DB021B: + pDf->dfDescription.pages_number = 1024; + pDf->dfDescription.pages_size = 264; + pDf->dfDescription.page_offset = 9; + break; +- ++/* + case AT45DB041B: + pDf->dfDescription.pages_number = 2048; + pDf->dfDescription.pages_size = 264; + pDf->dfDescription.page_offset = 9; + break; +- ++*/ + case AT45DB081B: + pDf->dfDescription.pages_number = 4096; + pDf->dfDescription.pages_size = 264; + pDf->dfDescription.page_offset = 9; + break; +-*/ +- case AT45DB161B: ++/* case AT45DB161B: + pDf->dfDescription.pages_number = 4096; + pDf->dfDescription.pages_size = 528; + pDf->dfDescription.page_offset = 10; +- dbg_print(">AT45DB161D detected\r\n"); + break; + + case AT45DB321B: + pDf->dfDescription.pages_number = 8192; + pDf->dfDescription.pages_size = 528; + pDf->dfDescription.page_offset = 10; +- dbg_print(">AT45DB321D detected\r\n"); + break; + + case AT45DB642: + pDf->dfDescription.pages_number = 8192; + pDf->dfDescription.pages_size = 1056; + pDf->dfDescription.page_offset = 11; +- dbg_print(">AT45DB642D detected\r\n"); + break; +-/* + case AT45DB1282: + pDf->dfDescription.pages_number = 16384; + pDf->dfDescription.pages_size = 1056; +@@ -368,21 +458,22 @@ static int df_init (AT91PS_DF pDf) + /*------------------------------------------------------------------------------*/ + static unsigned int df_is_boot_valid(unsigned char *buffer) + { +- int i = 3; ++ return SUCCESS; ++} + +- /* Verify if the 28 first bytes of the sram correspond to ARM vectors +- The sixth ARM vector contain the size of the code */ +- while(i < 28) +- { +- if (i != 23) +- { +- if ((buffer[i] != 0xEA) && (buffer[i] != 0xE5) ) +- return FAILURE; +- } +- i+=4; +- } ++int burn_df(unsigned int pcs, unsigned int addr, unsigned int size, unsigned int offset) ++{ ++ AT91S_DF sDF; ++ AT91PS_DF pDf = (AT91PS_DF)&sDF; ++ pDf->bSemaphore = UNLOCKED; + +- return SUCCESS; ++ df_spi_init(pcs, DF_CS_SETTINGS); ++ ++ if (df_init(pDf) == FAILURE) ++ return FAILURE; ++ df_write(pDf, addr, size, offset); ++ ++ return SUCCESS; + } + + /*------------------------------------------------------------------------------*/ +@@ -403,17 +494,13 @@ int load_df(unsigned int pcs, unsigned int img_addr, unsigned int img_size, unsi + if (df_init(pDf) == FAILURE) + return FAILURE; + +-#ifdef AT91SAM9260 +- /* Test if a button has been pressed or not */ +- /* Erase Page 0 to avoid infinite loop */ +- df_recovery(pDf); +-#endif +- + df_continuous_read(pDf, (char *)rxBuffer, 32, img_addr); + df_wait_ready(pDf); + + if (df_is_boot_valid((unsigned char*)rxBuffer) == FAILURE) { +- dbg_print(">Invalid Boot Area...\n\r"); ++ msg_print(MSG_INVALID); ++ msg_print(MSG_BOOT); ++ msg_print(MSG_NEWLINE); + return FAILURE; + } + +diff --git a/driver/debug.c b/driver/debug.c +index e30e883..762f33e 100644 +--- a/driver/debug.c ++++ b/driver/debug.c +@@ -106,3 +106,49 @@ void dbg_print_hex(unsigned int data) + } + + ++#ifdef CFG_DEBUG ++static char * messages[] = { ++ "detected", ++ "\r\n", ++ " ", ++ "!", ++ "dataflash", ++ "timeout", ++ "AT45", ++ "DB", ++ "invalid", ++ "boot", ++ "loading", ++ "from", ++ "code", ++ "complete", ++ "bytes", ++/* case AT45DB011B: ++ case AT45DB021B: ++ case AT45DB041B: ++ case AT45DB081B: ++ case AT45DB161B: ++ case AT45DB321B: ++ case AT45DB642: ++ case AT45DB1282: ++ case AT45DB2562: ++ case AT45DB5122: ++*/ ++}; ++#endif ++ ++void msg_print(int i) ++{ ++#ifdef CFG_DEBUG ++ dbg_print(messages[i]); ++#endif ++} ++ ++void msg_print_num(int n) ++{ ++#ifdef CFG_DEBUG ++ dbg_print("["); ++ dbg_print_hex(n); ++ dbg_print("]"); ++#endif ++} +diff --git a/driver/driver.mk b/driver/driver.mk +index 559d538..13d0e23 100644 +--- a/driver/driver.mk ++++ b/driver/driver.mk +@@ -1,7 +1,7 @@ + # Makefile for AT91-Bootstrap drivers directory + + COBJS-y += driver/debug.o +-COBJS-y += driver/gpio.o ++# COBJS-y += driver/gpio.o + COBJS-y += driver/pmc.o + COBJS-y += driver/sdramc.o + COBJS-y += driver/string.o +diff --git a/driver/gpio.c b/driver/gpio.c +index 9f17305..752b7c1 100644 +--- a/driver/gpio.c ++++ b/driver/gpio.c +@@ -208,6 +208,7 @@ int pio_get_value(unsigned pin) + return (pdsr & mask) != 0; + } + ++#if 0 + /*------------------------------------------------------------------------------*/ + /* \fn pio_device_pio_setup */ + /* \brief Configure PIO in periph mode according to the platform informations */ +@@ -248,3 +249,4 @@ int pio_setup (const struct pio_desc *pio_desc) + } + return pin; + } ++#endif +\ No newline at end of file +diff --git a/driver/nandflash.c b/driver/nandflash.c +index b4e3e70..081fa69 100644 +--- a/driver/nandflash.c ++++ b/driver/nandflash.c +@@ -126,6 +126,9 @@ static PSNandInitInfo AT91F_NandReadID(void) + NAND_DISABLE_CE(); + + uChipID = (bManufacturerID << 8) | bDeviceID; ++ dbg_print("NAND id:"); ++ dbg_print_hex(uChipID); ++ dbg_print("\r\n"); + + /* Search in NandFlash_InitInfo[] */ + while (NandFlash_InitInfo[i].uNandID != 0) +@@ -398,7 +401,7 @@ int load_nandflash(unsigned int img_addr, unsigned int img_size, unsigned int im + if (!pNandInitInfo) + { + #ifdef CFG_DEBUG +- dbg_print("\n\r-E- No NandFlash detected !!!\n\r"); ++ dbg_print("\n\r-E- No NandFlash\n\r"); + #endif + return -1; + } +diff --git a/driver/sdramc.c b/driver/sdramc.c +index 3e5715b..9940f67 100644 +--- a/driver/sdramc.c ++++ b/driver/sdramc.c +@@ -73,29 +73,10 @@ int sdram_init(unsigned int sdramc_cr, unsigned int sdramc_tr) + + for (i =0; i< 10000;i++); + +- write_sdramc(SDRAMC_MR, AT91C_SDRAMC_MODE_RFSH_CMD); // Set 1st CBR +- writel(0x00000001, AT91C_SDRAM+4); // Perform CBR +- +- write_sdramc(SDRAMC_MR, AT91C_SDRAMC_MODE_RFSH_CMD); // Set 2 CBR +- writel(0x00000002, AT91C_SDRAM+8); // Perform CBR +- +- write_sdramc(SDRAMC_MR, AT91C_SDRAMC_MODE_RFSH_CMD); // Set 3 CBR +- writel(0x00000003, AT91C_SDRAM+0xc); // Perform CBR +- +- write_sdramc(SDRAMC_MR, AT91C_SDRAMC_MODE_RFSH_CMD); // Set 4 CBR +- writel(0x00000004, AT91C_SDRAM+0x10); // Perform CBR +- +- write_sdramc(SDRAMC_MR, AT91C_SDRAMC_MODE_RFSH_CMD); // Set 5 CBR +- writel(0x00000005, AT91C_SDRAM+0x14); // Perform CBR +- +- write_sdramc(SDRAMC_MR, AT91C_SDRAMC_MODE_RFSH_CMD); // Set 6 CBR +- writel(0x00000006, AT91C_SDRAM+0x18); // Perform CBR +- +- write_sdramc(SDRAMC_MR, AT91C_SDRAMC_MODE_RFSH_CMD); // Set 7 CBR +- writel(0x00000007, AT91C_SDRAM+0x1C); // Perform CBR +- +- write_sdramc(SDRAMC_MR, AT91C_SDRAMC_MODE_RFSH_CMD); // Set 8 CBR +- writel(0x00000008, AT91C_SDRAM+0x20); // Perform CBR ++ for (i = 0; i < 8; i++) { ++ write_sdramc(SDRAMC_MR, AT91C_SDRAMC_MODE_RFSH_CMD); // 8 x CBR ++ writel(0x00000001 + i, AT91C_SDRAM + 4 + 4 * i); // Perform CBR ++ } + + write_sdramc(SDRAMC_MR, AT91C_SDRAMC_MODE_LMR_CMD); // Set LMR operation + writel(0xcafedede, AT91C_SDRAM+0x24); // Perform LMR burst=1, lat=2 +diff --git a/include/debug.h b/include/debug.h +index 686294a..be7fe89 100644 +--- a/include/debug.h ++++ b/include/debug.h +@@ -47,4 +47,22 @@ extern void dbg_init(unsigned int); + extern void dbg_print(const char *ptr); + extern void dbg_print_hex(unsigned int data); + ++#define MSG_DETECTED 0 ++#define MSG_NEWLINE 1 ++#define MSG_SPACE 2 ++#define MSG_EXCLAMATION 3 ++#define MSG_DATAFLASH 4 ++#define MSG_TIMEOUT 5 ++#define MSG_AT45 6 ++#define MSG_DB 7 ++#define MSG_INVALID 8 ++#define MSG_BOOT 9 ++#define MSG_LOADING 10 ++#define MSG_FROM 11 ++#define MSG_CODE 12 ++#define MSG_COMPLETE 13 ++#define MSG_BYTES 14 ++ ++void msg_print(int i); ++void msg_print_num(int n); + #endif /*_DEBUG_H_*/ +diff --git a/include/nand_ids.h b/include/nand_ids.h +index 5aa8753..c659b07 100644 +--- a/include/nand_ids.h ++++ b/include/nand_ids.h +@@ -42,6 +42,7 @@ + /* Supported NandFlash devices */ + static struct SNandInitInfo NandFlash_InitInfo[] = { + {0xecda, 0x800, 0x20000, 0x800, 0x40, 0x0, "Samsung K9F2G08U0M 256Mb\0"}, ++ {0xecaa, 0x800, 0x20000, 0x800, 0x40, 0x0, "Samsung K9F2G08U0A 256Mb\0"}, + {0x2cca, 0x800, 0x20000, 0x800, 0x40, 0x1, "Micron MT29F2G16AAB 256Mb\0"}, + {0,} + }; +diff --git a/main.c b/main.c +index ed750c2..e55e2fc 100644 +--- a/main.c ++++ b/main.c +@@ -41,18 +41,149 @@ + #include "include/flash.h" + #include "include/nandflash.h" + +-int test(void) +-{ +- +-} + /*------------------------------------------------------------------------------*/ + /* Function Name : main */ + /* Object : Main function */ + /* Input Parameters : none */ + /* Output Parameters : True */ + /*------------------------------------------------------------------------------*/ ++static unsigned long rand_next = 1; ++ ++unsigned long stupid_rand(void) ++{ ++ rand_next = rand_next * 1103515245 + 12345; ++ return (rand_next/131072) % 65536; ++} ++void stupid_srand(unsigned long seed) ++{ ++ rand_next = seed; ++} ++ ++unsigned long il, ij, k; ++unsigned char tbuf[128]; ++void writeall() ++{ ++ burn_df(AT91C_SPI_PCS_DATAFLASH, 0x200000, 0x1000, 0); ++ burn_df(AT91C_SPI_PCS_DATAFLASH, JUMP_ADDR, IMG_SIZE, IMG_ADDRESS); ++ while(1); ++} ++ ++void dbg_cr(void) ++{ ++ dbg_print("\r\n"); ++} ++ ++void dbg_printnum(char * s, unsigned long no) ++{ ++ dbg_print(s); ++ dbg_print(" "); ++ dbg_print_hex(no); ++} ++ ++void dbg_printnum_cr(char * s, unsigned long no) ++{ ++ dbg_printnum(s, no); ++ dbg_cr(); ++} ++void dbg_print_cr(char * s) ++{ ++ dbg_print(s); ++ dbg_cr(); ++} ++ ++void test_pass(int pass, int mode, unsigned long start, unsigned long size, unsigned long step) ++{ ++ unsigned long k, bad; ++ k = 0; ++ bad = 0; ++ stupid_srand(6); ++#if 0 ++ if(pass == 7) { ++ unsigned long r1, j, l, *a1, *a2; ++ r1 = stupid_rand(); ++ for(j = 0; (1 << j) < size; j++) { ++ a1 = start + j; ++ for(l = 1; l < size; l <<= 1) { ++ a2 = start + l; ++ if(j != l) { ++ *a1 = r1; ++ *a2 = r1 + 1; ++ for(k=0; k<100000; k++); ++ if(*a1 != r1 || *a2 != (r1 + 1) || *a1 == *a2) { ++ dbg_printnum("bad locations:", a2); ++ dbg_printnum_cr(" ", a1); ++ bad++; ++ } ++ } ++ } ++ } ++ } ++ else ++#endif ++ for (ij = 0; ij < size; ij+=step) { ++ unsigned long wval = 0; ++ unsigned long rval; ++ unsigned long tmp; ++ unsigned long randval; ++ for(il=(start+ij); il<(start+step+ij);il+=4) { ++#if 1 ++ randval = stupid_rand() & 0xffff; ++#endif ++ switch(pass) ++ { ++ case 0: ++ wval |= 0x1 << (k & 0x1f); ++ break; ++ case 1: ++ wval = (0x1 << (k & 0x1f)) | 1; ++ break; ++ case 2: ++ wval = 0x1 << (k & 0x1f); ++ break; ++ case 3: ++ wval = 0; ++ break; ++ case 4: ++ wval = 0xffffffff; ++ break; ++#if 1 ++ case 5: { ++ wval = (randval << 16) + randval; ++ } ++ break; ++#endif ++ } ++ if(!(mode & 1)) { ++ *((unsigned long *)il) = wval; ++ } ++ else if(mode & 1) { ++ rval = (mode & 2) ? *((unsigned long *)il) & 0xffff : ((mode & 4) ? *((unsigned long *)il) & 0xffff0000 : *((unsigned long *)il)); ++ tmp = wval; ++ wval = (mode & 2) ? wval & 0xffff: ((mode & 4) ? wval & 0xffff0000: wval); ++ if(wval != rval) { ++ dbg_print_hex(il); ++ dbg_printnum(": rd", rval); ++ dbg_printnum_cr("!= wr", wval); ++ bad++; ++ } ++ wval = tmp; ++ } ++ k++; ++ if(k > 95) {k = k & 95; if(pass == 0) wval = 0;} ++ } ++ } ++ if(mode & 1) { ++ dbg_printnum_cr("bad locations:", bad); ++ } ++ dbg_cr(); ++} ++ + int main(void) + { ++#undef LONG_TEST ++#ifdef LONG_TEST ++ int g, h, i; ++#endif + + /* ================== 1st step: Hardware Initialization ================= */ + /* Performs the hardware initialization */ +@@ -60,6 +191,27 @@ int main(void) + hw_init(); + #endif + ++#ifdef CFG_SDRAM ++#ifdef LONG_TEST ++ for(h = 0; h < 100; h++) { ++ dbg_printnum_cr("pass", h); ++ for(g = 0; g < 6; g++) { ++ dbg_printnum_cr("test", g); ++ test_pass(g, 0, 0x20000000, 0x2000000, 0x80); ++ for(i=0;i < 100000;i++); ++ dbg_print_cr("both chips"); ++ test_pass(g, 1, 0x20000000, 0x2000000, 0x80); ++ dbg_print_cr("low chip"); ++ test_pass(g, 3, 0x20000000, 0x2000000, 0x80); ++ dbg_print_cr("high chip"); ++ test_pass(g, 5, 0x20000000, 0x2000000, 0x80); ++ } ++ } ++ dbg_print_cr("END"); ++ while(1); ++#endif ++#endif ++ + /* ==================== 2nd step: Load from media ==================== */ + /* Load from Dataflash in RAM */ + #ifdef CFG_DATAFLASH +@@ -72,10 +224,10 @@ int main(void) + + /* Load from Nandflash in RAM */ + #ifdef CFG_NANDFLASH +- load_nandflash(IMG_ADDRESS, IMG_SIZE, JUMP_ADDR); +- dbg_print(">NANDflash ready\r\n"); ++ //load_nandflash(IMG_ADDRESS, IMG_SIZE, JUMP_ADDR); ++ load_nandflash(IMG_ADDRESS, 128, tbuf); + #endif +- ++#if 0 + /* ==================== 3rd step: Process the Image =================== */ + /* Uncompress the image */ + #ifdef GUNZIP +@@ -95,5 +247,6 @@ int main(void) + dbg_print("]\r\n"); + { volatile unsigned int loop; for(loop = 200000; loop > 0; loop--);} + /* Jump to the Image Address */ ++#endif + return JUMP_ADDR; + } +-- +1.5.6.5 + diff --git a/packages/at91bootstrap/files/0002-Making-image-directly-flashable.patch b/packages/at91bootstrap/files/0002-Making-image-directly-flashable.patch new file mode 100644 index 0000000000..698baec60b --- /dev/null +++ b/packages/at91bootstrap/files/0002-Making-image-directly-flashable.patch @@ -0,0 +1,39 @@ +From 482b2b7601a17264129aa50e77ba2ad51b1d2217 Mon Sep 17 00:00:00 2001 +From: Sergey Lapin +Date: Sat, 27 Sep 2008 01:28:19 +0400 +Subject: [PATCH] Making image directly flashable + + +Signed-off-by: Sergey Lapin +--- + fixboot.py | 18 ++++++++++++++++++ + 1 files changed, 18 insertions(+), 0 deletions(-) + create mode 100755 fixboot.py + +diff --git a/fixboot.py b/fixboot.py +new file mode 100755 +index 0000000..e4c604e +--- /dev/null ++++ b/fixboot.py +@@ -0,0 +1,18 @@ ++#!/usr/bin/env python ++ ++import struct, sys ++ ++#print sys.argv[1] ++ ++fd = open(sys.argv[1], "r") ++ ++line = fd.read() ++fd.close() ++ ++# print len(line) ++ ++vec = struct.pack(" +Date: Sat, 27 Sep 2008 01:34:12 +0400 +Subject: [PATCH] AFEB9260 board support + + +Signed-off-by: Sergey Lapin +--- + Makefile | 19 +++ + board/afeb9260/afeb9260.c | 240 +++++++++++++++++++++++++++++++++ + board/afeb9260/afeb9260.mk | 8 + + board/afeb9260/dataflash/afeb9260.h | 127 +++++++++++++++++ + board/afeb9260/nandflash/afeb9260ek.h | 151 +++++++++++++++++++++ + board/afeb9260/pll.h | 35 +++++ + include/part.h | 10 ++ + 7 files changed, 590 insertions(+), 0 deletions(-) + create mode 100644 board/afeb9260/afeb9260.c + create mode 100644 board/afeb9260/afeb9260.mk + create mode 100644 board/afeb9260/dataflash/afeb9260.h + create mode 100644 board/afeb9260/nandflash/afeb9260ek.h + create mode 100644 board/afeb9260/pll.h + +diff --git a/Makefile b/Makefile +index 475784e..805de99 100644 +--- a/Makefile ++++ b/Makefile +@@ -142,6 +142,25 @@ at91sam9263ek_defconfig: clean + echo SPI_BOOT=SPI_BOOT_CS0 >> .config + echo SPI_CLK=$(CONFIG_SPI_CLK) >> .config + ++afeb9260_defconfig: clean ++ echo BOARDNAME=afeb9260 > .config ++ echo BOARD=afeb9260 >> .config ++ echo PROJECT=$(MEMORY) >> .config ++ echo CONFIG_$(CFG_MEMORY)=y >> .config ++ echo SPI_MODE=$(CONFIG_SPI_MODE) >> .config ++ echo SPI_BOOT=SPI_BOOT_CS1 >> .config ++ echo SPI_CLK=$(CONFIG_SPI_CLK) >> .config ++ ++afeb9260-133_defconfig: clean ++ echo BOARDNAME=afeb9260-133 > .config ++ echo BOARD=afeb9260-133 >> .config ++ echo PROJECT=$(MEMORY) >> .config ++ echo CONFIG_$(CFG_MEMORY)=y >> .config ++ echo SPI_MODE=$(CONFIG_SPI_MODE) >> .config ++ echo SPI_BOOT=SPI_BOOT_CS1 >> .config ++ echo SPI_CLK=$(CONFIG_SPI_CLK) >> .config ++ ++ + ../buildroot: + (cd .. ; svn co svn://uclibc.org/trunk/buildroot) + +diff --git a/board/afeb9260/afeb9260.c b/board/afeb9260/afeb9260.c +new file mode 100644 +index 0000000..81c0919 +--- /dev/null ++++ b/board/afeb9260/afeb9260.c +@@ -0,0 +1,240 @@ ++/* ---------------------------------------------------------------------------- ++ * ATMEL Microcontroller Software Support - ROUSSET - ++ * ---------------------------------------------------------------------------- ++ * Copyright (c) 2006, Atmel Corporation ++ ++ * All rights reserved. ++ * ++ * Redistribution and use in source and binary forms, with or without ++ * modification, are permitted provided that the following conditions are met: ++ * ++ * - Redistributions of source code must retain the above copyright notice, ++ * this list of conditions and the disclaiimer below. ++ * ++ * - Redistributions in binary form must reproduce the above copyright notice, ++ * this list of conditions and the disclaimer below in the documentation and/or ++ * other materials provided with the distribution. ++ * ++ * Atmel's name may not be used to endorse or promote products derived from ++ * this software without specific prior written permission. ++ * ++ * DISCLAIMER: THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR ++ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF ++ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE ++ * DISCLAIMED. IN NO EVENT SHALL ATMEL BE LIABLE FOR ANY DIRECT, INDIRECT, ++ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT ++ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, ++ * OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF ++ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING ++ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, ++ * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ++ * ---------------------------------------------------------------------------- ++ * File Name : at91sam9260ek.c ++ * Object : ++ * Creation : NLe Jul 13th 2006 ++ * ODi Nov 9th : dstp #3507 "Bad PIO descriptors in at91samxxxek.c" ++ *----------------------------------------------------------------------------- ++ */ ++#include "../../include/part.h" ++#include "../../include/gpio.h" ++#include "../../include/pmc.h" ++#include "../../include/debug.h" ++#include "../../include/sdramc.h" ++#include "../../include/main.h" ++#ifdef CFG_NANDFLASH ++#include "../../include/nandflash.h" ++#endif ++#ifdef CFG_DATAFLASH ++#include "../../include/dataflash.h" ++#endif ++#ifdef CFG_FLASH ++#include "../../include/flash.h" ++#endif ++ ++/* We init NAND regardless of whatever */ ++/*------------------------------------------------------------------------------*/ ++/* \fn nandflash_hw_init */ ++/* \brief NandFlash HW init */ ++/*------------------------------------------------------------------------------*/ ++void nandflash_hw_init(void) ++{ ++ /* Setup Smart Media, first enable the address range of CS3 in HMATRIX user interface */ ++ writel(readl(AT91C_BASE_CCFG + CCFG_EBICSA) | AT91C_EBI_CS3A_SM, AT91C_BASE_CCFG + CCFG_EBICSA); ++ ++ /* Configure SMC CS3 */ ++ writel((AT91C_SM_NWE_SETUP | AT91C_SM_NCS_WR_SETUP | AT91C_SM_NRD_SETUP | AT91C_SM_NCS_RD_SETUP), AT91C_BASE_SMC + SMC_SETUP3); ++ writel((AT91C_SM_NWE_PULSE | AT91C_SM_NCS_WR_PULSE | AT91C_SM_NRD_PULSE | AT91C_SM_NCS_RD_PULSE), AT91C_BASE_SMC + SMC_PULSE3); ++ writel((AT91C_SM_NWE_CYCLE | AT91C_SM_NRD_CYCLE) , AT91C_BASE_SMC + SMC_CYCLE3); ++ writel((AT91C_SMC_READMODE | AT91C_SMC_WRITEMODE | AT91C_SMC_NWAITM_NWAIT_DISABLE | ++ AT91C_SMC_DBW_WIDTH_EIGTH_BITS | AT91C_SM_TDF) , AT91C_BASE_SMC + SMC_CTRL3); ++ ++ /* Configure the PIO controller */ ++ writel((1 << AT91C_ID_PIOC), PMC_PCER + AT91C_BASE_PMC); ++ ++ writel(1 << 13, AT91C_BASE_PIOC + PIO_IFDR(0)); ++ writel(1 << 13, AT91C_BASE_PIOC + PIO_PPUER(0)); ++ writel(1 << 13, AT91C_BASE_PIOC + PIO_ODR(0)); ++ writel(1 << 14, AT91C_BASE_PIOC + PIO_CODR(0)); ++ writel(1 << 14, AT91C_BASE_PIOC + PIO_MDDR(0)); ++ writel(1 << 14, AT91C_BASE_PIOC + PIO_PPUDR(0)); ++ writel(1 << 14, AT91C_BASE_PIOC + PIO_OER(0)); ++ writel(3 << 13, AT91C_BASE_PIOC + PIO_IDR(0)); ++ writel(3 << 13, AT91C_BASE_PIOC + PIO_PER(0)); ++} ++ ++ ++#ifdef CFG_HW_INIT ++/*----------------------------------------------------------------------------*/ ++/* \fn hw_init */ ++/* \brief This function performs very low level HW initialization */ ++/* This function is invoked as soon as possible during the c_startup */ ++/* The bss segment must be initialized */ ++/*----------------------------------------------------------------------------*/ ++void hw_init(void) ++{ ++ /* Disable watchdog */ ++ writel(AT91C_WDTC_WDDIS, AT91C_BASE_WDTC + WDTC_WDMR); ++ ++ /* At this stage the main oscillator is supposed to be enabled ++ * PCK = MCK = MOSC */ ++ ++ /* Configure PLLA = MOSC * (PLL_MULA + 1) / PLL_DIVA */ ++ pmc_cfg_plla(PLLA_SETTINGS, PLL_LOCK_TIMEOUT); ++ ++ /* Switch MCK on PLLA output PCK = PLLA = 2 * MCK */ ++ pmc_cfg_mck(MCKR_SETTINGS, PLL_LOCK_TIMEOUT); ++ ++ /* Configure PLLB */ ++ pmc_cfg_pllb(PLLB_SETTINGS, PLL_LOCK_TIMEOUT); ++ ++ /* Configure the PIO controller */ ++ writel(3 << 14, AT91C_BASE_PIOB + PIO_ASR(0)); ++ writel(3 << 14, AT91C_BASE_PIOB + PIO_PDR(0)); ++ ++#ifdef CFG_DEBUG ++ /* Enable Debug messages on the DBGU */ ++ dbg_init(BAUDRATE(MASTER_CLOCK, 115200)); ++ ++ dbg_print("AT91 bootstrap loading from 0x8400\n\r"); ++#endif /* CFG_DEBUG */ ++ ++#ifdef CFG_SDRAM ++ /* Initialize the matrix */ ++ writel(readl(AT91C_BASE_CCFG + CCFG_EBICSA) | AT91C_EBI_CS1A_SDRAMC, AT91C_BASE_CCFG + CCFG_EBICSA); ++ ++ /* Configure SDRAM Controller */ ++ ++#define HYNIX ++ ++//#define MICRON ++#ifdef MICRON ++#define MICRON_REFRESH 1420 /* 15.625 us / 11 ns @ 180 Mhz*/ ++ sdram_init( AT91C_SDRAMC_NC_9 | ++ AT91C_SDRAMC_NR_12 | ++ AT91C_SDRAMC_CAS_2 | ++ AT91C_SDRAMC_NB_4_BANKS | ++ AT91C_SDRAMC_DBW_32_BITS | ++ AT91C_SDRAMC_TWR_2 | // 1 CLK+7ns ++ AT91C_SDRAMC_TRC_7 | // 60 ns ++ AT91C_SDRAMC_TRP_3 | // 15 ns ++ AT91C_SDRAMC_TRCD_3 | // 15 ns ++ AT91C_SDRAMC_TRAS_7 | // 37-120 ns ++ AT91C_SDRAMC_TXSR_7, /* 67ns */ /* Control Register */ ++ /* 600 700 735 */ MICRON_REFRESH /* 740 1536*/ ); /* Refresh Timer Register */ ++ ++#endif ++/* ++HY57V561620BT-H ++ *CAS lat *tRCD *tRAS *tRC *tRP tAC tOH ++133 2 2 6 8 2 5.4ns 2.7ns ++125 3 3 6 9 3 6ns 3ns ++100 2 2 5 7 2 6ns 3ns ++ ++*/ ++#ifdef HYNIX ++#if defined(PLLA_180MHz) ++/* CLK= 11ns */ ++/* TWR = tDPL = 2 2CLK always */ ++/* TRC = tRC = 65ns = 6 clk */ ++/* TRP = tRP = 20ns = 2 clk */ ++/* TRCD = tRCD = 20ns = 2 clk */ ++/* TRAS = tRAS = 45ns = 5 clk */ ++/* TXSR = tRRC = 65ns = 6 clk */ ++ ++ sdram_init( AT91C_SDRAMC_NC_9 | ++ AT91C_SDRAMC_NR_13 | ++ AT91C_SDRAMC_CAS_2 | ++ AT91C_SDRAMC_NB_4_BANKS | ++ AT91C_SDRAMC_DBW_32_BITS | ++ AT91C_SDRAMC_TWR_2 | ++ AT91C_SDRAMC_TRC_6 | /* *7 */ ++ AT91C_SDRAMC_TRP_2 | ++ AT91C_SDRAMC_TRCD_2 | ++ AT91C_SDRAMC_TRAS_5 | /* *5 */ ++ AT91C_SDRAMC_TXSR_6, /* *8 */ /* Control Register */ ++ 710); /* Refresh Timer Register */ ++ ++#elif defined(PLLA_120MHz) ++/* CLK= 16ns, MCLK=60MHz */ ++/* TWR = tDPL = 2 2CLK always */ ++/* TRC = tRC = 65ns = 4 clk */ ++/* TRP = tRP = 20ns = 2 clk */ ++/* TRCD = tRCD = 20ns = 2 clk */ ++/* TRAS = tRAS = 45ns = 3 clk */ ++/* TXSR = tRRC = 65ns = 4 clk */ ++ ++ sdram_init( AT91C_SDRAMC_NC_9 | ++ AT91C_SDRAMC_NR_13 | ++ AT91C_SDRAMC_CAS_2 | ++ AT91C_SDRAMC_NB_4_BANKS | ++ AT91C_SDRAMC_DBW_32_BITS | ++ AT91C_SDRAMC_TWR_2 | ++ AT91C_SDRAMC_TRC_4 | ++ AT91C_SDRAMC_TRP_2 | ++ AT91C_SDRAMC_TRCD_2 | ++ AT91C_SDRAMC_TRAS_3 | /* *5 */ ++ AT91C_SDRAMC_TXSR_4, /* *8 */ /* Control Register */ ++ 1032); /* Refresh Timer Register */ ++#else ++#error define PLLA180MHz ++#endif ++#endif /* HYNIX */ ++#endif /* CFG_SDRAM */ ++ ++#ifdef CFG_FLASH ++ flash_hw_init(); ++#endif ++ nandflash_hw_init(); ++} ++#endif /* CFG_HW_INIT */ ++ ++#ifdef CFG_SDRAM ++/*------------------------------------------------------------------------------*/ ++/* \fn sdramc_hw_init */ ++/* \brief This function performs SDRAMC HW initialization */ ++/*------------------------------------------------------------------------------*/ ++void sdramc_hw_init(void) ++{ ++ writel(0xFFFF0000, AT91C_BASE_PIOC + PIO_ASR(0)); ++ writel(0xFFFF0000, AT91C_BASE_PIOC + PIO_PDR(0)); ++ ++} ++#endif /* CFG_SDRAM */ ++ ++#ifdef CFG_DATAFLASH ++ ++/*------------------------------------------------------------------------------*/ ++/* \fn df_hw_init */ ++/* \brief This function performs DataFlash HW initialization */ ++/*------------------------------------------------------------------------------*/ ++void df_hw_init(void) ++{ ++ writel(0xf, 0xfffff444); ++ writel(0xf, 0xfffff460); ++ writel(0xf, 0xfffff470); ++ writel(0xf, 0xfffff404); ++ writel(1 << 11, AT91C_BASE_PIOC + PIO_BSR(0)); ++ writel(1 << 11, AT91C_BASE_PIOC + PIO_PDR(0)); ++} ++#endif /* CFG_DATAFLASH */ ++ +diff --git a/board/afeb9260/afeb9260.mk b/board/afeb9260/afeb9260.mk +new file mode 100644 +index 0000000..88c2f64 +--- /dev/null ++++ b/board/afeb9260/afeb9260.mk +@@ -0,0 +1,8 @@ ++# Target name (case sensitive!!!) ++TARGET=AFEB9260 ++# Board name (case sensitive!!!) ++BOARD=afeb9260 ++# Link Address and Top_of_Memory ++LINK_ADDR=0x200000 ++TOP_OF_MEMORY=0x301000 ++ +diff --git a/board/afeb9260/dataflash/afeb9260.h b/board/afeb9260/dataflash/afeb9260.h +new file mode 100644 +index 0000000..8e60faa +--- /dev/null ++++ b/board/afeb9260/dataflash/afeb9260.h +@@ -0,0 +1,127 @@ ++/* ---------------------------------------------------------------------------- ++ * ATMEL Microcontroller Software Support - ROUSSET - ++ * ---------------------------------------------------------------------------- ++ * Copyright (c) 2006, Atmel Corporation ++ ++ * All rights reserved. ++ * ++ * Redistribution and use in source and binary forms, with or without ++ * modification, are permitted provided that the following conditions are met: ++ * ++ * - Redistributions of source code must retain the above copyright notice, ++ * this list of conditions and the disclaiimer below. ++ * ++ * - Redistributions in binary form must reproduce the above copyright notice, ++ * this list of conditions and the disclaimer below in the documentation and/or ++ * other materials provided with the distribution. ++ * ++ * Atmel's name may not be used to endorse or promote products derived from ++ * this software without specific prior written permission. ++ * ++ * DISCLAIMER: THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR ++ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF ++ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE ++ * DISCLAIMED. IN NO EVENT SHALL ATMEL BE LIABLE FOR ANY DIRECT, INDIRECT, ++ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT ++ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, ++ * OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF ++ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING ++ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, ++ * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ++ * ---------------------------------------------------------------------------- ++ * File Name : at91sam9260ek.h ++ * Object : ++ * Creation : NLe Jul 13th 2006 ++ *----------------------------------------------------------------------------- ++ */ ++#ifndef _AFEB9260_H ++#define _AFEB9260_H ++#include "spi.h" ++#include "pll.h" ++ ++/* ******************************************************************* */ ++/* DataFlash Settings */ ++/* */ ++/* ******************************************************************* */ ++#define AT91C_BASE_SPI AT91C_BASE_SPI0 ++#define AT91C_ID_SPI AT91C_ID_SPI0 ++ ++/* SPI CLOCK */ ++#define AT91C_SPI_CLK 5000000 ++/* AC characteristics */ ++/* DLYBS = tCSS= 250ns min and DLYBCT = tCSH = 250ns */ ++#define DATAFLASH_TCSS (0x1a << 16) /* 250ns min (tCSS) <=> 12/48000000 = 250ns */ ++#define DATAFLASH_TCHS (0x1 << 24) /* 250ns min (tCSH) <=> (64*1+SCBR)/(2*48000000) */ ++ ++#define DF_CS_SETTINGS ((SPI_MODE) | (AT91C_SPI_DLYBS & DATAFLASH_TCSS) | (AT91C_SPI_DLYBCT & DATAFLASH_TCHS) | ((MASTER_CLOCK / AT91C_SPI_CLK) << 8)) ++ ++ ++/* ******************************************************************* */ ++/* BootStrap Settings */ ++/* */ ++/* ******************************************************************* */ ++#define MACH_TYPE 0x44B /* AT91SAM9260-EK */ ++ ++#define IMG_ADDRESS 0x8400 /* Image Address in DataFlash */ ++ ++#if defined(IMG_SIZE) ++#warning "IMG_SIZE redefined" ++#else ++#define IMG_SIZE 0x39000 /* Image Size in DataFlash */ ++#endif ++ ++#if defined(JUMP_ADDR) ++#warning "JUMP_ADDR redefined" ++#else ++#define JUMP_ADDR 0x21F00000 /* Final Jump Address */ ++#endif ++ ++/* ******************************************************************* */ ++/* NandFlash Settings */ ++/* */ ++/* ******************************************************************* */ ++#define AT91C_SMARTMEDIA_BASE 0x40000000 ++ ++#define AT91_SMART_MEDIA_ALE (1 << 21) /* our ALE is AD21 */ ++#define AT91_SMART_MEDIA_CLE (1 << 22) /* our CLE is AD22 */ ++ ++#define NAND_DISABLE_CE() do { *(volatile unsigned int *)AT91C_PIOC_SODR = AT91C_PIO_PC14;} while(0) ++#define NAND_ENABLE_CE() do { *(volatile unsigned int *)AT91C_PIOC_CODR = AT91C_PIO_PC14;} while(0) ++ ++#define NAND_WAIT_READY() while (!(*(volatile unsigned int *)AT91C_PIOC_PDSR & AT91C_PIO_PC13)) ++ ++ ++/* ******************************************************************** */ ++/* SMC Chip Select 3 Timings for NandFlash for MASTER_CLOCK = 100000000.*/ ++/* Micron 16bits 256Mb for MASTER_CLOCK = 100000000. */ ++/* Please refer to SMC section in AT91SAM9261 datasheet to learn how */ ++/* to generate these values. */ ++/* ******************************************************************** */ ++ ++#define AT91C_SM_NWE_SETUP (2 << 0) ++#define AT91C_SM_NCS_WR_SETUP (2 << 8) ++#define AT91C_SM_NRD_SETUP (2 << 16) ++#define AT91C_SM_NCS_RD_SETUP (2 << 24) ++ ++#define AT91C_SM_NWE_PULSE (4 << 0) ++#define AT91C_SM_NCS_WR_PULSE (4 << 8) ++#define AT91C_SM_NRD_PULSE (4 << 16) ++#define AT91C_SM_NCS_RD_PULSE (4 << 24) ++ ++#define AT91C_SM_NWE_CYCLE (8 << 0) ++#define AT91C_SM_NRD_CYCLE (8 << 16) ++ ++#define AT91C_SM_TDF (2 << 16) ++ ++ ++ ++/* ******************************************************************* */ ++/* Application Settings */ ++/* ******************************************************************* */ ++#define CFG_DEBUG ++#define CFG_DATAFLASH ++#define CFG_SDRAM ++#define CFG_HW_INIT ++ ++ ++#endif /* _AT91SAM9260EK_H */ +diff --git a/board/afeb9260/nandflash/afeb9260ek.h b/board/afeb9260/nandflash/afeb9260ek.h +new file mode 100644 +index 0000000..752ae0a +--- /dev/null ++++ b/board/afeb9260/nandflash/afeb9260ek.h +@@ -0,0 +1,151 @@ ++/* ---------------------------------------------------------------------------- ++ * ATMEL Microcontroller Software Support - ROUSSET - ++ * ---------------------------------------------------------------------------- ++ * Copyright (c) 2006, Atmel Corporation ++ ++ * All rights reserved. ++ * ++ * Redistribution and use in source and binary forms, with or without ++ * modification, are permitted provided that the following conditions are met: ++ * ++ * - Redistributions of source code must retain the above copyright notice, ++ * this list of conditions and the disclaimer below. ++ * ++ * - Redistributions in binary form must reproduce the above copyright notice, ++ * this list of conditions and the disclaimer below in the documentation and/or ++ * other materials provided with the distribution. ++ * ++ * Atmel's name may not be used to endorse or promote products derived from ++ * this software without specific prior written permission. ++ * ++ * DISCLAIMER: THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR ++ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF ++ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE ++ * DISCLAIMED. IN NO EVENT SHALL ATMEL BE LIABLE FOR ANY DIRECT, INDIRECT, ++ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT ++ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, ++ * OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF ++ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING ++ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, ++ * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ++ * ---------------------------------------------------------------------------- ++ * File Name : at91sam9260ek.h ++ * Object : ++ * Creation : NLe Sep 28th 2006 ++ *----------------------------------------------------------------------------- ++ */ ++#ifndef _AFEB9260_H ++#define _AFEB9260_H ++#include "spi.h" ++#include "pll.h" ++ ++/* ******************************************************************* */ ++/* DataFlash Settings */ ++/* */ ++/* ******************************************************************* */ ++#define AT91C_BASE_SPI AT91C_BASE_SPI0 ++#define AT91C_ID_SPI AT91C_ID_SPI0 ++ ++/* SPI CLOCK */ ++#define AT91C_SPI_CLK 5000000 ++/* AC characteristics */ ++/* DLYBS = tCSS= 250ns min and DLYBCT = tCSH = 250ns */ ++#define DATAFLASH_TCSS (0x1a << 16) /* 250ns min (tCSS) <=> 12/48000000 = 250ns */ ++#define DATAFLASH_TCHS (0x1 << 24) /* 250ns min (tCSH) <=> (64*1+SCBR)/(2*48000000) */ ++ ++#define DF_CS_SETTINGS ((SPI_MODE) | (AT91C_SPI_DLYBS & DATAFLASH_TCSS) | (AT91C_SPI_DLYBCT & DATAFLASH_TCHS) | ((MASTER_CLOCK / AT91C_SPI_CLK) << 8)) ++ ++ ++/* ******************************************************************* */ ++/* NandFlash Settings */ ++/* */ ++/* ******************************************************************* */ ++#define AT91C_SMARTMEDIA_BASE 0x40000000 ++ ++#define AT91_SMART_MEDIA_ALE (1 << 21) /* our ALE is AD21 */ ++#define AT91_SMART_MEDIA_CLE (1 << 22) /* our CLE is AD22 */ ++ ++#define NAND_DISABLE_CE() do { *(volatile unsigned int *)AT91C_PIOC_SODR = AT91C_PIO_PC14;} while(0) ++#define NAND_ENABLE_CE() do { *(volatile unsigned int *)AT91C_PIOC_CODR = AT91C_PIO_PC14;} while(0) ++ ++#define NAND_WAIT_READY() while (!(*(volatile unsigned int *)AT91C_PIOC_PDSR & AT91C_PIO_PC13)) ++ ++ ++/* ******************************************************************** */ ++/* SMC Chip Select 3 Timings for NandFlash for MASTER_CLOCK = 100000000.*/ ++/* Micron 16bits 256Mb for MASTER_CLOCK = 100000000. */ ++/* Please refer to SMC section in AT91SAM9261 datasheet to learn how */ ++/* to generate these values. */ ++/* ******************************************************************** */ ++ ++#define AT91C_SM_NWE_SETUP (2 << 0) ++#define AT91C_SM_NCS_WR_SETUP (2 << 8) ++#define AT91C_SM_NRD_SETUP (2 << 16) ++#define AT91C_SM_NCS_RD_SETUP (2 << 24) ++ ++#define AT91C_SM_NWE_PULSE (4 << 0) ++#define AT91C_SM_NCS_WR_PULSE (4 << 8) ++#define AT91C_SM_NRD_PULSE (4 << 16) ++#define AT91C_SM_NCS_RD_PULSE (4 << 24) ++ ++#define AT91C_SM_NWE_CYCLE (8 << 0) ++#define AT91C_SM_NRD_CYCLE (8 << 16) ++ ++#define AT91C_SM_TDF (2 << 16) ++ ++ ++/* ******************************************************************** */ ++/* SMC Chip Select 3 Timings for NandFlash for MASTER_CLOCK = 100000000.*/ ++/* Micron 16bits 256Mb for MASTER_CLOCK = 100000000. */ ++/* Please refer to SMC section in AT91SAM9261 datasheet to learn how */ ++/* to generate these values. */ ++/* ******************************************************************** */ ++/*#define AT91C_SM_NWE_SETUP (0 << 0) ++#define AT91C_SM_NCS_WR_SETUP (0 << 8) ++#define AT91C_SM_NRD_SETUP (0 << 16) ++#define AT91C_SM_NCS_RD_SETUP (0 << 24) ++ ++#define AT91C_SM_NWE_PULSE (2 << 0) ++#define AT91C_SM_NCS_WR_PULSE (3 << 8) ++#define AT91C_SM_NRD_PULSE (2 << 16) ++#define AT91C_SM_NCS_RD_PULSE (3 << 24) ++ ++#define AT91C_SM_NWE_CYCLE (3 << 0) ++#define AT91C_SM_NRD_CYCLE (3 << 16) ++ ++#define AT91C_SM_TDF (1 << 16) ++*/ ++ ++/* ******************************************************************* */ ++/* BootStrap Settings */ ++/* */ ++/* ******************************************************************* */ ++#define MACH_TYPE 0x44B /* AT91SAM9260-EK */ ++ ++#define IMG_ADDRESS 0x20000 /* Image Address in NandFlash */ ++ ++#if defined(IMG_SIZE) ++#warning "IMG_SIZE redefined" ++#else ++#define IMG_SIZE 0x30000 /* Image Size in NandFlash */ ++#endif ++ ++#if defined(JUMP_ADDR) ++#warning "JUMP_ADDR redefined" ++#else ++#define JUMP_ADDR 0x23F00000 /* Final Jump Address */ ++#endif ++ ++/* ******************************************************************* */ ++/* Application Settings */ ++/* ******************************************************************* */ ++#define CFG_DEBUG ++#undef CFG_DATAFLASH ++ ++#define CFG_NANDFLASH ++#undef NANDFLASH_SMALL_BLOCKS /* NANDFLASH_LARGE_BLOCKS used instead */ ++ ++#define CFG_HW_INIT ++#define CFG_SDRAM ++ ++#endif /* _AT91SAM9260EK_H */ +diff --git a/board/afeb9260/pll.h b/board/afeb9260/pll.h +new file mode 100644 +index 0000000..6d20299 +--- /dev/null ++++ b/board/afeb9260/pll.h +@@ -0,0 +1,35 @@ ++/* ******************************************************************* */ ++/* PMC Settings */ ++/* */ ++/* The main oscillator is enabled as soon as possible in the c_startup */ ++/* and MCK is switched on the main oscillator. */ ++/* PLL initialization is done later in the hw_init() function */ ++/* ******************************************************************* */ ++#define PLL_LOCK_TIMEOUT 1000000 ++ ++#define PLLA_180MHz ++ ++#ifdef PLLA_200MHz ++#define PLLA_SETTINGS 0x2060BF09 ++#define MASTER_CLOCK (198656000/2) ++#endif ++ ++#ifdef PLLA_180MHz ++#define PLLA_SETTINGS 0x2125BF1E /* 180MHz */ ++#define MASTER_CLOCK (179999198/2) /* 180MHz MCK=90MHz */ ++#endif ++ ++#ifdef PLLA_120MHz ++//#define PLLA_SETTINGS 0x2125BF2d /* 120MHz */ ++//#define MASTER_CLOCK (119999322) /* 120MHz MCK=60MHz*/ ++#define PLLA_SETTINGS 0x2125BF2d /* 120MHz */ ++#define MASTER_CLOCK (119999465/2) /* 120MHz MCK=60MHz*/ ++#endif ++ ++#if !defined(PLLA_180MHz) && !defined(PLLA_120MHz) ++#error Define PLLA frequency ++#endif ++#define PLLB_SETTINGS 0x10483F0E ++ ++/* Switch MCK on PLLA output PCK = PLLA = 2 * MCK */ ++#define MCKR_SETTINGS (AT91C_PMC_CSS_PLLA_CLK | AT91C_PMC_PRES_CLK | AT91C_PMC_MDIV_2) +diff --git a/include/part.h b/include/part.h +index ec717d6..48e41e1 100644 +--- a/include/part.h ++++ b/include/part.h +@@ -52,4 +52,14 @@ + #include "at91sam9263ek.h" + #endif + ++#ifdef AFEB9260 ++#include "AT91SAM9260_inc.h" ++#include "afeb9260.h" ++#endif ++ ++#ifdef AFEB9260_133 ++#include "AT91SAM9260_inc.h" ++#include "afeb9260-133.h" ++#endif ++ + #endif /* _PART_H */ +-- +1.5.6.5 + diff --git a/packages/at91bootstrap/files/0004-AFEB9260-133-board-support.patch b/packages/at91bootstrap/files/0004-AFEB9260-133-board-support.patch new file mode 100644 index 0000000000..c88801cc9e --- /dev/null +++ b/packages/at91bootstrap/files/0004-AFEB9260-133-board-support.patch @@ -0,0 +1,777 @@ +From ef96ec1464569eb42788076d27c9aa9376a3c396 Mon Sep 17 00:00:00 2001 +From: Sergey Lapin +Date: Sat, 27 Sep 2008 01:34:49 +0400 +Subject: [PATCH] AFEB9260-133 board support + + +Signed-off-by: Sergey Lapin +--- + board/afeb9260-133/afeb9260-133.c | 403 +++++++++++++++++++++++++++ + board/afeb9260-133/afeb9260-133.mk | 8 + + board/afeb9260-133/dataflash/afeb9260-133.h | 127 +++++++++ + board/afeb9260-133/nandflash/afeb9260-133.h | 151 ++++++++++ + board/afeb9260-133/pll.h | 35 +++ + 5 files changed, 724 insertions(+), 0 deletions(-) + create mode 100644 board/afeb9260-133/afeb9260-133.c + create mode 100644 board/afeb9260-133/afeb9260-133.mk + create mode 100644 board/afeb9260-133/dataflash/afeb9260-133.h + create mode 100644 board/afeb9260-133/nandflash/afeb9260-133.h + create mode 100644 board/afeb9260-133/pll.h + +diff --git a/board/afeb9260-133/afeb9260-133.c b/board/afeb9260-133/afeb9260-133.c +new file mode 100644 +index 0000000..f54f7a7 +--- /dev/null ++++ b/board/afeb9260-133/afeb9260-133.c +@@ -0,0 +1,403 @@ ++/* ---------------------------------------------------------------------------- ++ * ATMEL Microcontroller Software Support - ROUSSET - ++ * ---------------------------------------------------------------------------- ++ * Copyright (c) 2006, Atmel Corporation ++ ++ * All rights reserved. ++ * ++ * Redistribution and use in source and binary forms, with or without ++ * modification, are permitted provided that the following conditions are met: ++ * ++ * - Redistributions of source code must retain the above copyright notice, ++ * this list of conditions and the disclaiimer below. ++ * ++ * - Redistributions in binary form must reproduce the above copyright notice, ++ * this list of conditions and the disclaimer below in the documentation and/or ++ * other materials provided with the distribution. ++ * ++ * Atmel's name may not be used to endorse or promote products derived from ++ * this software without specific prior written permission. ++ * ++ * DISCLAIMER: THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR ++ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF ++ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE ++ * DISCLAIMED. IN NO EVENT SHALL ATMEL BE LIABLE FOR ANY DIRECT, INDIRECT, ++ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT ++ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, ++ * OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF ++ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING ++ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, ++ * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ++ * ---------------------------------------------------------------------------- ++ * File Name : at91sam9260ek.c ++ * Object : ++ * Creation : NLe Jul 13th 2006 ++ * ODi Nov 9th : dstp #3507 "Bad PIO descriptors in at91samxxxek.c" ++ *----------------------------------------------------------------------------- ++ */ ++#include "../../include/part.h" ++#include "../../include/gpio.h" ++#include "../../include/pmc.h" ++#include "../../include/debug.h" ++#include "../../include/sdramc.h" ++#include "../../include/main.h" ++#ifdef CFG_NANDFLASH ++#include "../../include/nandflash.h" ++#endif ++#ifdef CFG_DATAFLASH ++#include "../../include/dataflash.h" ++#endif ++#ifdef CFG_FLASH ++#include "../../include/flash.h" ++#endif ++static inline unsigned int get_cp15(void) ++{ ++ unsigned int value; ++ __asm__("mrc p15, 0, %0, c1, c0, 0" : "=r" (value)); ++ return value; ++} ++ ++static inline void set_cp15(unsigned int value) ++{ ++ __asm__("mcr p15, 0, %0, c1, c0, 0" : : "r" (value)); ++} ++ ++#ifdef CFG_HW_INIT ++/*----------------------------------------------------------------------------*/ ++/* \fn hw_init */ ++/* \brief This function performs very low level HW initialization */ ++/* This function is invoked as soon as possible during the c_startup */ ++/* The bss segment must be initialized */ ++/*----------------------------------------------------------------------------*/ ++void hw_init(void) ++{ ++ unsigned int cp15; ++ ++ /* Disable watchdog */ ++ writel(AT91C_WDTC_WDDIS, AT91C_BASE_WDTC + WDTC_WDMR); ++ ++ /* At this stage the main oscillator is supposed to be enabled ++ * PCK = MCK = MOSC */ ++ ++ /* Configure PLLA = MOSC * (PLL_MULA + 1) / PLL_DIVA */ ++ pmc_cfg_plla(PLLA_SETTINGS, PLL_LOCK_TIMEOUT); ++ ++ /* Switch MCK on PLLA output PCK = PLLA = 2 * MCK */ ++ pmc_cfg_mck(MCKR_SETTINGS, PLL_LOCK_TIMEOUT); ++ ++ /* Configure PLLB */ ++ pmc_cfg_pllb(PLLB_SETTINGS, PLL_LOCK_TIMEOUT); ++ ++ /* Configure CP15 */ ++ /* Using procedure from u-boot for arm926ejs */ ++ cp15 = get_cp15(); ++ cp15 &= ~I_CACHE; ++ set_cp15(cp15); ++ ++ /* Configure the PIO controller */ ++ writel(3 << 14, AT91C_BASE_PIOB + PIO_ASR(0)); ++ writel(3 << 14, AT91C_BASE_PIOB + PIO_PDR(0)); ++ ++#ifdef CFG_DEBUG ++ /* Enable Debug messages on the DBGU */ ++ dbg_init(BAUDRATE(MASTER_CLOCK, 115200)); ++ /* Configure CP15 */ ++ /* Using procedure from u-boot for arm926ejs */ ++#if 0 ++ cp15 = get_cp15(); ++ cp15 |= 0xC0000000; ++ set_cp15(cp15); ++#endif ++ ++ dbg_print("AT91 bootstrap loading from @< 0x8400\n\r"); ++#endif /* CFG_DEBUG */ ++ ++#ifdef CFG_SDRAM ++ /* Initialize the matrix */ ++ writel(readl(AT91C_BASE_CCFG + CCFG_EBICSA) | AT91C_EBI_CS1A_SDRAMC, AT91C_BASE_CCFG + CCFG_EBICSA); ++ ++ /* Configure SDRAM Controller */ ++ ++#define HYNIX ++ ++//#define MICRON ++#ifdef MICRON ++#define MICRON_REFRESH 1420 /* 15.625 us / 11 ns @ 180 Mhz*/ ++ sdram_init( AT91C_SDRAMC_NC_9 | ++ AT91C_SDRAMC_NR_12 | ++ AT91C_SDRAMC_CAS_2 | ++ AT91C_SDRAMC_NB_4_BANKS | ++ AT91C_SDRAMC_DBW_32_BITS | ++ AT91C_SDRAMC_TWR_2 | // 1 CLK+7ns ++ AT91C_SDRAMC_TRC_7 | // 60 ns ++ AT91C_SDRAMC_TRP_3 | // 15 ns ++ AT91C_SDRAMC_TRCD_3 | // 15 ns ++ AT91C_SDRAMC_TRAS_7 | // 37-120 ns ++ AT91C_SDRAMC_TXSR_7, /* 67ns */ /* Control Register */ ++ /* 600 700 735 */ MICRON_REFRESH /* 740 1536*/ ); /* Refresh Timer Register */ ++ ++#endif ++/* ++HY57V561620BT-H ++ *CAS lat *tRCD *tRAS *tRC *tRP tAC tOH ++133 2 2 6 8 2 5.4ns 2.7ns ++125 3 3 6 9 3 6ns 3ns ++100 2 2 5 7 2 6ns 3ns ++ ++*/ ++#ifdef HYNIX ++#if defined(PLLA_180MHz) ++/* CLK= 11ns */ ++/* TWR = tDPL = 2 2CLK always */ ++/* TRC = tRC = 65ns = 6 clk */ ++/* TRP = tRP = 20ns = 2 clk */ ++/* TRCD = tRCD = 20ns = 2 clk */ ++/* TRAS = tRAS = 45ns = 5 clk */ ++/* TXSR = tRRC = 65ns = 6 clk */ ++ ++ sdram_init( AT91C_SDRAMC_NC_9 | ++ AT91C_SDRAMC_NR_13 | ++ AT91C_SDRAMC_CAS_2 | ++ AT91C_SDRAMC_NB_4_BANKS | ++ AT91C_SDRAMC_DBW_32_BITS | ++ AT91C_SDRAMC_TWR_2 | ++ AT91C_SDRAMC_TRC_6 | /* *7 */ ++ AT91C_SDRAMC_TRP_2 | ++ AT91C_SDRAMC_TRCD_2 | ++ AT91C_SDRAMC_TRAS_5 | /* *5 */ ++ AT91C_SDRAMC_TXSR_6, /* *8 */ /* Control Register */ ++ 710); /* Refresh Timer Register */ ++ ++#elif defined(PLLA_120MHz) ++/* CLK= 16ns, MCLK=60MHz */ ++/* TWR = tDPL = 2 2CLK always */ ++/* TRC = tRC = 65ns = 4 clk */ ++/* TRP = tRP = 20ns = 2 clk */ ++/* TRCD = tRCD = 20ns = 2 clk */ ++/* TRAS = tRAS = 45ns = 3 clk */ ++/* TXSR = tRRC = 65ns = 4 clk */ ++ ++ sdram_init( AT91C_SDRAMC_NC_9 | ++ AT91C_SDRAMC_NR_13 | ++ AT91C_SDRAMC_CAS_2 | ++ AT91C_SDRAMC_NB_4_BANKS | ++ AT91C_SDRAMC_DBW_32_BITS | ++ AT91C_SDRAMC_TWR_2 | ++ AT91C_SDRAMC_TRC_4 | ++ AT91C_SDRAMC_TRP_2 | ++ AT91C_SDRAMC_TRCD_2 | ++ AT91C_SDRAMC_TRAS_3 | /* *5 */ ++ AT91C_SDRAMC_TXSR_4, /* *8 */ /* Control Register */ ++ 1032); /* Refresh Timer Register */ ++#else ++#error define PLLA180MHz ++#endif ++#endif /* HYNIX */ ++#endif /* CFG_SDRAM */ ++ ++#ifdef CFG_FLASH ++ flash_hw_init(); ++#endif ++ nandflash_hw_init(); ++ dbg_print("CP15=\r\n"); ++ dbg_print_hex(get_cp15); ++} ++#endif /* CFG_HW_INIT */ ++ ++#ifdef CFG_SDRAM ++/*------------------------------------------------------------------------------*/ ++/* \fn sdramc_hw_init */ ++/* \brief This function performs SDRAMC HW initialization */ ++/*------------------------------------------------------------------------------*/ ++void sdramc_hw_init(void) ++{ ++ /* Configure PIOs */ ++/* const struct pio_desc sdramc_pio[] = { ++ {"D16", AT91C_PIN_PC(16), 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ {"D17", AT91C_PIN_PC(17), 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ {"D18", AT91C_PIN_PC(18), 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ {"D19", AT91C_PIN_PC(19), 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ {"D20", AT91C_PIN_PC(20), 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ {"D21", AT91C_PIN_PC(21), 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ {"D22", AT91C_PIN_PC(22), 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ {"D23", AT91C_PIN_PC(23), 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ {"D24", AT91C_PIN_PC(24), 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ {"D25", AT91C_PIN_PC(25), 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ {"D26", AT91C_PIN_PC(26), 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ {"D27", AT91C_PIN_PC(27), 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ {"D28", AT91C_PIN_PC(28), 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ {"D29", AT91C_PIN_PC(29), 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ {"D30", AT91C_PIN_PC(30), 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ {"D31", AT91C_PIN_PC(31), 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ {(char *) 0, 0, 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ }; ++*/ ++ /* Configure the SDRAMC PIO controller to output PCK0 */ ++/* pio_setup(sdramc_pio); */ ++ ++ writel(0xFFFF0000, AT91C_BASE_PIOC + PIO_ASR(0)); ++ writel(0xFFFF0000, AT91C_BASE_PIOC + PIO_PDR(0)); ++ ++} ++#endif /* CFG_SDRAM */ ++ ++#ifdef CFG_DATAFLASH ++ ++/*------------------------------------------------------------------------------*/ ++/* \fn df_recovery */ ++/* \brief This function erases DataFlash Page 0 if BP4 is pressed */ ++/* during boot sequence */ ++/*------------------------------------------------------------------------------*/ ++void df_recovery(AT91PS_DF pDf) ++{ ++#if 0 ++#if (AT91C_SPI_PCS_DATAFLASH == AT91C_SPI_PCS1_DATAFLASH) ++ /* Configure PIOs */ ++ const struct pio_desc bp4_pio[] = { ++ {"BP4", AT91C_PIN_PA(31), 0, PIO_PULLUP, PIO_INPUT}, ++ {(char *) 0, 0, 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ }; ++ ++ /* Configure the PIO controller */ ++ writel((1 << AT91C_ID_PIOA), PMC_PCER + AT91C_BASE_PMC); ++ pio_setup(bp4_pio); ++ ++ /* If BP4 is pressed during Boot sequence */ ++ /* Erase NandFlash block 0*/ ++ if ( !pio_get_value(AT91C_PIN_PA(31)) ) ++ df_page_erase(pDf, 0); ++#endif ++#endif ++} ++ ++/*------------------------------------------------------------------------------*/ ++/* \fn df_hw_init */ ++/* \brief This function performs DataFlash HW initialization */ ++/*------------------------------------------------------------------------------*/ ++void df_hw_init(void) ++{ ++#if 0 ++ /* Configure PIOs */ ++ const struct pio_desc df_pio[] = { ++ {"MISO", AT91C_PIN_PA(0), 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ {"MOSI", AT91C_PIN_PA(1), 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ {"SPCK", AT91C_PIN_PA(2), 0, PIO_DEFAULT, PIO_PERIPH_A}, ++#if (AT91C_SPI_PCS_DATAFLASH == AT91C_SPI_PCS0_DATAFLASH) ++ {"NPCS0", AT91C_PIN_PA(3), 0, PIO_DEFAULT, PIO_PERIPH_A}, ++#endif ++#if (AT91C_SPI_PCS_DATAFLASH == AT91C_SPI_PCS1_DATAFLASH) ++ {"NPCS1", AT91C_PIN_PC(11), 0, PIO_DEFAULT, PIO_PERIPH_B}, ++#endif ++ {(char *) 0, 0, 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ }; ++ ++ /* Configure the PIO controller */ ++ pio_setup(df_pio); ++#else ++ writel(0xf, 0xfffff444); ++ writel(0xf, 0xfffff460); ++ writel(0xf, 0xfffff470); ++ writel(0xf, 0xfffff404); ++ writel(1 << 11, AT91C_BASE_PIOC + PIO_BSR(0)); ++ writel(1 << 11, AT91C_BASE_PIOC + PIO_PDR(0)); ++#endif ++} ++#endif /* CFG_DATAFLASH */ ++ ++#ifdef CFG_FLASH ++ ++/*------------------------------------------------------------------------------*/ ++/* \fn flash_hw_init */ ++/* \brief This function performs Flash HW initialization */ ++/*------------------------------------------------------------------------------*/ ++void flash_hw_init(void) ++{ ++ /* Configure PIOs */ ++ const struct pio_desc flash_pio[] = { ++ {(char *) 0, 0, 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ }; ++ ++ /* Configure the PIO controller */ ++ pio_setup(flash_pio); ++} ++ ++#endif /* CFG_FLASH */ ++ ++#ifdef CFG_NANDFLASH ++/*------------------------------------------------------------------------------*/ ++/* \fn nand_recovery */ ++/* \brief This function erases NandFlash Block 0 if BP4 is pressed */ ++/* during boot sequence */ ++/*------------------------------------------------------------------------------*/ ++static void nand_recovery(void) ++{ ++ /* Configure PIOs */ ++ const struct pio_desc bp4_pio[] = { ++ {"BP4", AT91C_PIN_PA(31), 0, PIO_PULLUP, PIO_INPUT}, ++ {(char *) 0, 0, 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ }; ++ ++ /* Configure the PIO controller */ ++ writel((1 << AT91C_ID_PIOA), PMC_PCER + AT91C_BASE_PMC); ++ pio_setup(bp4_pio); ++ ++ /* If BP4 is pressed during Boot sequence */ ++ /* Erase NandFlash block 0*/ ++ if (!pio_get_value(AT91C_PIN_PA(31)) ) ++ AT91F_NandEraseBlock0(); ++} ++#endif ++/*------------------------------------------------------------------------------*/ ++/* \fn nandflash_hw_init */ ++/* \brief NandFlash HW init */ ++/*------------------------------------------------------------------------------*/ ++void nandflash_hw_init(void) ++{ ++#if 0 ++ /* Configure PIOs */ ++ const struct pio_desc nand_pio[] = { ++ {"RDY_BSY", AT91C_PIN_PC(13), 0, PIO_PULLUP, PIO_INPUT}, ++ {"NANDCS", AT91C_PIN_PC(14), 0, PIO_PULLUP, PIO_OUTPUT}, ++ {(char *) 0, 0, 0, PIO_DEFAULT, PIO_PERIPH_A}, ++ }; ++#endif ++ /* Setup Smart Media, first enable the address range of CS3 in HMATRIX user interface */ ++ writel(readl(AT91C_BASE_CCFG + CCFG_EBICSA) | AT91C_EBI_CS3A_SM, AT91C_BASE_CCFG + CCFG_EBICSA); ++ ++ /* Configure SMC CS3 */ ++ writel((AT91C_SM_NWE_SETUP | AT91C_SM_NCS_WR_SETUP | AT91C_SM_NRD_SETUP | AT91C_SM_NCS_RD_SETUP), AT91C_BASE_SMC + SMC_SETUP3); ++ writel((AT91C_SM_NWE_PULSE | AT91C_SM_NCS_WR_PULSE | AT91C_SM_NRD_PULSE | AT91C_SM_NCS_RD_PULSE), AT91C_BASE_SMC + SMC_PULSE3); ++ writel((AT91C_SM_NWE_CYCLE | AT91C_SM_NRD_CYCLE) , AT91C_BASE_SMC + SMC_CYCLE3); ++ writel((AT91C_SMC_READMODE | AT91C_SMC_WRITEMODE | AT91C_SMC_NWAITM_NWAIT_DISABLE | ++ AT91C_SMC_DBW_WIDTH_EIGTH_BITS | AT91C_SM_TDF) , AT91C_BASE_SMC + SMC_CTRL3); ++ ++ /* Configure the PIO controller */ ++ writel((1 << AT91C_ID_PIOC), PMC_PCER + AT91C_BASE_PMC); ++ ++ writel(1 << 13, AT91C_BASE_PIOC + PIO_IFDR(0)); ++ writel(1 << 13, AT91C_BASE_PIOC + PIO_PPUER(0)); ++ writel(1 << 13, AT91C_BASE_PIOC + PIO_ODR(0)); ++ writel(1 << 14, AT91C_BASE_PIOC + PIO_CODR(0)); ++ writel(1 << 14, AT91C_BASE_PIOC + PIO_MDDR(0)); ++ writel(1 << 14, AT91C_BASE_PIOC + PIO_PPUDR(0)); ++ writel(1 << 14, AT91C_BASE_PIOC + PIO_OER(0)); ++ writel(3 << 13, AT91C_BASE_PIOC + PIO_IDR(0)); ++ writel(3 << 13, AT91C_BASE_PIOC + PIO_PER(0)); ++ ++#if 0 ++ nand_recovery(); ++#endif ++} ++ ++ ++#if 0 ++/*------------------------------------------------------------------------------*/ ++/* \fn nandflash_cfg_16bits_dbw_init */ ++/* \brief Configure SMC in 16 bits mode */ ++/*------------------------------------------------------------------------------*/ ++void nandflash_cfg_16bits_dbw_init(void) ++{ ++ writel(readl(AT91C_BASE_SMC + SMC_CTRL3) | AT91C_SMC_DBW_WIDTH_SIXTEEN_BITS, AT91C_BASE_SMC + SMC_CTRL3); ++} ++ ++#endif /* #ifdef CFG_NANDFLASH */ +diff --git a/board/afeb9260-133/afeb9260-133.mk b/board/afeb9260-133/afeb9260-133.mk +new file mode 100644 +index 0000000..84e45d3 +--- /dev/null ++++ b/board/afeb9260-133/afeb9260-133.mk +@@ -0,0 +1,8 @@ ++# Target name (case sensitive!!!) ++TARGET=AFEB9260_133 ++# Board name (case sensitive!!!) ++BOARD=afeb9260-133 ++# Link Address and Top_of_Memory ++LINK_ADDR=0x200000 ++TOP_OF_MEMORY=0x301000 ++ +diff --git a/board/afeb9260-133/dataflash/afeb9260-133.h b/board/afeb9260-133/dataflash/afeb9260-133.h +new file mode 100644 +index 0000000..2ebb020 +--- /dev/null ++++ b/board/afeb9260-133/dataflash/afeb9260-133.h +@@ -0,0 +1,127 @@ ++/* ---------------------------------------------------------------------------- ++ * ATMEL Microcontroller Software Support - ROUSSET - ++ * ---------------------------------------------------------------------------- ++ * Copyright (c) 2006, Atmel Corporation ++ ++ * All rights reserved. ++ * ++ * Redistribution and use in source and binary forms, with or without ++ * modification, are permitted provided that the following conditions are met: ++ * ++ * - Redistributions of source code must retain the above copyright notice, ++ * this list of conditions and the disclaiimer below. ++ * ++ * - Redistributions in binary form must reproduce the above copyright notice, ++ * this list of conditions and the disclaimer below in the documentation and/or ++ * other materials provided with the distribution. ++ * ++ * Atmel's name may not be used to endorse or promote products derived from ++ * this software without specific prior written permission. ++ * ++ * DISCLAIMER: THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR ++ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF ++ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE ++ * DISCLAIMED. IN NO EVENT SHALL ATMEL BE LIABLE FOR ANY DIRECT, INDIRECT, ++ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT ++ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, ++ * OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF ++ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING ++ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, ++ * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ++ * ---------------------------------------------------------------------------- ++ * File Name : at91sam9260ek.h ++ * Object : ++ * Creation : NLe Jul 13th 2006 ++ *----------------------------------------------------------------------------- ++ */ ++#ifndef _AFEB9260_133_H ++#define _AFEB9260_133_H ++#include "spi.h" ++#include "pll.h" ++ ++/* ******************************************************************* */ ++/* DataFlash Settings */ ++/* */ ++/* ******************************************************************* */ ++#define AT91C_BASE_SPI AT91C_BASE_SPI0 ++#define AT91C_ID_SPI AT91C_ID_SPI0 ++ ++/* SPI CLOCK */ ++#define AT91C_SPI_CLK 5000000 ++/* AC characteristics */ ++/* DLYBS = tCSS= 250ns min and DLYBCT = tCSH = 250ns */ ++#define DATAFLASH_TCSS (0x1a << 16) /* 250ns min (tCSS) <=> 12/48000000 = 250ns */ ++#define DATAFLASH_TCHS (0x1 << 24) /* 250ns min (tCSH) <=> (64*1+SCBR)/(2*48000000) */ ++ ++#define DF_CS_SETTINGS ((SPI_MODE) | (AT91C_SPI_DLYBS & DATAFLASH_TCSS) | (AT91C_SPI_DLYBCT & DATAFLASH_TCHS) | ((MASTER_CLOCK / AT91C_SPI_CLK) << 8)) ++ ++ ++/* ******************************************************************* */ ++/* BootStrap Settings */ ++/* */ ++/* ******************************************************************* */ ++#define MACH_TYPE 0x44B /* AT91SAM9260-EK */ ++ ++#define IMG_ADDRESS 0x8400 /* Image Address in DataFlash */ ++ ++#if defined(IMG_SIZE) ++#warning "IMG_SIZE redefined" ++#else ++#define IMG_SIZE 0x39000 /* Image Size in DataFlash */ ++#endif ++ ++#if defined(JUMP_ADDR) ++#warning "JUMP_ADDR redefined" ++#else ++#define JUMP_ADDR 0x21F00000 /* Final Jump Address */ ++#endif ++ ++/* ******************************************************************* */ ++/* NandFlash Settings */ ++/* */ ++/* ******************************************************************* */ ++#define AT91C_SMARTMEDIA_BASE 0x40000000 ++ ++#define AT91_SMART_MEDIA_ALE (1 << 21) /* our ALE is AD21 */ ++#define AT91_SMART_MEDIA_CLE (1 << 22) /* our CLE is AD22 */ ++ ++#define NAND_DISABLE_CE() do { *(volatile unsigned int *)AT91C_PIOC_SODR = AT91C_PIO_PC14;} while(0) ++#define NAND_ENABLE_CE() do { *(volatile unsigned int *)AT91C_PIOC_CODR = AT91C_PIO_PC14;} while(0) ++ ++#define NAND_WAIT_READY() while (!(*(volatile unsigned int *)AT91C_PIOC_PDSR & AT91C_PIO_PC13)) ++ ++ ++/* ******************************************************************** */ ++/* SMC Chip Select 3 Timings for NandFlash for MASTER_CLOCK = 100000000.*/ ++/* Micron 16bits 256Mb for MASTER_CLOCK = 100000000. */ ++/* Please refer to SMC section in AT91SAM9261 datasheet to learn how */ ++/* to generate these values. */ ++/* ******************************************************************** */ ++ ++#define AT91C_SM_NWE_SETUP (2 << 0) ++#define AT91C_SM_NCS_WR_SETUP (2 << 8) ++#define AT91C_SM_NRD_SETUP (2 << 16) ++#define AT91C_SM_NCS_RD_SETUP (2 << 24) ++ ++#define AT91C_SM_NWE_PULSE (4 << 0) ++#define AT91C_SM_NCS_WR_PULSE (4 << 8) ++#define AT91C_SM_NRD_PULSE (4 << 16) ++#define AT91C_SM_NCS_RD_PULSE (4 << 24) ++ ++#define AT91C_SM_NWE_CYCLE (8 << 0) ++#define AT91C_SM_NRD_CYCLE (8 << 16) ++ ++#define AT91C_SM_TDF (2 << 16) ++ ++ ++ ++/* ******************************************************************* */ ++/* Application Settings */ ++/* ******************************************************************* */ ++#define CFG_DEBUG ++#define CFG_DATAFLASH ++#define CFG_SDRAM ++#define CFG_HW_INIT ++ ++ ++#endif /* _AT91SAM9260EK_H */ +diff --git a/board/afeb9260-133/nandflash/afeb9260-133.h b/board/afeb9260-133/nandflash/afeb9260-133.h +new file mode 100644 +index 0000000..414d30c +--- /dev/null ++++ b/board/afeb9260-133/nandflash/afeb9260-133.h +@@ -0,0 +1,151 @@ ++/* ---------------------------------------------------------------------------- ++ * ATMEL Microcontroller Software Support - ROUSSET - ++ * ---------------------------------------------------------------------------- ++ * Copyright (c) 2006, Atmel Corporation ++ ++ * All rights reserved. ++ * ++ * Redistribution and use in source and binary forms, with or without ++ * modification, are permitted provided that the following conditions are met: ++ * ++ * - Redistributions of source code must retain the above copyright notice, ++ * this list of conditions and the disclaimer below. ++ * ++ * - Redistributions in binary form must reproduce the above copyright notice, ++ * this list of conditions and the disclaimer below in the documentation and/or ++ * other materials provided with the distribution. ++ * ++ * Atmel's name may not be used to endorse or promote products derived from ++ * this software without specific prior written permission. ++ * ++ * DISCLAIMER: THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR ++ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF ++ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE ++ * DISCLAIMED. IN NO EVENT SHALL ATMEL BE LIABLE FOR ANY DIRECT, INDIRECT, ++ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT ++ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, ++ * OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF ++ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING ++ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, ++ * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ++ * ---------------------------------------------------------------------------- ++ * File Name : at91sam9260ek.h ++ * Object : ++ * Creation : NLe Sep 28th 2006 ++ *----------------------------------------------------------------------------- ++ */ ++#ifndef _AFEB9260_133_H ++#define _AFEB9260_133_H ++#include "spi.h" ++#include "pll.h" ++ ++/* ******************************************************************* */ ++/* DataFlash Settings */ ++/* */ ++/* ******************************************************************* */ ++#define AT91C_BASE_SPI AT91C_BASE_SPI0 ++#define AT91C_ID_SPI AT91C_ID_SPI0 ++ ++/* SPI CLOCK */ ++#define AT91C_SPI_CLK 5000000 ++/* AC characteristics */ ++/* DLYBS = tCSS= 250ns min and DLYBCT = tCSH = 250ns */ ++#define DATAFLASH_TCSS (0x1a << 16) /* 250ns min (tCSS) <=> 12/48000000 = 250ns */ ++#define DATAFLASH_TCHS (0x1 << 24) /* 250ns min (tCSH) <=> (64*1+SCBR)/(2*48000000) */ ++ ++#define DF_CS_SETTINGS ((SPI_MODE) | (AT91C_SPI_DLYBS & DATAFLASH_TCSS) | (AT91C_SPI_DLYBCT & DATAFLASH_TCHS) | ((MASTER_CLOCK / AT91C_SPI_CLK) << 8)) ++ ++ ++/* ******************************************************************* */ ++/* NandFlash Settings */ ++/* */ ++/* ******************************************************************* */ ++#define AT91C_SMARTMEDIA_BASE 0x40000000 ++ ++#define AT91_SMART_MEDIA_ALE (1 << 21) /* our ALE is AD21 */ ++#define AT91_SMART_MEDIA_CLE (1 << 22) /* our CLE is AD22 */ ++ ++#define NAND_DISABLE_CE() do { *(volatile unsigned int *)AT91C_PIOC_SODR = AT91C_PIO_PC14;} while(0) ++#define NAND_ENABLE_CE() do { *(volatile unsigned int *)AT91C_PIOC_CODR = AT91C_PIO_PC14;} while(0) ++ ++#define NAND_WAIT_READY() while (!(*(volatile unsigned int *)AT91C_PIOC_PDSR & AT91C_PIO_PC13)) ++ ++ ++/* ******************************************************************** */ ++/* SMC Chip Select 3 Timings for NandFlash for MASTER_CLOCK = 100000000.*/ ++/* Micron 16bits 256Mb for MASTER_CLOCK = 100000000. */ ++/* Please refer to SMC section in AT91SAM9261 datasheet to learn how */ ++/* to generate these values. */ ++/* ******************************************************************** */ ++ ++#define AT91C_SM_NWE_SETUP (2 << 0) ++#define AT91C_SM_NCS_WR_SETUP (2 << 8) ++#define AT91C_SM_NRD_SETUP (2 << 16) ++#define AT91C_SM_NCS_RD_SETUP (2 << 24) ++ ++#define AT91C_SM_NWE_PULSE (4 << 0) ++#define AT91C_SM_NCS_WR_PULSE (4 << 8) ++#define AT91C_SM_NRD_PULSE (4 << 16) ++#define AT91C_SM_NCS_RD_PULSE (4 << 24) ++ ++#define AT91C_SM_NWE_CYCLE (8 << 0) ++#define AT91C_SM_NRD_CYCLE (8 << 16) ++ ++#define AT91C_SM_TDF (2 << 16) ++ ++ ++/* ******************************************************************** */ ++/* SMC Chip Select 3 Timings for NandFlash for MASTER_CLOCK = 100000000.*/ ++/* Micron 16bits 256Mb for MASTER_CLOCK = 100000000. */ ++/* Please refer to SMC section in AT91SAM9261 datasheet to learn how */ ++/* to generate these values. */ ++/* ******************************************************************** */ ++/*#define AT91C_SM_NWE_SETUP (0 << 0) ++#define AT91C_SM_NCS_WR_SETUP (0 << 8) ++#define AT91C_SM_NRD_SETUP (0 << 16) ++#define AT91C_SM_NCS_RD_SETUP (0 << 24) ++ ++#define AT91C_SM_NWE_PULSE (2 << 0) ++#define AT91C_SM_NCS_WR_PULSE (3 << 8) ++#define AT91C_SM_NRD_PULSE (2 << 16) ++#define AT91C_SM_NCS_RD_PULSE (3 << 24) ++ ++#define AT91C_SM_NWE_CYCLE (3 << 0) ++#define AT91C_SM_NRD_CYCLE (3 << 16) ++ ++#define AT91C_SM_TDF (1 << 16) ++*/ ++ ++/* ******************************************************************* */ ++/* BootStrap Settings */ ++/* */ ++/* ******************************************************************* */ ++#define MACH_TYPE 0x44B /* AT91SAM9260-EK */ ++ ++#define IMG_ADDRESS 0x20000 /* Image Address in NandFlash */ ++ ++#if defined(IMG_SIZE) ++#warning "IMG_SIZE redefined" ++#else ++#define IMG_SIZE 0x30000 /* Image Size in NandFlash */ ++#endif ++ ++#if defined(JUMP_ADDR) ++#warning "JUMP_ADDR redefined" ++#else ++#define JUMP_ADDR 0x23F00000 /* Final Jump Address */ ++#endif ++ ++/* ******************************************************************* */ ++/* Application Settings */ ++/* ******************************************************************* */ ++#define CFG_DEBUG ++#undef CFG_DATAFLASH ++ ++#define CFG_NANDFLASH ++#undef NANDFLASH_SMALL_BLOCKS /* NANDFLASH_LARGE_BLOCKS used instead */ ++ ++#define CFG_HW_INIT ++#define CFG_SDRAM ++ ++#endif /* _AT91SAM9260EK_H */ +diff --git a/board/afeb9260-133/pll.h b/board/afeb9260-133/pll.h +new file mode 100644 +index 0000000..907aaa0 +--- /dev/null ++++ b/board/afeb9260-133/pll.h +@@ -0,0 +1,35 @@ ++/* ******************************************************************* */ ++/* PMC Settings */ ++/* */ ++/* The main oscillator is enabled as soon as possible in the c_startup */ ++/* and MCK is switched on the main oscillator. */ ++/* PLL initialization is done later in the hw_init() function */ ++/* ******************************************************************* */ ++#define PLL_LOCK_TIMEOUT 1000000 ++ ++#define PLLA_120MHz ++ ++#ifdef PLLA_200MHz ++#define PLLA_SETTINGS 0x2060BF09 ++#define MASTER_CLOCK (198656000/2) ++#endif ++ ++#ifdef PLLA_180MHz ++#define PLLA_SETTINGS 0x2125BF1E /* 180MHz */ ++#define MASTER_CLOCK (179999198/2) /* 180MHz MCK=90MHz */ ++#endif ++ ++#ifdef PLLA_120MHz ++//#define PLLA_SETTINGS 0x2125BF2d /* 120MHz */ ++//#define MASTER_CLOCK (119999322) /* 120MHz MCK=60MHz*/ ++#define PLLA_SETTINGS 0x2125BF2d /* 120MHz */ ++#define MASTER_CLOCK (119999465/2) /* 120MHz MCK=60MHz*/ ++#endif ++ ++#if !defined(PLLA_180MHz) && !defined(PLLA_120MHz) ++#error Define PLLA frequency ++#endif ++#define PLLB_SETTINGS 0x10483F0E ++ ++/* Switch MCK on PLLA output PCK = PLLA = 2 * MCK */ ++#define MCKR_SETTINGS (AT91C_PMC_CSS_PLLA_CLK | AT91C_PMC_PRES_CLK | AT91C_PMC_MDIV_2) +-- +1.5.6.5 + diff --git a/packages/at91bootstrap/files/at91bootstrap-2.3.4.patch b/packages/at91bootstrap/files/at91bootstrap-2.3.4.patch deleted file mode 100644 index 4b94f63d2f..0000000000 --- a/packages/at91bootstrap/files/at91bootstrap-2.3.4.patch +++ /dev/null @@ -1,265 +0,0 @@ -diff -urN at91bootstrap-2.3-0rig/driver/dataflash.c at91bootstrap-2.3.4/driver/dataflash.c ---- at91bootstrap-2.3-0rig/driver/dataflash.c 2007-04-22 13:56:29.000000000 +0200 -+++ at91bootstrap-2.3.4/driver/dataflash.c 2007-09-24 20:56:18.000000000 +0200 -@@ -39,8 +39,12 @@ - #include "../include/part.h" - #include "../include/main.h" - #include "../include/dataflash.h" -+#include "../include/debug.h" - #include - -+#define SUCCESS 1 -+#define FAILURE 0 -+ - #ifdef CFG_DATAFLASH - extern div_t udiv(unsigned int numerator, unsigned int denominator); - /* Write SPI register */ -@@ -92,7 +96,7 @@ - /* SPI_Enable */ - write_spi(SPI_CR, AT91C_SPI_SPIEN); - -- return 0; -+ return SUCCESS; - } - - /*------------------------------------------------------------------------------*/ -@@ -134,12 +138,10 @@ - - /* Try to get the dataflash semaphore */ - if ((pDataFlash->bSemaphore) != UNLOCKED) -- return (char) 0; -+ return (char) FAILURE; - pDataFlash->bSemaphore = LOCKED; -- - /* Compute command pattern */ - dInternalAdr = (result.quot << AT91C_PAGE_OFFSET(pDataFlash)) + result.rem; -- - if (AT91C_DF_NB_PAGE(pDataFlash) >= 16384) - { - pDataFlash->command[0] = (bCmd & 0x000000FF) | \ -@@ -178,7 +180,7 @@ - - while (df_is_busy(pDataFlash) == LOCKED); - -- return 1; -+ return SUCCESS; - } - - /*------------------------------------------------------------------------------*/ -@@ -194,13 +196,13 @@ - if (df_get_status(pDataFlash)) - { - if (df_is_ready(pDataFlash)) -- return 1; -+ return SUCCESS; - } - } - -- return 0; -+ return FAILURE; - } -- -+volatile int loop; - /*------------------------------------------------------------------------------*/ - /* \fn df_read */ - /* \brief Read a block in dataflash */ -@@ -212,21 +214,30 @@ - unsigned int size) - { - unsigned int SizeToRead; -+ int page_counter; - -+ page_counter = 32; - while (size) - { -- SizeToRead = (size < AT91C_MAX_PDC_SIZE)? size : AT91C_MAX_PDC_SIZE; -- -+ SizeToRead = (size < 0x8000)? size : 0x8000; - /* wait the dataflash ready status */ -- df_wait_ready(pDf); -- df_continuous_read(pDf, (char *)buffer, SizeToRead, addr); -- -- size -= SizeToRead; -- addr += SizeToRead; -- buffer += SizeToRead; -+ if(df_wait_ready(pDf) != 0) { -+ df_continuous_read(pDf, (char *)buffer, SizeToRead, addr); -+ dbg_print("."); -+ if(--page_counter <= 0) { -+ page_counter = 32; -+ dbg_print("\r\n"); -+ } -+ size -= SizeToRead; -+ addr += SizeToRead; -+ buffer += SizeToRead; -+ } else { -+ /* We got a timeout */ -+ dbg_print("Timeout while waiting for dataflash ready\n"); -+ return FAILURE; -+ } - } -- -- return 0; -+ return SUCCESS; - } - - /*----------------------------------------------------------------------*/ -@@ -235,13 +246,19 @@ - /*----------------------------------------------------------------------*/ - static int df_download(AT91PS_DF pDf, unsigned int img_addr, unsigned int img_size, unsigned int img_dest) - { -+ dbg_print(">Loading from Dataflash["); -+ dbg_print_hex(img_addr); -+ dbg_print("] to SDRAM["); -+ dbg_print_hex(img_dest); -+ dbg_print("]\r\n"); - /* read bytes in the dataflash */ -- df_read(pDf, img_addr,(unsigned char *)img_dest, img_size); -- -+ if(df_read(pDf, img_addr,(unsigned char *)img_dest, img_size) == FAILURE) -+ return FAILURE; -+ dbg_print("\r\n>Loading complete, ["); -+ dbg_print_hex(IMG_SIZE); -+ dbg_print("] bytes\r\n"); - /* wait the dataflash ready status */ -- df_wait_ready(pDf); -- -- return 0; -+ return df_wait_ready(pDf); - } - - /*----------------------------------------------------------------------*/ -@@ -263,7 +280,7 @@ - static int df_init (AT91PS_DF pDf) - { - int dfcode = 0; -- int status = 1; -+ int status = SUCCESS; - - /* Default: AT45DB321B */ - pDf->dfDescription.pages_number = 8192; -@@ -302,18 +319,21 @@ - pDf->dfDescription.pages_number = 4096; - pDf->dfDescription.pages_size = 528; - pDf->dfDescription.page_offset = 10; -+ dbg_print(">AT45DB161D detected\r\n"); - break; - - case AT45DB321B: - pDf->dfDescription.pages_number = 8192; - pDf->dfDescription.pages_size = 528; - pDf->dfDescription.page_offset = 10; -+ dbg_print(">AT45DB321D detected\r\n"); - break; - - case AT45DB642: - pDf->dfDescription.pages_number = 8192; - pDf->dfDescription.pages_size = 1056; - pDf->dfDescription.page_offset = 11; -+ dbg_print(">AT45DB642D detected\r\n"); - break; - /* - case AT45DB1282: -@@ -335,7 +355,7 @@ - break; - */ - default: -- status = 0; -+ status = FAILURE; - break; - } - -@@ -357,12 +377,12 @@ - if (i != 23) - { - if ((buffer[i] != 0xEA) && (buffer[i] != 0xE5) ) -- return -1; -+ return FAILURE; - } - i+=4; - } - -- return 0; -+ return SUCCESS; - } - - /*------------------------------------------------------------------------------*/ -@@ -374,13 +394,14 @@ - AT91S_DF sDF; - AT91PS_DF pDf = (AT91PS_DF)&sDF; - unsigned int rxBuffer[128]; -+ unsigned int status; - - pDf->bSemaphore = UNLOCKED; - - df_spi_init(pcs, DF_CS_SETTINGS); - -- if (!df_init(pDf)) -- return -1; -+ if (df_init(pDf) == FAILURE) -+ return FAILURE; - - #ifdef AT91SAM9260 - /* Test if a button has been pressed or not */ -@@ -391,10 +412,13 @@ - df_continuous_read(pDf, (char *)rxBuffer, 32, img_addr); - df_wait_ready(pDf); - -- if (df_is_boot_valid((unsigned char*)rxBuffer)) -- return -1; -+ if (df_is_boot_valid((unsigned char*)rxBuffer) == FAILURE) { -+ dbg_print(">Invalid Boot Area...\n\r"); -+ return FAILURE; -+ } - -- return df_download(pDf, img_addr, img_size, img_dest); -+ status = df_download(pDf, img_addr, img_size, img_dest); -+ return status; - } - - #endif /* CFG_DATAFLASH */ -diff -urN at91bootstrap-2.3-0rig/driver/debug.c at91bootstrap-2.3.4/driver/debug.c ---- at91bootstrap-2.3-0rig/driver/debug.c 2006-12-05 11:27:24.000000000 +0100 -+++ at91bootstrap-2.3.4/driver/debug.c 2007-09-24 20:38:01.000000000 +0200 -@@ -85,4 +85,19 @@ - } - } - -+void dbg_print_hex(unsigned int data) -+{ -+ unsigned char hex[11]; -+ int i=0; -+ hex[0]='0'; -+ hex[1]='x'; -+ for(i = 9 ;i >= 2;i--) { -+ hex[i] = "0123456789ABCDEF"[data & 0xF]; -+ data >>= 4; -+ } -+ hex[10]='\0'; -+ dbg_print((const char *) hex); -+} -+ -+ - #endif /* CFG_DEBUG */ -diff -urN at91bootstrap-2.3-0rig/include/debug.h at91bootstrap-2.3.4/include/debug.h ---- at91bootstrap-2.3-0rig/include/debug.h 2006-12-05 11:27:20.000000000 +0100 -+++ at91bootstrap-2.3.4/include/debug.h 2007-09-24 18:26:37.000000000 +0200 -@@ -45,5 +45,6 @@ - /* Global functions */ - extern void dbg_init(unsigned int); - extern void dbg_print(const char *ptr); -+extern void dbg_print_hex(unsigned int data); - - #endif /*_DEBUG_H_*/ -diff -urN at91bootstrap-2.3-0rig/Makefile at91bootstrap-2.3.4/Makefile ---- at91bootstrap-2.3-0rig/Makefile 2007-09-24 18:26:10.000000000 +0200 -+++ at91bootstrap-2.3.4/Makefile 2007-09-24 20:56:53.000000000 +0200 -@@ -17,7 +17,7 @@ - endif - - ifeq ($(CONFIG_SPI_CLK),) --CONFIG_SPI_CLK=5000000 -+CONFIG_SPI_CLK=33000000 - endif - - ifndef MEMORY -- cgit v1.2.3