Subject: CVE-2024-26717: HID: i2c-hid-of: fix NULL-deref on failed power up

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

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

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

HID: i2c-hid-of: fix NULL-deref on failed power up

A while back the I2C HID implementation was split in an ACPI and OF
part, but the new OF driver never initialises the client pointer which
is dereferenced on power-up failures.

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

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

	Issue introduced in 5.12 with commit b33752c30023 and fixed in 5.15.149 with commit 62f5d219edbd
	Issue introduced in 5.12 with commit b33752c30023 and fixed in 6.1.79 with commit d7d7a0e3b6f5
	Issue introduced in 5.12 with commit b33752c30023 and fixed in 6.6.18 with commit 4cad91344a62
	Issue introduced in 5.12 with commit b33752c30023 and fixed in 6.7.6 with commit e28d6b63aeec
	Issue introduced in 5.12 with commit b33752c30023 and fixed in 6.8 with commit 00aab7dcb226

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-26717
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/hid/i2c-hid/i2c-hid-of.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/62f5d219edbd174829aa18d4b3d97cd5fefbb783
	https://git.kernel.org/stable/c/d7d7a0e3b6f5adc45f23667cbb919e99093a5b5c
	https://git.kernel.org/stable/c/4cad91344a62536a2949873bad6365fbb6232776
	https://git.kernel.org/stable/c/e28d6b63aeecbda450935fb58db0e682ea8212d3
	https://git.kernel.org/stable/c/00aab7dcb2267f2aef59447602f34501efe1a07f