Skip to contentSkip to conversation

sparc: Add support for Gaisler GR712RC-BOARD Development Kit

PATCH New Francois Retief 3 participants 6 messages Nov 5, 2014 – Aug 11, 2015

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

cover sparc: Add support for Gaisler GR712RC-BOARD Development Kit

This patch series add support for the Aeroflex Gaisler GR712RC-BOARD Development Kit. It builds on top of the previous SPARC architecture update series.

Francois Retief (3):
sparc: Make LEON serial drivers use readl/writel macros
sparc: Add MDIO support to GRETH driver
sparc: Add support for gr712rc-board

 arch/sparc/Kconfig                          |   8 +
 arch/sparc/cpu/leon2/serial.c               | 121 +++++-----
 arch/sparc/cpu/leon3/serial.c               |  93 ++++----
 arch/sparc/include/asm/io.h                 |  43 ++--
 board/gaisler/gr712rc_board/Kconfig         |   9 +
 board/gaisler/gr712rc_board/MAINTAINERS     |   6 +
 board/gaisler/gr712rc_board/Makefile        |   8 +
 board/gaisler/gr712rc_board/README          |  24 ++
 board/gaisler/gr712rc_board/gr712rc_board.c |  68 ++++++
 common/cmd_bdinfo.c                         |   4 +
 configs/gr712rc_board_defconfig             |   3 +
 drivers/net/greth.c                         |  57 +++++
 include/configs/gr712rc_board.h             | 333 ++++++++++++++++++++++++++++
 include/configs/gr_cpci_ax2000.h            |   4 -
 include/configs/gr_ep2s60.h                 |   4 -
 include/configs/gr_xc3s_1500.h              |   4 -
 include/configs/grsim.h                     |   3 -
 17 files changed, 650 insertions(+), 142 deletions(-)
 create mode 100644 board/gaisler/gr712rc_board/Kconfig
 create mode 100644 board/gaisler/gr712rc_board/MAINTAINERS
 create mode 100644 board/gaisler/gr712rc_board/Makefile
 create mode 100644 board/gaisler/gr712rc_board/README
 create mode 100644 board/gaisler/gr712rc_board/gr712rc_board.c
 create mode 100644 configs/gr712rc_board_defconfig
 create mode 100644 include/configs/gr712rc_board.h

--
1.9.3

________________________________
Disclaimer and confidentiality note ? refer to our website for further details: www.spaceteq.co.za <http://www.spaceteq.co.za/home/emaildisclaimer/>

#1 lore raw

PATCH 1/3 sparc: Make LEON serial drivers use readl/writel macros

Update the LEON2/3 serial driver to make use of the readl and writel macros as well as the WATCHDOG_RESET() macro.

Also, added readl/writel and friends to the asm/io.h file.

Lastly, removed baudrate scaler macro variables from board config. It is now calculated in the serial driver using the global data variable.

---

 arch/sparc/cpu/leon2/serial.c    | 121 ++++++++++++++++++---------------------
 arch/sparc/cpu/leon3/serial.c    |  93 ++++++++++++++++--------------
 arch/sparc/include/asm/io.h      |  43 ++++++++------
 include/configs/gr_cpci_ax2000.h |   4 --
 include/configs/gr_ep2s60.h      |   4 --
 include/configs/gr_xc3s_1500.h   |   4 --
 include/configs/grsim.h          |   3 -
 7 files changed, 130 insertions(+), 142 deletions(-)
arch/sparc/cpu/leon2/serial.c +55 -66
index 5cfbb9e..9fe4fdd 100644
@@ -7,66 +7,68 @@
  */
 
 #include <common.h>
+#include <asm/io.h>
 #include <asm/processor.h>
-#include <asm/leon.h>
 #include <serial.h>
-#include <linux/compiler.h>
+#include <watchdog.h>
 
 DECLARE_GLOBAL_DATA_PTR;
 
