<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/drivers/i3c/master.c, branch linux-6.17.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-6.17.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-6.17.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2025-12-18T12:59:29Z</updated>
<entry>
<title>i3c: fix refcount inconsistency in i3c_master_register</title>
<updated>2025-12-18T12:59:29Z</updated>
<author>
<name>Frank Li</name>
</author>
<published>2025-10-16T14:38:13Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=89d4b075ef619198f029334932a0cf938a031979'/>
<id>urn:sha1:89d4b075ef619198f029334932a0cf938a031979</id>
<content type='text'>
[ Upstream commit 9d4f219807d5ac11fb1d596e4ddb09336b040067 ]

In `i3c_master_register`, a possible refcount inconsistency has been
identified, causing possible resource leak.

Function `of_node_get` increases the refcount of `parent-&gt;of_node`. If
function `i3c_bus_init` fails, the function returns immediately without
a corresponding decrease, resulting in an inconsistent refcounter.

Move call i3c_bus_init() after device_initialize() to let callback
i3c_masterdev_release() release of_node.

Reported-by: Shuhao Fu &lt;sfual@cse.ust.hk&gt;
Closes: https://lore.kernel.org/linux-i3c/aO2tjp_FsV_WohPG@osx.local/T/#m2c05a982beeb14e7bf039c1d8db856734bf234c7
Fixes: 3a379bbcea0a ("i3c: Add core I3C infrastructure")
Signed-off-by: Frank Li &lt;Frank.Li@nxp.com&gt;
Link: https://patch.msgid.link/20251016143814.2551256-1-Frank.Li@nxp.com
Signed-off-by: Alexandre Belloni &lt;alexandre.belloni@bootlin.com&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>i3c: Fix default I2C adapter timeout value</title>
<updated>2025-10-19T14:37:26Z</updated>
<author>
<name>Jarkko Nikula</name>
</author>
<published>2025-09-05T10:03:20Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=bb4142ef77b0dba7caf7a037b82a4c06675731a6'/>
<id>urn:sha1:bb4142ef77b0dba7caf7a037b82a4c06675731a6</id>
<content type='text'>
commit 9395b3c412933401a34845d5326afe4011bbd40f upstream.

Commit 3a379bbcea0a ("i3c: Add core I3C infrastructure") set the default
adapter timeout for I2C transfers as 1000 (ms). However that parameter
is defined in jiffies not in milliseconds.

With mipi-i3c-hci driver this wasn't visible until commit c0a90eb55a69
("i3c: mipi-i3c-hci: use adapter timeout value for I2C transfers").

Fix this by setting the default timeout as HZ (CONFIG_HZ) not 1000.

Fixes: 1b84691e7870 ("i3c: dw: use adapter timeout value for I2C transfers")
Fixes: be27ed672878 ("i3c: master: cdns: use adapter timeout value for I2C transfers")
Fixes: c0a90eb55a69 ("i3c: mipi-i3c-hci: use adapter timeout value for I2C transfers")
Fixes: a747e01adad2 ("i3c: master: svc: use adapter timeout value for I2C transfers")
Fixes: d028219a9f14 ("i3c: master: Add basic driver for the Renesas I3C controller")
Fixes: 3a379bbcea0a ("i3c: Add core I3C infrastructure")
Cc: stable@vger.kernel.org # 6.17
Signed-off-by: Jarkko Nikula &lt;jarkko.nikula@linux.intel.com&gt;
Reviewed-by: Frank Li &lt;Frank.Li@nxp.com&gt;
Reviewed-by: Wolfram Sang &lt;wsa+renesas@sang-engineering.com&gt;
Link: https://lore.kernel.org/r/20250905100320.954536-1-jarkko.nikula@linux.intel.com
Signed-off-by: Alexandre Belloni &lt;alexandre.belloni@bootlin.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>i3c: Standardize defines for specification parameters</title>
<updated>2025-07-30T23:33:20Z</updated>
<author>
<name>Wolfram Sang</name>
</author>
<published>2025-07-24T09:41:40Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=9c0609d685b27a0bb392390680207baa820ed118'/>
<id>urn:sha1:9c0609d685b27a0bb392390680207baa820ed118</id>
<content type='text'>
Align existing defines to follow the consistent pattern:
I3C_BUS_&lt;PARAM&gt;_&lt;MAX|MIN|TYP&gt;_&lt;UNIT&gt;. Prepare the codebase for adding
new parameters and help avoid duplication.

