[as4610] Replace hwmon_device_register() with hwmon_device_register_with_info()

This commit is contained in:
brandon_chuang
2019-02-12 14:37:29 +08:00
parent 857a4fb49c
commit 3f8142ccf4
3 changed files with 6 additions and 3 deletions

View File

@@ -461,7 +461,8 @@ static int ym2651y_probe(struct i2c_client *client,
goto exit_free;
}
data->hwmon_dev = hwmon_device_register(&client->dev);
data->hwmon_dev = hwmon_device_register_with_info(&client->dev, "ym2651y",
NULL, NULL, NULL);
if (IS_ERR(data->hwmon_dev)) {
status = PTR_ERR(data->hwmon_dev);
goto exit_remove;

View File

@@ -262,7 +262,8 @@ static int as4610_fan_probe(struct platform_device *pdev)
}
fan_data->hwmon_dev = hwmon_device_register(&pdev->dev);
fan_data->hwmon_dev = hwmon_device_register_with_info(&pdev->dev, "as4610_fan",
NULL, NULL, NULL);
if (IS_ERR(fan_data->hwmon_dev)) {
status = PTR_ERR(fan_data->hwmon_dev);
goto exit_remove;

View File

@@ -135,7 +135,8 @@ static int as4610_psu_probe(struct i2c_client *client,
goto exit_free;
}
data->hwmon_dev = hwmon_device_register(&client->dev);
data->hwmon_dev = hwmon_device_register_with_info(&client->dev, "as4610_psu",
NULL, NULL, NULL);
if (IS_ERR(data->hwmon_dev)) {
status = PTR_ERR(data->hwmon_dev);
goto exit_remove;