-static int leon2_serial_init(void)
+static inline LEON2_Uart_regs *leon2_get_uart_regs(void)
 {
        LEON2_regs *leon2 = (LEON2_regs *) LEON2_PREGS;
-       LEON2_Uart_regs *regs;
-       unsigned int tmp;
 
-       /* Init LEON2 UART
-        *
-        * Set scaler / baud rate
-        *
-        * Receiver & transmitter enable
-        */
 #if LEON2_CONSOLE_SELECT == LEON_CONSOLE_UART1
-       regs = (LEON2_Uart_regs *) & leon2->UART_Channel_1;
+       return (LEON2_Uart_regs *)&leon2->UART_Channel_1;
 #else
-       regs = (LEON2_Uart_regs *) & leon2->UART_Channel_2;
+       return (LEON2_Uart_regs *)&leon2->UART_Channel_2;
 #endif
+}
 
-       regs->UART_Scaler = CONFIG_SYS_LEON2_UART1_SCALER;
+static int leon2_serial_init(void)
+{
+       LEON2_Uart_regs *uart = leon2_get_uart_regs();
+       unsigned int tmp;
 
-       /* Let bit 11 be unchanged (debug bit for GRMON) */
-       tmp = READ_WORD(regs->UART_Control);
+       /* Init LEON2 UART */
+       if (!uart)
+               return -1;
 
-       regs->UART_Control = ((tmp & LEON2_UART_CTRL_DBG) |
-                             (LEON2_UART1_LOOPBACK_ENABLE << 7) |
-                             (LEON2_UART1_FLOWCTRL_ENABLE << 6) |
-                             (LEON2_UART1_PARITY_ENABLE << 5) |
-                             (LEON2_UART1_ODDPAR_ENABLE << 4) |
-                             LEON2_UART_CTRL_RE | LEON2_UART_CTRL_TE);
+       /* Set scaler / baud rate */
+       tmp = (((CONFIG_SYS_CLK_FREQ * 10)/(CONFIG_BAUDRATE * 8)) - 5) / 10;
+       writel(tmp, &uart->UART_Scaler);
+
+       /* Let bit 11 be unchanged (debug bit for GRMON) */
+       tmp = readl(&uart->UART_Control) & LEON2_UART_CTRL_DBG;
+       tmp |= (LEON2_UART1_LOOPBACK_ENABLE << 7);
+       tmp |= (LEON2_UART1_FLOWCTRL_ENABLE << 6);
+       tmp |= (LEON2_UART1_PARITY_ENABLE << 5);
+       tmp |= (LEON2_UART1_ODDPAR_ENABLE << 4);
+       /* Receiver & transmitter enable */
+       tmp |= (LEON2_UART_CTRL_RE | LEON2_UART_CTRL_TE);
+       writel(tmp, &uart->UART_Control);
 
        return 0;
 }
 
 static void leon2_serial_putc_raw(const char c)
 {
-       LEON2_regs *leon2 = (LEON2_regs *) LEON2_PREGS;
-       LEON2_Uart_regs *regs;
+       LEON2_Uart_regs *uart = leon2_get_uart_regs();
 
-#if LEON2_CONSOLE_SELECT == LEON_CONSOLE_UART1
-       regs = (LEON2_Uart_regs *) & leon2->UART_Channel_1;
-#else
-       regs = (LEON2_Uart_regs *) & leon2->UART_Channel_2;
-#endif
+       if (!uart)
+               return;
 
        /* Wait for last character to go. */
-       while (!(READ_WORD(regs->UART_Status) & LEON2_UART_STAT_THE)) ;
+       while (!(readl(&uart->UART_Status) & LEON2_UART_STAT_THE))
+               WATCHDOG_RESET();
 
        /* Send data */
-       regs->UART_Channel = c;
+       writel(c, &uart->UART_Channel);
 
 #ifdef LEON_DEBUG
        /* Wait for data to be sent */
-       while (!(READ_WORD(regs->UART_Status) & LEON2_UART_STAT_TSE)) ;
+       while (!(readl(&uart->UART_Status) & LEON2_UART_STAT_TSE))
+               WATCHDOG_RESET();
 #endif
 }
 
