mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* [PATCH 0/8] low level initialisation for ar2313
@ 2013-06-19  9:11 Oleksij Rempel
  2013-06-19  9:11 ` [PATCH 1/8] MIPS: pbl: add mips_barebox_10h asm macro Oleksij Rempel
                   ` (9 more replies)
  0 siblings, 10 replies; 18+ messages in thread
From: Oleksij Rempel @ 2013-06-19  9:11 UTC (permalink / raw)
  To: barebox

this patch set add low level initialisation for Atheros ar2313
and board based on this chip - Netgear wg102.

Antony Pavlov (2):
  MIPS: pbl: add mips_barebox_10h asm macro
  MIPS: mach-ar231x: enable DEBUG_LL

Oleksij Rempel (6):
  MIPS: pbl: add pbl_sleep macro
  MIPS: pbl: add pbl_probe_mem macro
  MIPS: mach-ar231x: add lowlevel init pbl macros
  MIPS: netgear-wg102: add pbl support
  MIPS: netgear-wg102: add debug_ll
  netgear-wg102: pbl, add extra check for mem config

 arch/mips/Kconfig                                  |   1 +
 .../netgear-wg102/include/board/board_pbl_start.h  |  77 +++++++++
 .../boards/netgear-wg102/include/board/debug_ll.h  |  33 ++++
 arch/mips/include/asm/pbl_macros.h                 |  38 +++++
 arch/mips/mach-ar231x/Kconfig                      |   2 +
 arch/mips/mach-ar231x/include/mach/debug_ll.h      |  27 ++++
 arch/mips/mach-ar231x/include/mach/pbl_macros.h    | 177 +++++++++++++++++++++
 7 files changed, 355 insertions(+)
 create mode 100644 arch/mips/boards/netgear-wg102/include/board/board_pbl_start.h
 create mode 100644 arch/mips/boards/netgear-wg102/include/board/debug_ll.h
 create mode 100644 arch/mips/mach-ar231x/include/mach/debug_ll.h
 create mode 100644 arch/mips/mach-ar231x/include/mach/pbl_macros.h

-- 
1.8.1.2


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 18+ messages in thread

* [PATCH 1/8] MIPS: pbl: add mips_barebox_10h asm macro
  2013-06-19  9:11 [PATCH 0/8] low level initialisation for ar2313 Oleksij Rempel
@ 2013-06-19  9:11 ` Oleksij Rempel
  2013-06-19  9:11 ` [PATCH 2/8] MIPS: pbl: add pbl_sleep macro Oleksij Rempel
                   ` (8 subsequent siblings)
  9 siblings, 0 replies; 18+ messages in thread
From: Oleksij Rempel @ 2013-06-19  9:11 UTC (permalink / raw)
  To: barebox

From: Antony Pavlov <antonynpavlov@gmail.com>

The mips_barebox_10h macro inserts at offset 0x10
of the barebox image the string 'barebox ' followed
by compile time version mark.

Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
---
 arch/mips/include/asm/pbl_macros.h | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/arch/mips/include/asm/pbl_macros.h b/arch/mips/include/asm/pbl_macros.h
index 3971b61..a3f970c 100644
--- a/arch/mips/include/asm/pbl_macros.h
+++ b/arch/mips/include/asm/pbl_macros.h
@@ -97,6 +97,22 @@ copy_loop_exit:
 	.set	pop
 	.endm
 
+	.macro	mips_barebox_10h
+	.set	push
+	.set	noreorder
+
+	b	1f
+	 nop
+
+	.org	0x10
+	.ascii	"barebox " UTS_RELEASE " " UTS_VERSION
+	.byte	0
+
+	.align	4
+1:
+	.set	pop
+	.endm
+
 	/*
 	 * Dominic Sweetman, See MIPS Run, Morgan Kaufmann, 2nd edition, 2006
 	 *
-- 
1.8.1.2


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 18+ messages in thread

* [PATCH 2/8] MIPS: pbl: add pbl_sleep macro
  2013-06-19  9:11 [PATCH 0/8] low level initialisation for ar2313 Oleksij Rempel
  2013-06-19  9:11 ` [PATCH 1/8] MIPS: pbl: add mips_barebox_10h asm macro Oleksij Rempel
@ 2013-06-19  9:11 ` Oleksij Rempel
  2013-06-21  6:44   ` [PATCH 2/8 v2] " Oleksij Rempel
  2013-06-19  9:11 ` [PATCH 3/8] MIPS: pbl: add pbl_probe_mem macro Oleksij Rempel
                   ` (7 subsequent siblings)
  9 siblings, 1 reply; 18+ messages in thread
From: Oleksij Rempel @ 2013-06-19  9:11 UTC (permalink / raw)
  To: barebox

Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
---
 arch/mips/include/asm/pbl_macros.h | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/arch/mips/include/asm/pbl_macros.h b/arch/mips/include/asm/pbl_macros.h
index a3f970c..cfca117 100644
--- a/arch/mips/include/asm/pbl_macros.h
+++ b/arch/mips/include/asm/pbl_macros.h
@@ -28,6 +28,16 @@
 #include <generated/compile.h>
 #include <generated/utsrelease.h>
 
