08 Dec, 2017
11 commits
-
Add a command which exercises the logging system.
Signed-off-by: Simon Glass
-
Add a command for adjusting the log level.
Signed-off-by: Simon Glass
Reviewed-by: Bin Meng -
It is useful to display log messages on the console. Add a simple driver
to handle this.Note that this driver outputs to the console, which may be serial or
video. It does not specifically select serial output.Signed-off-by: Simon Glass
Reviewed-by: Bin Meng -
Add the logging header file and implementation with some configuration
options to control it.Signed-off-by: Simon Glass
-
This does not appear to be used by any boards. Before introducing a new
log system, remove this old one.Signed-off-by: Simon Glass
Reviewed-by: Bin Meng -
With clang this gives a warning because hubsts appears to be used before
it is set, even if ultimately it is not used. Simplify the code to avoid
this problem.Signed-off-by: Simon Glass
-
The debug() macro now evaluates its expression so does not need #ifdef
protection. In fact the current code causes a warning with the new log
implementation. Adjust the code to fix this.Signed-off-by: Simon Glass
Reviewed-by: Bin Meng -
Before adding new features, move these definitions to a separate header
to avoid further cluttering common.h.Signed-off-by: Simon Glass
Reviewed-by: Bin Meng -
While sandbox works OK without the special-case code, it does result in
console output being stored in the pre-console buffer while sandbox starts
up. If there is a crash or a problem then there is no indication of what
is going on.For ease of debugging it seems better to revert this change also.
This reverts commit d8c6fb8cedbc35eee27730a7fa544e499b3c81cc.
Signed-off-by: Simon Glass
-
We cannot use sandbox memory at 0 since other things use memory at that
address. Move it up out of the way.Note that the pre-console buffer is currently disabled with sandbox, but
this change will avoid confusion if it is manually enabled.Signed-off-by: Simon Glass
-
While sandbox works OK without the special-case code, it does result in
console output being stored in the pre-console buffer while sandbox starts
up. If there is a crash or a problem then there is no indication of what
is going on.For ease of debugging it seems better to revert this change.
This reverts commit 47b98ad0f6779485d0f0c14f337c3eece273eb54.
Signed-off-by: Simon Glass
07 Dec, 2017
8 commits
-
sdram sub command of i2c command does not support Drivers Model.
This adds Drivers Model support to sdram sub command.Signed-off-by: Nobuhiro Iwamatsu
Reviewed-by: Simon Glass
Reviewed-by: Heiko Schocher -
The .probe_chip function is supposed to probe an i2c device on the bus to
determine whether a device is answering to a particular address.
at91_i2c_probe_chip() did not do anything resembling this and always
returned 0.It looks as though at91_i2c_probe_chip() was intended to be a .probe
function for the controller, as it was copied-and-pasted to become
at91_i2c_probe() in 0bc8f640a4d7ed.Removing the at91_i2c_probe_chip() function makes the higher layer
(i2c_probe_chip()) try a zero-length read transfer to test for the
presence of a device instead, which does work.Signed-off-by: Alan Ott
Acked-by: Wenyou Yang
Reviewed-by: Heiko Schocher -
The driver must wait for TXRDY after each byte is pushed into
the i2c FIFO before pushing the next byte. Previously this was
not done for the first byte, causing a race condition with zeros
sometimes being sent for the next byte (which is typically the
first actual data byte).Signed-off-by: Alan Ott
Reviewed-by: Heiko Schocher -
Add some comment describing the purpose of struct members and
functions.Signed-off-by: Beniamino Galvani
Reviewed-by: Simon Glass
Reviewed-by: Heiko Schocher -
Change meson_i2c_xfer_msg() to return -EREMOTEIO in case of NACK, as
done by other drivers. Also, don't change the return error in
meson_i2c_xfer().Signed-off-by: Beniamino Galvani
Reviewed-by: Simon Glass
Reviewed-by: Heiko Schocher -
The datasheet doesn't specify a suggested timeout and 500ms seems very
long: reduce it to 100ms.Signed-off-by: Beniamino Galvani
Reviewed-by: Simon Glass
Reviewed-by: Heiko Schocher -
Expand the Kconfig description with hardware features.
Signed-off-by: Beniamino Galvani
Reviewed-by: Simon Glass
Reviewed-by: Heiko Schocher
06 Dec, 2017
3 commits
-
Since commit 2614a208471e ("common: command: tempory buffer should
have size of command line buf"), there have been consistent Travis CI
failures on my builds (interestingly not for Tom, even though building
the same commit id) due to a SEGV in building the byteswapped
omapimage:
arm: pcm051_rev3
make[2]: *** [MLO.byteswap] Error 139
^^^ error code for a SEGVTurns out that the word-based byte-swapping loop in omapimage.c is to
blame. With the loop condition
while (swapped st_size / sizeof(uint32_t)))
there had been one-too-many iterations for all file sizes divisible by
the sizeof(uint32_t). I.e. we had 1 iteration for 0 bytes (and also 1
through 3 bytes) and 2 iterations at 4 bytes... clearly overshooting
on 0 and 4 bytes.This commit fixes the calculation of an up-rounded word-count and
makes sure to keep the zero-based loop-counter below the number of
words to be processed.References: 2614a20 ("common: command: tempory buffer should have size of command line buf")
Fixes: 79b9ebb ("omapimage: Add support for byteswapped SPI images")
Signed-off-by: Philipp Tomsich
Reviewed-by: Martin Elshuber -
Patch queue for efi - 2017-12-05
Highlights for this release:
- Dynamic EFI object creation (lists instead of static arrays)
- EFI selftest improvements
- Minor fixes -
Commit f5a2a93892f ("efi_loader: consistently use efi_uintn_t in boot
services") changed the internal EFI API header without adapting its existing
EFI stub users. Let's adapt the EFI stub as well.Fixes: f5a2a93892f ("efi_loader: consistently use efi_uintn_t in boot services")
Signed-off-by: Alexander Graf
Reviewed-by: Heinrich Schuchardt
05 Dec, 2017
1 commit
-
Signed-off-by: Tom Rini
04 Dec, 2017
17 commits
-
Move the warning to an error as we have been promising would happen in
this release.Signed-off-by: Tom Rini
-
Typo fix: CONIFG->CONFIG
Signed-off-by: Peng Fan
Cc: Tom Rini
Cc: Simon Glass
Reviewed-by: Simon Glass -
In Linux, the warning messages are printed out by pr_warn().
We can use Linux-like log functions in tree-wide.
Signed-off-by: Masahiro Yamada
Reviewed-by: Simon Glass -
[primary] Check MMC 0:1 for /extlinux/extlinux.conf and boot
[fallback 1] Check MMC 0:1 zImage and run mmcbootz
[fallback 2] Check MMC 0:1 uImage and run mmcboot
[fallback 3] Check NAND partitions and run nandbootIf 'extlinux.conf' is not found on MMC 0, the previous boot behavior is
followed.Signed-off-by: Derald D. Woods
-
To page mapping the lowest 2 bits needs to be 0x3.
If not fix this, the final lowest 3 bits for page mapping is 0x1
which is marked as reserved.Signed-off-by: Peng Fan
Reviewed-by: York Sun -
After relocation, when error happends, it is hard to track
ELR and LR with asm file objdumped from elf file.So subtract the gd->reloc_off the reflect the compliation address.
Signed-off-by: Peng Fan
Reviewed-by: Simon Glass -
As discussed at [1], the Amlogic Meson GX SoCs can embed a BL31 firmware
and a secondary BL32 firmware.
Since mid-2017, the reserved memory address of the BL31 firmware was moved
and grown for security reasons.But mainline U-Boot and Linux has the old address and size fixed.
These SoCs have a register interface to get the two firmware reserved
memory start and sizes.This patch adds a dynamic reservation of the memory zones in the device tree bootmem
reserved memory zone used by the kernel in early boot.
To be complete, the memory zones are also added to the EFI reserved zones.Depends on patchset "Add support for Amlogic GXL Based SBCs" at [2].
[1] http://lists.infradead.org/pipermail/linux-amlogic/2017-October/004860.html
[2] http://lists.infradead.org/pipermail/linux-amlogic/2017-November/005410.htmlChanges since v1:
- switched the #if to if(IS_ENABLED()) to compile all code paths
- renamed function to meson_board_add_reserved_memory()
- added a mem.h header with comment
- updated all boards ft_board_setup()Changes since RFC v2:
- reduced preprocessor load
- kept Odroid-C2 static memory mapping as exceptionChanges since RFC v1:
- switch to fdt rsv mem table and efi reserve memory
- replaced in_le32 by readl()Reviewed-by: Simon Glass
Signed-off-by: Neil Armstrong
[trini: Fix warning on khadas-vim over missing
Signed-off-by: Tom Rini -
This adds platform code for the Khadas VIM board based on a
Meson GXL (S905X) SoC with the Meson GXL configuration.This initial submission supports UART, MMC/SDCard and Ethernet with the
Internal RMII PHY.The meson-gxl-s905x-khadas-vim.dts is synchronised from the linux 4.13
stable tree as of 4.13.8.Reviewed-by: Simon Glass
Signed-off-by: Neil Armstrong -
This adds platform code for the Libre Computer CC "Le Potato" board based on a
Meson GXL (S905X) SoC with the Meson GXL configuration.This initial submission supports UART, MMC/SDCard and Ethernet with the
Internal RMII PHY.The meson-gxl-s905x-libretech-cc.dts is synchronised from the linux 4.13
stable tree as of 4.13.8.Reviewed-by: Simon Glass
Signed-off-by: Neil Armstrong -
Switch P212 Ethernet init to the common Ethernet init function.
Reviewed-by: Simon Glass
Signed-off-by: Neil Armstrong -
Switch Odroid-C2 Ethernet init to the common Ethernet init function.
Reviewed-by: Simon Glass
Signed-off-by: Neil Armstrong -
Introduce a generic common Ethernet Hardware init function
common to all Amlogic GX SoCs with support for the
Internal PHY enable for GXL SoCs.Signed-off-by: Neil Armstrong
-
Now, lib/libfdt/fdt_wip.c is the same as scripts/dtc/libfdt/fdt_wip.c
Change the former to a wrapper of the latter.
Signed-off-by: Masahiro Yamada
Reviewed-by: Simon Glass -
All the other fdt_*_region() functions are located in fdt_region.c,
while only fdt_find_regions() was added to fdt_wip.c, strangely.Move it to the suitable place.
Signed-off-by: Masahiro Yamada
Reviewed-by: Simon Glass -
In the moment our exception entry code needs 34 instructions, so we
can't use put it directly into the table entry, which offers "only"
32 instructions there. Right now we just put an unconditional branch
there, then use a macro to place the 34 instructions *per entry* after
that. That effectivly doubles the size of our exception table, which
is quite a waste, given that we use it mostly for debugging purposes.Since the register saving part is actually identical, let's just convert
that macro into a function, and "bl" into it directly from the exception
slot, of course after having saved at least the original LR.
This saves us about 950 bytes of code, which is quite a relief for some
tight SPLs, in particular the 64-bit Allwinner ones.Signed-off-by: Andre Przywara