From b8e82dfe4e5c25682add934f8327fa1516bc3995 Mon Sep 17 00:00:00 2001 From: "Ryan.RCS" Date: Wed, 21 Dec 2016 07:44:21 +0000 Subject: restore the yardstick-img-modify cleanup() func There is a result failed again after last update. So i restore the clean() function to its original codes and avoid CI failed. But i'm not sure something about the clean() function, and I will check this failed clearly in future. Change-Id: I8f49533788c7ccb2016e7a484368a72028579fa8 JIRA: YARDSTICK-502 Signed-off-by: Ryan.RCS --- tools/yardstick-img-modify | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'tools') diff --git a/tools/yardstick-img-modify b/tools/yardstick-img-modify index 1743d908a..68ce6e223 100755 --- a/tools/yardstick-img-modify +++ b/tools/yardstick-img-modify @@ -154,9 +154,11 @@ cleanup() { mount | grep "/mnt/vivid" && umount "/mnt/vivid" if [ -f $raw_imgfile ]; then - if [ -z "$(kpartx -l $raw_imgfile | grep 'loop deleted')" ]; then - kpartx -dv $raw_imgfile - fi + #kpartx -dv $raw_imgfile sometimes failed, we should checked it agein. + #if [ -z "$(kpartx -l $raw_imgfile | grep 'loop deleted')" ]; then + # kpartx -dv $raw_imgfile + #fi + kpartx -dv $raw_imgfile || true fi rm -f $raw_imgfile -- cgit 1.2.3-korg