+	.macro	pbl_sleep reg count
+	.set push
+	.set noreorder
+	li	\reg, \count
+1:
+	bgtz	\reg, 1b
+	 addi	\reg, -1
+	.set	pop
+	.endm
+
 	/*
 	 * ADR macro instruction (inspired by ARM)
 	 *
-- 
1.8.1.2


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 18+ messages in thread

* [PATCH 3/8] MIPS: pbl: add pbl_probe_mem macro
  2013-06-19  9:11 [PATCH 0/8] low level initialisation for ar2313 Oleksij Rempel
  2013-06-19  9:11 ` [PATCH 1/8] MIPS: pbl: add mips_barebox_10h asm macro Oleksij Rempel
  2013-06-19  9:11 ` [PATCH 2/8] MIPS: pbl: add pbl_sleep macro Oleksij Rempel
@ 2013-06-19  9:11 ` Oleksij Rempel
  2013-06-19  9:11 ` [PATCH 4/8] MIPS: mach-ar231x: add lowlevel init pbl macros Oleksij Rempel
                   ` (6 subsequent siblings)
  9 siblings, 0 replies; 18+ messages in thread
From: Oleksij Rempel @ 2013-06-19  9:11 UTC (permalink / raw)
  To: barebox

Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
---
 arch/mips/include/asm/pbl_macros.h | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/arch/mips/include/asm/pbl_macros.h b/arch/mips/include/asm/pbl_macros.h
index cfca117..22d41b8 100644
--- a/arch/mips/include/asm/pbl_macros.h
+++ b/arch/mips/include/asm/pbl_macros.h
@@ -38,6 +38,18 @@
 	.set	pop
 	.endm
 
+	.macro	pbl_probe_mem ret1 ret2 addr
+	.set	push
+	.set	noreorder
+	la	\ret1, \addr
+	sw	zero, 0(\ret1)
+	li	\ret2, 0x12345678
+	sw	\ret2, 0(\ret1)
+	lw	\ret2, 0(\ret1)
+	li	\ret1, 0x12345678
+	.set	pop
+	.endm
+
 	/*
 	 * ADR macro instruction (inspired by ARM)
 	 *
-- 
1.8.1.2


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 18+ messages in thread

* [PATCH 4/8] MIPS: mach-ar231x: add lowlevel init pbl macros
  2013-06-19  9:11 [PATCH 0/8] low level initialisation for ar2313 Oleksij Rempel
                   ` (2 preceding siblings ...)
  2013-06-19  9:11 ` [PATCH 3/8] MIPS: pbl: add pbl_probe_mem macro Oleksij Rempel
@ 2013-06-19  9:11 ` Oleksij Rempel
  2013-06-19  9:11 ` [PATCH 5/8] MIPS: netgear-wg102: add pbl support Oleksij Rempel
                   ` (5 subsequent siblings)
  9 siblings, 0 replies; 18+ messages in thread
From: Oleksij Rempel @ 2013-06-19  9:11 UTC (permalink / raw)
  To: barebox

Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
---
 arch/mips/mach-ar231x/include/mach/pbl_macros.h | 177 ++++++++++++++++++++++++
 1 file changed, 177 insertions(+)
 create mode 100644 arch/mips/mach-ar231x/include/mach/pbl_macros.h

diff --git a/arch/mips/mach-ar231x/include/mach/pbl_macros.h b/arch/mips/mach-ar231x/include/mach/pbl_macros.h
new file mode 100644
index 0000000..cb72dbe
--- /dev/null
+++ b/arch/mips/mach-ar231x/include/mach/pbl_macros.h
@@ -0,0 +1,177 @@
+#ifndef __ASM_MACH_AR2312_PBL_MACROS_H
+#define __ASM_MACH_AR2312_PBL_MACROS_H
+
+#include <asm/regdef.h>
+#include <mach/ar2312_regs.h>
+
+.macro	pbl_ar2312_pll
+	.set	push
+	.set	noreorder
+
+	mfc0	k0, CP0_STATUS
+	li	k1, ST0_NMI
+	and	k1, k1, k0
+	bnez	k1, pllskip
+	 nop
+
+	/* Clear any prior AHB errors by reading both addr registers */
+	li	t0, KSEG1 | AR2312_PROCADDR
+	lw	zero, 0(t0)
+	li	t0, KSEG1 | AR2312_DMAADDR
+	lw	zero, 0(t0)
+
+	pbl_sleep	t2, 4000
+
+	li	t0, KSEG1 | AR2312_CLOCKCTL2
+	lw	t1, (t0)
+	bgez	t1, pllskip	/* upper bit guaranteed non-0 at reset */
+	 nop
+
+	/* For Viper 0xbc003064 register has to be programmed with 0x91000 to
+	 * get 180Mhz Processor clock
+	 * Set /2 clocking and turn OFF AR2312_CLOCKCTL2_STATUS_PLL_BYPASS.
+	 * Processor RESETs at this point; the CLOCKCTL registers retain
+	 * their new values across the reset.
+	 */
+
+	li	t0, KSEG1 | AR2312_CLOCKCTL1
+	li	t1, AR2313_CLOCKCTL1_SELECTION
+	sw	t1, (t0)
+
+	li	t0, KSEG1 | AR2312_CLOCKCTL2
+	li	t1, AR2312_CLOCKCTL2_WANT_RESET
+	sw	t1, (t0)	/* reset CPU */
+1:	b	1b		/* NOTREACHED */
+	 nop
+pllskip:
+
+	.set	pop
+.endm
+
+.macro	pbl_ar2312_rst_uart0
+	.set	push
+	.set	noreorder
+
+	li	a0, KSEG1 | AR2312_RESET
+	lw	t0, 0(a0)
+	and	t0, ~AR2312_RESET_APB
+	or	t0, AR2312_RESET_UART0
+	sw	t0, 0(a0)
+	lw	zero, 0(a0)	/* flush */
+
+	and	t0, ~AR2312_RESET_UART0
+	sw	t0, 0(a0)
+	lw	zero, 0(a0)	/* flush */
+
+1:	/* Use internal clocking */
+	li	a0, KSEG1 | AR2312_CLOCKCTL0
+	lw	t0, 0(a0)
+	and	t0, ~AR2312_CLOCKCTL_UART0
+	sw	t0, 0(a0)
+
+	.set	pop
+.endm
+
+.macro	pbl_ar2312_x16_sdram
+	.set	push
+	.set	noreorder
+
+	li	a0, KSEG1 | AR2312_MEM_CFG0
+	li	a1, KSEG1 | AR2312_MEM_CFG1
+	li	a2, KSEG1 | AR2312_MEM_REF
+
+	li	a3, MEM_CFG1_E0 | (MEM_CFG1_AC_128 << MEM_CFG1_AC0_S)
+
+	/* Set the I and M bits to issue an SDRAM nop */
+	ori	t0, a3, MEM_CFG1_M | MEM_CFG1_I
+	sw	t0, 0(a1)	/* AR2312_MEM_CFG1 */
+
+	pbl_sleep	t2, 50
+
+	/* Reset the M bit to issue an SDRAM PRE-ALL */
+	ori	t0, a3, MEM_CFG1_I
+	sw	t0, 0(a1)	/* AR2312_MEM_CFG1 */
+	sync
+
+	/* Generate a refresh every 16 clocks (spec says 10) */
+	li	t0, 16		/* very fast refresh for now */
+	sw	t0, 0(a2)	/* AR2312_MEM_REF */
+
+	pbl_sleep	t2, 5
+
+	/* Set command write mode, and read SDRAM */
+	ori	t0, a3, MEM_CFG1_M
+	sw	t0, 0(a1)	/* AR2312_MEM_CFG1 */
+	sync
+
+	li	t0, KSEG1 | AR2312_SDRAM0
+	or	t0, 0x23000	/* 16bit burst */
+	lw	zero, 0(t0)
+
+	/* Program configuration register */
+	li	t0, MEM_CFG0_C | MEM_CFG0_C2 | MEM_CFG0_R1 | \
+			MEM_CFG0_B0 | MEM_CFG0_X
+	sw	t0, 0(a0)	/* AR2312_MEM_CFG0 */
+	sync
+
+	li	t0, AR2312_SDRAM_MEMORY_REFRESH_VALUE
+	sw	t0, 0(a2)	/* AR2312_MEM_REF */
+	sync
+
+	/* Clear I and M and set cfg1 to the normal operational value */
+	sw	a3, 0(a1)	/* AR2312_MEM_CFG1 */
+	sync
+
+	pbl_sleep	t2, 10
+
+	/* Now we need to set size of RAM to prevent some wired errors.
+	 * Since I do not have access to any board with two SDRAM chips, or
+	 * any was registered in the wild - we will support only one. */
+	/* So, lets find the beef */
+	li	a0, KSEG1 | AR2312_MEM_CFG1
+	li	a1, KSEG1 | AR2312_SDRAM0
+	li	a2, 0xdeadbeef
+	li	t0, 0x200000
+	li	t1, MEM_CFG1_AC_2
+
+	/* We will write some magic word to the beginning of RAM,
+	 * and see if it appears somewhere else. If yes, we made
+	 * a travel around the world. */
+
+	/* But first of all save original state of the first RAM word. */
+	lw	a3, 0(a1)
+	sw	a2, 0(a1)
+
+find_the_beef:
+	or	t2, a1, t0
+	lw	t3, 0(t2)
+	beq	a2, t3, 1f
+	 nop
+	sll	t0, 1
+	add	t1, 1
+	/* we should have some limit here. */
+	blt	t1, MEM_CFG1_AC_64, find_the_beef
+	 nop
+	b	make_beefsteak
+	 nop
+
+	/* additional paranoid check */
+1:
+	sw	zero, 0(a1)
+	lw	t3, 0(t2)
+	bne	zero, t3, find_the_beef
+	 nop
+
+make_beefsteak:
+	/* create new config for AR2312_MEM_CFG1 and overwrite it */
+	sll	t1, MEM_CFG1_AC0_S
+	or	t2, t1, MEM_CFG1_E0
+	sw	t2, 0(a0)	/* AR2312_MEM_CFG1 */
+
+	/* restore original state of the first RAM word */
+	sw	a3, 0(a1)
+
+	.set	pop
+.endm
+
+#endif /* __ASM_MACH_AR2312_PBL_MACROS_H */
-- 
1.8.1.2


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 18+ messages in thread

