vpd: Update of set_binary_flag_vpd to store zero values.

This is the reland of
https://chromium-review.googlesource.com/#/c/383051/.
The reason for revert of original CL has been fixed in
https://chromium-review.googlesource.com/#/c/423048/.

Old script was storing value 1 for flags that were set
and removed the variables that were unset. This CL changes
the behavior to store the zero values. The variable is
never removed from VPD. This allows us to disable FRE
in some situations (eg. consumer-owned devices) by
explicitly setting enrollment_check=0.

BUG=chromium:618340
TEST=Tested manually in console
BRANCH=none

Change-Id: I26a9eaa2bbf9915130d1c1fbec2c0c04bea5f416
Reviewed-on: https://chromium-review.googlesource.com/472628
Commit-Ready: Igor <igorcov@chromium.org>
Tested-by: Igor <igorcov@chromium.org>
Reviewed-by: Thiemo Nagel <tnagel@chromium.org>
diff --git a/util/set_binary_flag_vpd b/util/set_binary_flag_vpd
index a5db1aa..0053a67 100755
--- a/util/set_binary_flag_vpd
+++ b/util/set_binary_flag_vpd
@@ -36,12 +36,7 @@
     flag_name="${var}"
   else
     current="$(dump_vpd_log --full --stdout | grep "^\"${flag_name}\"" || true)"
-    if [[ "${var}" = 0 ]]; then
-      if [[ -n "${current}" ]]; then
-        arguments+=(-d)
-        arguments+=("${flag_name}")
-      fi
-    elif [[ "${var}" = 1 ]]; then
+    if [[ "${var}" = 0 || "${var}" = 1 ]]; then
       expected="\"${flag_name}\"=\"${var}\""
       if [[ "${current}" != "${expected}" ]]; then
         arguments+=(-s)