漏洞信息
# bus: fsl-mc: 解决 mc_dev 的重复释放问题
## 概述
在Linux内核中修复了fsl-mc驱动中的一个double-free漏洞。此漏洞涉及`mc_dev`变量的释放逻辑。
## 影响版本
未指明具体影响的版本。
## 细节
导致问题的提交尝试简化释放操作,但在过程中引入了对`mc_dev`变量的double-free错误。当MC设备为DPRC时,会分配一个新的`mc_bus`,而`mc_dev`变量只是其字段之一的引用。在这种情况下,仅需在错误路径上释放`mc_bus`。修复此漏洞引入了一个`checkpatch`误报警告,提示`kfree(NULL)`是安全的,可能不需要这个检查。
## 影响
此漏洞可能导致内存不稳定,甚至系统崩溃。
提示
尽管我们采用了先进的大模型技术,但其输出仍可能包含不准确或过时的信息。
神龙会尽力确保数据准确,但也请结合实际情况进行甄别与判断。
神龙祝您一切顺利!
漏洞标题
bus: fsl-mc: fix double-free on mc_dev
漏洞描述信息
In the Linux kernel, the following vulnerability has been resolved:
bus: fsl-mc: fix double-free on mc_dev
The blamed commit tried to simplify how the deallocations are done but,
in the process, introduced a double-free on the mc_dev variable.
In case the MC device is a DPRC, a new mc_bus is allocated and the
mc_dev variable is just a reference to one of its fields. In this
circumstance, on the error path only the mc_bus should be freed.
This commit introduces back the following checkpatch warning which is a
false-positive.
WARNING: kfree(NULL) is safe and this check is probably not required
+ if (mc_bus)
+ kfree(mc_bus);
CVSS信息
N/A
漏洞类别
N/A
漏洞标题
Linux kernel 安全漏洞
漏洞描述信息
Linux kernel是美国Linux基金会的开源操作系统Linux所使用的内核。 Linux kernel存在安全漏洞,该漏洞源于fsl-mc总线中双重释放mc_dev,可能导致内存损坏。
CVSS信息
N/A
漏洞类别
其他