* [PATCH 5/8] MIPS: netgear-wg102: add pbl support
  2013-06-19  9:11 [PATCH 0/8] low level initialisation for ar2313 Oleksij Rempel
                   ` (3 preceding siblings ...)
  2013-06-19  9:11 ` [PATCH 4/8] MIPS: mach-ar231x: add lowlevel init pbl macros Oleksij Rempel
@ 2013-06-19  9:11 ` Oleksij Rempel
  2013-06-19  9:11 ` [PATCH 6/8] MIPS: netgear-wg102: add debug_ll Oleksij Rempel
                   ` (4 subsequent siblings)
  9 siblings, 0 replies; 18+ messages in thread
From: Oleksij Rempel @ 2013-06-19  9:11 UTC (permalink / raw)
  To: barebox

Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
---
 .../netgear-wg102/include/board/board_pbl_start.h  | 69 ++++++++++++++++++++++
 arch/mips/mach-ar231x/Kconfig                      |  2 +
 2 files changed, 71 insertions(+)
 create mode 100644 arch/mips/boards/netgear-wg102/include/board/board_pbl_start.h

diff --git a/arch/mips/boards/netgear-wg102/include/board/board_pbl_start.h b/arch/mips/boards/netgear-wg102/include/board/board_pbl_start.h
new file mode 100644
index 0000000..4deae06
--- /dev/null
+++ b/arch/mips/boards/netgear-wg102/include/board/board_pbl_start.h
@@ -0,0 +1,69 @@
+/*
+ * Copyright (C) 2013 Antony Pavlov <antonynpavlov@gmail.com>
+ * Copyright (C) 2013 Oleksij Rempel <linux@rempel-privat.de>
+ *
+ * This file is part of barebox.
+ * See file CREDITS for list of people who contributed to this project.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2
+ * as published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ */
+
+#include <asm/pbl_macros.h>
+#include <mach/pbl_macros.h>
+
+#include <mach/debug_ll.h>
+
+	.macro	board_pbl_start
+	.set	push
+	.set	noreorder
+
+	mips_barebox_10h
+
+	mips_disable_interrupts
+
+	pbl_ar2312_pll
+
+	pbl_ar2312_rst_uart0
+	debug_ll_ns16550_init
+
+	debug_ll_ns16550_outc 'a'
+	debug_ll_ns16550_outnl
+
+	/* check if SDRAM is already configured,
+	 * if yes, we are probably starting
+	 * as second stage loader and can skip configuration */
+	pbl_probe_mem t0, t1, KSEG1
+	beq t0, t1, sdram_configured
+	 nop
+
+	/* start SDRAM configuration */
+	pbl_ar2312_x16_sdram
+
+	/* check one more time. if some thing wrong,
+	 * we don't need to continue */
+	pbl_probe_mem t0, t1, KSEG1
+	beq t0, t1, sdram_configured
+	 nop
+	debug_ll_ns16550_outc '#'
+	debug_ll_ns16550_outnl
+
+1:
+	b	1b /* dead end */
+	 nop
+
+sdram_configured:
+	debug_ll_ns16550_outc 'b'
+	debug_ll_ns16550_outnl
+
+	copy_to_link_location	pbl_start
+
+	.set	pop
+	.endm
diff --git a/arch/mips/mach-ar231x/Kconfig b/arch/mips/mach-ar231x/Kconfig
index 1c6a12f..3f338ea 100644
--- a/arch/mips/mach-ar231x/Kconfig
+++ b/arch/mips/mach-ar231x/Kconfig
@@ -9,6 +9,8 @@ choice
 
 config BOARD_NETGEAR_WG102
 	bool "Netgear WG102"
+	select HAVE_PBL_IMAGE
+	select HAVE_IMAGE_COMPRESSION
 
 endchoice
 
-- 
1.8.1.2


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 18+ messages in thread

* [PATCH 6/8] MIPS: netgear-wg102: add debug_ll
  2013-06-19  9:11 [PATCH 0/8] low level initialisation for ar2313 Oleksij Rempel
                   ` (4 preceding siblings ...)
  2013-06-19  9:11 ` [PATCH 5/8] MIPS: netgear-wg102: add pbl support Oleksij Rempel
@ 2013-06-19  9:11 ` Oleksij Rempel
  2013-06-19  9:11 ` [PATCH 7/8] MIPS: mach-ar231x: enable DEBUG_LL Oleksij Rempel
                   ` (3 subsequent siblings)
  9 siblings, 0 replies; 18+ messages in thread
