In the Linux kernel, the following vulnerability has been resolved:
thermal: Fix NULL pointer dereferences in ofthermal functions
ofparsethermalzones() parses the thermal-zones node and registers a thermalzone device for each subnode. However, if a thermal zone is consuming a thermal sensor and that thermal sensor device hasn't probed yet, an attempt to set trippoint*_temp for that thermal zone device can cause a NULL pointer dereference. Fix it.
console:/sys/class/thermal/thermalzone87 # echo 120000 > trippoint0temp ... Unable to handle kernel NULL pointer dereference at virtual address 0000000000000020 ... Call trace: ofthermalsettriptemp+0x40/0xc4 trippointtempstore+0xc0/0x1dc devattrstore+0x38/0x88 sysfskfwrite+0x64/0xc0 kernfsfopwriteiter+0x108/0x1d0 vfswrite+0x2f4/0x368 ksyswrite+0x7c/0xec __arm64syswrite+0x20/0x30 el0svccommon.llvm.7279915941325364641+0xbc/0x1bc doel0svc+0x28/0xa0 el0svc+0x14/0x24 el0synchandler+0x88/0xec el0sync+0x1c0/0x200
While at it, fix the possible NULL pointer dereference in other functions as well: ofthermalgettemp(), ofthermalsetemultemp(), ofthermalgettrend().
"https://storage.googleapis.com/osv-test-cve-osv-conversion/osv-output/CVE-2021-47202.json"
[
{
"events": [
{
"introduced": "0"
},
{
"fixed": "5.4.210"
}
]
},
{
"events": [
{
"introduced": "5.5"
},
{
"fixed": "5.10.81"
}
]
},
{
"events": [
{
"introduced": "5.11"
},
{
"fixed": "5.14.21"
}
]
},
{
"events": [
{
"introduced": "5.15"
},
{
"fixed": "5.15.4"
}
]
}
]