Subrata Banik has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/41059 )
Change subject: payloads/libpayload: Fix BIT macro redefinition error ......................................................................
Patch Set 2:
Patch Set 2:
where are you getting this error - is this from depthcharge/src/board/tglrvp/board.c?
i was doing emerge-tglrvp depthcharge libpayload and could see this issue.
i'd suggest moving <libpayload.h> and <sysinfo.h> up in the up in the include order. also, which file is including ec_commands.h directly? it may be better to include ec.h instead. it's essentially a wrapper and will take care of the libpayload.h dependency and ordering.
ec_commands.h has a guard for a previous BIT, so as long as libpayload.h comes first, it'll be fine.
+#include <libpayload.h> +#include <sysinfo.h> #include "base/init_funcs.h" #include "base/list.h" #include "drivers/ec/cros/lpc.h" @@ -33,25 +35,33 @@ #include "drivers/power/pch.h" #include "drivers/storage/blockdev.h" #include "drivers/storage/nvme.h" -#include <libpayload.h> -#include <sysinfo.h>
this is fixing as well. But do you like to have this hard dependency of include ordering or having this check here make sense. I believe this issue has started coming along with EC_HEADERS CL.