projects
/
coreboot.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Use convenience function to checksum
[coreboot.git]
/
payloads
/
libpayload
/
include
/
coreboot_tables.h
diff --git
a/payloads/libpayload/include/coreboot_tables.h
b/payloads/libpayload/include/coreboot_tables.h
index 3b3b7d2299b00146b1838cb3dc8edaf05d9d3420..574469a6ed57085f9e3c6ddc808fb753e848edae 100644
(file)
--- a/
payloads/libpayload/include/coreboot_tables.h
+++ b/
payloads/libpayload/include/coreboot_tables.h
@@
-223,6
+223,11
@@
static inline u64 cb_unpack64(struct cbuint64 val)
return (((u64) val.hi) << 32) | val.lo;
}
+static inline u16 cb_checksum(const void *ptr, unsigned len)
+{
+ return ipchksum(ptr, len);
+}
+
/* Helpful macros */
#define MEM_RANGE_COUNT(_rec) \