scsi: ufs: Fix system suspend status
authorStanley Chu <stanley.chu@mediatek.com>
Mon, 7 Jan 2019 14:19:34 +0000 (22:19 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 27 Feb 2019 09:08:04 +0000 (10:08 +0100)
commitf7e2a3857feb21fe06fc1d65363b6e3c5aef0cee
tree11c40cb5fa1f58b9598484cc7c8947bb01776770
parent64717501b578a37243d6ad8bb9698745d260386e
scsi: ufs: Fix system suspend status

[ Upstream commit ce9e7bce43526626f7cffe2e657953997870197e ]

hba->is_sys_suspended is set after successful system suspend but
not clear after successful system resume.

According to current behavior, hba->is_sys_suspended will not be set if
host is runtime-suspended but not system-suspended. Thus we shall aligh the
same policy: clear this flag even if host remains runtime-suspended after
ufshcd_system_resume is successfully returned.

Simply fix this flag to correct host status logs.

Signed-off-by: Stanley Chu <stanley.chu@mediatek.com>
Reviewed-by: Avri Altman <avri.altman@wdc.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/scsi/ufs/ufshcd.c