chromeos-config: fix cros_config_mock script

read command returns none zero while input has no newline.
Ignore and assume the read would be success. Also fix
whitelabel_tag path.

BUG=b:245210865
TEST=run "cros_config_mock --sku-id 262148 / name"

Change-Id: Id4c4bbeb13370b9144459d17a638a95605ecc143
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform2/+/3875963
Tested-by: Ivan Chen <yulunchen@google.com>
Commit-Queue: Ivan Chen <yulunchen@google.com>
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
(cherry picked from commit 9f4092e28429dc0dc802495511547e8ad0c3aaa3)
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform2/+/3890469
Tested-by: Kenny Pan <kennypan@google.com>
Reviewed-by: Ivan Chen <yulunchen@google.com>
diff --git a/chromeos-config/cros_config_mock.sh b/chromeos-config/cros_config_mock.sh
index f6e1960..4598beb 100755
--- a/chromeos-config/cros_config_mock.sh
+++ b/chromeos-config/cros_config_mock.sh
@@ -107,12 +107,14 @@
   SKU_ID="$(cut -b4- </sys/class/dmi/id/product_sku)"
 fi
 
-if [[ -f /sys/firmware/vpd/ro/custom_label_tag && -z "${CUSTOM_LABEL_TAG}" ]]; then
-  read -r CUSTOM_LABEL_TAG </sys/firmware/vpd/ro/custom_label_tag
+if [[ -f /sys/firmware/vpd/ro/custom_label_tag && \
+  -z "${CUSTOM_LABEL_TAG}" ]]; then
+  read -r CUSTOM_LABEL_TAG </sys/firmware/vpd/ro/custom_label_tag || true
 fi
 
-if [[ -f /sys/firmware/vpd/whitelabel_tag && -z "${CUSTOM_LABEL_TAG}" ]]; then
-  read -r CUSTOM_LABEL_TAG </sys/firmware/vpd/whitelabel_tag
+if [[ -f /sys/firmware/vpd/ro/whitelabel_tag && \
+  -z "${CUSTOM_LABEL_TAG}" ]]; then
+  read -r CUSTOM_LABEL_TAG </sys/firmware/vpd/ro/whitelabel_tag || true
 fi
 
 on_exit_unmount () {