<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/base/regmap, branch v6.14</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v6.14</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v6.14'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2025-02-05T11:55:42Z</updated>
<entry>
<title>regmap-irq: Add missing kfree()</title>
<updated>2025-02-05T11:55:42Z</updated>
<author>
<name>Jiasheng Jiang</name>
<email>jiashengjiangcool@gmail.com</email>
</author>
<published>2025-02-05T00:43:43Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=32ffed055dcee17f6705f545b069e44a66067808'/>
<id>urn:sha1:32ffed055dcee17f6705f545b069e44a66067808</id>
<content type='text'>
Add kfree() for "d-&gt;main_status_buf" to the error-handling path to prevent
a memory leak.

Fixes: a2d21848d921 ("regmap: regmap-irq: Add main status register support")
Cc: stable@vger.kernel.org  # v5.1+
Signed-off-by: Jiasheng Jiang &lt;jiashengjiangcool@gmail.com&gt;
Link: https://patch.msgid.link/20250205004343.14413-1-jiashengjiangcool@gmail.com
Signed-off-by: Mark Brown &lt;broonie@kernel.org&gt;
</content>
</entry>
<entry>
<title>Expand SoundWire MBQ register map support</title>
<updated>2025-01-07T23:28:07Z</updated>
<author>
<name>Mark Brown</name>
<email>broonie@kernel.org</email>
</author>
<published>2025-01-07T23:28:07Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=d406b354df909155ff0122acf80f3bc7410fa27e'/>
<id>urn:sha1:d406b354df909155ff0122acf80f3bc7410fa27e</id>
<content type='text'>
Merge series from Charles Keepax &lt;ckeepax@opensource.cirrus.com&gt;:

The current SDCA MBQ (Multi-Byte Quantities) register map only
supports 16-bit types, add support for more sizes and then update
the rt722 driver to use the new support. We also add support for
the deferring feature of MBQs to allow hardware to indicate it is
not currently ready to service a read/write.

Afraid I don't have hardware to test the rt722 change so it is
only build tested, but I thought it good to include a change to
demonstrate the new features in use.
</content>
</entry>
<entry>
<title>regmap: sdw-mbq: Add support for SDCA deferred controls</title>
<updated>2025-01-07T20:21:00Z</updated>
<author>
<name>Charles Keepax</name>
<email>ckeepax@opensource.cirrus.com</email>
</author>
<published>2025-01-07T15:44:06Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=5bc493bf0c37c157bf2eb364e55a1c6f8bc43a69'/>
<id>urn:sha1:5bc493bf0c37c157bf2eb364e55a1c6f8bc43a69</id>
<content type='text'>
The SDCA specification allows for controls to be deferred. In the case
of a deferred control the device will return COMMAND_IGNORED to the
8-bit operation that would cause the value to commit. Which is the
final 8-bits on a write, or the first 8-bits on a read. In the case of
receiving a defer, the regmap will poll the SDCA function busy bit,
after which the transaction will be retried, returning an error if the
function busy does not clear within a chip specific timeout. Since
this is common SDCA functionality which is the 99% use-case for MBQs
it makes sense to incorporate this functionality into the register
map. If no MBQ configuration is specified, the behaviour will default
to the existing behaviour.

Signed-off-by: Charles Keepax &lt;ckeepax@opensource.cirrus.com&gt;
Link: https://patch.msgid.link/20250107154408.814455-5-ckeepax@opensource.cirrus.com
Reviewed-by: Pierre-Louis Bossart &lt;pierre-louis.bossart@linux.dev&gt;
Signed-off-by: Mark Brown &lt;broonie@kernel.org&gt;
</content>
</entry>
<entry>
<title>regmap: sdw-mbq: Add support for further MBQ register sizes</title>
<updated>2025-01-07T20:20:59Z</updated>
<author>
<name>Charles Keepax</name>
<email>ckeepax@opensource.cirrus.com</email>
</author>
<published>2025-01-07T15:44:05Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=fdd9ef3dce98e035d21c17fac587cb6e3c7706fd'/>
<id>urn:sha1:fdd9ef3dce98e035d21c17fac587cb6e3c7706fd</id>
<content type='text'>
SoundWire MBQ register maps typically contain a variety of register
sizes, which doesn't map ideally to the regmap abstraction which
expects register maps to have a consistent size. Currently the MBQ
register map only allows 16-bit registers to be defined, however
this leads to complex CODEC driver implementations with an 8-bit
register map and a 16-bit MBQ, every control will then have a custom
get and put handler that allows them to access different register
maps. Further more 32-bit MBQ quantities are not currently supported.

Add support for additional MBQ sizes and to avoid the complexity
of multiple register maps treat the val_size as a maximum size for
the register map. Within the regmap use an ancillary callback to
determine how many bytes to actually read/write to the hardware for
a specific register. In the case that no callback is defined the
behaviour defaults back to the existing behaviour of a fixed size
register map.

Signed-off-by: Charles Keepax &lt;ckeepax@opensource.cirrus.com&gt;
Link: https://patch.msgid.link/20250107154408.814455-4-ckeepax@opensource.cirrus.com
Reviewed-by: Pierre-Louis Bossart &lt;pierre-louis.bossart@linux.dev&gt;
Signed-off-by: Mark Brown &lt;broonie@kernel.org&gt;
</content>
</entry>
<entry>
<title>regmap: regmap_multi_reg_read(): make register list const</title>
<updated>2024-12-11T14:24:09Z</updated>
<author>
<name>Richard Fitzgerald</name>
<email>rf@opensource.cirrus.com</email>
</author>
<published>2024-12-11T13:35:58Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=eb708cd631a8dca17ff004ccc39bbeb096c1db22'/>
<id>urn:sha1:eb708cd631a8dca17ff004ccc39bbeb096c1db22</id>
<content type='text'>
Mark the list of registers passed into regmap_multi_reg_read() as a
pointer to const. This allows the caller to define the register list
as const data.

