thermal/drivers/mediatek/lvts: add missing fields for mt7987
Subsystems (2)
PATCH v2 1/1 thermal/drivers/mediatek/lvts: add missing fields for mt7987
From: Frank Wunderlich <[email protected]>
Commit a4c40559499f ("thermal/drivers/mediatek/lvts: Add platform ops to support alternative conversion logic") added new ops field which causes crash on mt7987.
[ 1.518540] Internal error: Oops: 0000000096000005 [#1] SMP ... [ 1.564481] pc : lvts_get_temp+0x84/0xc4 [ 1.564492] lr : lvts_get_temp+0x60/0xc4 ... [ 1.620900] Call trace: [ 1.631753] lvts_get_temp+0x84/0xc4 (P) [ 1.645471] __thermal_zone_get_temp+0x24/0x11c [ 1.656502] __thermal_zone_device_update+0x9c/0x52c
Add the new ops member added in 7.0-rc1 for mt7987 too.
Commit 6931d597c5ef ("thermal/drivers/mediatek/lvts: Make number of calibration offsets configurable") introduced field num_cal_offsets in lvts_data. Add this for mt7987 too.
--- drivers/thermal/mediatek/lvts_thermal.c | 2 ++ 1 file changed, 2 insertions(+)
drivers/thermal/mediatek/lvts_thermal.c +2 -0
@@ -2026,6 +2026,8 @@ static const struct lvts_data mt7987_lvts_ap_data = { .temp_offset = LVTS_COEFF_B_MT7987, .gt_calib_bit_offset = 32, .def_calibration = 19380, + .num_cal_offsets = LVTS_NUM_CAL_OFFSETS_MT7988, + .ops = &lvts_platform_ops_mt7988, };static const struct lvts_data mt7988_lvts_ap_data = {
Signature · 1 line
2.43.0
Quoted 16 lines · Frank Wunderlich
From: Frank Wunderlich <[email protected]>
Commit
a4c40559499f("thermal/drivers/mediatek/lvts: Add platform ops to support alternative conversion logic") added new ops field which causes crash on mt7987.[ 1.518540] Internal error: Oops: 0000000096000005 [#1] SMP ... [ 1.564481] pc : lvts_get_temp+0x84/0xc4 [ 1.564492] lr : lvts_get_temp+0x60/0xc4 ... [ 1.620900] Call trace: [ 1.631753] lvts_get_temp+0x84/0xc4 (P) [ 1.645471] __thermal_zone_get_temp+0x24/0x11c [ 1.656502] __thermal_zone_device_update+0x9c/0x52c
Quoted 8 lines
Add the new ops member added in 7.0-rc1 for mt7987 too.
Commit
6931d597c5ef("thermal/drivers/mediatek/lvts: Make number of calibration offsets configurable") introduced fieldnum_cal_offsetsinlvts_data. Add this for mt7987 too.Fixes 78c24e67d6f8 ("thermal/drivers/mediatek/lvts_thermal: Add mt7987 support")Signed-off-by Frank Wunderlich <[email protected]>
Quoted 16 lines · Frank Wunderlich
From: Frank Wunderlich <[email protected]>
Commit
a4c40559499f("thermal/drivers/mediatek/lvts: Add platform ops to support alternative conversion logic") added new ops field which causes crash on mt7987.[ 1.518540] Internal error: Oops: 0000000096000005 [#1] SMP ... [ 1.564481] pc : lvts_get_temp+0x84/0xc4 [ 1.564492] lr : lvts_get_temp+0x60/0xc4 ... [ 1.620900] Call trace: [ 1.631753] lvts_get_temp+0x84/0xc4 (P) [ 1.645471] __thermal_zone_get_temp+0x24/0x11c [ 1.656502] __thermal_zone_device_update+0x9c/0x52c
Quoted 8 lines
Add the new ops member added in 7.0-rc1 for mt7987 too.
Commit
6931d597c5ef("thermal/drivers/mediatek/lvts: Make number of calibration offsets configurable") introduced fieldnum_cal_offsetsinlvts_data. Add this for mt7987 too.Fixes 78c24e67d6f8 ("thermal/drivers/mediatek/lvts_thermal: Add mt7987 support")Signed-off-by Frank Wunderlich <[email protected]>
Hi,
just a friedly reminder
@angelo do my mails get tagged as spam or similar?
Am 12. März 2026 um 21:24 schrieb "Frank Wunderlich" <[email protected] mailto:[email protected]?to=%22Frank%20Wunderlich%22%20%3Clinux%40fw-web.de%3E >:
Quoted 45 lines
From: Frank Wunderlich <[email protected]>
Commit
a4c40559499f("thermal/drivers/mediatek/lvts: Add platform ops to support alternative conversion logic") added new ops field which causes crash on mt7987.[ 1.518540] Internal error: Oops: 0000000096000005 [#1] SMP ... [ 1.564481] pc : lvts_get_temp+0x84/0xc4 [ 1.564492] lr : lvts_get_temp+0x60/0xc4 ... [ 1.620900] Call trace: [ 1.631753] lvts_get_temp+0x84/0xc4 (P) [ 1.645471] __thermal_zone_get_temp+0x24/0x11c [ 1.656502] __thermal_zone_device_update+0x9c/0x52cAdd the new ops member added in 7.0-rc1 for mt7987 too.
Commit
6931d597c5ef("thermal/drivers/mediatek/lvts: Make number of calibration offsets configurable") introduced fieldnum_cal_offsetsinlvts_data. Add this for mt7987 too.Fixes 78c24e67d6f8 ("thermal/drivers/mediatek/lvts_thermal: Add mt7987 support")Signed-off-by Frank Wunderlich <[email protected]>--- drivers/thermal/mediatek/lvts_thermal.c | 2 ++ 1 file changed, 2 insertions(+)drivers/thermal/mediatek/lvts_thermal.c +2
-0@@ -2026,6 +2026,8 @@ static const struct lvts_data mt7987_lvts_ap_data = { .temp_offset = LVTS_COEFF_B_MT7987, .gt_calib_bit_offset = 32, .def_calibration = 19380, + .num_cal_offsets = LVTS_NUM_CAL_OFFSETS_MT7988, + .ops = &lvts_platform_ops_mt7988, };static const struct lvts_data mt7988_lvts_ap_data = {Signature · 1 line
2.43.0
regards Frank