update_engine: Stop adding unneeded parameters for some operations.

Currently we are adding src_extents, src_length and dst_length for ZERO,
DISCARD and but they don't need it.

Also we are secretly adding dst_length for all REPLACE operations
which they don't need it either.

BUG=chromium:776576
TEST=unittests passed; brillo_update_payload {generate|verify} passed;

Change-Id: I9bf04071a40ef4b9a9d437830f9bdcfb507f18a2
Reviewed-on: https://chromium-review.googlesource.com/729061
Commit-Ready: Amin Hassani <ahassani@chromium.org>
Tested-by: Amin Hassani <ahassani@chromium.org>
Reviewed-by: Ben Chan <benchan@chromium.org>
Reviewed-by: Sen Jiang <senj@chromium.org>
diff --git a/update_metadata.proto b/update_metadata.proto
index 1120bd1..f91f673 100644
--- a/update_metadata.proto
+++ b/update_metadata.proto
@@ -178,14 +178,15 @@
   // Ordered list of extents that are read from (if any) and written to.
   repeated Extent src_extents = 4;
   // Byte length of src, equal to the number of blocks in src_extents *
-  // block_size. It is used for BSDIFF, because we need to pass that
-  // external program the number of bytes to read from the blocks we pass it.
-  // This is not used in any other operation.
+  // block_size. It is used for BSDIFF and SOURCE_BSDIFF, because we need to
+  // pass that external program the number of bytes to read from the blocks we
+  // pass it.  This is not used in any other operation.
   optional uint64 src_length = 5;
 
   repeated Extent dst_extents = 6;
   // Byte length of dst, equal to the number of blocks in dst_extents *
-  // block_size. Used for BSDIFF, but not in any other operation.
+  // block_size. Used for BSDIFF and SOURCE_BSDIFF, but not in any other
+  // operation.
   optional uint64 dst_length = 7;
 
   // Optional SHA 256 hash of the blob associated with this operation.