summaryrefslogtreecommitdiff
path: root/util/cbfstool/cse_fpt.h
diff options
context:
space:
mode:
authorFurquan Shaikh <furquan@google.com>2021-10-08 15:18:33 -0700
committerFurquan Shaikh <furquan@google.com>2021-10-19 16:08:45 +0000
commit555f0407721ca1c29e3d6f3a6f4076fdcb550915 (patch)
tree8b81402d1fc812d4a608c34995f9de050dfa61b7 /util/cbfstool/cse_fpt.h
parentd7fb6a90e1d0130db18c84530272f5d35dd914b0 (diff)
util/cse*: Add cse_helpers.{c,h}
This change moves `read_member` and `write_member` helper functions out of cse_fpt.c and cse_serger.c into cse_helpers.c to avoid duplication. BUG=b:189177186,b:189167923 Change-Id: I7b646b29c9058d892bb0fc9824ef1b4340d2510c Signed-off-by: Furquan Shaikh <furquan@google.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/58201 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Diffstat (limited to 'util/cbfstool/cse_fpt.h')
-rw-r--r--util/cbfstool/cse_fpt.h5
1 files changed, 1 insertions, 4 deletions
diff --git a/util/cbfstool/cse_fpt.h b/util/cbfstool/cse_fpt.h
index eda8a07930..3f9c1855b4 100644
--- a/util/cbfstool/cse_fpt.h
+++ b/util/cbfstool/cse_fpt.h
@@ -7,12 +7,11 @@
#include <commonlib/region.h>
#include "common.h"
+#include "cse_helpers.h"
#define FPT_MARKER "$FPT"
#define FPT_ENTRY_VERSION 0x10
-#define READ_MEMBER(_buff, _x) read_member(_buff, &(_x), sizeof(_x))
-
enum fpt_hdr_version {
FPT_HDR_VERSION_20 = 0x20,
FPT_HDR_VERSION_21 = 0x21,
@@ -32,6 +31,4 @@ struct fpt_hdr_ops {
extern const struct fpt_hdr_ops fpt_hdr_20_ops;
extern const struct fpt_hdr_ops fpt_hdr_21_ops;
-void read_member(struct buffer *buff, void *dst, size_t size);
-
#endif /* __CBFSTOOL_CSE_FPT_H__ */