coreboot/src/lib
Jan Dabros 086c5e6fc8 lib/imd: Fix imdr_recover for small regions
One of the checks inside imdr_recover() was written with the
assumption that imdr limit is always aligned to LIMIT_ALIGN. This is
true only for large allocations, thus may fail for small regions.

It's not necessary to check if root_pointer is under the limit, since
this is implicitly verified by imdr_get_root_pointer().

Signed-off-by: Jan Dabros <jsd@semihalf.com>
Change-Id: I25d6291301797d10c6a267b5f6e56ac38b995b7b
Reviewed-on: https://review.coreboot.org/c/coreboot/+/44667
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Paul Fagerburg <pfagerburg@chromium.org>
2020-08-26 07:33:05 +00:00
..
gnat
asan.c arch/x86: Add support for ASan to memory functions 2020-08-21 07:46:04 +00:00
b64_decode.c
boot_device.c
bootblock.c
bootmem.c lib/bootmem.c: Improve bootmem_allocate_buffer algorithm 2020-07-30 17:13:28 +00:00
bootmode.c
bootsplash.c
cb.ads
cbfs.c drivers/intel/fsp2_0: add option to compress FSP-M in cbfs 2020-05-28 20:33:34 +00:00
cbmem_common.c src: Remove unused 'include <bootstate.h>' 2020-06-02 07:40:35 +00:00
cbmem_console.c
cbmem_stage_cache.c
compute_ip_checksum.c
coreboot_table.c lib/coreboot_table: Add Intel FSP version to coreboot table 2020-07-04 11:20:08 +00:00
crc_byte.c
decompressor.c
delay.c
device_tree.c
dimm_info_util.c
edid.c treewide: Replace CONFIG(ARCH_xx) tests 2020-06-17 21:13:09 +00:00
edid_fill_fb.c
espi_debug.c
ext_stage_cache.c src/lib: Remove unused function parameters in imd.c 2020-08-04 07:13:59 +00:00
fallback_boot.c
fit.c fit: Swap compat matching priorities for board-revX and board-skuY 2020-05-29 20:47:54 +00:00
fit_payload.c
fmap.c lib: Update fmap cache error for psp_verstage 2020-08-21 18:48:06 +00:00
fw_config.c fw_config: Add firmware configuration interface 2020-06-02 16:40:04 +00:00
gcc.c
gcov-glue.c lib/gcov: Remove assert(0) 2020-08-03 10:36:00 +00:00
gcov-io.c
gcov-io.h
gcov-iov.h
gpio.c gpio: Pull down HiZ pins after reading tristate GPIO strapping 2020-08-06 23:54:41 +00:00
halt.c
hardwaremain.c ACPI S3: Clean up resume path 2020-07-28 10:37:28 +00:00
hexdump.c
hexstrtobin.c
hw-time-timer.adb
imd.c lib/imd: Fix imdr_recover for small regions 2020-08-26 07:33:05 +00:00
imd_cbmem.c lib/imd_cbmem.c: Add a helper function to indicate that cbmem is ready 2020-08-17 06:22:58 +00:00
jpeg.c src/lib/jpeg.c: Drop dead code 2020-07-09 23:50:51 +00:00
jpeg.h
Kconfig
libgcc.c treewide: Replace CONFIG(ARCH_xx) tests 2020-06-17 21:13:09 +00:00
libgcov.c lib/libgcov.c: Do not redefine alloca 2020-07-29 09:27:33 +00:00
list.c
lzma.c
lzmadecode.c
lzmadecode.h
Makefile.inc lib: Add ASan support to romstage on x86 arch 2020-08-21 07:41:19 +00:00
malloc.c lib/malloc: Drop <cpu/x86/smm.h> include 2020-06-16 08:09:13 +00:00
memchr.c
memcmp.c
memcpy.c
memmove.c
memrange.c
memset.c
nhlt.c
primitive_memtest.c
prog_loaders.c prog_loaders: Fix ramstage loading on x86 2020-07-06 09:36:15 +00:00
prog_ops.c
program.ld lib: Add ASan support to ramstage on x86 arch 2020-08-21 07:37:52 +00:00
ramdetect.c
ramtest.c treewide: Replace CONFIG(ARCH_xx) tests 2020-06-17 21:13:09 +00:00
reg_script.c lib/reg_script: Add guards for <arch/io.h> 2020-06-17 21:13:36 +00:00
region_file.c
reset.c
rmodule.c
rmodule.ld
romstage_handoff.c
rtc.c
selfboot.c
spd_bin.c
spd_cache.c
stack.c
string.c lib/string: Add standard strstr() function 2020-08-03 05:12:23 +00:00
thread.c
timer.c
timer_queue.c src: Remove unused 'include <stddef.h> 2020-08-18 12:15:44 +00:00
timestamp.c src: Remove unused 'include <stddef.h> 2020-08-18 12:15:44 +00:00
trace.c src: Remove unused 'include <types.h>' 2020-07-14 16:10:17 +00:00
ubsan.c lib/ubsan.c: Update error handlers for current toolchain's GCC 2020-07-31 19:53:27 +00:00
uuid.c
version.c
wrdd.c