Merge branch '2020-12-02-master-imports'

- Assorted minor fixes
This commit is contained in:
Tom Rini 2020-12-03 09:43:47 -05:00
commit ee1e04558f
15 changed files with 23 additions and 27 deletions

View file

@ -758,6 +758,7 @@ T: git https://gitlab.denx.de/u-boot/u-boot.git
F: common/log* F: common/log*
F: cmd/log.c F: cmd/log.c
F: doc/develop/logging.rst F: doc/develop/logging.rst
F: include/log.h
F: lib/getopt.c F: lib/getopt.c
F: test/log/ F: test/log/
F: test/py/tests/test_log.py F: test/py/tests/test_log.py

View file

@ -29,7 +29,7 @@
#include <errno.h> #include <errno.h>
#include <mtd/cfi_flash.h> #include <mtd/cfi_flash.h>
#ifdef CONFIG_DFU_TFTP #if defined(CONFIG_DFU_TFTP) || defined(CONFIG_UPDATE_TFTP)
/* env variable holding the location of the update file */ /* env variable holding the location of the update file */
#define UPDATE_FILE_ENV "updatefile" #define UPDATE_FILE_ENV "updatefile"
@ -99,7 +99,6 @@ static int update_load(char *filename, ulong msec_max, int cnt_max, ulong addr)
return rv; return rv;
} }
#endif /* CONFIG_DFU_TFTP */
#ifdef CONFIG_MTD_NOR_FLASH #ifdef CONFIG_MTD_NOR_FLASH
static int update_flash_protect(int prot, ulong addr_first, ulong addr_last) static int update_flash_protect(int prot, ulong addr_first, ulong addr_last)
@ -216,6 +215,7 @@ static int update_flash(ulong addr_source, ulong addr_first, ulong size)
#endif #endif
return 0; return 0;
} }
#endif /* CONFIG_DFU_TFTP || CONFIG_UPDATE_TFTP */
static int update_fit_getparams(const void *fit, int noffset, ulong *addr, static int update_fit_getparams(const void *fit, int noffset, ulong *addr,
ulong *fladdr, ulong *size) ulong *fladdr, ulong *size)
@ -233,7 +233,7 @@ static int update_fit_getparams(const void *fit, int noffset, ulong *addr,
return 0; return 0;
} }
#ifdef CONFIG_DFU_TFTP #if defined(CONFIG_DFU_TFTP) || defined(CONFIG_UPDATE_TFTP)
int update_tftp(ulong addr, char *interface, char *devstring) int update_tftp(ulong addr, char *interface, char *devstring)
{ {
char *filename, *env_addr, *fit_image_name; char *filename, *env_addr, *fit_image_name;
@ -340,7 +340,7 @@ next_node:
return ret; return ret;
} }
#endif /* CONFIG_DFU_UPDATE */ #endif /* CONFIG_DFU_UPDATE || CONFIG_UPDATE_TFTP */
#ifdef CONFIG_UPDATE_FIT #ifdef CONFIG_UPDATE_FIT
/** /**

View file

@ -278,6 +278,11 @@ const struct flash_info spi_nor_ids[] = {
SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ | SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ |
SPI_NOR_HAS_LOCK | SPI_NOR_HAS_TB) SPI_NOR_HAS_LOCK | SPI_NOR_HAS_TB)
}, },
{
INFO("w25q32jwm", 0xef8016, 0, 64 * 1024, 64,
SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ |
SPI_NOR_HAS_LOCK | SPI_NOR_HAS_TB)
},
{ INFO("w25x64", 0xef3017, 0, 64 * 1024, 128, SECT_4K) }, { INFO("w25x64", 0xef3017, 0, 64 * 1024, 128, SECT_4K) },
{ {
INFO("w25q64dw", 0xef6017, 0, 64 * 1024, 128, INFO("w25q64dw", 0xef6017, 0, 64 * 1024, 128,

View file

@ -61,7 +61,7 @@ static int sbsa_gwdt_start(struct udevice *dev, u64 timeout, ulong flags)
* to half value of timeout. * to half value of timeout.
*/ */
clk = get_tbclk(); clk = get_tbclk();
writel(clk / 2 * timeout, writel(clk / (2 * 1000) * timeout,
priv->reg_control + SBSA_GWDT_WOR); priv->reg_control + SBSA_GWDT_WOR);
/* writing WCS will cause an explicit watchdog refresh */ /* writing WCS will cause an explicit watchdog refresh */

View file