From: Oleksij Rempel @ 2013-06-19  9:11 UTC (permalink / raw)
  To: barebox

Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
---
 .../boards/netgear-wg102/include/board/debug_ll.h  | 33 ++++++++++++++++++++++
 1 file changed, 33 insertions(+)
 create mode 100644 arch/mips/boards/netgear-wg102/include/board/debug_ll.h

diff --git a/arch/mips/boards/netgear-wg102/include/board/debug_ll.h b/arch/mips/boards/netgear-wg102/include/board/debug_ll.h
new file mode 100644
index 0000000..2725032
--- /dev/null
+++ b/arch/mips/boards/netgear-wg102/include/board/debug_ll.h
@@ -0,0 +1,33 @@
+/*
+ * Copyright (C) 2013 Oleksij Rempel <linux@rempel-privat.de>
+ *
+ * This file is part of barebox.
+ * See file CREDITS for list of people who contributed to this project.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2
+ * as published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ */
+
+/** @file
+ *  This File contains declaration for early output support
+ */
+#ifndef __NETGEAR_WG102_DEBUG_LL_H__
+#define __NETGEAR_WG102_DEBUG_LL_H__
+
+#include <mach/ar2312_regs.h>
+
+#define DEBUG_LL_UART_ADDR	KSEG1ADDR(AR2312_UART0)
+#define DEBUG_LL_UART_SHIFT	AR2312_UART_SHIFT
+
+#define DEBUG_LL_UART_CLK   (45000000 / 16)
+#define DEBUG_LL_UART_BPS   CONFIG_BAUDRATE
+#define DEBUG_LL_UART_DIVISOR   (DEBUG_LL_UART_CLK / DEBUG_LL_UART_BPS)
+
+#endif /* __NETGEAR_WG102_DEBUG_LL_H__ */
-- 
1.8.1.2


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 18+ messages in thread

* [PATCH 7/8] MIPS: mach-ar231x: enable DEBUG_LL
  2013-06-19  9:11 [PATCH 0/8] low level initialisation for ar2313 Oleksij Rempel
                   ` (5 preceding siblings ...)
  2013-06-19  9:11 ` [PATCH 6/8] MIPS: netgear-wg102: add debug_ll Oleksij Rempel
@ 2013-06-19  9:11 ` Oleksij Rempel
  2013-06-19  9:11 ` [PATCH 8/8] netgear-wg102: pbl, add extra check for mem config Oleksij Rempel
                   ` (2 subsequent siblings)
  9 siblings, 0 replies; 18+ messages in thread
From: Oleksij Rempel @ 2013-06-19  9:11 UTC (permalink / raw)
  To: barebox

From: Antony Pavlov <antonynpavlov@gmail.com>

Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
---
 arch/mips/Kconfig                             |  1 +
 arch/mips/mach-ar231x/include/mach/debug_ll.h | 27 +++++++++++++++++++++++++++
 2 files changed, 28 insertions(+)
 create mode 100644 arch/mips/mach-ar231x/include/mach/debug_ll.h

diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig
index 2e44619..6179fd8 100644
--- a/arch/mips/Kconfig
+++ b/arch/mips/Kconfig
@@ -52,6 +52,7 @@ config MACH_MIPS_AR231X
 	select SYS_SUPPORTS_BIG_ENDIAN
 	select CSRC_R4K_LIB
 	select DRIVER_SERIAL_NS16550
+	select HAS_DEBUG_LL
 
 config MACH_MIPS_BCM47XX
 	bool "Broadcom BCM47xx-based boards"
diff --git a/arch/mips/mach-ar231x/include/mach/debug_ll.h b/arch/mips/mach-ar231x/include/mach/debug_ll.h
new file mode 100644
index 0000000..5ab7f9a
--- /dev/null
+++ b/arch/mips/mach-ar231x/include/mach/debug_ll.h
@@ -0,0 +1,27 @@
+/*
+ * Copyright (C) 2013 Antony Pavlov <antonynpavlov@gmail.com>
+ *
+ * This file is part of barebox.
+ * See file CREDITS for list of people who contributed to this project.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2
+ * as published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ */
+
+#ifndef __MACH_AR231X_DEBUG_LL__
+#define __MACH_AR231X_DEBUG_LL__
+
+/** @file
+ *  This File contains declaration for early output support
+ */
+#include <board/debug_ll.h>
+#include <asm/debug_ll_ns16550.h>
+
+#endif /* __MACH_AR231X_DEBUG_LL__ */
-- 
1.8.1.2


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 18+ messages in thread

* [PATCH 8/8] netgear-wg102: pbl, add extra check for mem config
  2013-06-19  9:11 [PATCH 0/8] low level initialisation for ar2313 Oleksij Rempel
                   ` (6 preceding siblings ...)
  2013-06-19  9:11 ` [PATCH 7/8] MIPS: mach-ar231x: enable DEBUG_LL Oleksij Rempel
@ 2013-06-19  9:11 ` Oleksij Rempel
  2013-06-21  5:30 ` [PATCH 0/8] low level initialisation for ar2313 Sascha Hauer
  2013-06-21 15:48 ` Sascha Hauer
  9 siblings, 0 replies; 18+ messages in thread
From: Oleksij Rempel @ 2013-06-19  9:11 UTC (permalink / raw)
  To: barebox

