Skip to content

Commit

Permalink
Merge tag 'thermal-v5.13-rc4' of git://git.kernel.org/pub/scm/linux/k…
Browse files Browse the repository at this point in the history
…ernel/git/thermal/linux

Pull thermal fixes from Daniel Lezcano:

 - Fix uninitialized error code value for the SPMI adc driver (Yang
   Yingliang)

 - Fix kernel doc warning (Yang Li)

 - Fix wrong read-write thermal trip point initialization (Srinivas
   Pandruvada)

* tag 'thermal-v5.13-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/thermal/linux:
  thermal/drivers/qcom: Fix error code in adc_tm5_get_dt_channel_data()
  thermal/ti-soc-thermal: Fix kernel-doc
  thermal/drivers/intel: Initialize RW trip to THERMAL_TEMP_INVALID
  • Loading branch information
Linus Torvalds committed May 29, 2021
2 parents f956cb9 + 5d8db38 commit df8c66c
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 3 deletions.
4 changes: 4 additions & 0 deletions drivers/thermal/intel/int340x_thermal/int340x_thermal_zone.c
Original file line number Diff line number Diff line change
Expand Up @@ -237,6 +237,8 @@ struct int34x_thermal_zone *int340x_thermal_zone_add(struct acpi_device *adev,
if (ACPI_FAILURE(status))
trip_cnt = 0;
else {
int i;

int34x_thermal_zone->aux_trips =
kcalloc(trip_cnt,
sizeof(*int34x_thermal_zone->aux_trips),
Expand All @@ -247,6 +249,8 @@ struct int34x_thermal_zone *int340x_thermal_zone_add(struct acpi_device *adev,
}
trip_mask = BIT(trip_cnt) - 1;
int34x_thermal_zone->aux_trip_nr = trip_cnt;
for (i = 0; i < trip_cnt; ++i)
int34x_thermal_zone->aux_trips[i] = THERMAL_TEMP_INVALID;
}

trip_cnt = int340x_thermal_read_trips(int34x_thermal_zone);
Expand Down
2 changes: 1 addition & 1 deletion drivers/thermal/intel/x86_pkg_temp_thermal.c
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ static int sys_get_trip_temp(struct thermal_zone_device *tzd,
if (thres_reg_value)
*temp = zonedev->tj_max - thres_reg_value * 1000;
else
*temp = 0;
*temp = THERMAL_TEMP_INVALID;
pr_debug("sys_get_trip_temp %d\n", *temp);

return 0;
Expand Down
2 changes: 1 addition & 1 deletion drivers/thermal/qcom/qcom-spmi-adc-tm5.c
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,7 @@ static int adc_tm5_get_dt_channel_data(struct adc_tm5_chip *adc_tm,

if (args.args_count != 1 || args.args[0] >= ADC5_MAX_CHANNEL) {
dev_err(dev, "%s: invalid ADC channel number %d\n", name, chan);
return ret;
return -EINVAL;
}
channel->adc_channel = args.args[0];

Expand Down
2 changes: 1 addition & 1 deletion drivers/thermal/ti-soc-thermal/ti-bandgap.c
Original file line number Diff line number Diff line change
Expand Up @@ -770,7 +770,7 @@ static int ti_bandgap_tshut_init(struct ti_bandgap *bgp,
}

/**
* ti_bandgap_alert_init() - setup and initialize talert handling
* ti_bandgap_talert_init() - setup and initialize talert handling
* @bgp: pointer to struct ti_bandgap
* @pdev: pointer to device struct platform_device
*
Expand Down

0 comments on commit df8c66c

Please sign in to comment.