summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2019-12-03blk: Make use of CONFIG_HAVE_BLOCK_DEVICE moreTom Rini3-4/+2
When we do not have CONFIG_BLK (or SPL/TPL) enabled there are very few cases where we need the blk_legacy code linked in. To catch these, build when we have CONFIG_HAVE_BLOCK_DEVICE set. In addition, we only need cmd/blk_common.o to be linked in when we have CONFIG_HAVE_BLOCK_DEVICE set, so make use of that directly. Signed-off-by: Tom Rini <trini@konsulko.com>
2019-12-03mtd: mtdcore: Drop unused mtd_tableTom Rini1-2/+0
The array 'mtd_table' is unused in the code. Remove this as gcc doesn't always discard unused global variables. Signed-off-by: Tom Rini <trini@konsulko.com>
2019-12-03pci: Only link pci_rom.o in some casesTom Rini1-2/+2
The content of pci_rom.c is only used in a few cases. Only build and link in these cases to avoid a global variable as gcc doesn't always discard those when they are unused. Signed-off-by: Tom Rini <trini@konsulko.com>
2019-12-03Convert CONFIG_SYS_CORTINA_FW_IN_MMC et al to KconfigTom Rini9-12/+26
This converts the following to Kconfig: CONFIG_SYS_CORTINA_FW_IN_MMC CONFIG_SYS_CORTINA_FW_IN_NAND CONFIG_SYS_CORTINA_FW_IN_NOR CONFIG_SYS_CORTINA_FW_IN_REMOTE CONFIG_SYS_CORTINA_FW_IN_SPIFLASH Signed-off-by: Tom Rini <trini@konsulko.com>
2019-12-03Convert CONFIG_PHY_CORTINA to KconfigTom Rini20-3/+17
This converts the following to Kconfig: CONFIG_PHY_CORTINA Signed-off-by: Tom Rini <trini@konsulko.com>
2019-12-03bootm: vxworks: Support Linux compatible standard DTB for ARM and PPCLihua Zhao3-2/+53
Enhance do_bootm_vxworks() to support Linux compatible standard DTB for ARM and PPC, when the least significant bit of flags in VxWorks bootargs is set. Otherwise it falls back to the existing bootm flow which is now legacy. Signed-off-by: Lihua Zhao <lihua.zhao@windriver.com> Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
2019-12-03tbs2910: Disable VxWorks image booting supportTom Rini1-0/+1
There are currently no known users of this functionality on this platform, disable it to prepare for additional VxWorks functionality that would cause this platform to fail to link. Cc: Soeren Moch <smoch@web.de> Signed-off-by: Tom Rini <trini@konsulko.com> Acked-by: Soeren Moch <smoch@web.de>
2019-12-03cosmetic: Fix spelling and whitespace errorsThomas Hebb14-26/+28
Signed-off-by: Thomas Hebb <tommyhebb@gmail.com>
2019-12-03Makefile: add Rockchip idbloader.img to CLEAN_FILESThomas Hebb1-1/+2
This file is generated in the root during Rockchip builds and so should be cleaned up. Signed-off-by: Thomas Hebb <tommyhebb@gmail.com> Reviewed-by: Michael Trimarchi <michael@amarulasolutions.com>
2019-12-03Makefile: consolidate hardcoded lists of files to cleanThomas Hebb1-3/+2
Currently, we have two places where we list files that should always be cleaned if they exist. One, the CLEAN_FILES variable, is from the Linux build system and is the proper place to list files. The other, a set of extra arguments passed in the xargs template used to remove files with certain extensions, was introduced by 8f06f0cee3d3 ("Makefile: clean image.map") and is clearly wrong: by extending the xargs template, we attempt to remove the files once for each batch of arguments that xargs produces and we reduce the number of files from stdin that xargs can include in each of its rm commands. To fix this, put all hardcoded files into CLEAN_FILES. Signed-off-by: Thomas Hebb <tommyhebb@gmail.com>
2019-12-03Makefile: don't try to construct CLEAN_FILES based on configThomas Hebb1-3/+3
All of the clean targets (clean, dist-clean, mrproper) are run without loading a configuration. That means that any conditional modification of CLEAN_FILES will either always apply or never apply and so shouldn't be in a conditional in the first place. Since CLEAN_FILES is allowed to list nonexistent files, just add everything to it unconditionally to fix the issue. Signed-off-by: Thomas Hebb <tommyhebb@gmail.com>
2019-12-03Kconfig: make TPL_DM_SERIAL depend on TPL_DMThomas Hebb1-1/+1
This missing dependency seems like an oversight, since all other TPL_DM_* options have it. Signed-off-by: Thomas Hebb <tommyhebb@gmail.com>
2019-12-03Kconfig: disambiguate config names for tiny printfThomas Hebb1-2/+2
27084c03d36a ("spl: Allow tiny printf() to be controlled in SPL and TPL") split this option in two for TPL and SPL, but didn't change the Kconfig names, making them hard to set quickly. Signed-off-by: Thomas Hebb <tommyhebb@gmail.com>
2019-12-03Prepare v2020.01-rc4Tom Rini1-1/+1
Signed-off-by: Tom Rini <trini@konsulko.com>
2019-12-03Merge branch '2019-12-02-master-imports'Tom Rini836-465/+1598
- A large series of clean-ups to reduce common.h contents
2019-12-03common: Move old EEPROM functions into a new headerSimon Glass19-15/+41
These functions do not use driver model but are still used. Move them to a new eeprom.h header file. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Drop get_endaddr()Simon Glass1-1/+0
This is not used in U-Boot. Drop it. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Move trap_init() out of common.hSimon Glass4-1/+4
Move this function into the init.h header file. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com> Reviewed-by: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
2019-12-03common: Move pci_init_board() out of common.hSimon Glass49-2/+50
This function can be dropped when all boards use driver model for PCI. For now, move it into init.h with a comment. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Move some board functions out of common.hSimon Glass188-8/+195
A number of board function belong in init.h with the others. Move them. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Move board_get_usable_ram_top() out of common.hSimon Glass28-13/+44
Move this function into init.h which seems to be designed for this sort of thing. Also update the header to declare struct global_data so that it can be included without global_data.h being needed. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Drop board_show_dram()Simon Glass2-16/+2
This function is not defined by any boards so the feature is not used. Drop it. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Move command functions out of common.hSimon Glass23-16/+38
Move these functions into the command.h header file which is a better fit. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Move enable/disable_interrupts out of common.hSimon Glass61-7/+69
Move these two functions into the irq_funcs.h header file. Also move interrupt_handler_t as this is used by the irq_install_handler() function. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Move interrupt functions into a new headerSimon Glass42-7/+60
These functions do not use driver model but are fairly widely used in U-Boot. But it is not clear that they will use driver model anytime soon, so we don't want to label them as 'legacy'. Move them to a new irq_func.h header file. Avoid the name 'irq.h' since it is widely used in U-Boot already. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03arm: powerpc: Tidy up code style for interrupt functionsSimon Glass14-35/+35
Remove the unwanted space before the bracket. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Move ARM cache operations out of common.hSimon Glass135-24/+159
These functions are CPU-related and do not use driver model. Move them to cpu_func.h Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Daniel Schwierzeck <daniel.schwierzeck@gmail.com> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Drop checkicache() and checkdcache()Simon Glass2-67/+65
These are used by only one arch and only within a single file. Drop the declarations from the common file. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Move some cache and MMU functions out of common.hSimon Glass94-9/+101
These functions belong in cpu_func.h. Another option would be cache.h but that code uses driver model and we have not moved these cache functions to use driver model. Since they are CPU-related it seems reasonable to put them here. Move them over. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03arm: powerpc: Tidy up code style for cache functionsSimon Glass6-24/+28
Remove the unwanted space before the bracket. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Move some SMP functions out of common.hSimon Glass12-3/+13
These functions belong in cpu_func.h so move them over. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Move checkcpu() out of common.hSimon Glass17-1/+44
This function belongs in cpu_func.h so move it over. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Drop cpu_init()Simon Glass1-2/+0
This function is not defined anywhere. Drop it. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Move some CPU functions out of common.hSimon Glass10-20/+9
These functions belong in cpu_func.h since they do not use driver model. Move them over. Don't bother adding comments since these functions should be deleted. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Move mii_init() function out of common.hSimon Glass10-3/+10
This function belongs in mii.h so move it over. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Move get_ticks() function out of common.hSimon Glass68-5/+78
This function belongs in time.h so move it over and add a comment. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Move timer_get_us() function out of common.hSimon Glass2-3/+7
This function belongs in time.h so move it over and update the comment style. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03arm: pxa: Drop pxa_wait_ticks()Simon Glass1-8/+4
This function has a similar name to the common wait_ticks(). It is only used in one place and seems small enough to drop. Inline it. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Move wait_ticks functions out of common.hSimon Glass3-1/+11
This function belongs in time.h so move it over and add a comment. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Move some time functions out of common.hSimon Glass12-4/+26
These functions belong in time.h so move them over and add comments. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Add a new lz4.h header fileSimon Glass5-3/+27
Add a header file to house the lz4 compression function. Add a comment while we are here, since it not even clear from the name what the function actuall does. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Move serial functions out of common.hSimon Glass34-9/+40
These functions belong in serial.h so move them over. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Move serial_printf() to the serial headerSimon Glass8-8/+18
Move this function header to serial.h since this function is clearly related to serial. The function itself stays in console.c since we don't have a single serial file. DM and non-DM each has a separate file so we would have to either create a new common serial file, or repeat the function in both serial.c and serial-uclass.c, neither of which seem worthwhile. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03serial: usb: Correct the usbtty_...() prototypesSimon Glass2-8/+11
The function declarations in serial.h are not in sync with what is currently used in usbtty. Fix this by updating the header and including it, to help catch future such problems. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Move env_get_ip() to net.hSimon Glass2-5/+20
This function relates to networking, so move it out of the common.h header file. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com> Acked-by: Joe Hershberger <joe.hershberger@ni.com>
2019-12-03Move strtomhz() to vsprintf.hSimon Glass50-26/+76
At present this function sits in its own file but it does not really justify it. There are similar string functions in vsprintf.h, so move it there. Also add the missing function comment. Use the vsprintf.h include file explicitly where needed. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Move sorting functions to their own header fileSimon Glass8-5/+40
These don't need to be in common.h so move them out into a new header. Also add some missing comments. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03common: Move bootcount functions to their header fileSimon Glass3-4/+11
These don't need to be in common.h so move them out. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03spl: bootcount: Move code out of header fileSimon Glass2-4/+11
It is not good practice to write code in a header file. If it is included multiple times then the code can cause duplicate functions. Move the bootcount_store() and bootcount_load() functions into SPL. Note: bootcount is a bit strange in that it uses driver model but does not define proper drivers. This should be fixed. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-12-03crc32: Use the crc.h header for crc functionsSimon Glass65-5/+63
Drop inclusion of crc.h in common.h and use the correct header directly instead. With this we can drop the conflicting definition in fw_env.h and rely on the crc.h header, which is already included. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>