if E0 flag is not set, sdram is defenetly not configured.

Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
---
 arch/mips/boards/netgear-wg102/include/board/board_pbl_start.h | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/arch/mips/boards/netgear-wg102/include/board/board_pbl_start.h b/arch/mips/boards/netgear-wg102/include/board/board_pbl_start.h
index 4deae06..d74d2c2 100644
--- a/arch/mips/boards/netgear-wg102/include/board/board_pbl_start.h
+++ b/arch/mips/boards/netgear-wg102/include/board/board_pbl_start.h
@@ -18,6 +18,7 @@
 
 #include <asm/pbl_macros.h>
 #include <mach/pbl_macros.h>
+#include <mach/ar2312_regs.h>
 
 #include <mach/debug_ll.h>
 
@@ -40,10 +41,17 @@
 	/* check if SDRAM is already configured,
 	 * if yes, we are probably starting
 	 * as second stage loader and can skip configuration */
+	la	t0, KSEG1 | AR2312_MEM_CFG1
+	lw	t1, 0(t0)
+	and	t0, t1, MEM_CFG1_E0
+	beq	zero, t0, 1f
+	 nop
+
 	pbl_probe_mem t0, t1, KSEG1
 	beq t0, t1, sdram_configured
 	 nop
 
+1:
 	/* start SDRAM configuration */
 	pbl_ar2312_x16_sdram
 
-- 
1.8.1.2


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH 0/8] low level initialisation for ar2313
  2013-06-19  9:11 [PATCH 0/8] low level initialisation for ar2313 Oleksij Rempel
                   ` (7 preceding siblings ...)
  2013-06-19  9:11 ` [PATCH 8/8] netgear-wg102: pbl, add extra check for mem config Oleksij Rempel
@ 2013-06-21  5:30 ` Sascha Hauer
  2013-06-21  6:25   ` antonynpavlov
  2013-06-21 15:48 ` Sascha Hauer
  9 siblings, 1 reply; 18+ messages in thread
From: Sascha Hauer @ 2013-06-21  5:30 UTC (permalink / raw)
  To: Oleksij Rempel; +Cc: barebox

Hi Oleksij, Antony,

I'm fine with this series. Antony, do you have comments?

Sascha

On Wed, Jun 19, 2013 at 11:11:25AM +0200, Oleksij Rempel wrote:
> this patch set add low level initialisation for Atheros ar2313
> and board based on this chip - Netgear wg102.
> 
> Antony Pavlov (2):
>   MIPS: pbl: add mips_barebox_10h asm macro
>   MIPS: mach-ar231x: enable DEBUG_LL
> 
> Oleksij Rempel (6):
>   MIPS: pbl: add pbl_sleep macro
>   MIPS: pbl: add pbl_probe_mem macro
>   MIPS: mach-ar231x: add lowlevel init pbl macros
>   MIPS: netgear-wg102: add pbl support
>   MIPS: netgear-wg102: add debug_ll
>   netgear-wg102: pbl, add extra check for mem config
> 
>  arch/mips/Kconfig                                  |   1 +
>  .../netgear-wg102/include/board/board_pbl_start.h  |  77 +++++++++
>  .../boards/netgear-wg102/include/board/debug_ll.h  |  33 ++++
>  arch/mips/include/asm/pbl_macros.h                 |  38 +++++
>  arch/mips/mach-ar231x/Kconfig                      |   2 +
>  arch/mips/mach-ar231x/include/mach/debug_ll.h      |  27 ++++
>  arch/mips/mach-ar231x/include/mach/pbl_macros.h    | 177 +++++++++++++++++++++
>  7 files changed, 355 insertions(+)
>  create mode 100644 arch/mips/boards/netgear-wg102/include/board/board_pbl_start.h
>  create mode 100644 arch/mips/boards/netgear-wg102/include/board/debug_ll.h
>  create mode 100644 arch/mips/mach-ar231x/include/mach/debug_ll.h
>  create mode 100644 arch/mips/mach-ar231x/include/mach/pbl_macros.h
> 
> -- 
> 1.8.1.2
> 
> 
> _______________________________________________
> barebox mailing list
> barebox@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/barebox
> 

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH 0/8] low level initialisation for ar2313
  2013-06-21  5:30 ` [PATCH 0/8] low level initialisation for ar2313 Sascha Hauer
@ 2013-06-21  6:25   ` antonynpavlov
  2013-06-21  7:23     ` Sascha Hauer
  0 siblings, 1 reply; 18+ messages in thread
From: antonynpavlov @ 2013-06-21  6:25 UTC (permalink / raw)
  To: Sascha Hauer; +Cc: barebox

On Fri, 21 Jun 2013 07:30:17 +0200
Sascha Hauer <s.hauer@pengutronix.de> wrote:

> Hi Oleksij, Antony,
> 
> I'm fine with this series. Antony, do you have comments?

The series looks good!

But in the last minute I made a small fix for the "MIPS: pbl: add pbl_sleep macro" patch.

It's a shame, but generated label inside assembly macros are not "local" (at least I have not found how to make them local in my toolchain). 

As the user of the pbl_sleep can use generated label "1" (this label already used in pbl_sleep), there can be some painful side effects, e.g. 

1:                    // user's generated label

   ...                // some user code

   pbl_sleep t1 100

   ...                // another user code

   b 1b               // jump to the back label "1"


Inside the pbl_sleep macro we have one more "1" label, so the jump instruction of the
example transfer control not to the user's label "1" but to label "1" inside pbl_sleep. 

So I propose a ad-hoc solution.

--- a/arch/mips/include/asm/pbl_macros.h
+++ b/arch/mips/include/asm/pbl_macros.h
@@ -32,8 +32,8 @@
        .set push
        .set noreorder
        li      \reg, \count
-1:
-       bgtz    \reg, 1b
+254:
+       bgtz    \reg, 254b
         addi   \reg, -1
        .set    pop
        .endm

The programmers are lazy (at least many of them), they like short names "1", "2"
and "254" is very long name, so the conflict is not expected.
To prevent conflicts like this we can make a convention "don't use generated labels 200-255 in you assembler pbl code". 

Is there a need for series/patch reposting for fixing the issue?

