depthcharge: gbb_clear_flags should not use cparams.gbb_data

In preparation to deprecate the use of cparams to store GBB data,
update depthcharge's gbb_clear_flags to write directly to flash
without using cparams or vb2_gbb_header.

The offset and size of GBB flags member is determined using the
two constants VB2_GBB_FLAGS_OFFSET and VB2_GBB_FLAGS_TYPE.

Remove gbb_copy_out since it is no longer used.

BUG=b:124141368, chromium:954774
TEST=Build and flash to eve device; manually check that a
     gbb_clear_flags() call functions correctly
BRANCH=none

Change-Id: Icddaf27ffabbbb8dec0ff5d0b2c9b1fcb1654c32
Signed-off-by: Joel Kitching <kitching@google.com>
Cq-Depend: chromium:1657503
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/depthcharge/+/1657928
Tested-by: Joel Kitching <kitching@chromium.org>
Commit-Queue: Joel Kitching <kitching@chromium.org>
Auto-Submit: Joel Kitching <kitching@chromium.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
1 file changed