Signed-off-by: Wolfram Sang &lt;wsa+renesas@sang-engineering.com&gt;
Tested-by: Tommaso Merciai &lt;tommaso.merciai.xr@bp.renesas.com&gt;
Reviewed-by: Frank Li &lt;Frank.Li@nxp.com&gt;
Link: https://lore.kernel.org/r/20250724094146.6443-2-wsa+renesas@sang-engineering.com
Signed-off-by: Alexandre Belloni &lt;alexandre.belloni@bootlin.com&gt;
</content>
</entry>
<entry>
<title>i3c: prefix hexadecimal entries in sysfs</title>
<updated>2025-07-07T21:18:58Z</updated>
<author>
<name>Wolfram Sang</name>
</author>
<published>2025-07-07T11:54:08Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=12aa3e0cb0c6f8d406be00bc9f5d89bfbee7b9d9'/>
<id>urn:sha1:12aa3e0cb0c6f8d406be00bc9f5d89bfbee7b9d9</id>
<content type='text'>
Hexadecimal values in sysfs should be prefixed with '0x' like e.g. PCI
and SCSI already do it. Also ensure the two digit length since BCR and
DCR are a byte in size.

Signed-off-by: Wolfram Sang &lt;wsa+renesas@sang-engineering.com&gt;
Reviewed-by: Frank Li &lt;Frank.Li@nxp.com&gt;
Link: https://lore.kernel.org/r/20250707115409.73545-2-wsa+renesas@sang-engineering.com
Signed-off-by: Alexandre Belloni &lt;alexandre.belloni@bootlin.com&gt;
</content>
</entry>
<entry>
<title>i3c: master: replace ENOTSUPP with SUSV4-compliant EOPNOTSUPP</title>
<updated>2025-07-07T21:14:46Z</updated>
<author>
<name>Wolfram Sang</name>
</author>
<published>2025-06-28T19:20:28Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=d10a4c323883c41cf1b652309e61c48bce248e35'/>
<id>urn:sha1:d10a4c323883c41cf1b652309e61c48bce248e35</id>
<content type='text'>
Replace non-standard ENOTSUPP with the SUSV4-defined error code
EOPNOTSUPP to fix below checkpatch warning:
  "ENOTSUPP is not a SUSV4 error code, prefer EOPNOTSUPP"

Signed-off-by: Wolfram Sang &lt;wsa+renesas@sang-engineering.com&gt;
Reviewed-by: Frank Li &lt;Frank.Li@nxp.com&gt;
Link: https://lore.kernel.org/r/20250628192027.3932-6-wsa+renesas@sang-engineering.com
Signed-off-by: Alexandre Belloni &lt;alexandre.belloni@bootlin.com&gt;
</content>
</entry>
<entry>
<title>i3c: don't fail if GETHDRCAP is unsupported</title>
<updated>2025-07-07T21:14:26Z</updated>
<author>
<name>Wolfram Sang</name>
</author>
<published>2025-07-04T20:44:32Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=447270cdb41b1c8c3621bb14b93a6749f942556e'/>
<id>urn:sha1:447270cdb41b1c8c3621bb14b93a6749f942556e</id>
<content type='text'>
'I3C_BCR_HDR_CAP' is still spec v1.0 and has been renamed to 'advanced
capabilities' in v1.1 onwards. The ST pressure sensor LPS22DF does not
have HDR, but has the 'advanced cap' bit set. The core still wants to
get additional information using the CCC 'GETHDRCAP' (or GETCAPS in v1.1
onwards). Not all controllers support this CCC and will notify the upper
layers about it. For instantiating the device, we can ignore this
unsupported CCC as standard communication will work. Without this patch,
the device will not be instantiated at all.

Signed-off-by: Wolfram Sang &lt;wsa+renesas@sang-engineering.com&gt;
Reviewed-by: Frank Li &lt;Frank.Li@nxp.com&gt;
Link: https://lore.kernel.org/r/20250704204524.6124-1-wsa+renesas@sang-engineering.com
Signed-off-by: Alexandre Belloni &lt;alexandre.belloni@bootlin.com&gt;
</content>
</entry>
<entry>
<title>i3c: master: Initialize ret in i3c_i2c_notifier_call()</title>
<updated>2025-07-03T23:15:56Z</updated>
<author>
<name>Jorge Marques</name>
</author>
<published>2025-06-22T10:11:07Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=290ce8b2d0745e45a3155268184523a8c75996f1'/>
<id>urn:sha1:290ce8b2d0745e45a3155268184523a8c75996f1</id>
<content type='text'>
Set ret to -EINVAL if i3c_i2c_notifier_call() receives an invalid
action, resolving uninitialized warning.

