Skip to content

Commit e9a7c52

Browse files
committed
thermal: int340x_thermal: Consolidate priv->data_vault checks
It is sufficient to check priv->data_vault once in the error code path of int3400_thermal_probe(), so do that. Signed-off-by: Rafael J. Wysocki <[email protected]>
1 parent b90cb10 commit e9a7c52

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

drivers/thermal/intel/int340x_thermal/int3400_thermal.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -614,9 +614,8 @@ static int int3400_thermal_probe(struct platform_device *pdev)
614614

615615
free_sysfs:
616616
cleanup_odvp(priv);
617-
if (priv->data_vault) {
618-
if (!ZERO_OR_NULL_PTR(priv->data_vault))
619-
sysfs_remove_group(&pdev->dev.kobj, &data_attribute_group);
617+
if (!ZERO_OR_NULL_PTR(priv->data_vault)) {
618+
sysfs_remove_group(&pdev->dev.kobj, &data_attribute_group);
620619
kfree(priv->data_vault);
621620
}
622621
free_uuid:

0 commit comments

Comments
 (0)