build_image/mod_image_for_recovery: switch to loopback_partscan helper

The losetup+partx logic in these scripts is the same as our
loopback_partscan helper.  Move to that so we can add some
retry/debug logic in a single place to workaround problems
on current CI bots.

BUG=chromium:999596
TEST=build_image passed

Change-Id: I4dcacbde3d4f3291799df14101fe9c1134861fc1
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosutils/+/1780890
Reviewed-by: Mike Frysinger <vapier@chromium.org>
Tested-by: Mike Frysinger <vapier@chromium.org>
Legacy-Commit-Queue: Commit Bot <commit-bot@chromium.org>
2 files changed