Signed-off-by: Jorge Marques &lt;jorge.marques@analog.com&gt;
Reviewed-by: Frank Li &lt;Frank.Li@nxp.com&gt;
Link: https://lore.kernel.org/r/20250622-i3c-master-ret-uninitialized-v1-1-aabb5625c932@analog.com
Signed-off-by: Alexandre Belloni &lt;alexandre.belloni@bootlin.com&gt;
</content>
</entry>
<entry>
<title>i3c: Add NULL pointer check in i3c_master_queue_ibi()</title>
<updated>2025-03-31T09:44:00Z</updated>
<author>
<name>Manjunatha Venkatesh</name>
</author>
<published>2025-03-26T12:30:46Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=bd496a44f041da9ef3afe14d1d6193d460424e91'/>
<id>urn:sha1:bd496a44f041da9ef3afe14d1d6193d460424e91</id>
<content type='text'>
The I3C master driver may receive an IBI from a target device that has not
been probed yet. In such cases, the master calls `i3c_master_queue_ibi()`
to queue an IBI work task, leading to "Unable to handle kernel read from
unreadable memory" and resulting in a kernel panic.

Typical IBI handling flow:
1. The I3C master scans target devices and probes their respective drivers.
2. The target device driver calls `i3c_device_request_ibi()` to enable IBI
   and assigns `dev-&gt;ibi = ibi`.
3. The I3C master receives an IBI from the target device and calls
   `i3c_master_queue_ibi()` to queue the target device driver’s IBI
   handler task.

However, since target device events are asynchronous to the I3C probe
sequence, step 3 may occur before step 2, causing `dev-&gt;ibi` to be `NULL`,
leading to a kernel panic.

Add a NULL pointer check in `i3c_master_queue_ibi()` to prevent accessing
an uninitialized `dev-&gt;ibi`, ensuring stability.

Fixes: 3a379bbcea0af ("i3c: Add core I3C infrastructure")
Cc: stable@vger.kernel.org
Link: https://lore.kernel.org/lkml/Z9gjGYudiYyl3bSe@lizhi-Precision-Tower-5810/
Signed-off-by: Manjunatha Venkatesh &lt;manjunatha.venkatesh@nxp.com&gt;
Reviewed-by: Frank Li &lt;Frank.Li@nxp.com&gt;
Link: https://lore.kernel.org/r/20250326123047.2797946-1-manjunatha.venkatesh@nxp.com
Signed-off-by: Alexandre Belloni &lt;alexandre.belloni@bootlin.com&gt;
</content>
</entry>
<entry>
<title>i3c: master: Drop duplicate check before calling OF APIs</title>
<updated>2025-03-31T09:41:48Z</updated>
<author>
<name>Andy Shevchenko</name>
</author>
<published>2025-03-21T19:30:06Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=465e5486aa5e1cdedc910bc3487ca92c5e6d51c4'/>
<id>urn:sha1:465e5486aa5e1cdedc910bc3487ca92c5e6d51c4</id>
<content type='text'>
OF APIs are usually NULL-aware and returns an error in case when
device node is not present or supported. We already have a check
for the returned value, no need to check for the parameter.

Signed-off-by: Andy Shevchenko &lt;andriy.shevchenko@linux.intel.com&gt;
Reviewed-by: Frank Li &lt;Frank.Li@nxp.com&gt;
Link: https://lore.kernel.org/r/20250321193044.457649-1-andriy.shevchenko@linux.intel.com
Signed-off-by: Alexandre Belloni &lt;alexandre.belloni@bootlin.com&gt;
</content>
</entry>
<entry>
<title>i3c: master: Improve initialization of numbered I2C adapters</title>
<updated>2025-01-12T23:01:42Z</updated>
<author>
<name>Defa Li</name>
</author>
<published>2024-12-12T09:17:53Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5eb6d3561f6cb6d59887be6da764417e437f6afa'/>
<id>urn:sha1:5eb6d3561f6cb6d59887be6da764417e437f6afa</id>
<content type='text'>
Add logic to initialize I2C adapters with a specific ID if available,
improving device identification and configuration.

For mixed buses, in addition to the i3c alias, an i2c alias can be added to
assign a fixed bus number to the i2c adapter.

This allows an alias node such as:
    aliases {
        i2c2 = &amp;mixed_bus_a,
        i3c2 = &amp;mixed_bus_a,
        i3c4 = &amp;mixed_bus_b,
    };

    /* assigned "i3c-2" and "i2c-2" */
    mixed_bus_a: i3c-master {
    };

If there is no i2c alias for a mixed bus, the i2c adapter numbers will
remain as is and will be assigned starting after the highest fixed bus
number.

    /* assigned "i3c-4" and likely assigned "i2c-3" */
    mixed_bus_b: i3c-master {
    };

Signed-off-by: Defa Li &lt;defa.li@mediatek.com&gt;
Reviewed-by: Frank Li &lt;Frank.Li@nxp.com&gt;
Link: https://lore.kernel.org/r/20241212091818.8591-1-defa.li@mediatek.com
Signed-off-by: Alexandre Belloni &lt;alexandre.belloni@bootlin.com&gt;
</content>
</entry>
</feed>
