In the Linux kernel, the following vulnerability has been resolved:
serial: arcuart: fix ofiomap leak in arc_serial_probe
Smatch reports:
drivers/tty/serial/arcuart.c:631 arcserialprobe() warn: 'port->membase' from ofiomap() not released on lines: 631.
In arcserialprobe(), if uartaddone_port() fails, port->membase is not released, which would cause a resource leak.
To fix this, I replace ofiomap with devmplatformioremapresource.
[
{
"id": "CVE-2023-53719-3689a816",
"signature_version": "v1",
"digest": {
"length": 1201.0,
"function_hash": "297773870740935963817129678743552886062"
},
"deprecated": false,
"signature_type": "Function",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@153017561d2804cfae87cc9aa377aa84dd906ae1",
"target": {
"file": "drivers/tty/serial/arc_uart.c",
"function": "arc_serial_probe"
}
},
{
"id": "CVE-2023-53719-ee7ffab8",
"signature_version": "v1",
"digest": {
"threshold": 0.9,
"line_hashes": [
"177911320436384208057486973561737319776",
"134910297681889229615559196817792042806",
"126941043705382859999423222951637747976",
"58820481516220954704978347495156004809",
"49525020232307675304370873287964360462",
"109461773276704055160759961784721529200"
]
},
"deprecated": false,
"signature_type": "Line",
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@153017561d2804cfae87cc9aa377aa84dd906ae1",
"target": {
"file": "drivers/tty/serial/arc_uart.c"
}
}
]