<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/sound/core/compress_offload.c, branch linux-rolling-stable</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-rolling-stable</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-rolling-stable'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2026-02-26T23:00:56Z</updated>
<entry>
<title>ALSA: compress_offload: Relax __free() variable declarations</title>
<updated>2026-02-26T23:00:56Z</updated>
<author>
<name>Takashi Iwai</name>
</author>
<published>2025-12-16T14:06:23Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=d48a6616af1c025809a70f10895eff908b3906d4'/>
<id>urn:sha1:d48a6616af1c025809a70f10895eff908b3906d4</id>
<content type='text'>
[ Upstream commit 14324b8f0760ca6f56202bb4ad356ec459ce165b ]

We used to have a variable declaration with __free() initialized with
NULL.  This was to keep the old coding style rule, but recently it's
relaxed and rather recommends to follow the new rule to declare in
place of use for __free() -- which avoids potential deadlocks or UAFs
with nested cleanups.

Although the current code has no bug, per se, let's follow the new
standard and move the declaration to the place of assignment.

Fixes: 9b02221422a5 ("ALSA: compress_offload: Use automatic cleanup of kfree()")
Fixes: 04177158cf98 ("ALSA: compress_offload: introduce accel operation mode")
Signed-off-by: Takashi Iwai &lt;tiwai@suse.de&gt;
Link: https://patch.msgid.link/20251216140634.171890-2-tiwai@suse.de
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>ALSA: compress_offload: Add SNDRV_COMPRESS_AVAIL64 ioctl</title>
<updated>2025-09-08T07:33:24Z</updated>
<author>
<name>Joris Verhaegen</name>
</author>
<published>2025-09-05T09:12:56Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=86eec88c5bddf9a57bfebe701d9c7a4d439aed9b'/>
<id>urn:sha1:86eec88c5bddf9a57bfebe701d9c7a4d439aed9b</id>
<content type='text'>
The previous patch introduced a 64-bit timestamp ioctl
(SNDRV_COMPRESS_TSTAMP64). To provide a consistent API, this patch
adds a corresponding 64-bit version of the SNDRV_COMPRESS_AVAIL ioctl.

A new struct snd_compr_avail64 is added to the UAPI, which includes
the 64-bit timestamp. The existing ioctl implementation is refactored
to handle both the 32-bit and 64-bit variants.

Reviewed-by: Miller Liang &lt;millerliang@google.com&gt;
Tested-by: Joris Verhaegen &lt;verhaegen@google.com&gt;
Signed-off-by: Joris Verhaegen &lt;verhaegen@google.com&gt;
Acked-by: Vinod Koul &lt;vkoul@kernel.org&gt;
Reviewed-by: Charles Keepax &lt;ckeepax@opensource.cirrus.com&gt;
Signed-off-by: Takashi Iwai &lt;tiwai@suse.de&gt;
Link: https://patch.msgid.link/20250905091301.2711705-4-verhaegen@google.com
</content>
</entry>
<entry>
<title>ALSA: compress_offload: Add SNDRV_COMPRESS_TSTAMP64 ioctl</title>
<updated>2025-09-08T07:33:24Z</updated>
<author>
<name>Joris Verhaegen</name>
</author>
<published>2025-09-05T09:12:55Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=f20a53974f79619d0ef6c9f17bb8693499fb6ebb'/>
<id>urn:sha1:f20a53974f79619d0ef6c9f17bb8693499fb6ebb</id>
<content type='text'>
The previous patch introduced the internal infrastructure for handling
64-bit timestamps. This patch exposes this capability to user-space.

Define the new ioctl command SNDRV_COMPRESS_TSTAMP64, which allows
applications to fetch the overflow-safe struct snd_compr_tstamp64.

The ioctl dispatch table is updated to handle the new command by
calling a new snd_compr_tstamp64 handler, while the legacy path is
renamed to snd_compr_tstamp32 for clarity.

This patch bumps the SNDRV_COMPRESS_VERSION to 0.4.0.

