Commit f8dc7a31 authored by Jinyoung Choi's avatar Jinyoung Choi Committed by Martin K. Petersen
parent 87bd0501
...@@ -5758,10 +5758,8 @@ int ufshcd_wb_toggle(struct ufs_hba *hba, bool enable) ...@@ -5758,10 +5758,8 @@ int ufshcd_wb_toggle(struct ufs_hba *hba, bool enable)
{ {
int ret; int ret;
if (!ufshcd_is_wb_allowed(hba)) if (!ufshcd_is_wb_allowed(hba) ||
return 0; hba->dev_info.wb_enabled == enable)
if (!(enable ^ hba->dev_info.wb_enabled))
return 0; return 0;
ret = __ufshcd_wb_toggle(hba, enable, QUERY_FLAG_IDN_WB_EN); ret = __ufshcd_wb_toggle(hba, enable, QUERY_FLAG_IDN_WB_EN);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment