summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2020-06-11 07:35:39 +0200
committerSascha Hauer <s.hauer@pengutronix.de>2020-06-11 07:35:39 +0200
commitf8eaeee4571358afa5fb0d9e6374d095c7531c96 (patch)
tree40e37b7eb56c4f6f43273c07b58f310e68cfc2a6
parent91649f1065d735bb4bcc6bb1a8067e670dcbbead (diff)
parent34d18aaa2a47522a8b607fb2e61c79f5b10ecb9a (diff)
downloadbarebox-f8eaeee4571358afa5fb0d9e6374d095c7531c96.tar.gz
barebox-f8eaeee4571358afa5fb0d9e6374d095c7531c96.tar.xz
Merge branch 'for-next/misc'
-rw-r--r--arch/arm/boards/eukrea_cpuimx35/eukrea_cpuimx35.c2
-rw-r--r--arch/arm/dts/imx6q-phytec-phycard.dts2
-rw-r--r--arch/arm/include/asm/types.h48
-rw-r--r--arch/arm/mach-imx/iim.c8
-rw-r--r--arch/mips/include/asm/io.h6
-rw-r--r--arch/mips/lib/reloc.c6
-rw-r--r--arch/nios2/include/asm/int-ll64.h78
-rw-r--r--arch/nios2/include/asm/types.h2
-rw-r--r--arch/nios2/lib/libgcc.c21
-rw-r--r--arch/openrisc/include/asm/types.h48
-rw-r--r--arch/powerpc/include/asm/types.h35
-rw-r--r--arch/riscv/include/asm/types.h42
-rw-r--r--arch/sandbox/include/asm/types.h42
-rw-r--r--arch/x86/include/asm/types.h42
-rw-r--r--common/blspec.c12
-rw-r--r--common/password.c4
-rw-r--r--drivers/i2c/busses/i2c-imx-early.c2
-rw-r--r--drivers/i2c/busses/i2c-imx.c2
-rw-r--r--drivers/i2c/busses/i2c-omap.c2
-rw-r--r--drivers/mci/stm32_sdmmc2.c4
-rw-r--r--drivers/net/usb/usbnet.c10
-rw-r--r--drivers/serial/amba-pl011.c1
-rw-r--r--drivers/serial/serial_ns16550.c12
-rw-r--r--drivers/serial/stm-serial.c1
-rw-r--r--include/.gitignore1
-rw-r--r--lib/logo/Makefile19
-rw-r--r--net/nfs.c4
-rw-r--r--scripts/.gitignore1
28 files changed, 94 insertions, 363 deletions
diff --git a/arch/arm/boards/eukrea_cpuimx35/eukrea_cpuimx35.c b/arch/arm/boards/eukrea_cpuimx35/eukrea_cpuimx35.c
index 220a484bde..558bc07912 100644
--- a/arch/arm/boards/eukrea_cpuimx35/eukrea_cpuimx35.c
+++ b/arch/arm/boards/eukrea_cpuimx35/eukrea_cpuimx35.c
@@ -242,7 +242,7 @@ static int eukrea_cpuimx35_core_init(void)
reg = writel(reg, MX35_CCM_BASE_ADDR + MX35_CCM_CGR0);
reg = readl(MX35_CCM_BASE_ADDR + MX35_CCM_CGR1);
reg |= 0x3 << MX35_CCM_CGR1_FEC_SHIFT;
- reg |= 0x3 << MX35_CCM_CGR1_I2C1_SHIFT,
+ reg |= 0x3 << MX35_CCM_CGR1_I2C1_SHIFT;
reg = writel(reg, MX35_CCM_BASE_ADDR + MX35_CCM_CGR1);
reg = readl(MX35_CCM_BASE_ADDR + MX35_CCM_CGR2);
reg |= 0x3 << MX35_CCM_CGR2_USB_SHIFT;
diff --git a/arch/arm/dts/imx6q-phytec-phycard.dts b/arch/arm/dts/imx6q-phytec-phycard.dts
index c06461c2c7..b0e47e9b62 100644
--- a/arch/arm/dts/imx6q-phytec-phycard.dts
+++ b/arch/arm/dts/imx6q-phytec-phycard.dts
@@ -16,7 +16,7 @@
/ {
model = "PHYTEC phyCARD-i.MX6 Quad";
- compatible = "phytec,imx6q-pbaa03", "phytec,imx6q-pcaaxl3", "fsl,imx6q";
+ compatible = "phytec,imx6q-pcaaxl3", "fsl,imx6q";
chosen {
stdout-path = &uart3;
diff --git a/arch/arm/include/asm/types.h b/arch/arm/include/asm/types.h
index 9c21066882..22b9642655 100644
--- a/arch/arm/include/asm/types.h
+++ b/arch/arm/include/asm/types.h
@@ -1,52 +1,6 @@
#ifndef __ASM_ARM_TYPES_H
#define __ASM_ARM_TYPES_H
-#ifndef __ASSEMBLY__
-
-/*
- * __xx is ok: it doesn't pollute the POSIX namespace. Use these in the
- * header files exported to user space
- */
-
-typedef __signed__ char __s8;
-typedef unsigned char __u8;
-
-typedef __signed__ short __s16;
-typedef unsigned short __u16;
-
-typedef __signed__ int __s32;
-typedef unsigned int __u32;
-
-#if defined(__GNUC__) && !defined(__STRICT_ANSI__)
-typedef __signed__ long long __s64;
-typedef unsigned long long __u64;
-#endif
-
-#endif /* __ASSEMBLY__ */
-
-/*
- * These aren't exported outside the kernel to avoid name space clashes
- */
-#ifdef __KERNEL__
-
-#include <asm/bitsperlong.h>
-
-#ifndef __ASSEMBLY__
-
-typedef signed char s8;
-typedef unsigned char u8;
-
-typedef signed short s16;
-typedef unsigned short u16;
-
-typedef signed int s32;
-typedef unsigned int u32;
-
-typedef signed long long s64;
-typedef unsigned long long u64;
-
-#endif /* __ASSEMBLY__ */
-
-#endif /* __KERNEL__ */
+#include <asm-generic/int-ll64.h>
#endif
diff --git a/arch/arm/mach-imx/iim.c b/arch/arm/mach-imx/iim.c
index 207e1879c3..2f9ffbd271 100644
--- a/arch/arm/mach-imx/iim.c
+++ b/arch/arm/mach-imx/iim.c
@@ -329,10 +329,10 @@ static int imx_iim_add_bank(struct iim_priv *iim, int num, int nregs)
iim->bank[num] = bank;
- bank->map_config.reg_bits = 8,
- bank->map_config.val_bits = 8,
- bank->map_config.reg_stride = 1,
- bank->map_config.max_register = (nregs - 1),
+ bank->map_config.reg_bits = 8;
+ bank->map_config.val_bits = 8;
+ bank->map_config.reg_stride = 1;
+ bank->map_config.max_register = (nregs - 1);
bank->map_config.name = xasprintf("bank%d", num);
bank->map = regmap_init(&iim->dev, &imx_iim_regmap_bus, bank, &bank->map_config);
diff --git a/arch/mips/include/asm/io.h b/arch/mips/include/asm/io.h
index c155199430..4df9853680 100644
--- a/arch/mips/include/asm/io.h
+++ b/arch/mips/include/asm/io.h
@@ -39,7 +39,11 @@ static inline unsigned long virt_to_phys(const void *address)
*/
static inline void *phys_to_virt(unsigned long address)
{
- return (void *)CKSEG0ADDR(address);
+ if (IS_ENABLED(CONFIG_MMU)) {
+ return (void *)CKSEG0ADDR(address);
+ }
+
+ return (void *)CKSEG1ADDR(address);
}
#define IO_SPACE_LIMIT 0
diff --git a/arch/mips/lib/reloc.c b/arch/mips/lib/reloc.c
index 4b0e252352..b084a88be7 100644
--- a/arch/mips/lib/reloc.c
+++ b/arch/mips/lib/reloc.c
@@ -120,7 +120,11 @@ void relocate_code(void *fdt, u32 fdt_size, u32 ram_size)
length = __bss_stop - __image_start;
relocaddr = ALIGN_DOWN(ram_size - length, SZ_64K);
- relocaddr = KSEG0ADDR(relocaddr);
+ if (IS_ENABLED(CONFIG_MMU)) {
+ relocaddr = KSEG0ADDR(relocaddr);
+ } else {
+ relocaddr = KSEG1ADDR(relocaddr);
+ }
new_stack = relocaddr - MALLOC_SIZE - 16;
/*
diff --git a/arch/nios2/include/asm/int-ll64.h b/arch/nios2/include/asm/int-ll64.h
deleted file mode 100644
index f394147c07..0000000000
--- a/arch/nios2/include/asm/int-ll64.h
+++ /dev/null
@@ -1,78 +0,0 @@
-/*
- * asm-generic/int-ll64.h
- *
- * Integer declarations for architectures which use "long long"
- * for 64-bit types.
- */
-
-#ifndef _ASM_GENERIC_INT_LL64_H
-#define _ASM_GENERIC_INT_LL64_H
-
-#include <asm/bitsperlong.h>
-
-#ifndef __ASSEMBLY__
-/*
- * __xx is ok: it doesn't pollute the POSIX namespace. Use these in the
- * header files exported to user space
- */
-
-typedef __signed__ char __s8;
-typedef unsigned char __u8;
-
-typedef __signed__ short __s16;
-typedef unsigned short __u16;
-
-typedef __signed__ int __s32;
-typedef unsigned int __u32;
-
-#ifdef __GNUC__
-__extension__ typedef __signed__ long long __s64;
-__extension__ typedef unsigned long long __u64;
-#else
-typedef __signed__ long long __s64;
-typedef unsigned long long __u64;
-#endif
-
-#endif /* __ASSEMBLY__ */
-
-#ifdef __KERNEL__
-
-#ifndef __ASSEMBLY__
-
-typedef signed char s8;
-typedef unsigned char u8;
-
-typedef signed short s16;
-typedef unsigned short u16;
-
-typedef signed int s32;
-typedef unsigned int u32;
-
-typedef signed long long s64;
-typedef unsigned long long u64;
-
-#define S8_C(x) x
-#define U8_C(x) x ## U
-#define S16_C(x) x
-#define U16_C(x) x ## U
-#define S32_C(x) x
-#define U32_C(x) x ## U
-#define S64_C(x) x ## LL
-#define U64_C(x) x ## ULL
-
-#else /* __ASSEMBLY__ */
-
-#define S8_C(x) x
-#define U8_C(x) x
-#define S16_C(x) x
-#define U16_C(x) x
-#define S32_C(x) x
-#define U32_C(x) x
-#define S64_C(x) x
-#define U64_C(x) x
-
-#endif /* __ASSEMBLY__ */
-
-#endif /* __KERNEL__ */
-
-#endif /* _ASM_GENERIC_INT_LL64_H */
diff --git a/arch/nios2/include/asm/types.h b/arch/nios2/include/asm/types.h
index 0067ea83c1..380ad340c3 100644
--- a/arch/nios2/include/asm/types.h
+++ b/arch/nios2/include/asm/types.h
@@ -1,6 +1,6 @@
#ifndef __ASM_TYPES_H
#define __ASM_TYPES_H
-#include <asm/int-ll64.h>
+#include <asm-generic/int-ll64.h>
#endif
diff --git a/arch/nios2/lib/libgcc.c b/arch/nios2/lib/libgcc.c
index abf93fdd71..814df73310 100644
--- a/arch/nios2/lib/libgcc.c
+++ b/arch/nios2/lib/libgcc.c
@@ -319,15 +319,15 @@ DWtype __divdi3(DWtype u, DWtype v)
DWunion vv = {.ll = v};
DWtype w;
- if (uu.s.high < 0)
- c = ~c,
-
- uu.ll = -uu.ll;
-
- if (vv.s.high < 0)
- c = ~c,
+ if (uu.s.high < 0) {
+ c = ~c;
+ uu.ll = -uu.ll;
+ }
- vv.ll = -vv.ll;
+ if (vv.s.high < 0) {
+ c = ~c;
+ vv.ll = -vv.ll;
+ }
w = __udivmoddi4(uu.ll, vv.ll, (UDWtype *) 0);
@@ -366,9 +366,10 @@ DWtype __moddi3(DWtype u, DWtype v)
DWunion vv = {.ll = v};
DWtype w;
- if (uu.s.high < 0)
- c = ~c,
+ if (uu.s.high < 0) {
+ c = ~c;
uu.ll = -uu.ll;
+ }
if (vv.s.high < 0)
vv.ll = -vv.ll;
diff --git a/arch/openrisc/include/asm/types.h b/arch/openrisc/include/asm/types.h
index 8ee6bb00f9..21a45b74cd 100644
--- a/arch/openrisc/include/asm/types.h
+++ b/arch/openrisc/include/asm/types.h
@@ -16,52 +16,6 @@
#ifndef _ASM_TYPES_H
#define _ASM_TYPES_H
-/*
- * This file is never included by application software unless
- * explicitly requested (e.g., via linux/types.h) in which case the
- * application is Linux specific so (user-) name space pollution is
- * not a major issue. However, for interoperability, libraries still
- * need to be careful to avoid a name clashes.
- */
-
-/*
- * __xx is ok: it doesn't pollute the POSIX namespace. Use these in the
- * header files exported to user space
- */
-
-typedef __signed__ char __s8;
-typedef unsigned char __u8;
-
-typedef __signed__ short __s16;
-typedef unsigned short __u16;
-
-typedef __signed__ int __s32;
-typedef unsigned int __u32;
-
-#if defined(__GNUC__)
-__extension__ typedef __signed__ long long __s64;
-__extension__ typedef unsigned long long __u64;
-#endif
-
-/*
- * These aren't exported outside the kernel to avoid name space clashes
- */
-#ifdef __KERNEL__
-
-typedef signed char s8;
-typedef unsigned char u8;
-
-typedef signed short s16;
-typedef unsigned short u16;
-
-typedef signed int s32;
-typedef unsigned int u32;
-
-typedef signed long long s64;
-typedef unsigned long long u64;
-
-#include <asm/bitsperlong.h>
-
-#endif /* __KERNEL__ */
+#include <asm-generic/int-ll64.h>
#endif /* _ASM_TYPES_H */
diff --git a/arch/powerpc/include/asm/types.h b/arch/powerpc/include/asm/types.h
index 2d3ce0a283..f3d41905ca 100644
--- a/arch/powerpc/include/asm/types.h
+++ b/arch/powerpc/include/asm/types.h
@@ -1,45 +1,14 @@
#ifndef _PPC_TYPES_H
#define _PPC_TYPES_H
-#ifndef __ASSEMBLY__
-
-typedef __signed__ char __s8;
-typedef unsigned char __u8;
-
-typedef __signed__ short __s16;
-typedef unsigned short __u16;
+#include <asm-generic/int-ll64.h>
-typedef __signed__ int __s32;
-typedef unsigned int __u32;
-
-#if defined(__GNUC__) && !defined(__STRICT_ANSI__)
-typedef __signed__ long long __s64;
-typedef unsigned long long __u64;
-#endif
+#ifndef __ASSEMBLY__
typedef struct {
__u32 u[4];
} __attribute((aligned(16))) vector128;
-#ifdef __KERNEL__
-/*
- * These aren't exported outside the kernel to avoid name space clashes
- */
-typedef signed char s8;
-typedef unsigned char u8;
-
-typedef signed short s16;
-typedef unsigned short u16;
-
-typedef signed int s32;
-typedef unsigned int u32;
-
-typedef signed long long s64;
-typedef unsigned long long u64;
-
-#include <asm-generic/bitsperlong.h>
-
-#endif /* __KERNEL__ */
#endif /* __ASSEMBLY__ */
#endif
diff --git a/arch/riscv/include/asm/types.h b/arch/riscv/include/asm/types.h
index 8200a03349..af37d7738c 100644
--- a/arch/riscv/include/asm/types.h
+++ b/arch/riscv/include/asm/types.h
@@ -1,6 +1,8 @@
#ifndef __ASM_RISCV_TYPES_H
#define __ASM_RISCV_TYPES_H
+#include <asm-generic/int-ll64.h>
+
#ifdef __riscv64
/*
* This is used in dlmalloc. On RISCV64 we need it to be 64 bit
@@ -15,44 +17,4 @@
#endif
-/*
- * __xx is ok: it doesn't pollute the POSIX namespace. Use these in the
- * header files exported to user space
- */
-
-typedef __signed__ char __s8;
-typedef unsigned char __u8;
-
-typedef __signed__ short __s16;
-typedef unsigned short __u16;
-
-typedef __signed__ int __s32;
-typedef unsigned int __u32;
-
-#if defined(__GNUC__) && !defined(__STRICT_ANSI__)
-typedef __signed__ long long __s64;
-typedef unsigned long long __u64;
-#endif
-
-/*
- * These aren't exported outside the kernel to avoid name space clashes
- */
-#ifdef __KERNEL__
-
-typedef signed char s8;
-typedef unsigned char u8;
-
-typedef signed short s16;
-typedef unsigned short u16;
-
-typedef signed int s32;
-typedef unsigned int u32;
-
-typedef signed long long s64;
-typedef unsigned long long u64;
-
-#include <asm/bitsperlong.h>
-
-#endif /* __KERNEL__ */
-
#endif /* __ASM_RISCV_TYPES_H */
diff --git a/arch/sandbox/include/asm/types.h b/arch/sandbox/include/asm/types.h
index 8426de4cc2..3e4a8f7ba3 100644
--- a/arch/sandbox/include/asm/types.h
+++ b/arch/sandbox/include/asm/types.h
@@ -1,6 +1,8 @@
#ifndef __ASM_I386_TYPES_H
#define __ASM_I386_TYPES_H
+#include <asm-generic/int-ll64.h>
+
#ifdef __x86_64__
/*
* This is used in dlmalloc. On X86_64 we need it to be
@@ -16,44 +18,4 @@
#endif
-/*
- * __xx is ok: it doesn't pollute the POSIX namespace. Use these in the
- * header files exported to user space
- */
-
-typedef __signed__ char __s8;
-typedef unsigned char __u8;
-
-typedef __signed__ short __s16;
-typedef unsigned short __u16;
-
-typedef __signed__ int __s32;
-typedef unsigned int __u32;
-
-#if defined(__GNUC__) && !defined(__STRICT_ANSI__)
-typedef __signed__ long long __s64;
-typedef unsigned long long __u64;
-#endif
-
-/*
- * These aren't exported outside the kernel to avoid name space clashes
- */
-#ifdef __KERNEL__
-
-typedef signed char s8;
-typedef unsigned char u8;
-
-typedef signed short s16;
-typedef unsigned short u16;
-
-typedef signed int s32;
-typedef unsigned int u32;
-
-typedef signed long long s64;
-typedef unsigned long long u64;
-
-#include <asm/bitsperlong.h>
-
-#endif /* __KERNEL__ */
-
#endif
diff --git a/arch/x86/include/asm/types.h b/arch/x86/include/asm/types.h
index e57ae2c8cf..17947b2ff3 100644
--- a/arch/x86/include/asm/types.h
+++ b/arch/x86/include/asm/types.h
@@ -1,6 +1,8 @@
#ifndef __ASM_I386_TYPES_H
#define __ASM_I386_TYPES_H
+#include <asm-generic/int-ll64.h>
+
#ifndef __ASSEMBLY__
#ifdef __x86_64__
@@ -18,46 +20,6 @@
#endif
-/*
- * __xx is ok: it doesn't pollute the POSIX namespace. Use these in the
- * header files exported to user space
- */
-
-typedef __signed__ char __s8;
-typedef unsigned char __u8;
-
-typedef __signed__ short __s16;
-typedef unsigned short __u16;
-
-typedef __signed__ int __s32;
-typedef unsigned int __u32;
-
-#if defined(__GNUC__) && !defined(__STRICT_ANSI__)
-typedef __signed__ long long __s64;
-typedef unsigned long long __u64;
-#endif
-
-/*
- * These aren't exported outside the kernel to avoid name space clashes
- */
-#ifdef __KERNEL__
-
-typedef signed char s8;
-typedef unsigned char u8;
-
-typedef signed short s16;
-typedef unsigned short u16;
-
-typedef signed int s32;
-typedef unsigned int u32;
-
-typedef signed long long s64;
-typedef unsigned long long u64;
-
-#include <asm/bitsperlong.h>
-
-#endif /* __KERNEL__ */
-
#endif
#endif
diff --git a/common/blspec.c b/common/blspec.c
index 1a6d581f5a..9e1036c834 100644
--- a/common/blspec.c
+++ b/common/blspec.c
@@ -298,6 +298,18 @@ static struct blspec_entry *blspec_entry_open(struct bootentries *bootentries,
val = end;
+ if (!strcmp(name, "options")) {
+ /* If there was a previous "options" key given, prepend its value
+ * (as per spec). */
+ const char *prev_val = blspec_entry_var_get(entry, name);
+ if (prev_val) {
+ char *opts = xasprintf("%s %s", prev_val, val);
+ blspec_entry_var_set(entry, name, opts);
+ free(opts);
+ continue;
+ }
+ }
+
blspec_entry_var_set(entry, name, val);
}
diff --git a/common/password.c b/common/password.c
index a2a9c4cd6c..3c08ab782e 100644
--- a/common/password.c
+++ b/common/password.c
@@ -161,6 +161,9 @@ static int read_default_passwd(unsigned char *sum, size_t length)
unsigned char *buf = (unsigned char *)default_passwd;
unsigned char c;
+ if (ARRAY_SIZE(default_passwd) == 1)
+ return -ENOSYS;
+
if (!sum || length < 1)
return -EINVAL;
@@ -179,7 +182,6 @@ static int read_default_passwd(unsigned char *sum, size_t length)
return 0;
}
-EXPORT_SYMBOL(read_default_passwd);
static int read_env_passwd(unsigned char *sum, size_t length)
{
diff --git a/drivers/i2c/busses/i2c-imx-early.c b/drivers/i2c/busses/i2c-imx-early.c
index 26922c1044..472e4be83a 100644
--- a/drivers/i2c/busses/i2c-imx-early.c
+++ b/drivers/i2c/busses/i2c-imx-early.c
@@ -282,7 +282,7 @@ fail0:
i2c_fsl_stop(fsl_i2c);
/* Disable I2C controller, and force our state to stopped */
- temp = fsl_i2c->i2cr_ien_opcode ^ I2CR_IEN,
+ temp = fsl_i2c->i2cr_ien_opcode ^ I2CR_IEN;
fsl_i2c_write_reg(temp, fsl_i2c, FSL_I2C_I2CR);
return (ret < 0) ? ret : num;
diff --git a/drivers/i2c/busses/i2c-imx.c b/drivers/i2c/busses/i2c-imx.c
index 6911f803b2..7d25ed3af5 100644
--- a/drivers/i2c/busses/i2c-imx.c
+++ b/drivers/i2c/busses/i2c-imx.c
@@ -511,7 +511,7 @@ fail0:
i2c_fsl_stop(adapter);
/* Disable I2C controller, and force our state to stopped */
- temp = i2c_fsl->hwdata->i2cr_ien_opcode ^ I2CR_IEN,
+ temp = i2c_fsl->hwdata->i2cr_ien_opcode ^ I2CR_IEN;
fsl_i2c_write_reg(temp, i2c_fsl, FSL_I2C_I2CR);
return (result < 0) ? result : num;
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
index bdb34ca1b4..d3f525f333 100644
--- a/drivers/i2c/busses/i2c-omap.c
+++ b/drivers/i2c/busses/i2c-omap.c
@@ -1176,7 +1176,7 @@ i2c_omap_probe(struct device_d *pdev)
omap_i2c_idle(i2c_omap);
- i2c_omap->adapter.master_xfer = omap_i2c_xfer,
+ i2c_omap->adapter.master_xfer = omap_i2c_xfer;
i2c_omap->adapter.nr = pdev->id;
i2c_omap->adapter.dev.parent = pdev;
i2c_omap->adapter.dev.device_node = pdev->device_node;
diff --git a/drivers/mci/stm32_sdmmc2.c b/drivers/mci/stm32_sdmmc2.c
index 3ce3bb0f89..da2dc592ad 100644
--- a/drivers/mci/stm32_sdmmc2.c
+++ b/drivers/mci/stm32_sdmmc2.c
@@ -586,8 +586,8 @@ static int stm32_sdmmc2_probe(struct amba_device *adev,
priv->dev = dev;
mci = &priv->mci;
- mci->send_cmd = stm32_sdmmc2_send_cmd,
- mci->set_ios = stm32_sdmmc2_set_ios,
+ mci->send_cmd = stm32_sdmmc2_send_cmd;
+ mci->set_ios = stm32_sdmmc2_set_ios;
mci->init = stm32_sdmmc2_reset;
mci->hw_dev = dev;
diff --git a/drivers/net/usb/usbnet.c b/drivers/net/usb/usbnet.c
index 406b8c964f..7397034586 100644
--- a/drivers/net/usb/usbnet.c
+++ b/drivers/net/usb/usbnet.c
@@ -198,11 +198,11 @@ int usbnet_probe(struct usb_device *usbdev, const struct usb_device_id *prod)
edev = &undev->edev;
undev->udev = usbdev;
- edev->open = usbnet_open,
- edev->init = usbnet_init,
- edev->send = usbnet_send,
- edev->recv = usbnet_recv,
- edev->halt = usbnet_halt,
+ edev->open = usbnet_open;
+ edev->init = usbnet_init;
+ edev->send = usbnet_send;
+ edev->recv = usbnet_recv;
+ edev->halt = usbnet_halt;
edev->priv = undev;
edev->parent = &usbdev->dev;
diff --git a/drivers/serial/amba-pl011.c b/drivers/serial/amba-pl011.c
index 0751c52513..865ecdddb2 100644
--- a/drivers/serial/amba-pl011.c
+++ b/drivers/serial/amba-pl011.c
@@ -204,6 +204,7 @@ static int pl011_probe(struct amba_device *dev, const struct amba_id *id)
cdev->putc = pl011_putc;
cdev->getc = pl011_getc;
cdev->setbrg = pl011_setbaudrate;
+ cdev->linux_console_name = "ttyAMA";
pl011_init_port(cdev);
diff --git a/drivers/serial/serial_ns16550.c b/drivers/serial/serial_ns16550.c
index 5d6cec82a4..f117ab9dc1 100644
--- a/drivers/serial/serial_ns16550.c
+++ b/drivers/serial/serial_ns16550.c
@@ -308,6 +308,17 @@ static int ns16550_tstc(struct console_device *cdev)
return ((ns16550_read(cdev, lsr) & LSR_DR) != 0);
}
+/**
+ * @brief Flush remaining characters in serial device
+ *
+ * @param[in] cdev pointer to console device
+ */
+static void ns16550_flush(struct console_device *cdev)
+{
+ /* Loop Doing Nothing */
+ while ((ns16550_read(cdev, lsr) & LSR_TEMT) == 0) ;
+}
+
static void ns16550_probe_dt(struct device_d *dev, struct ns16550_priv *priv)
{
struct device_node *np = dev->device_node;
@@ -501,6 +512,7 @@ static int ns16550_probe(struct device_d *dev)
cdev->putc = ns16550_putc;
cdev->getc = ns16550_getc;
cdev->setbrg = ns16550_setbaudrate;
+ cdev->flush = ns16550_flush;
cdev->linux_console_name = devtype->linux_console_name;
priv->fcrval = FCRVAL;
diff --git a/drivers/serial/stm-serial.c b/drivers/serial/stm-serial.c
index ea482415ce..a2c3dcf56e 100644
--- a/drivers/serial/stm-serial.c
+++ b/drivers/serial/stm-serial.c
@@ -159,6 +159,7 @@ static int stm_serial_probe(struct device_d *dev)
cdev->flush = stm_serial_flush;
cdev->setbrg = stm_serial_setbaudrate;
cdev->dev = dev;
+ cdev->linux_console_name = "ttyAMA";
dev->priv = priv;
iores = dev_request_mem_resource(dev, 0);
diff --git a/include/.gitignore b/include/.gitignore
index f28372a3df..18e58a752a 100644
--- a/include/.gitignore
+++ b/include/.gitignore
@@ -1,2 +1 @@
-asm
/config.h
diff --git a/lib/logo/Makefile b/lib/logo/Makefile
index eb7aee080e..bf700da89b 100644
--- a/lib/logo/Makefile
+++ b/lib/logo/Makefile
@@ -1,17 +1,17 @@
-OPTS_barebox-logo-w64.bblogo="-w 64"
+OPTS_barebox-logo-w64.bblogo = --export-width=64
bblogo-$(CONFIG_BAREBOX_LOGO_64) += barebox-logo-w64
-OPTS_barebox-logo-w240.bblogo="-w 240"
+OPTS_barebox-logo-w240.bblogo = --export-width=240
bblogo-$(CONFIG_BAREBOX_LOGO_240) += barebox-logo-w240
-OPTS_barebox-logo-w320.bblogo="-w 320"
+OPTS_barebox-logo-w320.bblogo = --export-width=320
bblogo-$(CONFIG_BAREBOX_LOGO_320) += barebox-logo-w320
-OPTS_barebox-logo-w400.bblogo="-w 400"
+OPTS_barebox-logo-w400.bblogo = --export-width=400
bblogo-$(CONFIG_BAREBOX_LOGO_400) += barebox-logo-w400
-OPTS_barebox-logo-w640.bblogo="-w 640"
+OPTS_barebox-logo-w640.bblogo = --export-width=640
bblogo-$(CONFIG_BAREBOX_LOGO_640) += barebox-logo-w640
obj-y += $(patsubst %,%.bblogo.o,$(bblogo-y))
@@ -38,10 +38,17 @@ cmd_logo_S = \
%.bblogo.S: %.bblogo FORCE
$(call if_changed,logo_S)
+# Inkscape 0.92.4 supports -z but Inkscape 1.0 doesn't
+INKSCAPEOPTS += $(call try-run, inkscape -z,-z,)
+# Inkscape 0.92.4 uses -e but Inkscape 1.0 uses --export-type=png
+INKSCAPEOPTS += $(call try-run, inkscape -e -,-e -,--export-type=png)
+# Inkscape 1.0 supports -o -
+INKSCAPEOPTS += $(call try-run, inkscape -o -,-o -,)
+
quiet_cmd_logo = LOGO.S $@
cmd_logo = \
( \
- inkscape -z $(OPTS_$(@F)) -e $@ $< > /dev/null; \
+ DISPLAY="" inkscape $(OPTS_$(@F)) $(INKSCAPEOPTS) $< > $@; \
)
%.bblogo: $(srctree)/Documentation/barebox.svg FORCE
diff --git a/net/nfs.c b/net/nfs.c
index 63573098d7..591417e0de 100644
--- a/net/nfs.c
+++ b/net/nfs.c
@@ -533,7 +533,7 @@ static int nfs_readlink_reply(unsigned char *pkt, unsigned len)
static int nfs_read_reply(unsigned char *pkt, unsigned len)
{
- int rlen;
+ unsigned int rlen;
uint32_t *data;
int ret;
@@ -552,6 +552,8 @@ static int nfs_read_reply(unsigned char *pkt, unsigned len)
rlen = ntohl(net_read_uint32(data + 18));
+ rlen = max_t(unsigned int, rlen, len - 19);
+
ret = write(net_store_fd, (char *)(data + 19), rlen);
if (ret < 0) {
perror("write");
diff --git a/scripts/.gitignore b/scripts/.gitignore
index c3ac0b5702..7c9a3f5571 100644
--- a/scripts/.gitignore
+++ b/scripts/.gitignore
@@ -31,3 +31,4 @@ omap3-usb-loader
mips-relocs
rsatoc
stm32image
+mvebuimg