@@ -80,56 +82,43 @@ static void leon2_serial_putc(const char c)
 
 static int leon2_serial_getc(void)
 {
-       LEON2_regs *leon2 = (LEON2_regs *) LEON2_PREGS;
-       LEON2_Uart_regs *regs;
+       LEON2_Uart_regs *uart = leon2_get_uart_regs();
 
-#if LEON2_CONSOLE_SELECT == LEON_CONSOLE_UART1
-       regs = (LEON2_Uart_regs *) & leon2->UART_Channel_1;
-#else
-       regs = (LEON2_Uart_regs *) & leon2->UART_Channel_2;
-#endif
+       if (!uart)
+               return 0;
 
-       /* Wait for a character to arrive. */
-       while (!(READ_WORD(regs->UART_Status) & LEON2_UART_STAT_DR)) ;
+       /* Wait for a character to arrive */
+       while (!(readl(&uart->UART_Status) & LEON2_UART_STAT_DR))
+               WATCHDOG_RESET();
 
-       /* read data */
-       return READ_WORD(regs->UART_Channel);
+       /* Read character data */
+       return readl(&uart->UART_Channel);
 }
 
 static int leon2_serial_tstc(void)
 {
-       LEON2_regs *leon2 = (LEON2_regs *) LEON2_PREGS;
-       LEON2_Uart_regs *regs;
+       LEON2_Uart_regs *uart = leon2_get_uart_regs();
 
-#if LEON2_CONSOLE_SELECT == LEON_CONSOLE_UART1
-       regs = (LEON2_Uart_regs *) & leon2->UART_Channel_1;
-#else
-       regs = (LEON2_Uart_regs *) & leon2->UART_Channel_2;
-#endif
+       if (!uart)
+               return 0;
 
-       return (READ_WORD(regs->UART_Status) & LEON2_UART_STAT_DR);
+       return readl(&uart->UART_Status) & LEON2_UART_STAT_DR;
 }
 
