Skip to content
Commits on Source (12)
......@@ -224,7 +224,6 @@ ARM BROADCOM BCMBCA
M: Anand Gore <anand.gore@broadcom.com>
M: William Zhang <william.zhang@broadcom.com>
M: Kursad Oney <kursad.oney@broadcom.com>
M: Joel Peshkin <joel.peshkin@broadcom.com>
M: Philippe Reynes <philippe.reynes@softathome.com>
S: Maintained
F: arch/arm/mach-bcmbca/
......@@ -1568,7 +1567,7 @@ F: cmd/sqfs.c
F: test/py/tests/test_fs/test_squashfs/
STACKPROTECTOR
M: Joel Peshkin <joel.peshkin@broadcom.com>
M: William Zhang <william.zhang@broadcom.com>
S: Maintained
F: common/stackprot.c
F: cmd/stackprot_test.c
......
......@@ -27,6 +27,15 @@ int board_init(void)
return 0;
}
phys_size_t get_effective_memsize(void)
{
/* Use bank0 only */
if (gd->ram_size > DRAM_2GB_SIZE)
return DRAM_2GB_SIZE;
return gd->ram_size;
}
int dram_init(void)
{
struct npcm_gcr *gcr = (struct npcm_gcr *)NPCM_GCR_BA;
......@@ -70,21 +79,16 @@ int dram_init_banksize(void)
gd->bd->bi_dram[1].start = DRAM_4GB_SIZE;
gd->bd->bi_dram[1].size = DRAM_2GB_SIZE -
(DRAM_4GB_SIZE - DRAM_4GB_ECC_SIZE);
/* use bank0 only */
gd->ram_size = DRAM_2GB_SIZE;
break;
case DRAM_4GB_SIZE:
gd->bd->bi_dram[0].size = DRAM_2GB_SIZE;
gd->bd->bi_dram[1].start = DRAM_4GB_SIZE;
gd->bd->bi_dram[1].size = DRAM_2GB_SIZE;
/* use bank0 only */
gd->ram_size = DRAM_2GB_SIZE;
break;
default:
gd->bd->bi_dram[0].size = DRAM_1GB_SIZE;
gd->bd->bi_dram[1].start = 0;
gd->bd->bi_dram[1].size = 0;
gd->ram_size = DRAM_1GB_SIZE;
break;
}
......
......@@ -21,7 +21,6 @@ int board_init(void)
int dram_init(void)
{
char value[32];
struct npcm_gcr *gcr = (struct npcm_gcr *)NPCM_GCR_BA;
int ramsize = (readl(&gcr->intcr3) >> 8) & 0x7;
......@@ -47,17 +46,31 @@ int dram_init(void)
break;
}
if (gd->ram_size > 0) {
sprintf(value, "%ldM", (gd->ram_size / 0x100000));
env_set("mem", value);
}
return 0;
}
int last_stage_init(void)
{
board_set_console();
char value[32];
struct udevice *dev = gd->cur_serial_dev;
if (gd->ram_size > 0) {
sprintf(value, "%ldM", (gd->ram_size / 0x100000));
env_set("mem", value);
}
if (dev && (dev->seq_ >= 0)) {
void *addr;
addr = dev_read_addr_ptr(dev);
if (addr) {
sprintf(value, "uart8250,mmio32,0x%x", (u32)addr);
env_set("earlycon", value);
}
sprintf(value, "ttyS%d,115200n8", dev->seq_);
env_set("console", value);
board_set_console();
}
return 0;
}
......@@ -643,6 +643,10 @@ static int gpt_default(struct blk_desc *blk_dev_desc, const char *str_part)
free(str_disk_guid);
free(partitions);
/* initialize partition table */
if (blk_enabled())
part_init(blk_dev_desc);
return ret;
}
......
......@@ -26,6 +26,7 @@ CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
CONFIG_SPL_BSS_START_ADDR=0x43c3b000
CONFIG_SPL_BSS_MAX_SIZE=0x3000
CONFIG_SPL_STACK_R=y
CONFIG_SPL_STACK_R_MALLOC_SIMPLE_LEN=0x200000
CONFIG_SPL_SIZE_LIMIT=0x3A7F0
CONFIG_SPL_SIZE_LIMIT_PROVIDE_STACK=0x3500
CONFIG_SPL_FS_FAT=y
......
......@@ -7,6 +7,7 @@
#include <dm.h>
#include <spi.h>
#include <clk.h>
#include <reset.h>
#include <asm/gpio.h>
#include <linux/iopoll.h>
......@@ -194,6 +195,7 @@ static int npcm_pspi_probe(struct udevice *bus)
{
struct npcm_pspi_priv *priv = dev_get_priv(bus);
int node = dev_of_offset(bus);
struct reset_ctl reset;
int ret;
ret = clk_get_by_index(bus, 0, &priv->clk);
......@@ -205,6 +207,14 @@ static int npcm_pspi_probe(struct udevice *bus)
gpio_request_by_name_nodev(offset_to_ofnode(node), "cs-gpios", 0,
&priv->cs_gpio, GPIOD_IS_OUT| GPIOD_ACTIVE_LOW);
/* Reset HW */
ret = reset_get_by_index(bus, 0, &reset);
if (!ret) {
reset_assert(&reset);
udelay(5);
reset_deassert(&reset);
}
return 0;
}
......
......@@ -7,7 +7,7 @@
#define __CONFIG_ARBEL_H
#define CFG_SYS_SDRAM_BASE 0x0
#define CFG_SYS_BOOTMAPSZ (128 << 20)
#define CFG_SYS_BOOTMAPSZ (192 << 20)
#define CFG_SYS_BOOTM_LEN (20 << 20)
#define CFG_SYS_INIT_RAM_ADDR CFG_SYS_SDRAM_BASE
#define CFG_SYS_INIT_RAM_SIZE 0x8000
......
......@@ -30,9 +30,9 @@
"eth2addr=00:00:F7:A0:00:FE\0" \
"eth3addr=00:00:F7:A0:00:FF\0" \
"console=ttyS0,115200n8\0" \
"earlycon=uart8250,mmio32,0xf0000000\0" \
"earlycon=uart8250,mmio32,0xf0001000\0" \
"common_bootargs=setenv bootargs earlycon=${earlycon} root=/dev/ram " \
"console=${console} mem=${mem} ramdisk_size=48000 basemac=${ethaddr}\0" \
"console=${console} mem=${mem} ramdisk_size=48000 basemac=${ethaddr} oops=panic panic=20\0" \
"sd_prog=fatload mmc 0 10000000 image-bmc; cp.b 10000000 80000000 ${filesize}\0" \
"sd_run=fatload mmc 0 10000000 image-bmc; bootm 10200000\0" \
"\0"
......
......@@ -316,7 +316,7 @@ static inline const char *event_spy_id(struct evspy_info *spy)
__used ll_entry_declare(struct evspy_info, _type ## _3_ ## _func, \
evspy_info) = _ESPY_REC(_type, _func)
/* Simple spy with no function arguemnts */
/* Simple spy with no function arguments */
#define EVENT_SPY_SIMPLE(_type, _func) \
__used ll_entry_declare(struct evspy_info_simple, \
_type ## _3_ ## _func, \
......
......@@ -886,7 +886,7 @@ static void dhcp_process_options(uchar *popt, uchar *end)
case 40: /* NIS Domain name */
if (net_nis_domain[0] == 0) {
size = truncate_sz("NIS Domain Name",
sizeof(net_nis_domain), size);
sizeof(net_nis_domain), oplen);
memcpy(&net_nis_domain, popt + 2, size);
net_nis_domain[size] = 0;
}
......
......@@ -11,7 +11,7 @@ class Bintoolmkimage(bintool.Bintool):
"""Image generation for U-Boot
This bintool supports running `mkimage` with some basic parameters as
neeed by binman.
needed by binman.
Normally binman uses the mkimage built by U-Boot. But when run outside the
U-Boot build system, binman can use the version installed in your system.
......
......@@ -195,7 +195,7 @@ class TestBuild(unittest.TestCase):
Args:
echo_lines: True to echo lines to the terminal to aid test
development
kwdisplay_args: Dict of arguemnts to pass to
kwdisplay_args: Dict of arguments to pass to
Builder.SetDisplayOptions()
Returns:
......