Reviewed-by: Miller Liang &lt;millerliang@google.com&gt;
Tested-by: Joris Verhaegen &lt;verhaegen@google.com&gt;
Signed-off-by: Joris Verhaegen &lt;verhaegen@google.com&gt;
Reviewed-by: Charles Keepax &lt;ckeepax@opensource.cirrus.com&gt;
Acked-by: Mark Brown &lt;broonie@kernel.org&gt;
Acked-by: Vinod Koul &lt;vkoul@kernel.org&gt;
Signed-off-by: Takashi Iwai &lt;tiwai@suse.de&gt;
Link: https://patch.msgid.link/20250905091301.2711705-3-verhaegen@google.com
</content>
</entry>
<entry>
<title>ALSA: compress_offload: Add 64-bit safe timestamp infrastructure</title>
<updated>2025-09-08T07:33:24Z</updated>
<author>
<name>Joris Verhaegen</name>
</author>
<published>2025-09-05T09:12:54Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=2c92e2fbe9e22cefdae87d8a0d654691ee4c1957'/>
<id>urn:sha1:2c92e2fbe9e22cefdae87d8a0d654691ee4c1957</id>
<content type='text'>
The copied_total field in struct snd_compr_tstamp is a 32-bit
value that can overflow on long-running high-bitrate streams,
leading to incorrect calculations for buffer availablility.

This patch adds a 64-bit safe timestamping mechanism.
A new UAPI struct, snd_compr_tstamp64, is added which uses 64-bit
types for byte counters. The relevant ops structures across the
ASoC and core compress code are updated to use this new struct.
ASoC drivers are updated to use u64 counters.

Internal timestamps being u64 now, a compatibility function is added
to convert the 64-bit timestamp back to the 32-bit format for legacy
ioctl callers.

Reviewed-by: Miller Liang &lt;millerliang@google.com&gt;
Tested-by: Joris Verhaegen &lt;verhaegen@google.com&gt;
Signed-off-by: Joris Verhaegen &lt;verhaegen@google.com&gt;
Reviewed-by: Srinivas Kandagatla &lt;srinivas.kandagatla@oss.qualcomm.com&gt;
Reviewed-by: Charles Keepax &lt;ckeepax@opensource.cirrus.com&gt;
Acked-by: Mark Brown &lt;broonie@kernel.org&gt;
Acked-by: Vinod Koul &lt;vkoul@kernel.org&gt;
Signed-off-by: Takashi Iwai &lt;tiwai@suse.de&gt;
Link: https://patch.msgid.link/20250905091301.2711705-2-verhaegen@google.com
</content>
</entry>
<entry>
<title>ALSA: compress_offload: tighten ioctl command number checks</title>
<updated>2025-07-10T08:10:08Z</updated>
<author>
<name>Arnd Bergmann</name>
</author>
<published>2025-07-10T06:30:49Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=19c4096ccdd809c6213e2e62b0d4f57c880138cd'/>
<id>urn:sha1:19c4096ccdd809c6213e2e62b0d4f57c880138cd</id>
<content type='text'>
The snd_compr_ioctl() ignores the upper 24 bits of the ioctl command
number and only compares the number of the ioctl command, which can
cause unintended behavior if an application tries to use an unsupprted
command that happens to have the same _IOC_NR() value.

Remove the truncation to the low bits and compare the entire ioctl
command code like every other driver does.

