summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Makefile2
-rw-r--r--arch/arm/boards/at91rm9200ek/init.c3
-rw-r--r--arch/arm/boards/mini2440/Kconfig2
-rw-r--r--arch/arm/boards/pcm038/env/config5
-rw-r--r--arch/arm/boards/pcm038/pcm038.c14
-rw-r--r--arch/arm/boards/pm9261/init.c2
-rw-r--r--arch/arm/mach-at91/at91sam9g45_devices.c4
-rw-r--r--arch/arm/mach-imx/boot.c4
-rw-r--r--arch/arm/mach-imx/include/mach/imx27-regs.h2
-rw-r--r--arch/arm/mach-mxs/include/mach/iomux-imx23.h4
-rw-r--r--arch/mips/lib/libgcc.h4
-rw-r--r--arch/x86/lib/barebox.lds.S1
-rw-r--r--defaultenv/bin/_update2
-rw-r--r--drivers/mtd/core.c2
-rw-r--r--drivers/nor/cfi_flash_intel.c20
-rw-r--r--drivers/serial/serial_s3c.c2
-rw-r--r--drivers/usb/gadget/pxa27x_udc.c6
-rw-r--r--drivers/video/Kconfig2
-rw-r--r--lib/string.c24
19 files changed, 53 insertions, 52 deletions
diff --git a/Makefile b/Makefile
index eef76c515b..c19154067b 100644
--- a/Makefile
+++ b/Makefile
@@ -1,5 +1,5 @@
VERSION = 2012
-PATCHLEVEL = 02
+PATCHLEVEL = 04
SUBLEVEL = 0
EXTRAVERSION =
NAME = Amissive Actinocutious Kiwi
diff --git a/arch/arm/boards/at91rm9200ek/init.c b/arch/arm/boards/at91rm9200ek/init.c
index 6911447aaf..3875f4ab4d 100644
--- a/arch/arm/boards/at91rm9200ek/init.c
+++ b/arch/arm/boards/at91rm9200ek/init.c
@@ -28,6 +28,7 @@
#include <fs.h>
#include <fcntl.h>
#include <io.h>
+#include <sizes.h>
#include <asm/hardware.h>
#include <mach/at91_pmc.h>
#include <mach/board.h>
@@ -116,7 +117,7 @@ static int at91rm9200ek_devices_init(void)
at91_add_device_eth(0, &ether_pdata);
- add_cfi_flash_device(0, AT91_CHIPSELECT_0, 0, 0);
+ add_cfi_flash_device(0, AT91_CHIPSELECT_0, SZ_8M, 0);
/* USB Host */
at91_add_device_usbh_ohci(&ek_usbh_data);
ek_device_add_leds();
diff --git a/arch/arm/boards/mini2440/Kconfig b/arch/arm/boards/mini2440/Kconfig
index 929df6039e..a8e79b3b07 100644
--- a/arch/arm/boards/mini2440/Kconfig
+++ b/arch/arm/boards/mini2440/Kconfig
@@ -4,7 +4,7 @@ if MACH_MINI2440
config MINI2440_VIDEO
bool
select VIDEO
- select DRIVER_VIDEO_S3C
+ select DRIVER_VIDEO_S3C24XX
config MINI2440_VIDEO_N35
bool "Support N35 display (240x320)"
diff --git a/arch/arm/boards/pcm038/env/config b/arch/arm/boards/pcm038/env/config
index eb0f9c1a79..b1a5f42eff 100644
--- a/arch/arm/boards/pcm038/env/config
+++ b/arch/arm/boards/pcm038/env/config
@@ -40,11 +40,12 @@ autoboot_timeout=3
bootargs="console=ttymxc0,115200"
-nor_parts="256k(barebox)ro,128k(bareboxenv),2M(kernel),-(root)"
+nor_parts="512k(barebox)ro,128k(bareboxenv),2M(kernel),-(root)"
rootfs_mtdblock_nor=3
-nand_parts="256k(barebox)ro,128k(bareboxenv),2M(kernel),-(root)"
+nand_parts="512k(barebox)ro,128k(bareboxenv),2M(kernel),-(root)"
rootfs_mtdblock_nand=7
+nand_device="mxc_nand"
# set a fancy prompt (if support is compiled in)
PS1="\e[1;32mbarebox@\e[1;31m\h:\w\e[0m "
diff --git a/arch/arm/boards/pcm038/pcm038.c b/arch/arm/boards/pcm038/pcm038.c
index 86bc7211e5..01129bb291 100644
--- a/arch/arm/boards/pcm038/pcm038.c
+++ b/arch/arm/boards/pcm038/pcm038.c
@@ -135,7 +135,7 @@ static int pcm038_mem_init(void)
{
arm_add_mem_device("ram0", 0xa0000000, 128 * 1024 * 1024);
- add_mem_device("ram0", 0xc8000000, 512 * 1024, /* Can be up to 2MiB */
+ add_mem_device("ram1", 0xc8000000, 512 * 1024, /* Can be up to 2MiB */
IORESOURCE_MEM_WRITEABLE);
return 0;
}
@@ -268,16 +268,20 @@ static int pcm038_devices_init(void)
case GPCR_BOOT_16BIT_NAND_2k:
case GPCR_BOOT_16BIT_NAND_512:
case GPCR_BOOT_8BIT_NAND_512:
- devfs_add_partition("nand0", 0x00000, 0x40000, PARTITION_FIXED, "self_raw");
+ devfs_add_partition("nand0", 0x00000, 0x80000,
+ PARTITION_FIXED, "self_raw");
dev_add_bb_dev("self_raw", "self0");
- devfs_add_partition("nand0", 0x40000, 0x20000, PARTITION_FIXED, "env_raw");
+ devfs_add_partition("nand0", 0x80000, 0x100000,
+ PARTITION_FIXED, "env_raw");
dev_add_bb_dev("env_raw", "env0");
envdev = "NAND";
break;
default:
- devfs_add_partition("nor0", 0x00000, 0x40000, PARTITION_FIXED, "self0");
- devfs_add_partition("nor0", 0x40000, 0x20000, PARTITION_FIXED, "env0");
+ devfs_add_partition("nor0", 0x00000, 0x80000,
+ PARTITION_FIXED, "self0");
+ devfs_add_partition("nor0", 0x80000, 0x100000,
+ PARTITION_FIXED, "env0");
protect_file("/dev/env0", 1);
envdev = "NOR";
diff --git a/arch/arm/boards/pm9261/init.c b/arch/arm/boards/pm9261/init.c
index 23ed44ec60..f7f2928c44 100644
--- a/arch/arm/boards/pm9261/init.c
+++ b/arch/arm/boards/pm9261/init.c
@@ -123,7 +123,7 @@ static void __init pm_add_device_dm9000(void)
IORESOURCE_MEM_16BIT, &dm9000_data);
}
#else
-static void __init ek_add_device_dm9000(void) {}
+static void __init pm_add_device_dm9000(void) {}
#endif /* CONFIG_DRIVER_NET_DM9K */
static int pm9261_mem_init(void)
diff --git a/arch/arm/mach-at91/at91sam9g45_devices.c b/arch/arm/mach-at91/at91sam9g45_devices.c
index 05b197c2c2..25a8d80c24 100644
--- a/arch/arm/mach-at91/at91sam9g45_devices.c
+++ b/arch/arm/mach-at91/at91sam9g45_devices.c
@@ -296,9 +296,9 @@ void at91_add_device_mci(short mmc_id, struct atmel_mci_platform_data *data) {}
#if defined(CONFIG_DRIVER_SPI_ATMEL)
/* SPI */
-static const unsigned spi0_standard_cs[4] = { AT91_PIN_PB3, AT91_PIN_PB18, AT91_PIN_PB19, AT91_PIN_PD27 };
+static unsigned spi0_standard_cs[4] = { AT91_PIN_PB3, AT91_PIN_PB18, AT91_PIN_PB19, AT91_PIN_PD27 };
-static const unsigned spi1_standard_cs[4] = { AT91_PIN_PB17, AT91_PIN_PD28, AT91_PIN_PD18, AT91_PIN_PD19 };
+static unsigned spi1_standard_cs[4] = { AT91_PIN_PB17, AT91_PIN_PD28, AT91_PIN_PD18, AT91_PIN_PD19 };
static struct at91_spi_platform_data spi_pdata[] = {
[0] = {
diff --git a/arch/arm/mach-imx/boot.c b/arch/arm/mach-imx/boot.c
index 9f2def6b2b..b79ebc7406 100644
--- a/arch/arm/mach-imx/boot.c
+++ b/arch/arm/mach-imx/boot.c
@@ -87,8 +87,6 @@ static int imx_25_35_boot_save_loc(void)
return 0;
}
coredevice_initcall(imx_25_35_boot_save_loc);
-
-BAREBOX_MAGICVAR(barebox_loc, "The source barebox has been booted from");
#endif
#if defined(CONFIG_ARCH_IMX27)
@@ -114,6 +112,6 @@ static int imx_27_boot_save_loc(void)
return 0;
}
coredevice_initcall(imx_27_boot_save_loc);
+#endif
BAREBOX_MAGICVAR(barebox_loc, "The source barebox has been booted from");
-#endif
diff --git a/arch/arm/mach-imx/include/mach/imx27-regs.h b/arch/arm/mach-imx/include/mach/imx27-regs.h
index 25ea04a556..437cc7d302 100644
--- a/arch/arm/mach-imx/include/mach/imx27-regs.h
+++ b/arch/arm/mach-imx/include/mach/imx27-regs.h
@@ -240,11 +240,13 @@
#define IMX_CS4_BASE 0xD4000000
#define IMX_CS5_BASE 0xD6000000
+#ifndef __ASSEMBLY__
static inline void imx27_setup_weimcs(size_t cs, unsigned upper, unsigned lower, unsigned addional)
{
CSxU(cs) = upper;
CSxL(cs) = lower;
CSxA(cs) = addional;
}
+#endif /* __ASSEMBLY__ */
#endif /* _IMX27_REGS_H */
diff --git a/arch/arm/mach-mxs/include/mach/iomux-imx23.h b/arch/arm/mach-mxs/include/mach/iomux-imx23.h
index bebaf56571..7b2883c7ba 100644
--- a/arch/arm/mach-mxs/include/mach/iomux-imx23.h
+++ b/arch/arm/mach-mxs/include/mach/iomux-imx23.h
@@ -63,9 +63,13 @@
/* control pad's pull up / bit keeper feature */
#define PE (1 << 10)
+#define BK (1 << 11) /* FIXME useful to distinguish? */
#define PE_PRESENT(x) (!!((x) & PE))
+#define BK_PRESENT(x) (!!((x) & BK))
#define PULLUP(x) ((x) << 13)
+#define BITKEEPER(x) ((x) << 14)
#define GET_PULLUP(x) (!!((x) & (1 << 13)))
+#define GET_BITKEEPER(x) (!!((x) & BITKEEPER(1)))
/* control pad's voltage feature */
#define VE (1 << 14)
diff --git a/arch/mips/lib/libgcc.h b/arch/mips/lib/libgcc.h
index 05909d58e2..593e598022 100644
--- a/arch/mips/lib/libgcc.h
+++ b/arch/mips/lib/libgcc.h
@@ -22,4 +22,8 @@ typedef union {
long long ll;
} DWunion;
+long long __lshrdi3(long long u, word_type b);
+long long __ashldi3(long long u, word_type b);
+long long __ashrdi3(long long u, word_type b);
+
#endif /* __ASM_LIBGCC_H */
diff --git a/arch/x86/lib/barebox.lds.S b/arch/x86/lib/barebox.lds.S
index 9798ed5c61..3315be2554 100644
--- a/arch/x86/lib/barebox.lds.S
+++ b/arch/x86/lib/barebox.lds.S
@@ -144,6 +144,7 @@ SECTIONS
.text : AT ( LOADADDR(.bootstrapping) + SIZEOF(.bootstrapping) ) {
/* do not align here! It may fails with the LOADADDR! */
_stext = .;
+ _text = .;
*(.text_entry*)
__bare_init_start = .;
*(.text_bare_init*)
diff --git a/defaultenv/bin/_update b/defaultenv/bin/_update
index e7cf1496e9..8e27ee10c6 100644
--- a/defaultenv/bin/_update
+++ b/defaultenv/bin/_update
@@ -11,7 +11,7 @@ if [ ! -e "$part" ]; then
fi
if [ x$mode = xtftp -o x$mode = xnfs ]; then
- if [ x$ip = xdhcp ]; then
+ if [ x$ip = xdhcp -o x$ip = "xdhcp-barebox" ]; then
dhcp
fi
diff --git a/drivers/mtd/core.c b/drivers/mtd/core.c
index ccc5c262ac..7bc0a0f04c 100644
--- a/drivers/mtd/core.c
+++ b/drivers/mtd/core.c
@@ -119,7 +119,9 @@ int mtd_ioctl(struct cdev *cdev, int request, void *buf)
int ret = 0;
struct mtd_info *mtd = cdev->priv;
struct mtd_info_user *user = buf;
+#if (defined(CONFIG_NAND_ECC_HW) || defined(CONFIG_NAND_ECC_SOFT))
struct mtd_ecc_stats *ecc = buf;
+#endif
struct region_info_user *reg = buf;
switch (request) {
diff --git a/drivers/nor/cfi_flash_intel.c b/drivers/nor/cfi_flash_intel.c
index 6318cfec83..32e581a395 100644
--- a/drivers/nor/cfi_flash_intel.c
+++ b/drivers/nor/cfi_flash_intel.c
@@ -57,6 +57,9 @@ static int intel_flash_write_cfibuffer (struct flash_info *info, ulong dest, con
int retcode;
void *src = (void*)cp;
void *dst = (void *)dest;
+ /* reduce width due to possible alignment problems */
+ const unsigned long ptr = (unsigned long)dest | (unsigned long)cp | info->portwidth;
+ const int width = ptr & -ptr;
sector = find_sector (info, dest);
flash_write_cmd (info, sector, 0, FLASH_CMD_CLEAR_STATUS);
@@ -68,22 +71,27 @@ static int intel_flash_write_cfibuffer (struct flash_info *info, ulong dest, con
return retcode;
/* reduce the number of loops by the width of the port */
- cnt = len >> (info->portwidth - 1);
+ cnt = len / width;
- flash_write_cmd(info, sector, 0, (u32)cnt - 1);
+ flash_write_cmd(info, sector, 0, cnt - 1);
while (cnt-- > 0) {
- if (bankwidth_is_1(info)) {
+ switch (width) {
+ case 1:
flash_write8(flash_read8(src), dst);
src += 1, dst += 1;
- } else if (bankwidth_is_2(info)) {
+ break;
+ case 2:
flash_write16(flash_read16(src), dst);
src += 2, dst += 2;
- } else if (bankwidth_is_4(info)) {
+ break;
+ case 4:
flash_write32(flash_read32(src), dst);
src += 4, dst += 4;
- } else if (bankwidth_is_8(info)) {
+ break;
+ case 8:
flash_write64(flash_read64(src), dst);
src += 8, dst += 8;
+ break;
}
}
diff --git a/drivers/serial/serial_s3c.c b/drivers/serial/serial_s3c.c
index a5fd4eeb52..2bdc1df696 100644
--- a/drivers/serial/serial_s3c.c
+++ b/drivers/serial/serial_s3c.c
@@ -153,7 +153,7 @@ static int s3c_serial_probe(struct device_d *dev)
struct s3c_uart *priv;
struct console_device *cdev;
- priv = xzalloc(sizeof(struct console_device));
+ priv = xzalloc(sizeof(struct s3c_uart));
cdev = &priv->cdev;
priv->regs = dev_request_mem_region(dev, 0);
dev->priv = priv;
diff --git a/drivers/usb/gadget/pxa27x_udc.c b/drivers/usb/gadget/pxa27x_udc.c
index 56525559f6..87dcfac965 100644
--- a/drivers/usb/gadget/pxa27x_udc.c
+++ b/drivers/usb/gadget/pxa27x_udc.c
@@ -1260,7 +1260,7 @@ static void pxa27x_change_configuration(struct pxa_udc *udc, int config)
udc->driver->setup(&udc->gadget, &req);
}
-static void pxa27x_change_interface(struct pxa_udc *udc, int iface, int alt)
+static void __maybe_unused pxa27x_change_interface(struct pxa_udc *udc, int iface, int alt)
{
struct usb_ctrlrequest req;
@@ -1473,9 +1473,9 @@ static struct pxa_udc memory = {
}
};
-static int pxa27x_udc_poller(struct poller_struct *poller)
+static void pxa27x_udc_poller(struct poller_struct *poller)
{
- return usb_gadget_poll();
+ usb_gadget_poll();
}
static struct poller_struct poller = {
.func = pxa27x_udc_poller
diff --git a/drivers/video/Kconfig b/drivers/video/Kconfig
index 509ba640e3..519cdbf25a 100644
--- a/drivers/video/Kconfig
+++ b/drivers/video/Kconfig
@@ -37,7 +37,7 @@ config DRIVER_VIDEO_S3C24XX
help
Add support for the S3C244x LCD controller.
-if DRIVER_VIDEO_S3C
+if DRIVER_VIDEO_S3C24XX
config DRIVER_VIDEO_S3C_VERBOSE
bool "S3C244x verbose framebuffer info"
diff --git a/lib/string.c b/lib/string.c
index 77435aad79..28650883cc 100644
--- a/lib/string.c
+++ b/lib/string.c
@@ -420,30 +420,6 @@ void * memset(void * s,int c,size_t count)
#endif
EXPORT_SYMBOL(memset);
-#ifndef __HAVE_ARCH_BCOPY
-/**
- * bcopy - Copy one area of memory to another
- * @src: Where to copy from
- * @dest: Where to copy to
- * @count: The size of the area.
- *
- * Note that this is the same as memcpy(), with the arguments reversed.
- * memcpy() is the standard, bcopy() is a legacy BSD function.
- *
- * You should not use this function to access IO space, use memcpy_toio()
- * or memcpy_fromio() instead.
- */
-char * bcopy(const char * src, char * dest, int count)
-{
- char *tmp = dest;
-
- while (count--)
- *tmp++ = *src++;
-
- return dest;
-}
-#endif
-
#ifndef __HAVE_ARCH_MEMCPY
/**
* memcpy - Copy one area of memory to another