Add CONFIG_IGNORE_G_UPDATE_CHECKS

In some scenarios we want to take RW updates w/o taking version numbers into consideration,
much like the behavior we get w/ CR50_DEV.
But then without the additional CR50_DEV features enabled for the rest of the code.

BRANCH=none
BUG=none
TEST=compiles
Change-Id: I7dd946ab77bbdc35850ed934cd53735418e13845
Reviewed-on: https://chromium-review.googlesource.com/724967
Reviewed-by: Marius Schilder <mschilder@chromium.org>
Reviewed-by: Vadim Bendebury <vbendeb@chromium.org>
Tested-by: Marius Schilder <mschilder@chromium.org>
Trybot-Ready: Marius Schilder <mschilder@chromium.org>
This commit is contained in:
Marius Schilder
2017-10-17 21:52:56 -07:00
committed by Marius Schilder
parent 8f3f0c0807
commit e5663fcc81
2 changed files with 11 additions and 1 deletions

View File

@@ -162,8 +162,13 @@ int usb_pdu_valid(struct upgrade_command *cmd_body, size_t cmd_size)
return 1;
}
#ifndef CR50_DEV
#ifdef CR50_DEV
#ifndef CONFIG_IGNORE_G_UPDATE_CHECKS
#define CONFIG_IGNORE_G_UPDATE_CHECKS
#endif
#endif
#ifndef CONFIG_IGNORE_G_UPDATE_CHECKS
/* Compare two versions, return True if the new version is older. */
static int new_is_older(const struct SignedHeader *new,
const struct SignedHeader *old)

View File

@@ -908,6 +908,11 @@
*/
#undef CONFIG_UPTO_SHA512
/*
* When enabled ignore version et al during fw upgrade for chip/g.
*/
#undef CONFIG_IGNORE_G_UPDATE_CHECKS
/*****************************************************************************/
/*
* Debugging config