Commit b7a80dac authored by Dan Carpenter's avatar Dan Carpenter Committed by Martin K. Petersen

scsi: ufs: ufs-exynos: Remove an unnecessary NULL check

The "head" pointer can't be NULL because it points to an address in the
middle of a ufs_hba struct.  Looking at this code, probably someone would
wonder if the intent was to check whether "hba" is NULL, but "hba" isn't
NULL and the check can just be removed.

Link: https://lore.kernel.org/r/20200626105133.GF314359@mwandaAcked-by: default avatarAlim Akhtar <alim.akhtar@samsung.com>
Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
parent fbca7a04
......@@ -264,7 +264,7 @@ static int exynos_ufs_get_clk_info(struct exynos_ufs *ufs)
u8 div = 0;
int ret = 0;
if (!head || list_empty(head))
if (list_empty(head))
goto out;
list_for_each_entry(clki, head, list) {
......
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