@ -49,6 +49,7 @@ static int sqfs_read_sblk(struct squashfs_super_block **sblk)
if (sqfs_disk_read(0, 1, *sblk) != 1) { if (sqfs_disk_read(0, 1, *sblk) != 1) {
free(*sblk); free(*sblk);
sblk = NULL;
return -EINVAL; return -EINVAL;
} }
@ -1689,9 +1690,10 @@ free_strings:
void sqfs_close(void) void sqfs_close(void)
{ {
free(ctxt.sblk);
ctxt.cur_dev = NULL;
sqfs_decompressor_cleanup(&ctxt); sqfs_decompressor_cleanup(&ctxt);
free(ctxt.sblk);
ctxt.sblk = NULL;
ctxt.cur_dev = NULL;
} }
void sqfs_closedir(struct fs_dir_stream *dirs) void sqfs_closedir(struct fs_dir_stream *dirs)

View file

@ -196,7 +196,7 @@ struct global_data {
*/ */
struct list_head uclass_root; struct list_head uclass_root;
# if CONFIG_IS_ENABLED(OF_PLATDATA) # if CONFIG_IS_ENABLED(OF_PLATDATA)
/** Dynamic info about the driver */ /** @dm_driver_rt: Dynamic info about the driver */
struct driver_rt *dm_driver_rt; struct driver_rt *dm_driver_rt;
# endif # endif
#endif #endif

View file

@ -62,7 +62,6 @@
/* JFFS2 */ /* JFFS2 */
#ifdef CONFIG_CMD_JFFS2 #ifdef CONFIG_CMD_JFFS2
#define CONFIG_JFFS2_CMDLINE
#define CONFIG_JFFS2_NAND #define CONFIG_JFFS2_NAND
#endif #endif

View file

@ -32,9 +32,6 @@
*/ */
#define CONFIG_BOOTP_BOOTFILESIZE #define CONFIG_BOOTP_BOOTFILESIZE
/* UBI Support for all Keymile boards */
#define CONFIG_MTD_CONCAT
#ifndef CONFIG_KM_DEF_ENV_BOOTPARAMS #ifndef CONFIG_KM_DEF_ENV_BOOTPARAMS
#define CONFIG_KM_DEF_ENV_BOOTPARAMS \ #define CONFIG_KM_DEF_ENV_BOOTPARAMS \
"actual_bank=0\0" "actual_bank=0\0"

View file

@ -9,8 +9,6 @@
/* Do boardspecific init for all boards */ /* Do boardspecific init for all boards */
#define CONFIG_JFFS2_CMDLINE
/* EEprom support 24C08, 24C16, 24C64 */ /* EEprom support 24C08, 24C16, 24C64 */
#define CONFIG_SYS_EEPROM_PAGE_WRITE_ENABLE #define CONFIG_SYS_EEPROM_PAGE_WRITE_ENABLE
#define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 3 /* 8 Byte write page */ #define CONFIG_SYS_EEPROM_PAGE_WRITE_BITS 3 /* 8 Byte write page */

View file

@ -337,9 +337,6 @@ int get_scl(void);
* additionnal command line configuration. * additionnal command line configuration.
*/ */
/* we don't need flash support */
#undef CONFIG_JFFS2_CMDLINE
/* /*
* For booting Linux, the board info and command line data * For booting Linux, the board info and command line data
* have to be in the first 64 MB of memory, since this is * have to be in the first 64 MB of memory, since this is

View file

@ -190,7 +190,6 @@
#endif #endif
#define CONFIG_JFFS2_CMDLINE 1
#define CONFIG_JFFS2_NAND 1 #define CONFIG_JFFS2_NAND 1
#define CONFIG_JFFS2_DEV "nand0" /* NAND device jffs2 lives on */ #define CONFIG_JFFS2_DEV "nand0" /* NAND device jffs2 lives on */
#define CONFIG_JFFS2_PART_OFFSET 0 /* start of jffs2 partition */ #define CONFIG_JFFS2_PART_OFFSET 0 /* start of jffs2 partition */

View file

@ -49,7 +49,6 @@
#define CONFIG_SYS_MCFRRTC_BASE 0xFC0A8000 #define CONFIG_SYS_MCFRRTC_BASE 0xFC0A8000
/* spi not partitions */ /* spi not partitions */
#define CONFIG_JFFS2_CMDLINE
#define CONFIG_JFFS2_DEV "nor0" #define CONFIG_JFFS2_DEV "nor0"
/* Timer */ /* Timer */

View file

@ -248,7 +248,7 @@ typedef int wait_queue_head_t;
#define spin_lock_init(lock) do {} while (0) #define spin_lock_init(lock) do {} while (0)
#define spin_lock(lock) do {} while (0) #define spin_lock(lock) do {} while (0)
#define spin_unlock(lock) do {} while (0) #define spin_unlock(lock) do {} while (0)
#define spin_lock_irqsave(lock, flags) do { debug("%lu\n", flags); } while (0) #define spin_lock_irqsave(lock, flags) do {} while (0)
#define spin_unlock_irqrestore(lock, flags) do { flags = 0; } while (0) #define spin_unlock_irqrestore(lock, flags) do { flags = 0; } while (0)
#define DEFINE_MUTEX(...) #define DEFINE_MUTEX(...)

View file

@ -29,7 +29,7 @@ enum log_level_t {
LOGL_CRIT, LOGL_CRIT,
/** @LOGL_ERR: Error that prevents something from working */ /** @LOGL_ERR: Error that prevents something from working */
LOGL_ERR, LOGL_ERR,
/** @LOGL_WARNING: Warning may prevent optimial operation */ /** @LOGL_WARNING: Warning may prevent optimal operation */
LOGL_WARNING, LOGL_WARNING,
/** @LOGL_NOTICE: Normal but significant condition, printf() */ /** @LOGL_NOTICE: Normal but significant condition, printf() */
LOGL_NOTICE, LOGL_NOTICE,
@ -96,8 +96,8 @@ enum log_category_t {
LOGC_DEVRES, LOGC_DEVRES,
/** @LOGC_ACPI: Advanced Configuration and Power Interface (ACPI) */ /** @LOGC_ACPI: Advanced Configuration and Power Interface (ACPI) */
LOGC_ACPI, LOGC_ACPI,
LOGC_BOOT, /* Related to boot process / boot image processing */ /** @LOGC_BOOT: Related to boot process / boot image processing */
LOGC_BOOT,
/** @LOGC_COUNT: Number of log categories */ /** @LOGC_COUNT: Number of log categories */
LOGC_COUNT, LOGC_COUNT,
/** @LOGC_END: Sentinel value for lists of log categories */ /** @LOGC_END: Sentinel value for lists of log categories */
@ -322,7 +322,7 @@ void __assert_fail(const char *assertion, const char *file, unsigned int line,
* *
* Members marked as 'not allocated' are stored as pointers and the caller is * Members marked as 'not allocated' are stored as pointers and the caller is
* responsible for making sure that the data pointed to is not overwritten. * responsible for making sure that the data pointed to is not overwritten.
* Memebers marked as 'allocated' are allocated (e.g. via strdup()) by the log * Members marked as 'allocated' are allocated (e.g. via strdup()) by the log
* system. * system.
* *
* TODO(sjg@chromium.org): Compress this struct down a bit to reduce space, e.g. * TODO(sjg@chromium.org): Compress this struct down a bit to reduce space, e.g.
@ -379,7 +379,7 @@ struct log_driver {
* the run-time aspects of drivers (currently just a list of filters to apply * the run-time aspects of drivers (currently just a list of filters to apply
* to records send to this device). * to records send to this device).
* *
* @next_filter_num: Seqence number of next filter filter added (0=no filters * @next_filter_num: Sequence number of next filter filter added (0=no filters
* yet). This increments with each new filter on the device, but never * yet). This increments with each new filter on the device, but never
* decrements * decrements
* @flags: Flags for this filter (enum log_device_flags) * @flags: Flags for this filter (enum log_device_flags)
@ -412,7 +412,7 @@ enum log_filter_flags {
}; };
/** /**
* struct log_filter - criterial to filter out log messages * struct log_filter - criteria to filter out log messages
* *
* If a message matches all criteria, then it is allowed. If LOGFF_DENY is set, * If a message matches all criteria, then it is allowed. If LOGFF_DENY is set,
* then it is denied instead. * then it is denied instead.

View file

@ -848,7 +848,6 @@ CONFIG_IRAM_STACK
CONFIG_IRAM_TOP CONFIG_IRAM_TOP
CONFIG_IRDA_BASE CONFIG_IRDA_BASE
CONFIG_IS_ENABLED CONFIG_IS_ENABLED
CONFIG_JFFS2_CMDLINE
CONFIG_JFFS2_DEV CONFIG_JFFS2_DEV
CONFIG_JFFS2_LZO CONFIG_JFFS2_LZO
CONFIG_JFFS2_NAND CONFIG_JFFS2_NAND