Fixes: b21c60a4edd2 ("ALSA: core: add support for compress_offload")
Signed-off-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Acked-by: Vinod Koul &lt;vkoul@kernel.org&gt;
Link: https://patch.msgid.link/20250710063059.2683476-1-arnd@kernel.org
Signed-off-by: Takashi Iwai &lt;tiwai@suse.de&gt;
</content>
</entry>
<entry>
<title>ALSA: compress_offload: fix remaining descriptor races in sound/core/compress_offload.c</title>
<updated>2024-12-30T10:49:38Z</updated>
<author>
<name>Al Viro</name>
</author>
<published>2024-12-29T18:52:32Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=7439b395211874e20c24b2fe0e4903864357a3f5'/>
<id>urn:sha1:7439b395211874e20c24b2fe0e4903864357a3f5</id>
<content type='text'>
3d3f43fab4cf ("ALSA: compress_offload: improve file descriptors
installation for dma-buf") fixed some of descriptor races in
snd_compr_task_new(), but there's a couple more left.

We need to grab the references to dmabuf before moving them into
descriptor table - trying to do that by descriptor afterwards might
end up getting a different object, with a dangling reference left in
task-&gt;{input,output}

Fixes: 3d3f43fab4cf ("ALSA: compress_offload: improve file descriptors installation for dma-buf")
Signed-off-by: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
Link: https://patch.msgid.link/20241229185232.GA1977892@ZenIV
Signed-off-by: Takashi Iwai &lt;tiwai@suse.de&gt;
</content>
</entry>
<entry>
<title>ALSA: compress_offload: Drop unneeded no_free_ptr()</title>
<updated>2024-12-30T10:40:41Z</updated>
<author>
<name>Takashi Iwai</name>
</author>
<published>2024-12-29T08:39:13Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=ac9fae799eda81e24bbf2e0d5cb9e5c33fc9bdcb'/>
<id>urn:sha1:ac9fae799eda81e24bbf2e0d5cb9e5c33fc9bdcb</id>
<content type='text'>
The error path for memdup_user() no longer needs the tricky wrap with
no_free_ptr() and we can safely return the error pointer directly.

Fixes: 04177158cf98 ("ALSA: compress_offload: introduce accel operation mode")
Reported-by: kernel test robot &lt;lkp@intel.com&gt;
Closes: https://lore.kernel.org/oe-kbuild-all/202412290846.cncnpGaw-lkp@intel.com/
Link: https://patch.msgid.link/20241229083917.14912-1-tiwai@suse.de
Signed-off-by: Takashi Iwai &lt;tiwai@suse.de&gt;
</content>
</entry>
<entry>
<title>ALSA: compress_offload: improve file descriptors installation for dma-buf</title>
<updated>2024-12-20T08:52:15Z</updated>
<author>
<name>Jaroslav Kysela</name>
</author>
<published>2024-12-17T10:07:26Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=3d3f43fab4cfb9cf245e3dbffa1736ce925bb54a'/>
<id>urn:sha1:3d3f43fab4cfb9cf245e3dbffa1736ce925bb54a</id>
<content type='text'>
Avoid to use single dma_buf_fd() call for both directions. This code
ensures that both file descriptors are allocated before fd_install().

Link: https://lore.kernel.org/linux-sound/6a923647-4495-4cff-a253-b73f48cfd0ea@stanley.mountain/
Fixes: 04177158cf98 ("ALSA: compress_offload: introduce accel operation mode")
Reported-by: Dan Carpenter &lt;dan.carpenter@linaro.org&gt;
Cc: Vinod Koul &lt;vkoul@kernel.org&gt;
Signed-off-by: Jaroslav Kysela &lt;perex@perex.cz&gt;
Signed-off-by: Takashi Iwai &lt;tiwai@suse.de&gt;
Link: https://patch.msgid.link/20241217100726.732863-1-perex@perex.cz
</content>
</entry>
<entry>
<title>ALSA: compress_offload: use safe list iteration in snd_compr_task_seq()</title>
<updated>2024-12-20T08:51:36Z</updated>
<author>
<name>Jaroslav Kysela</name>
</author>
<published>2024-12-17T10:07:07Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=f25a51b47c61540585a9e8a4e16f91677ebcbbc4'/>
<id>urn:sha1:f25a51b47c61540585a9e8a4e16f91677ebcbbc4</id>
<content type='text'>
The sequence function can call snd_compr_task_free_one(). Use
list_for_each_entry_safe_reverse() to make sure that the used
pointers are safe.

Link: https://lore.kernel.org/linux-sound/f2769cff-6c7a-4092-a2d1-c33a5411a182@stanley.mountain/
Fixes: 04177158cf98 ("ALSA: compress_offload: introduce accel operation mode")
Reported-by: Dan Carpenter &lt;dan.carpenter@linaro.org&gt;
Cc: Vinod Koul &lt;vkoul@kernel.org&gt;
Signed-off-by: Jaroslav Kysela &lt;perex@perex.cz&gt;
Signed-off-by: Takashi Iwai &lt;tiwai@suse.de&gt;
Link: https://patch.msgid.link/20241217100707.732766-1-perex@perex.cz
</content>
</entry>
<entry>
<title>ALSA: compress_offload: avoid 64-bit get_user()</title>
<updated>2024-12-20T08:49:15Z</updated>
<author>
<name>Arnd Bergmann</name>
</author>
<published>2024-12-16T09:33:41Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=6018f2fe1089b46c6c9eb136338eca7b16a92331'/>
<id>urn:sha1:6018f2fe1089b46c6c9eb136338eca7b16a92331</id>
<content type='text'>
On some architectures, get_user() cannot read a 64-bit user variable:

arm-linux-gnueabi-ld: sound/core/compress_offload.o: in function `snd_compr_ioctl':
compress_offload.c:(.text.snd_compr_ioctl+0x538): undefined reference to `__get_user_bad'

Use an equivalent copy_from_user() instead.

Fixes: 04177158cf98 ("ALSA: compress_offload: introduce accel operation mode")
Signed-off-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Acked-by: Shengjiu Wang &lt;shengjiu.wang@gmail.com&gt;
Acked-by: Vinod Koul &lt;vkoul@kernel.org&gt;
Signed-off-by: Takashi Iwai &lt;tiwai@suse.de&gt;
Link: https://patch.msgid.link/20241216093410.377112-2-arnd@kernel.org
</content>
</entry>
</feed>
