Skip to content

Commit

Permalink
Style changes from checkpatch.
Browse files Browse the repository at this point in the history
  • Loading branch information
iwanders committed Dec 16, 2023
1 parent 5363119 commit 6f27668
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions drivers/platform/surface/surface_fan.c
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,8 @@ static int surface_fan_hwmon_read(struct device *dev,
switch (attr) {
case hwmon_fan_input:
res = __ssam_fan_rpm_get(sdev, &value);
if (res) {
if (res)
return -EIO;
}
*val = le16_to_cpu(value);
return 0;
case hwmon_fan_min:
Expand Down Expand Up @@ -98,11 +97,11 @@ static int surface_fan_probe(struct ssam_device *sdev)
{
struct device *hdev;

hdev = devm_hwmon_device_register_with_info(
&sdev->dev, "fan", sdev, &surface_fan_chip_info, NULL);
if (IS_ERR(hdev)) {
hdev = devm_hwmon_device_register_with_info(&sdev->dev, "fan", sdev,
&surface_fan_chip_info,
NULL);
if (IS_ERR(hdev))
return PTR_ERR(hdev);
}

ssam_device_set_drvdata(sdev, sdev);

Expand Down

0 comments on commit 6f27668

Please sign in to comment.