CVE-2021-47025: iommu/mediatek: Always enable the clk on resume
In the Linux kernel, the following vulnerability has been resolved:
iommu/mediatek: Always enable the clk on resume
In mtkiommuruntimeresume always enable the clk, even if m4udom is null. Otherwise the 'suspend' cb might disable the clk which is already disabled causing the warning:
[ 1.586104] infram4u already disabled [ 1.586133] WARNING: CPU: 0 PID: 121 at drivers/clk/clk.c:952 clkcoredisable+0xb0/0xb8 [ 1.594391] mtk-iommu 10205000.iommu: bound 18001000.larb (ops mtksmilarbcomponentops) [ 1.598108] Modules linked in: [ 1.598114] CPU: 0 PID: 121 Comm: kworker/0:2 Not tainted 5.12.0-rc5 #69 [ 1.609246] mtk-iommu 10205000.iommu: bound 14027000.larb (ops mtksmilarbcomponentops) [ 1.617487] Hardware name: Google Elm (DT) [ 1.617491] Workqueue: pm pmruntimework [ 1.620545] mtk-iommu 10205000.iommu: bound 19001000.larb (ops mtksmilarbcomponentops)
[ 1.627229] pstate: 60000085 (nZCv daIf -PAN -UAO -TCO BTYPE=--) [ 1.659297] pc : clkcoredisable+0xb0/0xb8 [ 1.663475] lr : clkcoredisable+0xb0/0xb8 [ 1.667652] sp : ffff800011b9bbe0 [ 1.670959] x29: ffff800011b9bbe0 x28: 0000000000000000 [ 1.676267] x27: ffff800011448000 x26: ffff8000100cfd98 [ 1.681574] x25: ffff800011b9bd48 x24: 0000000000000000 [ 1.686882] x23: 0000000000000000 x22: ffff8000106fad90 [ 1.692189] x21: 000000000000000a x20: ffff0000c0048500 [ 1.697496] x19: ffff0000c0048500 x18: ffffffffffffffff [ 1.702804] x17: 0000000000000000 x16: 0000000000000000 [ 1.708112] x15: ffff800011460300 x14: fffffffffffe0000 [ 1.713420] x13: ffff8000114602d8 x12: 0720072007200720 [ 1.718727] x11: 0720072007200720 x10: 0720072007200720 [ 1.724035] x9 : ffff800011b9bbe0 x8 : ffff800011b9bbe0 [ 1.729342] x7 : 0000000000000009 x6 : ffff8000114b8328 [ 1.734649] x5 : 0000000000000000 x4 : 0000000000000000 [ 1.739956] x3 : 00000000ffffffff x2 : ffff800011460298 [ 1.745263] x1 : 1af1d7de276f4500 x0 : 0000000000000000 [ 1.750572] Call trace: [ 1.753010] clkcoredisable+0xb0/0xb8 [ 1.756840] clkcoredisablelock+0x24/0x40 [ 1.761105] clkdisable+0x20/0x30 [ 1.764501] mtkiommuruntimesuspend+0x88/0xa8 [ 1.769114] pmgenericruntimesuspend+0x2c/0x48 [ 1.773815] rpmcallback+0xe0/0x178 [ 1.777559] rpmcallback+0x24/0x88 [ 1.781041] rpmsuspend+0xdc/0x470 [ 1.784523] rpmidle+0x12c/0x170 [ 1.787831] pmruntimework+0xa8/0xc0 [ 1.791573] processonework+0x1e8/0x360 [ 1.795580] workerthread+0x44/0x478 [ 1.799237] kthread+0x150/0x158 [ 1.802460] retfromfork+0x10/0x30 [ 1.806034] ---[ end trace 82402920ef64573b ]--- [ 1.810728] ------------[ cut here ]------------
In addition, we now don't need to enable the clock from the function mtkiommuhwinit since it is already enabled by the resume.
Affected Software
Remediation
Event History
Frequently Asked Questions
What is the severity of CVE-2021-47025?
The severity of CVE-2021-47025 is classified as high due to potential impacts on system stability.
How do I fix CVE-2021-47025?
To fix CVE-2021-47025, update to a patched version of the Linux kernel beyond 5.12.4.
What systems are affected by CVE-2021-47025?
CVE-2021-47025 affects the Linux kernel versions from 5.12 and below.
What vulnerabilities does CVE-2021-47025 address in the Linux kernel?
CVE-2021-47025 addresses an issue with the IOMMU subsystem related to clock management during the resume process.
Is there a workaround for CVE-2021-47025?
Currently, no specific workaround for CVE-2021-47025 is recommended other than applying the appropriate kernel update.