[PATCH 7/8] If adding Unit Attention sense fails upon target destroy, just print error message and still return TGTADM_SUCCESS

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]


From: Alexander Nezhinsky <alexandern@xxxxxxxxxxxx>


Signed-off-by: Alexander Nezhinsky <alexandern@xxxxxxxxxxxx>
---
 usr/target.c |    3 +++
 1 file changed, 3 insertions(+)

diff --git a/usr/target.c b/usr/target.c
index dd3ca91..660cac6 100644
--- a/usr/target.c
+++ b/usr/target.c
@@ -735,6 +735,9 @@ tgtadm_err tgt_device_destroy(int tid, uint64_t lun, int force)
 
 			ret = ua_sense_add(itn_lu,
 					   ASC_REPORTED_LUNS_DATA_HAS_CHANGED);
+			if (ret)
+				eprintf("fail to add ua %" PRIu64 " %" PRIu64 "\n",
+					lun, itn->itn_id);
 		}
 	}
 
-- 
1.7.9.6

--
To unsubscribe from this list: send the line "unsubscribe stgt" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Linux SCSI]     [Linux RAID]     [Linux Clusters]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]    [Yosemite Photos]    [Free Online Dating]     [Linux Kernel]     [XFree86]     [Video Devices]

Add to Google Powered by Linux