Merge "drivers: dcvs: memlat: check return value of devm_protocol_get"
This commit is contained in:
commit
f852a8b67d
@ -1427,8 +1427,8 @@ int cpucp_memlat_init(struct scmi_device *sdev)
|
||||
return -EINVAL;
|
||||
|
||||
ops = sdev->handle->devm_protocol_get(sdev, SCMI_PROTOCOL_MEMLAT, &ph);
|
||||
if (!ops)
|
||||
return -ENODEV;
|
||||
if (IS_ERR(ops))
|
||||
return PTR_ERR(ops);
|
||||
|
||||
mutex_lock(&memlat_lock);
|
||||
memlat_data->ph = ph;
|
||||
|
Loading…
Reference in New Issue
Block a user