Message ID | 20230727233405.35937-2-mike.maslenkin@gmail.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | hw/ufs: fix compilation warnings | expand |
diff --git a/hw/ufs/ufs.c b/hw/ufs/ufs.c index 1760e0f88d70..af32366c8504 100644 --- a/hw/ufs/ufs.c +++ b/hw/ufs/ufs.c @@ -514,10 +514,10 @@ static UfsReqResult ufs_exec_scsi_cmd(UfsRequest *req) if (!is_wlun(lun)) { if (lun >= u->device_desc.number_lu) { trace_ufs_err_scsi_cmd_invalid_lun(lun); - return UFS_REQUEST_ERROR; + return UFS_REQUEST_FAIL; } else if (u->lus[lun] == NULL) { trace_ufs_err_scsi_cmd_invalid_lun(lun); - return UFS_REQUEST_ERROR; + return UFS_REQUEST_FAIL; } }
This patch fixes a compilation warning: implicit conversion from enumeration type 'enum UfsRequestState' to different enumeration type 'UfsReqResult' (aka 'enum UfsReqResult') [-Wenum-conversion] ufs_exec_scsi_cmd() returns a value from UfsReqResult enum. Cc: Jeuk Kim <jeuk20.kim@samsung.com> Cc: Stefan Hajnoczi <stefanha@redhat.com> Signed-off-by: Mike Maslenkin <mike.maslenkin@gmail.com> --- hw/ufs/ufs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)