futility: updater: Enable ec_partial_recovery quirk by default

Enable QUIRK_EC_PARTIAL_RECOVERY (ec_partial_recovery=1) by default so
full/recovery EC firmware updates only flash WP_RO when the EC is active
in RW with EC software sync enabled, leaving EC_RW to be updated by EC
software sync on the next reboot.

During a full EC update (EC_RECOVERY_FULL, RO+RW), flashrom's
cros_ec_prepare() sees EC_IMAGE_RO | EC_IMAGE_RW and forces an
unconditional sysjump from RW to RO when EXEC_IN_RAM is unsupported (such
as on ITE IT8xxx2 ECs), resetting the EC/TCPC or dropping host
communication while the AP is in S0 (b/574563907). Flashrom commit
af7ed034 (b/278652302) added support for RO-only updates (-i WP_RO,
EC_RECOVERY_RO) to skip the sysjump when the EC is already running in RW,
allowing WP_RO to be updated in place while EC software sync updates
EC_RW on reboot.

Callers or board CBFS configs that require an immediate full RO+RW write
can still opt out via --quirks=ec_partial_recovery=0.

BRANCH=none
BUG=b:574563907
TEST=make runfutiltests
TEST=futility update -a /usr/sbin/chromeos-firmwareupdate --mode=recovery
     --force on dirks (IT81302) updates WP_RO without crashing EC in RW

Change-Id: Iadcb674d804e3397075fe93462199424ffa1a564
Signed-off-by: Jon Murphy <jpmurphy@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/vboot_reference/+/8609747
Reviewed-by: Grzegorz Bernacki <bernacki@google.com>
3 files changed