firmware: arm_scmi: remove redundant null check on array

The null check on clk->name is redundant since name is a char array
and can never be null, so the check is always true.  Remove it.

Detected by CoverityScan, CID#1466117 ("Array compared against 0")

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Sudeep Holla <sudeep.holla@arm.com>
This commit is contained in:
Colin Ian King 2018-03-21 18:01:58 +00:00 committed by Sudeep Holla
parent 60cc43fc88
commit d27a3c3436

View File

@ -284,7 +284,7 @@ scmi_clock_info_get(const struct scmi_handle *handle, u32 clk_id)
struct clock_info *ci = handle->clk_priv;
struct scmi_clock_info *clk = ci->clk + clk_id;
if (!clk->name || !clk->name[0])
if (!clk->name[0])
return NULL;
return clk;