19 Apr, 2014
1 commit
-
Tegra's crypto.c uses apply_cbc_chain_data() to sign the warm restart
code. This function was recently moved into the core aes.c and made
static, which prevents the Tegra code from compiling. Make it public
again to avoid the compile errors:arch/arm/cpu/tegra20-common/crypto.c: In function ‘sign_object’:
arch/arm/cpu/tegra20-common/crypto.c:74:3: warning: implicit declaration of function ‘apply_cbc_chain_data’ [-Wimplicit-function-declaration]
arch/arm/cpu/built-in.o: In function `sign_object':
.../arch/arm/cpu/tegra20-common/crypto.c:74: undefined reference to `apply_cbc_chain_data'
.../arch/arm/cpu/tegra20-common/crypto.c:78: undefined reference to `apply_cbc_chain_data'Fixes: 6e7b9f4fa0ae ("aes: Move the AES-128-CBC encryption function to common code")
Signed-off-by: Stephen Warren
Reviewed-by: Simon Glass
Acked-by: Marek Vasut
18 Apr, 2014
1 commit
08 Apr, 2014
1 commit
-
Conflicts:
arch/arm/cpu/arm926ejs/mxs/Makefile
include/configs/trats.h
include/configs/trats2.h
include/mmc.h
03 Apr, 2014
5 commits
-
Changes:
- randomly generate partition uuid if any is undefined and CONFIG_RAND_UUID
is defined
- print debug info about set/unset/generated uuid
- update doc/README.gptSigned-off-by: Przemyslaw Marczak
Acked-by: Lukasz Majewski
Cc: Piotr Wilczek
Cc: Tom Rini
Cc: Stephen Warren
Cc: Lukasz Majewski -
Those commands basis on implementation of random UUID generator version 4
which is described in RFC4122. The same algorithm is used for generation
both ids but string representation is different as below.char: 0 9 14 19 24 36
xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
UUID: be be be be be
GUID: le le le be beCommands usage:
- uuid []
- guid []The result is saved in environment as a "varname" variable if argument is given,
if not then it is printed.New config:
- CONFIG_CMD_UUIDSigned-off-by: Przemyslaw Marczak
Cc: Stephen Warren
Cc: Lukasz Majewski
Cc: trini@ti.com -
This patch adds support to generate UUID (Universally Unique Identifier)
in version 4 based on RFC4122, which is randomly.Source: https://www.ietf.org/rfc/rfc4122.txt
Changes:
- new configs:
- CONFIG_LIB_UUID for compile lib/uuid.c
- CONFIG_RANDOM_UUID for functions gen_rand_uuid() and gen_rand_uuid_str()
- add configs dependency to include/config_fallbacks.h for lib uuid.lib/uuid.c:
- add gen_rand_uuid() - this function writes 16 bytes len binary representation
of UUID v4 to the memory at given address.- add gen_rand_uuid_str() - this function writes 37 bytes len hexadecimal
ASCII string representation of UUID v4 to the memory at given address.Signed-off-by: Przemyslaw Marczak
Cc: Stephen Warren
Cc: Lukasz Majewski
[trini: Add CONFIG_EFI_PARTITION to fallbacks]
Signed-off-by: Tom Rini -
Changes in lib/uuid.c to:
- uuid_str_to_bin()
- uuid_bin_to_str()New parameter is added to specify input/output string format in listed functions
This change allows easy recognize which UUID type is or should be stored in given
string array. Binary data of UUID and GUID is always stored in big endian, only
string representations are different as follows.String byte: 0 36
String char: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
string UUID: be be be be be
string GUID: le le le be beThis patch also updates functions calls and declarations in a whole code.
Signed-off-by: Przemyslaw Marczak
Cc: Stephen Warren
Cc: Lukasz Majewski
Cc: trini@ti.com -
This commit introduces cleanup for uuid library.
Changes:
- move uuidstring conversion functions into lib/uuid.c so they can be
used by code outside part_efi.c.
- rename uuid_string() to uuid_bin_to_str() for consistency with existing
uuid_str_to_bin()
- add an error return code to uuid_str_to_bin()
- update existing code to the new library functions.Signed-off-by: Przemyslaw Marczak
Cc: Stephen Warren
Cc: Lukasz Majewski
Cc: trini@ti.com
29 Mar, 2014
2 commits
-
New configs:
- CONFIG_LIB_RAND - to enable implementation of rand library in lib/rand.c
- CONFIG_LIB_HW_RAND - to enable hardware based implementations of lib randOther changes:
- add CONFIG_LIB_RAND to boards configs which needs rand()
- put only one rand.o dependency in lib/MakefileCONFIG_LIB_HW_RAND should be defined for drivers which implements rand library
(declared in include/common.h):
- void srand(unsigned int seed)
- unsigned int rand(void)
- unsigned int rand_r(unsigned int *seedp)Signed-off-by: Przemyslaw Marczak
Cc: Michael Walle
Cc: Tom Rini
Cc: Masahiro Yamada -
Since TIZEN group has been used 450 X 140 bmp logo for lunchbox,
this patch tries to change the logo size from 500 X 150 to official size.
By reducing image size, we also save about 35KB.To make row aligned 4 bytes, add 2 pixels to row. Therefore the real width
of image size is 452.Signed-off-by: Jonghwa Lee
Reviewed-by : Przemyslaw Marczak
25 Mar, 2014
1 commit
-
Trivial merge conflict, needed to manually remove
local_info as per commit 41364f0f.Conflicts:
board/samsung/common/board.c
22 Mar, 2014
7 commits
-
Implement support for encrypting/decrypting the environment block
into the tools/env/fw_* tools. The cipher used is AES 128 CBC and
the implementation depends solely on components internal to U-Boot.To allow building against the internal AES library, the library did
need minor adjustments to not include U-Boot's headers which are not
wanted to be included and define missing types.Signed-off-by: Marek Vasut
-
Implement a compatible AES-128-CBC decryption function as a counterpart
of the encryption function pulled from tegra20-common/crypto.c .Signed-off-by: Marek Vasut
-
Move the AES-128-CBC encryption function implemented in
tegra20-common/crypto.c into lib/aes.c . This is well re-usable common
code. Moreover, clean the code up a bit and fix the kerneldoc-style
annotations.Signed-off-by: Marek Vasut
-
add host tool "fit_check_sign" which verifies, if a fit image is
signed correct.Signed-off-by: Heiko Schocher
Cc: Simon Glass -
Add support for sha256,rsa4096 signatures in u-boot.
Signed-off-by: Heiko Schocher
Acked-by: Simon Glass
Cc: andreas@oetken.name -
based on patch from andreas@oetken.name:
http://patchwork.ozlabs.org/patch/294318/
commit message:
I currently need support for rsa-sha256 signatures in u-boot and found out that
the code for signatures is not very generic. Thus adding of different
hash-algorithms for rsa-signatures is not easy to do without copy-pasting the
rsa-code. I attached a patch for how I think it could be better and included
support for rsa-sha256. This is a fast first shot.aditionally work:
- removed checkpatch warnings
- removed compiler warnings
- rebased against current headSigned-off-by: Heiko Schocher
Cc: andreas@oetken.name
Cc: Simon Glass -
add sha256 support to fit images
Signed-off-by: Heiko Schocher
Acked-by: Simon Glass
18 Mar, 2014
3 commits
-
Add a simple LCD driver which uses SDL to display the image. We update the
image regularly, while still providing for reasonable performance.Adjust the common lcd code to support sandbox.
For command-line runs we do not want the LCD to be displayed, so add a
--show_lcd option to enable it.Tested-by: Che-Liang Chiou
Signed-off-by: Simon Glass -
Add a simple emulation of the Chrome OS EC for sandbox, so that it can
perform various EC tasks such as keyboard handling.Reviewed-by: Vadim Bendebury
Signed-off-by: Simon Glass -
A flash map describes the layout of flash memory in terms of offsets and
sizes for each region. Add a function to read a flash map entry from the
device tree.Reviewed-by: Che-Liang Chiou
Signed-off-by: Simon Glass
12 Mar, 2014
2 commits
-
This patch enables support for device tree for sdhci driver.
Non DT case is still supported.Signed-off-by: Piotr Wilczek
Signed-off-by: Kyungmin Park
Signed-off-by: Minkyu Kang -
This patch enables parsing mipi data from device tree.
Non device tree case is still supported.Signed-off-by: Piotr Wilczek
Signed-off-by: Kyungmin Park
Signed-off-by: Minkyu Kang
07 Mar, 2014
1 commit
-
Many (but not all) of Blackfin boards give -O2 option
to compile under lib/ directory.
That means lib/ should be speed-optimized,
whereas other parts should be size-optimized.We want to keep the same behavior,
but do not want to parse board/*/config.mk again and again.
We've got no choice but to invent a new method.CONFIG_CC_OPTIMIZE_LIBS_FOR_SPEED, if it is enabled,
gives -O2 flag only for building under lib/ directory.Dirty codes which I had marked as "FIX ME"
in board/${BOARD}/config.mk have been deleted.
Instead, CONFIG_CC_OPTIMIZE_LIBS_FOR_SPEED has been
defined in include/configs/${BOARD}.h.Signed-off-by: Masahiro Yamada
Cc: Sonic Zhang
05 Mar, 2014
1 commit
-
Add 64-bit data for memory commands, such as md, mw, mm, cmp. The new
size ".q " is introduced.For 64-bit architecture, 64-bit data is enabled by default, by detecting
compiler __LP64__. It is optional for other architectures.Signed-off-by: York Sun
27 Feb, 2014
1 commit
-
When we tell the compiler to optimize for ARMv7 (and ARMv6 for that
matter) it assumes a default of SCTRL.A being cleared and unaligned
accesses being allowed and fast at the hardware level. We set this bit
and must pass along -mno-unaligned-access so that the compiler will
still breakdown accesses and not trigger a data abort.To better help understand the requirements of the project with respect
to unaligned memory access, the
Documentation/unaligned-memory-access.txt file has been added as
doc/README.unaligned-memory-access.txt and is taken from the v3.14-rc1
tag of the kernel.Cc: Albert ARIBAUD
Cc: Mans Rullgard
Signed-off-by: Tom Rini
20 Feb, 2014
2 commits
-
Now we are ready to switch over to real Kbuild.
This commit disables temporary scripts:
scripts/{Makefile.build.tmp, Makefile.host.tmp}
and enables real Kbuild scripts:
scripts/{Makefile.build,Makefile.host,Makefile.lib}.This switch is triggered by the line in scripts/Kbuild.include
-build := -f $(if $(KBUILD_SRC),$(srctree)/)scripts/Makefile.build.tmp obj
+build := -f $(if $(KBUILD_SRC),$(srctree)/)scripts/Makefile.build objWe need to adjust some build scripts for U-Boot.
But smaller amount of modification is preferable.Additionally, we need to fix compiler flags which are
locally added or removed.In Kbuild, it is not allowed to change CFLAGS locally.
Instead, ccflags-y, asflags-y, cppflags-y,
CFLAGS_$(basetarget).o, CFLAGS_REMOVE_$(basetarget).o
are prepared for that purpose.Signed-off-by: Masahiro Yamada
Tested-by: Gerhard Sittig -
This commit changes the working directory
where the build process occurs.Before this commit, build process occurred under the source
tree for both in-tree and out-of-tree build.That's why we needed to add $(obj) prefix to all generated
files in makefiles like follows:
$(obj)u-boot.bin: $(obj)u-bootHere, $(obj) is empty for in-tree build, whereas it points
to the output directory for out-of-tree build.And our old build system changes the current working directory
with "make -C " syntax when descending into the
sub-directories.On the other hand, Kbuild uses a different idea
to handle out-of-tree build and directory descending.The build process of Kbuild always occurs under the output tree.
When "O=dir/to/store/output/files" is given, the build system
changes the current working directory to that directory and
restarts the make.Kbuild uses "make -f $(srctree)/scripts/Makefile.build obj="
syntax for descending into sub-directories.
(We can write it like "make $(obj)=" with a shorthand.)
This means the current working directory is always the top
of the output directory.Signed-off-by: Masahiro Yamada
Tested-by: Gerhard Sittig
13 Feb, 2014
1 commit
04 Feb, 2014
1 commit
-
Tegra124's MMC controller is very similar to earlier SoC generations,
and can be supported by the same driver.However, there are some non-backwards-compatible HW differences, and
hence a new DT compatible value must be used to describe the HW. This
patch updates the driver to support that new compatible value.That said, the HW differences are only relevant when enabling certain
high-performance transfer modes. Since the driver is currently very
simple and doesn't enable those modes, we don't actually need to address
any of these HW differences in the code yet, hence the simple nature of
this patch.Signed-off-by: Stephen Warren
Acked-by: Pantelis Antoniou
Tested-by: Thierry Reding
Acked-by: Simon Glass
Signed-off-by: Tom Warren
03 Feb, 2014
1 commit
-
Changes:
- check image bpp instead of resolution when returns logo address
- remove 32bpp logo
- add 16bpp logo in two formats: bmp and gzipped bmp
- init logo address with "0" for unsupported bpp mode
- update boards configs with proper image size for gunzip
- extend structure vidinfo by two fields: logo_x_offset and logo_y_offset.Signed-off-by: Przemyslaw Marczak
Tested-by: Hyungwon Hwang
Signed-off-by: Minkyu Kang
25 Jan, 2014
2 commits
-
When CONFIG_SYS_VSNPRINTF is enabled, it protects print operations
such as sprintf, snprintf, vsnprintf, etc., from buffer overflows.
But vsnprintf_internal includes the terminating NULL character in
the calculation of number of characters written. This affects sprintf
and snprintf return values. Fix this issue by setting pointer 'str'
back to the location of the '\0'.Signed-off-by: Darwin Rambo
Reviewed-by: Steve Rae -
If timer_init() is made a weak stub function, then it allows us to
remove several empty timer_init functions for those boards that
already have a timer initialized when u-boot starts. Architectures
that use the timer framework may also remove the need for timer.c.Signed-off-by: Darwin Rambo
Reviewed-by: Tim Kryger
14 Jan, 2014
1 commit
-
Variable uncompressedSize references the space available, while outSizeFull is
the actual expected uncompressed size. Using the wrong value causes LzmaDecode
to return SZ_ERROR_INPUT_EOF. Problem was introduced in commit afca294. While
at it add additional debug message.Signed-off-by: Antonios Vamporakis
CC: Kees Cook
CC: Simon Glass
CC: Daniel Schwierzeck
CC: Luka Perkov
09 Jan, 2014
1 commit
-
Add an implementation of the CRC8 algorithm. This is required by the TPM
emulation, but is probably useful to U-Boot in general.Signed-off-by: Simon Glass
Signed-off-by: Simon Glass
Reviewed-by: Simon Glass
13 Dec, 2013
1 commit
-
Commit 8dfafdde88eb ("Introduce common timer functions") created a
common definition of usec_to_tick() which had a couple problems:static unsigned long long usec_to_tick(unsigned long usec)
{
uint64_t tick = usec * get_tbclk();That likely overflows.
usec *= get_tbclk();
That was an attempt to fix it by performing the multiply after the
promotion of usec to 64-bit, but was applied to the wrong variable,
which was never used.This patch fixes these issues. A user-visible symptom of the problem was
the e.g. "dhcp zImage" using an ASIX USB Ethernet dongle would print:Waiting for Ethernet connection... unable to connect.
... with no delay before "unable to connect". There are likely other
symptoms.Signed-off-by: Stephen Warren
Acked-by: Rob Herring
25 Nov, 2013
2 commits
-
Signed-off-by: Masahiro Yamada
22 Nov, 2013
1 commit
-
There are a few wwrnings in this file when building for sandbox. Addresses
coming from the device tree need to be treated as ulong as elsewhere in
U-Boot and we must use map_sysmem() to convert to a pointer when needed.Signed-off-by: Simon Glass
Signed-off-by: Simon Glass
Reviewed-by: Hung-ying Tyan
18 Nov, 2013
1 commit
-
Signed-off-by: Masahiro Yamada