This requires making the same change to _regmap_bulk_read(), which is
called by regmap_multi_reg_read().

Signed-off-by: Richard Fitzgerald &lt;rf@opensource.cirrus.com&gt;
Link: https://patch.msgid.link/20241211133558.884669-1-rf@opensource.cirrus.com
Signed-off-by: Mark Brown &lt;broonie@kernel.org&gt;
</content>
</entry>
<entry>
<title>regmap: Merge up v6.12-rc2</title>
<updated>2024-12-09T12:50:45Z</updated>
<author>
<name>Mark Brown</name>
<email>broonie@kernel.org</email>
</author>
<published>2024-12-09T12:50:45Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=1331fb6640440f42a709eafd5c802f3496f746b8'/>
<id>urn:sha1:1331fb6640440f42a709eafd5c802f3496f746b8</id>
<content type='text'>
This has fixes for several boards which help my testing a lot.
</content>
</entry>
<entry>
<title>regmap: Cleanup and microoptimization</title>
<updated>2024-12-02T13:42:01Z</updated>
<author>
<name>Mark Brown</name>
<email>broonie@kernel.org</email>
</author>
<published>2024-12-02T13:42:01Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=a308f9e47fc2377863f0f561ceedd45ccc7c7f9c'/>
<id>urn:sha1:a308f9e47fc2377863f0f561ceedd45ccc7c7f9c</id>
<content type='text'>
Merge series from Andy Shevchenko &lt;andriy.shevchenko@linux.intel.com&gt;:

Two patches move the code to use BITS_TO_BYTES(), while the last
one otpimizes the code generation on x86 (32- and 64-bit on different
compilers).
</content>
</entry>
<entry>
<title>regmap: cache: rbtree: use krealloc_array() to replace krealloc()</title>
<updated>2024-12-02T00:31:16Z</updated>
<author>
<name>Andy Shevchenko</name>
<email>andriy.shevchenko@linux.intel.com</email>
</author>
<published>2024-11-21T12:34:39Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=b95cacd8d708bce5839db2767d425e20ae548fd8'/>
<id>urn:sha1:b95cacd8d708bce5839db2767d425e20ae548fd8</id>
<content type='text'>
Use krealloc_array() to replace krealloc() with multiplication.
krealloc_array() has multiply overflow check, which will be safer.

Signed-off-by: Andy Shevchenko &lt;andriy.shevchenko@linux.intel.com&gt;
Link: https://patch.msgid.link/20241121123439.4180167-1-andriy.shevchenko@linux.intel.com
Signed-off-by: Mark Brown &lt;broonie@kernel.org&gt;
</content>
</entry>
<entry>
<title>regmap: cache: mapple: use kmalloc_array() to replace kmalloc()</title>
<updated>2024-12-02T00:31:15Z</updated>
<author>
<name>Andy Shevchenko</name>
<email>andriy.shevchenko@linux.intel.com</email>
</author>
<published>2024-11-21T12:34:33Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=37c95f022a7a34823c123eeccdfe415b88562867'/>
<id>urn:sha1:37c95f022a7a34823c123eeccdfe415b88562867</id>
<content type='text'>
Use kmalloc_array() to replace kmalloc() with multiplication.
kmalloc_array() has multiply overflow check, which will be safer.
In once case change kcalloc() as we don't need to clear the memory
since it's all being reinitialised just immediately after that.

Signed-off-by: Andy Shevchenko &lt;andriy.shevchenko@linux.intel.com&gt;
Link: https://patch.msgid.link/20241121123433.4180133-1-andriy.shevchenko@linux.intel.com
Signed-off-by: Mark Brown &lt;broonie@kernel.org&gt;
</content>
</entry>
<entry>
<title>regmap: place foo / 8 and foo % 8 closer to each other</title>
<updated>2024-12-02T00:31:00Z</updated>
<author>
<name>Andy Shevchenko</name>
<email>andriy.shevchenko@linux.intel.com</email>
</author>
<published>2024-11-21T10:57:23Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=9b3cd5c7099fe7710356dd76ecf9910dc8c32548'/>
<id>urn:sha1:9b3cd5c7099fe7710356dd76ecf9910dc8c32548</id>
<content type='text'>
On x86 the compiler (gcc (Debian 14.2.0-8) 14.2.0) may generate
a better code if it sees division and modulo goes together.

  Function                          old     new   delta
  __regmap_init                    3740    3732      -8
  Total: Before=31159, After=31151, chg -0.03%

clang (Debian clang version 18.1.8) on x86_64 still shows better code

  Function                          old     new   delta
  __regmap_init                    3582    3579      -3
  Total: Before=39854, After=39851, chg -0.01%

Signed-off-by: Andy Shevchenko &lt;andriy.shevchenko@linux.intel.com&gt;
Link: https://patch.msgid.link/20241121105838.4073659-4-andriy.shevchenko@linux.intel.com
Signed-off-by: Mark Brown &lt;broonie@kernel.org&gt;
</content>
</entry>
</feed>