> On Wed, Jun 19, 2013 at 11:11:25AM +0200, Oleksij Rempel wrote:
> > this patch set add low level initialisation for Atheros ar2313
> > and board based on this chip - Netgear wg102.
> > 
> > Antony Pavlov (2):
> >   MIPS: pbl: add mips_barebox_10h asm macro
> >   MIPS: mach-ar231x: enable DEBUG_LL
> > 
> > Oleksij Rempel (6):
> >   MIPS: pbl: add pbl_sleep macro
> >   MIPS: pbl: add pbl_probe_mem macro
> >   MIPS: mach-ar231x: add lowlevel init pbl macros
> >   MIPS: netgear-wg102: add pbl support
> >   MIPS: netgear-wg102: add debug_ll
> >   netgear-wg102: pbl, add extra check for mem config
> > 
> >  arch/mips/Kconfig                                  |   1 +
> >  .../netgear-wg102/include/board/board_pbl_start.h  |  77 +++++++++
> >  .../boards/netgear-wg102/include/board/debug_ll.h  |  33 ++++
> >  arch/mips/include/asm/pbl_macros.h                 |  38 +++++
> >  arch/mips/mach-ar231x/Kconfig                      |   2 +
> >  arch/mips/mach-ar231x/include/mach/debug_ll.h      |  27 ++++
> >  arch/mips/mach-ar231x/include/mach/pbl_macros.h    | 177 +++++++++++++++++++++
> >  7 files changed, 355 insertions(+)
> >  create mode 100644 arch/mips/boards/netgear-wg102/include/board/board_pbl_start.h
> >  create mode 100644 arch/mips/boards/netgear-wg102/include/board/debug_ll.h
> >  create mode 100644 arch/mips/mach-ar231x/include/mach/debug_ll.h
> >  create mode 100644 arch/mips/mach-ar231x/include/mach/pbl_macros.h
> > 
> > -- 
> > 1.8.1.2
> > 
> > 
> > _______________________________________________
> > barebox mailing list
> > barebox@lists.infradead.org
> > http://lists.infradead.org/mailman/listinfo/barebox
> > 
> 
> -- 
> Pengutronix e.K.                           |                             |
> Industrial Linux Solutions                 | http://www.pengutronix.de/  |
> Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
> Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |


-- 
-- 
Best regards,
  Antony Pavlov

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 18+ messages in thread

* [PATCH 2/8 v2] MIPS: pbl: add pbl_sleep macro
  2013-06-19  9:11 ` [PATCH 2/8] MIPS: pbl: add pbl_sleep macro Oleksij Rempel
@ 2013-06-21  6:44   ` Oleksij Rempel
  0 siblings, 0 replies; 18+ messages in thread
From: Oleksij Rempel @ 2013-06-21  6:44 UTC (permalink / raw)
  To: barebox

Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
---
 arch/mips/include/asm/pbl_macros.h | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/arch/mips/include/asm/pbl_macros.h b/arch/mips/include/asm/pbl_macros.h
index a3f970c..fde9434 100644
--- a/arch/mips/include/asm/pbl_macros.h
+++ b/arch/mips/include/asm/pbl_macros.h
@@ -28,6 +28,16 @@
 #include <generated/compile.h>
 #include <generated/utsrelease.h>
 