-/* set baud rate for uart */
 static void leon2_serial_setbrg(void)
 {
-       /* update baud rate settings, read it from gd->baudrate */
+       LEON2_Uart_regs *uart = leon2_get_uart_regs();
        unsigned int scaler;
-       LEON2_regs *leon2 = (LEON2_regs *) LEON2_PREGS;
-       LEON2_Uart_regs *regs;
 
-#if LEON2_CONSOLE_SELECT == LEON_CONSOLE_UART1
-       regs = (LEON2_Uart_regs *) & leon2->UART_Channel_1;
-#else
-       regs = (LEON2_Uart_regs *) & leon2->UART_Channel_2;
-#endif
+       if (!uart)
+               return;
+
+       if (!gd->baudrate)
+               gd->baudrate = CONFIG_BAUDRATE;
+
+       scaler = (((CONFIG_SYS_CLK_FREQ * 10)/(gd->baudrate * 8)) - 5) / 10;
 
-       if (gd->baudrate > 0) {
-               scaler =
-                   (((CONFIG_SYS_CLK_FREQ * 10) / (gd->baudrate * 8)) -
-                    5) / 10;
-               regs->UART_Scaler = scaler;
-       }
+       writel(scaler, &uart->UART_Scaler);
 }
 
 static struct serial_device leon2_serial_drv = {
arch/sparc/cpu/leon3/serial.c +50 -43

145 lines not on this page · raw message

arch/sparc/include/asm/io.h +25 -18

62 lines not on this page · raw message

include/configs/gr_cpci_ax2000.h +0 -4
index 3029f42..344aea1 100644
@@ -343,10 +343,6 @@
 #define CONFIG_SYS_GRLIB_DDR2_CFG1 0x00000000
 #define CONFIG_SYS_GRLIB_DDR2_CFG3 0x00000000
 
-/* Calculate scaler register value from default baudrate */
-#define CONFIG_SYS_GRLIB_APBUART_SCALER \
- ((((CONFIG_SYS_CLK_FREQ*10)/(CONFIG_BAUDRATE*8))-5)/10)
-
 /* Identification string */
 #define CONFIG_IDENT_STRING " Gaisler LEON3 GR-CPCI-AX2000"
 
include/configs/gr_ep2s60.h +0 -4
index 32ee7c9..4460dde 100644
@@ -318,10 +318,6 @@
 #define CONFIG_SYS_GRLIB_DDR2_CFG1 0x00000000
 #define CONFIG_SYS_GRLIB_DDR2_CFG3 0x00000000
 
-/* Calculate scaler register value from default baudrate */
-#define CONFIG_SYS_GRLIB_APBUART_SCALER \
- ((((CONFIG_SYS_CLK_FREQ*10)/(CONFIG_BAUDRATE*8))-5)/10)
-
 /* Identification string */
 #define CONFIG_IDENT_STRING " Gaisler LEON3 EP2S60"
 
include/configs/gr_xc3s_1500.h +0 -4
index 565310e..e546ed6 100644
@@ -283,10 +283,6 @@
 #define CONFIG_SYS_GRLIB_DDR2_CFG1 0x00000000
 #define CONFIG_SYS_GRLIB_DDR2_CFG3 0x00000000
 
-/* Calculate scaler register value from default baudrate */
-#define CONFIG_SYS_GRLIB_APBUART_SCALER \
- ((((CONFIG_SYS_CLK_FREQ*10)/(CONFIG_BAUDRATE*8))-5)/10)
-
 /* Identification string */
 #define CONFIG_IDENT_STRING " Gaisler LEON3 GR-XC3S-1500"
 
include/configs/grsim.h +0 -3
index 3b70983..a7b9dae 100644
@@ -310,9 +310,6 @@
 #define CONFIG_SYS_GRLIB_DDR2_CFG1 0x00000000
 #define CONFIG_SYS_GRLIB_DDR2_CFG3 0x00000000
 
-#define CONFIG_SYS_GRLIB_APBUART_SCALER \
- ((((CONFIG_SYS_CLK_FREQ*10)/(CONFIG_BAUDRATE*8))-5)/10)
-
 /* default kernel command line */
 #define CONFIG_DEFAULT_KERNEL_COMMAND_LINE "console=ttyS0,38400\0\0"
 

--
1.9.3

________________________________
Disclaimer and confidentiality note ? refer to our website for further details: www.spaceteq.co.za <http://www.spaceteq.co.za/home/emaildisclaimer/>

#2 lore raw

PATCH 2/3 sparc: Add MDIO support to GRETH driver

In reply to Francois Retief

Added MDIO support to the Aeroflex Gaisler GRETH driver. The result is that we can now use the CONFIG_CMD_MII commands to access the PHY chip.

---

 drivers/net/greth.c | 57 +++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 57 insertions(+)
drivers/net/greth.c +57 -0
index 7784684..5f5abd6 100644
@@ -18,6 +18,8 @@
 #include <asm/processor.h>
 #include <ambapp.h>
 #include <asm/leon.h>
+#include <miiphy.h>
+#include <errno.h>
 
 #include "greth.h"
 
@@ -52,6 +54,7 @@ typedef struct {
        greth_regs *regs;
        int irq;
        struct eth_device *dev;
+       struct mii_dev *bus;
 
        /* Hardware info */
        unsigned char phyaddr;
@@ -124,6 +127,57 @@ static void write_mii(int phyaddr, int regaddr, int data, volatile greth_regs *
 
 }
 
+#ifdef CONFIG_MII
+
+static int greth_mdio_read(struct mii_dev *bus, int port_addr, int dev_addr, int regnum)
+{
+       greth_regs *regs = (greth_regs *)bus->priv;
+
+       debug("GRETH: mdio_read (port_addr=%d, dev_addr=%d, reg=%d)\n", port_addr, dev_addr, regnum);
+
+       return read_mii(port_addr, regnum, regs);
+}
+
+static int greth_mdio_write(struct mii_dev *bus, int port_addr, int dev_addr, int regnum, u16 value)
+{
+       greth_regs *regs = (greth_regs *)bus->priv;
+
+       debug("GRETH: mdio_write (port_addr=%d, dev_addr=%d, reg=%d, value=%d)\n", port_addr, dev_addr, regnum, value);
+
+       write_mii(port_addr, regnum, value, regs);
+       return 0;
+}
+
+static int greth_mdio_reset(struct mii_dev *bus)
+{
+       puts("GRETH: Reset PHY via MDIO reset\n");
+       return 0;
+}
+
+int greth_mdio_register(greth_priv *greth, bd_t *bis)
+{
+       struct mii_dev *bus = mdio_alloc();
+
+       if (!bus) {
+               printf("GRETH: Failed to allocate MDIO bus\n");
+               return -ENOMEM;
+       }
+
+       bus->read = greth_mdio_read;
+       bus->write = greth_mdio_write;
+       bus->reset = greth_mdio_reset;
+       sprintf(bus->name, "GRETH%d", 0);
+
+       bus->priv = (void *)greth->regs;
+       greth->bus = bus;
+
+       return mdio_register(bus);
+}
+
+#else
+static inline int greth_mdio_register(greth_priv *greth, bd_t *bis) { return 0; }
+#endif /* CONFIG_CMD_MII */
+
 /* init/start hardware and allocate descriptor buffers for rx side
  *
  */
@@ -633,6 +687,9 @@ int greth_initialize(bd_t * bis)
                sprintf(dev->name, "GRETH_10/100");
        }
 
+       /* Register our device with the MDIO subsystem */
+       greth_mdio_register(greth, bis);
+
        /* initiate PHY, select speed/duplex depending on connected PHY */
        if (greth_init_phy(greth, bis)) {
                /* Failed to init PHY (timedout) */

--
1.9.3

________________________________
Disclaimer and confidentiality note ? refer to our website for further details: www.spaceteq.co.za <http://www.spaceteq.co.za/home/emaildisclaimer/>

#3 lore raw

PATCH 2/3 sparc: Add MDIO support to GRETH driver

Hi Francios,

Quoted 5 lines · Francois Retief

Added MDIO support to the Aeroflex Gaisler GRETH driver. The result is that we can now use the CONFIG_CMD_MII commands to access the PHY chip.

---

I noticed this still sitting in patchwork. I attempted to apply it, but it fails checkpatch.pl.

WARNING: please, no spaces at the start of a line
#41: FILE: drivers/net/greth.c:57:
+ struct mii_dev *bus;$

WARNING: line over 80 characters
#51: FILE: drivers/net/greth.c:132:
+static int greth_mdio_read(struct mii_dev *bus, int port_addr, int dev_addr, int regnum)

WARNING: please, no spaces at the start of a line
#53: FILE: drivers/net/greth.c:134:
+ greth_regs *regs = (greth_regs *)bus->priv;$

WARNING: line over 80 characters
#55: FILE: drivers/net/greth.c:136:
+ debug("GRETH: mdio_read (port_addr=%d, dev_addr=%d,
reg=%d)\n", port_addr, dev_addr, regnum);

WARNING: please, no spaces at the start of a line
#55: FILE: drivers/net/greth.c:136:
+ debug("GRETH: mdio_read (port_addr=%d, dev_addr=%d,
reg=%d)\n", port_addr, dev_addr, regnum);$

WARNING: please, no spaces at the start of a line
#57: FILE: drivers/net/greth.c:138:
+ return read_mii(port_addr, regnum, regs);$

WARNING: line over 80 characters
#60: FILE: drivers/net/greth.c:141:
+static int greth_mdio_write(struct mii_dev *bus, int port_addr, int dev_addr, int regnum, u16 value)

WARNING: please, no spaces at the start of a line
#62: FILE: drivers/net/greth.c:143:
+ greth_regs *regs = (greth_regs *)bus->priv;$

WARNING: line over 80 characters
#64: FILE: drivers/net/greth.c:145:
+ debug("GRETH: mdio_write (port_addr=%d, dev_addr=%d, reg=%d,
value=%d)\n", port_addr, dev_addr, regnum, value);

WARNING: please, no spaces at the start of a line #64: FILE: drivers/net/greth.c:145:
+ debug("GRETH: mdio_write (port_addr=%d, dev_addr=%d, reg=%d,
value=%d)\n", port_addr, dev_addr, regnum, value);$

WARNING: please, no spaces at the start of a line
#66: FILE: drivers/net/greth.c:147:
+ write_mii(port_addr, regnum, value, regs);$

WARNING: please, no spaces at the start of a line
#67: FILE: drivers/net/greth.c:148:
+ return 0;$

WARNING: please, no spaces at the start of a line
#72: FILE: drivers/net/greth.c:153:
+ puts("GRETH: Reset PHY via MDIO reset\n");$

WARNING: please, no spaces at the start of a line
#73: FILE: drivers/net/greth.c:154:
+ return 0;$

WARNING: please, no spaces at the start of a line
#78: FILE: drivers/net/greth.c:159:
+ struct mii_dev *bus = mdio_alloc();$

WARNING: please, no spaces at the start of a line
#80: FILE: drivers/net/greth.c:161:
+ if (!bus) {$

WARNING: suspect code indent for conditional statements (7, 15) #80: FILE: drivers/net/greth.c:161:
+ if (!bus) {
+ printf("GRETH: Failed to allocate MDIO bus\n");

ERROR: code indent should use tabs where possible
#81: FILE: drivers/net/greth.c:162:
+ printf("GRETH: Failed to allocate MDIO bus\n");$

WARNING: please, no spaces at the start of a line
#81: FILE: drivers/net/greth.c:162:
+ printf("GRETH: Failed to allocate MDIO bus\n");$

ERROR: code indent should use tabs where possible
#82: FILE: drivers/net/greth.c:163:
+ return -ENOMEM;$

WARNING: please, no spaces at the start of a line
#82: FILE: drivers/net/greth.c:163:
+ return -ENOMEM;$

WARNING: please, no spaces at the start of a line
#83: FILE: drivers/net/greth.c:164:
+ }$

WARNING: please, no spaces at the start of a line
#85: FILE: drivers/net/greth.c:166:
+ bus->read = greth_mdio_read;$

WARNING: please, no spaces at the start of a line
#86: FILE: drivers/net/greth.c:167:
+ bus->write = greth_mdio_write;$

WARNING: please, no spaces at the start of a line
#87: FILE: drivers/net/greth.c:168:
+ bus->reset = greth_mdio_reset;$

WARNING: please, no spaces at the start of a line
#88: FILE: drivers/net/greth.c:169:
+ sprintf(bus->name, "GRETH%d", 0);$

WARNING: please, no spaces at the start of a line
#90: FILE: drivers/net/greth.c:171:
+ bus->priv = (void *)greth->regs;$

WARNING: please, no spaces at the start of a line
#91: FILE: drivers/net/greth.c:172:
+ greth->bus = bus;$

WARNING: please, no spaces at the start of a line
#93: FILE: drivers/net/greth.c:174:
+ return mdio_register(bus);$

WARNING: line over 80 characters
#97: FILE: drivers/net/greth.c:178:
+static inline int greth_mdio_register(greth_priv *greth, bd_t *bis) { return 0; }

WARNING: please, no spaces at the start of a line
#108: FILE: drivers/net/greth.c:691:
+ greth_mdio_register(greth, bis);$

total: 2 errors, 29 warnings, 0 checks, 81 lines checked

NOTE: whitespace errors detected, you may wish to use scripts/cleanpatch or
scripts/cleanfile

Please clean up and repost.

Thanks,
-Joe

#4 lore raw

PATCH 3/3 sparc: Add support for gr712rc-board

In reply to Francois Retief

Add support of the Aeroflex Gaisler GR712RC-BOARD Development Kit.

---

 arch/sparc/Kconfig                          |   8 +
 board/gaisler/gr712rc_board/Kconfig         |   9 +
 board/gaisler/gr712rc_board/MAINTAINERS     |   6 +
 board/gaisler/gr712rc_board/Makefile        |   8 +
 board/gaisler/gr712rc_board/README          |  24 ++
 board/gaisler/gr712rc_board/gr712rc_board.c |  68 ++++++
 common/cmd_bdinfo.c                         |   4 +
 configs/gr712rc_board_defconfig             |   3 +
 include/configs/gr712rc_board.h             | 333 ++++++++++++++++++++++++++++
 9 files changed, 463 insertions(+)
 create mode 100644 board/gaisler/gr712rc_board/Kconfig
 create mode 100644 board/gaisler/gr712rc_board/MAINTAINERS
 create mode 100644 board/gaisler/gr712rc_board/Makefile
 create mode 100644 board/gaisler/gr712rc_board/README
 create mode 100644 board/gaisler/gr712rc_board/gr712rc_board.c
 create mode 100644 configs/gr712rc_board_defconfig
 create mode 100644 include/configs/gr712rc_board.h
arch/sparc/Kconfig +8 -0
index 2df09b2..fa0e5bf 100644
@@ -35,6 +35,13 @@ config TARGET_GR_XC3S_1500
        bool "Gaisler GR-XC3S-1500 spartan board"
        select LEON3
 
+config TARGET_GR712RC_BOARD
+       bool "Gaisler GR712RC-BOARD Development Kit"
+       select LEON3
+       help
+         Aeroflex Gaisler's GR712RC development board, based on the Gaisler
+         GR712RC dual-core 32-bit fault tolerant LEON3FT SPARC v8 processor.
+
 config TARGET_GRSIM
        bool "GRSIM simulating a LEON3 GR-XC3S-1500 board"
        select LEON3
@@ -54,6 +61,7 @@ config SYS_VENDOR
 source "board/gaisler/gr_cpci_ax2000/Kconfig"
 source "board/gaisler/gr_ep2s60/Kconfig"
 source "board/gaisler/gr_xc3s_1500/Kconfig"
+source "board/gaisler/gr712rc_board/Kconfig"
 source "board/gaisler/grsim/Kconfig"
 source "board/gaisler/grsim_leon2/Kconfig"
 
board/gaisler/gr712rc_board/Kconfig new file +9 -0
new file mode 100644
index 0000000..4ef60e2
@@ -0,0 +1,9 @@
+if TARGET_GR712RC_BOARD
+
+config SYS_BOARD
+       default "gr712rc_board"
+
+config SYS_CONFIG_NAME
+       default "gr712rc_board"
+
+endif
board/gaisler/gr712rc_board/MAINTAINERS new file +6 -0
new file mode 100644
index 0000000..1a77f89
@@ -0,0 +1,6 @@
+GR712RC BOARD
+#M:    -
+S:     Maintained
+F:     board/gaisler/gr712rc_board/
+F:     include/configs/gr712rc_board.h
+F:     configs/gr712rc_board_defconfig
board/gaisler/gr712rc_board/Makefile new file +8 -0
new file mode 100644
index 0000000..11861ef
@@ -0,0 +1,8 @@
+#
+# (C) Copyright 2014, Denel Spaceteq
+# Francois Retief <[email protected]>
+#
+# SPDX-License-Identifier:     GPL-2.0+
+#
+
+obj-y  := gr712rc_board.o
board/gaisler/gr712rc_board/README new file +24 -0
new file mode 100644
index 0000000..1f2efab
@@ -0,0 +1,24 @@
+These jumpers need to be correctly set for U-Boot to operate.
+
+Jumpers for SDRAM:
+  JP12 = C     SDCSN0
+  JP13 = C     SDCSN1
+  JP24 = C     SDDQM0
+  JP25 = C     SDDQM1
+  JP48 = C     SDCASN
+  JP49 = C     SDRASN
+  JP52 = C     SDWEN
+  JP53 = C     SDDQM2
+  JP54 = C     SDDQM3
+
+Jumpers for Ethernet (RMII):
+  JP28 = F     RMTXD0
+  JP29 = F     RMTXD1
+  JP30 = F     RMRXD0
+  JP31 = F     RMRXD1
+  JP32 = F     RMTXEN
+  JP34 = F     RMCRSDV
+  JP35 = F     RMMDINT
+  JP36 = F     RMMDIO
+  JP37 = F     RMMDC
+  JP38 = F     RMRFCLK
board/gaisler/gr712rc_board/gr712rc_board.c new file +68 -0

68 lines not on this page · raw message

common/cmd_bdinfo.c +4 -0
index 3d37a86..6af5afe 100644
@@ -216,10 +216,14 @@ int do_bdinfo(cmd_tbl_t * cmdtp, int flag, int argc, char * const argv[])
        print_num("flashstart             ", bd->bi_flashstart);
        print_num("CONFIG_SYS_MONITOR_BASE       ", CONFIG_SYS_MONITOR_BASE);
        print_num("CONFIG_ENV_ADDR           ", CONFIG_ENV_ADDR);
+#ifdef CONFIG_SYS_RELOC_MONITOR_BASE
        printf("CONFIG_SYS_RELOC_MONITOR_BASE = 0x%x (%d)\n", CONFIG_SYS_RELOC_MONITOR_BASE,
               CONFIG_SYS_MONITOR_LEN);
+#endif
+#ifdef CONFIG_SYS_MALLOC_BASE
        printf("CONFIG_SYS_MALLOC_BASE        = 0x%x (%d)\n", CONFIG_SYS_MALLOC_BASE,
               CONFIG_SYS_MALLOC_LEN);
+#endif
        printf("CONFIG_SYS_INIT_SP_OFFSET     = 0x%x (%d)\n", CONFIG_SYS_INIT_SP_OFFSET,
               CONFIG_SYS_STACK_SIZE);
        printf("CONFIG_SYS_PROM_OFFSET        = 0x%x (%d)\n", CONFIG_SYS_PROM_OFFSET,
configs/gr712rc_board_defconfig new file +3 -0
new file mode 100644
index 0000000..c3c0a93
@@ -0,0 +1,3 @@
+CONFIG_SYS_TEXT_BASE=0x60000000
+CONFIG_SPARC=y
+CONFIG_TARGET_GR712RC_BOARD=y
include/configs/gr712rc_board.h new file +333 -0

333 lines not on this page · raw message

--
1.9.3

________________________________
Disclaimer and confidentiality note ? refer to our website for further details: www.spaceteq.co.za <http://www.spaceteq.co.za/home/emaildisclaimer/>

#5 lore raw

PATCH 3/3 sparc: Add support for gr712rc-board

Hi Francois,

board/gaisler/gr712rc_board/MAINTAINERS line 6

Quoted 12 lines · On Wed, 5 Nov 2014 14:30:53 +0200 Francois Retief <[email protected]>…
board/gaisler/gr712rc_board/MAINTAINERS new file +6 -0
new file mode 100644
index 0000000..1a77f89
@@ -0,0 +1,6 @@
+GR712RC BOARD
+#M:    -
+S:     Maintained
+F:     board/gaisler/gr712rc_board/
+F:     include/configs/gr712rc_board.h
+F:     configs/gr712rc_board_defconfig

Please fill the M: field with your name and email address. You are the maintainer of this board.

Best Regards
Masahiro Yamada