diff options
author | Claudio Carvalho <cclaudio@linux.vnet.ibm.com> | 2017-12-09 02:52:15 -0200 |
---|---|---|
committer | Stewart Smith <stewart@linux.vnet.ibm.com> | 2017-12-18 21:30:57 -0600 |
commit | 4fb528b394115ff8dd832b980032d7656aece099 (patch) | |
tree | f6ca6c31c34b6e37ca6998938ae154af9b805cc3 /libstb | |
parent | b7b7b84ef565380a22dd636cd22d0622e360c440 (diff) | |
download | skiboot-4fb528b394115ff8dd832b980032d7656aece099.zip skiboot-4fb528b394115ff8dd832b980032d7656aece099.tar.gz skiboot-4fb528b394115ff8dd832b980032d7656aece099.tar.bz2 |
libstb: move drivers/sha512.* to mbedtls directory
The drivers/sha512.c file is a SHA512 hash implementation imported from
the mbed TLS project.
As a matter of semantics, this moves drivers/sha512.* to the mbedtls
directory.
Signed-off-by: Claudio Carvalho <cclaudio@linux.vnet.ibm.com>
Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'libstb')
-rw-r--r-- | libstb/Makefile.inc | 3 | ||||
-rw-r--r-- | libstb/drivers/Makefile.inc | 2 | ||||
-rw-r--r-- | libstb/drivers/sw_driver.c | 2 | ||||
-rw-r--r-- | libstb/mbedtls/Makefile.inc | 11 | ||||
-rw-r--r-- | libstb/mbedtls/sha512.c (renamed from libstb/drivers/sha512.c) | 0 | ||||
-rw-r--r-- | libstb/mbedtls/sha512.h (renamed from libstb/drivers/sha512.h) | 0 |
6 files changed, 15 insertions, 3 deletions
diff --git a/libstb/Makefile.inc b/libstb/Makefile.inc index 64be4d6..0122ca2 100644 --- a/libstb/Makefile.inc +++ b/libstb/Makefile.inc @@ -8,10 +8,11 @@ LIBSTB_SRCS = container.c rom.c tpm_chip.c stb.c LIBSTB_OBJS = $(LIBSTB_SRCS:%.c=%.o) LIBSTB = $(LIBSTB_DIR)/built-in.o +include $(SRC)/$(LIBSTB_DIR)/mbedtls/Makefile.inc include $(SRC)/$(LIBSTB_DIR)/drivers/Makefile.inc include $(SRC)/$(LIBSTB_DIR)/tss/Makefile.inc -$(LIBSTB): $(LIBSTB_OBJS:%=$(LIBSTB_DIR)/%) $(DRIVERS) $(TSS) +$(LIBSTB): $(LIBSTB_OBJS:%=$(LIBSTB_DIR)/%) $(DRIVERS) $(TSS) $(MBEDTLS) libstb/create-container: libstb/create-container.c $(call Q, HOSTCC ,$(HOSTCC) $(HOSTCFLAGS) \ diff --git a/libstb/drivers/Makefile.inc b/libstb/drivers/Makefile.inc index d0f88ea..9eaa257 100644 --- a/libstb/drivers/Makefile.inc +++ b/libstb/drivers/Makefile.inc @@ -4,7 +4,7 @@ DRIVERS_DIR = libstb/drivers SUBDIRS += $(DRIVERS_DIR) -DRIVERS_SRCS = romcode.c tpm_i2c_interface.c tpm_i2c_nuvoton.c sw_driver.c sha512.c +DRIVERS_SRCS = romcode.c tpm_i2c_interface.c tpm_i2c_nuvoton.c sw_driver.c DRIVERS_OBJS = $(DRIVERS_SRCS:%.c=%.o) DRIVERS = $(DRIVERS_DIR)/built-in.o diff --git a/libstb/drivers/sw_driver.c b/libstb/drivers/sw_driver.c index e7f3740..287dae9 100644 --- a/libstb/drivers/sw_driver.c +++ b/libstb/drivers/sw_driver.c @@ -17,8 +17,8 @@ #include <chip.h> #include <string.h> #include <skiboot.h> +#include <libstb/mbedtls/sha512.h> #include "../rom.h" -#include "sha512.h" #include "sw_driver.h" static sha2_hash_t *hw_key_hash = NULL; diff --git a/libstb/mbedtls/Makefile.inc b/libstb/mbedtls/Makefile.inc new file mode 100644 index 0000000..07aa26a --- /dev/null +++ b/libstb/mbedtls/Makefile.inc @@ -0,0 +1,11 @@ +# -*-Makefile-*- + +MBEDTLS_DIR = libstb/mbedtls + +SUBDIRS += $(MBEDTLS_DIR) + +MBEDTLS_SRCS = sha512.c +MBEDTLS_OBJS = $(MBEDTLS_SRCS:%.c=%.o) +MBEDTLS = $(MBEDTLS_DIR)/built-in.o + +$(MBEDTLS): $(MBEDTLS_OBJS:%=$(MBEDTLS_DIR)/%) diff --git a/libstb/drivers/sha512.c b/libstb/mbedtls/sha512.c index a133795..a133795 100644 --- a/libstb/drivers/sha512.c +++ b/libstb/mbedtls/sha512.c diff --git a/libstb/drivers/sha512.h b/libstb/mbedtls/sha512.h index 627694f..627694f 100644 --- a/libstb/drivers/sha512.h +++ b/libstb/mbedtls/sha512.h |