+	.macro	pbl_sleep reg count
+	.set push
+	.set noreorder
+	li	\reg, \count
+254:
+	bgtz	\reg, 254b
+	 addi	\reg, -1
+	.set	pop
+	.endm
+
 	/*
 	 * ADR macro instruction (inspired by ARM)
 	 *
-- 
1.8.1.2


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH 0/8] low level initialisation for ar2313
  2013-06-21  6:25   ` antonynpavlov
@ 2013-06-21  7:23     ` Sascha Hauer
  2013-06-21  7:34       ` antonynpavlov
  0 siblings, 1 reply; 18+ messages in thread
From: Sascha Hauer @ 2013-06-21  7:23 UTC (permalink / raw)
  To: antonynpavlov; +Cc: barebox

On Fri, Jun 21, 2013 at 10:25:25AM +0400, antonynpavlov@gmail.com wrote:
> On Fri, 21 Jun 2013 07:30:17 +0200
> Sascha Hauer <s.hauer@pengutronix.de> wrote:
> 
> > Hi Oleksij, Antony,
> > 
> > I'm fine with this series. Antony, do you have comments?
> 
> The series looks good!
> 
> But in the last minute I made a small fix for the "MIPS: pbl: add pbl_sleep macro" patch.
> 
> It's a shame, but generated label inside assembly macros are not "local" (at least I have not found how to make them local in my toolchain). 
> 
> As the user of the pbl_sleep can use generated label "1" (this label already used in pbl_sleep), there can be some painful side effects, e.g. 
> 
> 1:                    // user's generated label
> 
>    ...                // some user code
> 
>    pbl_sleep t1 100
> 
>    ...                // another user code
> 
>    b 1b               // jump to the back label "1"
> 
> 
> Inside the pbl_sleep macro we have one more "1" label, so the jump instruction of the
> example transfer control not to the user's label "1" but to label "1" inside pbl_sleep. 
> 
> So I propose a ad-hoc solution.
> 
> --- a/arch/mips/include/asm/pbl_macros.h
> +++ b/arch/mips/include/asm/pbl_macros.h
> @@ -32,8 +32,8 @@
>         .set push
>         .set noreorder
>         li      \reg, \count
> -1:
> -       bgtz    \reg, 1b
> +254:
> +       bgtz    \reg, 254b
>          addi   \reg, -1
>         .set    pop
>         .endm

Yeah, I noticed the same problem some time ago and came up with the same
solution. I'm not aware of a better way to do this.

> 
> The programmers are lazy (at least many of them), they like short names "1", "2"
> and "254" is very long name, so the conflict is not expected.
> To prevent conflicts like this we can make a convention "don't use generated labels 200-255 in you assembler pbl code". 
> 
> Is there a need for series/patch reposting for fixing the issue?

Yes, please post what you want me to apply on -next.

Sascha

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH 0/8] low level initialisation for ar2313
  2013-06-21  7:23     ` Sascha Hauer
@ 2013-06-21  7:34       ` antonynpavlov
  0 siblings, 0 replies; 18+ messages in thread
From: antonynpavlov @ 2013-06-21  7:34 UTC (permalink / raw)
  To: Sascha Hauer; +Cc: barebox

On Fri, 21 Jun 2013 09:23:19 +0200
Sascha Hauer <s.hauer@pengutronix.de> wrote:

> On Fri, Jun 21, 2013 at 10:25:25AM +0400, antonynpavlov@gmail.com wrote:
> > On Fri, 21 Jun 2013 07:30:17 +0200
> > Sascha Hauer <s.hauer@pengutronix.de> wrote:
> > 
> > > Hi Oleksij, Antony,
> > > 
> > > I'm fine with this series. Antony, do you have comments?
> > 
> > The series looks good!
> > 
> > But in the last minute I made a small fix for the "MIPS: pbl: add pbl_sleep macro" patch.
> > 
> > It's a shame, but generated label inside assembly macros are not "local" (at least I have not found how to make them local in my toolchain). 
> > 
> > As the user of the pbl_sleep can use generated label "1" (this label already used in pbl_sleep), there can be some painful side effects, e.g. 
> > 
> > 1:                    // user's generated label
> > 
> >    ...                // some user code
> > 
> >    pbl_sleep t1 100
> > 
> >    ...                // another user code
> > 
> >    b 1b               // jump to the back label "1"
> > 
> > 
> > Inside the pbl_sleep macro we have one more "1" label, so the jump instruction of the
> > example transfer control not to the user's label "1" but to label "1" inside pbl_sleep. 
> > 
> > So I propose a ad-hoc solution.
> > 
> > --- a/arch/mips/include/asm/pbl_macros.h
> > +++ b/arch/mips/include/asm/pbl_macros.h
> > @@ -32,8 +32,8 @@
> >         .set push
> >         .set noreorder
> >         li      \reg, \count
> > -1:
> > -       bgtz    \reg, 1b
> > +254:
> > +       bgtz    \reg, 254b
> >          addi   \reg, -1
> >         .set    pop
> >         .endm
> 
> Yeah, I noticed the same problem some time ago and came up with the same
> solution. I'm not aware of a better way to do this.
> 
> > 
> > The programmers are lazy (at least many of them), they like short names "1", "2"
> > and "254" is very long name, so the conflict is not expected.
> > To prevent conflicts like this we can make a convention "don't use generated labels 200-255 in you assembler pbl code". 
> > 
> > Is there a need for series/patch reposting for fixing the issue?
> 
> Yes, please post what you want me to apply on -next.

Oleksij have reposted the fixed patch: "[PATCH 2/8 v2] MIPS: pbl: add pbl_sleep macro"

> 
> Sascha
> 
> -- 
> Pengutronix e.K.                           |                             |
> Industrial Linux Solutions                 | http://www.pengutronix.de/  |
> Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
> Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |


-- 
-- 
Best regards,
  Antony Pavlov

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH 0/8] low level initialisation for ar2313
  2013-06-19  9:11 [PATCH 0/8] low level initialisation for ar2313 Oleksij Rempel
                   ` (8 preceding siblings ...)
  2013-06-21  5:30 ` [PATCH 0/8] low level initialisation for ar2313 Sascha Hauer
@ 2013-06-21 15:48 ` Sascha Hauer
  2013-06-21 16:37   ` antonynpavlov
  9 siblings, 1 reply; 18+ messages in thread
From: Sascha Hauer @ 2013-06-21 15:48 UTC (permalink / raw)
  To: Oleksij Rempel; +Cc: barebox

On Wed, Jun 19, 2013 at 11:11:25AM +0200, Oleksij Rempel wrote:
> this patch set add low level initialisation for Atheros ar2313
> and board based on this chip - Netgear wg102.
> 
> Antony Pavlov (2):
>   MIPS: pbl: add mips_barebox_10h asm macro
>   MIPS: mach-ar231x: enable DEBUG_LL
> 
> Oleksij Rempel (6):
>   MIPS: pbl: add pbl_sleep macro
>   MIPS: pbl: add pbl_probe_mem macro
>   MIPS: mach-ar231x: add lowlevel init pbl macros
>   MIPS: netgear-wg102: add pbl support
>   MIPS: netgear-wg102: add debug_ll
>   netgear-wg102: pbl, add extra check for mem config

Applied, thanks

Sascha

> 
>  arch/mips/Kconfig                                  |   1 +
>  .../netgear-wg102/include/board/board_pbl_start.h  |  77 +++++++++
>  .../boards/netgear-wg102/include/board/debug_ll.h  |  33 ++++
>  arch/mips/include/asm/pbl_macros.h                 |  38 +++++
>  arch/mips/mach-ar231x/Kconfig                      |   2 +
>  arch/mips/mach-ar231x/include/mach/debug_ll.h      |  27 ++++
>  arch/mips/mach-ar231x/include/mach/pbl_macros.h    | 177 +++++++++++++++++++++
>  7 files changed, 355 insertions(+)
>  create mode 100644 arch/mips/boards/netgear-wg102/include/board/board_pbl_start.h
>  create mode 100644 arch/mips/boards/netgear-wg102/include/board/debug_ll.h
>  create mode 100644 arch/mips/mach-ar231x/include/mach/debug_ll.h
>  create mode 100644 arch/mips/mach-ar231x/include/mach/pbl_macros.h
> 
> -- 
> 1.8.1.2
> 
> 
> _______________________________________________
> barebox mailing list
> barebox@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/barebox
> 

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH 0/8] low level initialisation for ar2313
  2013-06-21 15:48 ` Sascha Hauer
@ 2013-06-21 16:37   ` antonynpavlov
  2013-06-23 18:42     ` Sascha Hauer
  0 siblings, 1 reply; 18+ messages in thread
From: antonynpavlov @ 2013-06-21 16:37 UTC (permalink / raw)
  To: Oleksij Rempel; +Cc: barebox

On Fri, 21 Jun 2013 17:48:40 +0200
Sascha Hauer <s.hauer@pengutronix.de> wrote:

Well done, Oleksij! Congratulations!

Thanks, Sascha!

Now we have in the next branch THE FIRST PUBLICLY AVAILABLE FULLY SUPPORTED "HARDWARE" MIPS-based BOARD!

> On Wed, Jun 19, 2013 at 11:11:25AM +0200, Oleksij Rempel wrote:
> > this patch set add low level initialisation for Atheros ar2313
> > and board based on this chip - Netgear wg102.
> > 
> > Antony Pavlov (2):
> >   MIPS: pbl: add mips_barebox_10h asm macro
> >   MIPS: mach-ar231x: enable DEBUG_LL
> > 
> > Oleksij Rempel (6):
> >   MIPS: pbl: add pbl_sleep macro
> >   MIPS: pbl: add pbl_probe_mem macro
> >   MIPS: mach-ar231x: add lowlevel init pbl macros
> >   MIPS: netgear-wg102: add pbl support
> >   MIPS: netgear-wg102: add debug_ll
> >   netgear-wg102: pbl, add extra check for mem config
> 
> Applied, thanks
> 
> Sascha
> 
> > 
> >  arch/mips/Kconfig                                  |   1 +
> >  .../netgear-wg102/include/board/board_pbl_start.h  |  77 +++++++++
> >  .../boards/netgear-wg102/include/board/debug_ll.h  |  33 ++++
> >  arch/mips/include/asm/pbl_macros.h                 |  38 +++++
> >  arch/mips/mach-ar231x/Kconfig                      |   2 +
> >  arch/mips/mach-ar231x/include/mach/debug_ll.h      |  27 ++++
> >  arch/mips/mach-ar231x/include/mach/pbl_macros.h    | 177 +++++++++++++++++++++
> >  7 files changed, 355 insertions(+)
> >  create mode 100644 arch/mips/boards/netgear-wg102/include/board/board_pbl_start.h
> >  create mode 100644 arch/mips/boards/netgear-wg102/include/board/debug_ll.h
> >  create mode 100644 arch/mips/mach-ar231x/include/mach/debug_ll.h
> >  create mode 100644 arch/mips/mach-ar231x/include/mach/pbl_macros.h
> > 
> > -- 
> > 1.8.1.2
> > 
> > 
> > _______________________________________________
> > barebox mailing list
> > barebox@lists.infradead.org
> > http://lists.infradead.org/mailman/listinfo/barebox
> > 
> 
> -- 
> Pengutronix e.K.                           |                             |
> Industrial Linux Solutions                 | http://www.pengutronix.de/  |
> Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
> Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |
> 
> _______________________________________________
> barebox mailing list
> barebox@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/barebox


-- 
-- 
Best regards,
  Antony Pavlov

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH 0/8] low level initialisation for ar2313
  2013-06-21 16:37   ` antonynpavlov
@ 2013-06-23 18:42     ` Sascha Hauer
  2013-06-23 19:16       ` antonynpavlov
  0 siblings, 1 reply; 18+ messages in thread
From: Sascha Hauer @ 2013-06-23 18:42 UTC (permalink / raw)
  To: antonynpavlov; +Cc: barebox

On Fri, Jun 21, 2013 at 08:37:45PM +0400, antonynpavlov@gmail.com wrote:
> On Fri, 21 Jun 2013 17:48:40 +0200
> Sascha Hauer <s.hauer@pengutronix.de> wrote:
> 
> Well done, Oleksij! Congratulations!
> 
> Thanks, Sascha!
> 
> Now we have in the next branch THE FIRST PUBLICLY AVAILABLE FULLY SUPPORTED "HARDWARE" MIPS-based BOARD!

Hurray \o/

What about the dlink 320? Does it only work 2nd stage?

Sascha

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 18+ messages in thread

* Re: [PATCH 0/8] low level initialisation for ar2313
  2013-06-23 18:42     ` Sascha Hauer
@ 2013-06-23 19:16       ` antonynpavlov
  0 siblings, 0 replies; 18+ messages in thread
From: antonynpavlov @ 2013-06-23 19:16 UTC (permalink / raw)
  To: Sascha Hauer; +Cc: barebox

On Sun, 23 Jun 2013 20:42:17 +0200
Sascha Hauer <s.hauer@pengutronix.de> wrote:

> On Fri, Jun 21, 2013 at 08:37:45PM +0400, antonynpavlov@gmail.com wrote:
> > On Fri, 21 Jun 2013 17:48:40 +0200
> > Sascha Hauer <s.hauer@pengutronix.de> wrote:
> > 
> > Well done, Oleksij! Congratulations!
> > 
> > Thanks, Sascha!
> > 
> > Now we have in the next branch THE FIRST PUBLICLY AVAILABLE FULLY SUPPORTED "HARDWARE" MIPS-based BOARD!
> 
> Hurray \o/
> 
> What about the dlink 320? Does it only work 2nd stage?

Alas it works only 2nd stage.

I have a Ingenic JZ4770-based tablet with barebox only firmware. I made the 1st stage loader as a very very dirty hack, but it works! It is time to clean it...


> Sascha
> 
> -- 
> Pengutronix e.K.                           |                             |
> Industrial Linux Solutions                 | http://www.pengutronix.de/  |
> Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
> Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |


-- 
-- 
Best regards,
  Antony Pavlov

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2013-06-23 19:17 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-06-19  9:11 [PATCH 0/8] low level initialisation for ar2313 Oleksij Rempel
2013-06-19  9:11 ` [PATCH 1/8] MIPS: pbl: add mips_barebox_10h asm macro Oleksij Rempel
2013-06-19  9:11 ` [PATCH 2/8] MIPS: pbl: add pbl_sleep macro Oleksij Rempel
2013-06-21  6:44   ` [PATCH 2/8 v2] " Oleksij Rempel
2013-06-19  9:11 ` [PATCH 3/8] MIPS: pbl: add pbl_probe_mem macro Oleksij Rempel
2013-06-19  9:11 ` [PATCH 4/8] MIPS: mach-ar231x: add lowlevel init pbl macros Oleksij Rempel
2013-06-19  9:11 ` [PATCH 5/8] MIPS: netgear-wg102: add pbl support Oleksij Rempel
2013-06-19  9:11 ` [PATCH 6/8] MIPS: netgear-wg102: add debug_ll Oleksij Rempel
2013-06-19  9:11 ` [PATCH 7/8] MIPS: mach-ar231x: enable DEBUG_LL Oleksij Rempel
2013-06-19  9:11 ` [PATCH 8/8] netgear-wg102: pbl, add extra check for mem config Oleksij Rempel
2013-06-21  5:30 ` [PATCH 0/8] low level initialisation for ar2313 Sascha Hauer
2013-06-21  6:25   ` antonynpavlov
2013-06-21  7:23     ` Sascha Hauer
2013-06-21  7:34       ` antonynpavlov
2013-06-21 15:48 ` Sascha Hauer
2013-06-21 16:37   ` antonynpavlov
2013-06-23 18:42     ` Sascha Hauer
2013-06-23 19:16       ` antonynpavlov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox