Subject: CVE-2024-44988: net: dsa: mv88e6xxx: Fix out-of-bound access

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

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

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

net: dsa: mv88e6xxx: Fix out-of-bound access

If an ATU violation was caused by a CPU Load operation, the SPID could
be larger than DSA_MAX_PORTS (the size of mv88e6xxx_chip.ports[] array).

The Linux kernel CVE team has assigned CVE-2024-44988 to this issue.

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

	Issue introduced in 5.0 with commit 75c05a74e745 and fixed in 5.4.283 with commit d39f5be62f09
	Issue introduced in 5.0 with commit 75c05a74e745 and fixed in 5.10.225 with commit 050e7274ab21
	Issue introduced in 5.0 with commit 75c05a74e745 and fixed in 5.15.166 with commit a10d0337115a
	Issue introduced in 5.0 with commit 75c05a74e745 and fixed in 6.1.107 with commit 18b2e833daf0
	Issue introduced in 5.0 with commit 75c05a74e745 and fixed in 6.6.48 with commit f7d8c2fabd39
	Issue introduced in 5.0 with commit 75c05a74e745 and fixed in 6.10.7 with commit f87ce03c652d
	Issue introduced in 5.0 with commit 75c05a74e745 and fixed in 6.11 with commit 528876d867a2
	Issue introduced in 4.19.21 with commit 27a2fa009817
	Issue introduced in 4.20.8 with commit 1657d2814e83

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-2024-44988
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/net/dsa/mv88e6xxx/global1_atu.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/d39f5be62f098fe367d672b4dd4bc4b2b80e08e7
	https://git.kernel.org/stable/c/050e7274ab2150cd212b2372595720e7b83a15bd
	https://git.kernel.org/stable/c/a10d0337115a6d223a1563d853d4455f05d0b2e3
	https://git.kernel.org/stable/c/18b2e833daf049223ab3c2efdf8cdee08854c484
	https://git.kernel.org/stable/c/f7d8c2fabd39250cf2333fbf8eef67e837f90a5d
	https://git.kernel.org/stable/c/f87ce03c652dba199aef15ac18ade3991db5477e
	https://git.kernel.org/stable/c/528876d867a23b5198022baf2e388052ca67c952