From ac7f0c20b816784fca6b21e2a931f55b4089e219 Mon Sep 17 00:00:00 2001 From: Edward O'Callaghan Date: Thu, 11 Aug 2022 22:02:26 +1000 Subject: flashrom.c: flatten out read_buf_from_include_args() read_buf_from_include_args() does not need the whole flashctx, rather it works with a fix layout and buffer. Just pass what state is actually required. BUG=b:242246291 TEST=builds Change-Id: Ieadd68895c7ba05cc3d770d304351b02622f14d7 Signed-off-by: Edward O'Callaghan Reviewed-on: https://review.coreboot.org/c/flashrom/+/66633 Reviewed-by: Evan Benn Tested-by: build bot (Jenkins) Reviewed-by: Nico Huber Reviewed-by: Nikolai Artemiev Reviewed-by: Sam McNally Reviewed-by: Thomas Heijligen --- include/flash.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include/flash.h') diff --git a/include/flash.h b/include/flash.h index 449ed9d1..3fedb2b6 100644 --- a/include/flash.h +++ b/include/flash.h @@ -423,7 +423,7 @@ void print_banner(void); void list_programmers_linebreak(int startcol, int cols, int paren); int selfcheck(void); int read_buf_from_file(unsigned char *buf, unsigned long size, const char *filename); -int read_buf_from_include_args(const struct flashctx *const flash, unsigned char *buf); +int read_buf_from_include_args(const struct flashrom_layout *const layout, unsigned char *buf); int write_buf_to_file(const unsigned char *buf, unsigned long size, const char *filename); int write_buf_to_include_args(const struct flashctx *const flash, unsigned char *buf); int prepare_flash_access(struct flashctx *, bool read_it, bool write_it, bool erase_it, bool verify_it); -- cgit v1.2.3