Subject: CVE-2023-52500: scsi: pm80xx: Avoid leaking tags when processing OPC_INB_SET_CONTROLLER_CONFIG command

From: Greg Kroah-Hartman <[email-masked]>

Description
===========

In the Linux kernel, the following vulnerability has been resolved:

scsi: pm80xx: Avoid leaking tags when processing OPC_INB_SET_CONTROLLER_CONFIG command

Tags allocated for OPC_INB_SET_CONTROLLER_CONFIG command need to be freed
when we receive the response.

The Linux kernel CVE team has assigned CVE-2023-52500 to this issue.

Affected and fixed versions
===========================

	Fixed in 5.10.198 with commit 2afd8fcee0c4
	Fixed in 5.15.134 with commit d540a4370aba
	Fixed in 6.1.56 with commit 2259e1901b2d
	Fixed in 6.5.6 with commit 22e6d783a330
	Fixed in 6.6 with commit c13e73317458

Please see https://www.kernel.org for a full list of currently supported
kernel versions by the kernel community.

Unaffected versions might change over time as fixes are backported to
older supported kernel versions.  The official CVE entry at
	https://cve.org/CVERecord/?id=CVE-2023-52500
will be updated if fixes are backported, please check that for the most
up to date information about this issue.

Affected files
==============

The file(s) affected by this issue are:
	drivers/scsi/pm8001/pm80xx_hwi.c

Mitigation
==========

The Linux kernel CVE team recommends that you update to the latest
stable kernel version for this, and many other bugfixes.  Individual
changes are never tested alone, but rather are part of a larger kernel
release.  Cherry-picking individual commits is not recommended or
supported by the Linux kernel community at all.  If however, updating to
the latest release is impossible, the individual changes to resolve this
issue can be found at these commits:
	https://git.kernel.org/stable/c/2afd8fcee0c4d65a482e30c3ad2a92c25e5e92d4
	https://git.kernel.org/stable/c/d540a4370aba378fbedf349ba0bb68e96e24243d
	https://git.kernel.org/stable/c/2259e1901b2d8c0e8538fc99e77de443b939e749
	https://git.kernel.org/stable/c/22e6d783a33015bcdf0979015e4eac603912bea7
	https://git.kernel.org/stable/c/c13e7331745852d0dd7c35eabbe181cbd5b01172