<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/sound/isa/sb, branch linux-6.9.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-6.9.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-6.9.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2023-09-02T06:11:55Z</updated>
<entry>
<title>ALSA: sb: Fix wrong argument in commented code</title>
<updated>2023-09-02T06:11:55Z</updated>
<author>
<name>Takashi Iwai</name>
</author>
<published>2023-09-02T06:10:44Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=4cbc7d9cdfbed4c0ab65c3061af901fa8ec971ff'/>
<id>urn:sha1:4cbc7d9cdfbed4c0ab65c3061af901fa8ec971ff</id>
<content type='text'>
While rewriting the code from sockptr_t to iov_iter during the
development, I forgot to replace one place in emu8000-pcm code.  As
it's in the disabled area (with ifdef), it's never built and
overlooked.  Replace with the proper argument NULL.

Fixes: 9d0fdc602de9 ("ALSA: emu8000: Convert to generic PCM copy ops")
Reported-by: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
Closes: https://lore.kernel.org/r/20230902053646.GK3390869@ZenIV
Link: https://lore.kernel.org/r/20230902061044.19366-2-tiwai@suse.de
Signed-off-by: Takashi Iwai &lt;tiwai@suse.de&gt;
</content>
</entry>
<entry>
<title>ALSA: emu8000: Convert to generic PCM copy ops</title>
<updated>2023-08-18T10:18:19Z</updated>
<author>
<name>Takashi Iwai</name>
</author>
<published>2023-08-15T19:01:17Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=9d0fdc602de9d4368ce58da158725d2c43765fd1'/>
<id>urn:sha1:9d0fdc602de9d4368ce58da158725d2c43765fd1</id>
<content type='text'>
This patch converts the SB Emu8000 driver code to use the new unified
PCM copy callback.  The conversion is a bit complicated because of
many open code in emu8000_pcm.c.  GET_VAL() and LOOP_WRITE() macros
were rewritten / simplified with copy_from_iter().  As
copy_from_iter() updates the internal offset value, we can drop the
corresponding part, too.

Link: https://lore.kernel.org/r/20230815190136.8987-7-tiwai@suse.de
Signed-off-by: Takashi Iwai &lt;tiwai@suse.de&gt;
</content>
</entry>
<entry>
<title>ALSA: control: Take controls_rwsem lock in snd_ctl_remove()</title>
<updated>2023-07-20T08:01:27Z</updated>
<author>
<name>Takashi Iwai</name>
</author>
<published>2023-07-18T14:12:57Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=192c4cccd015f52c94d0420eb5d7305a1ca28998'/>
<id>urn:sha1:192c4cccd015f52c94d0420eb5d7305a1ca28998</id>
<content type='text'>
So far, snd_ctl_remove() requires its caller to take
card-&gt;controls_rwsem manually before the call for avoiding possible
races.  However, many callers don't care and miss the locking.

Basically it's cumbersome and error-prone to enforce it to each
caller.  Moreover, card-&gt;controls_rwsem is a field that should be used
only by internal or proper helpers, and it's not to be touched at
random external places.

This patch is an attempt to make those calls more consistent: now
snd_ctl_remove() takes the card-&gt;controls_rwsem internally, just like
other API functions for kctls.  Since a few callers already take the
controls_rwsem locks, the patch removes those locks at the same time,
too.

Link: https://lore.kernel.org/r/20230718141304.1032-5-tiwai@suse.de
Signed-off-by: Takashi Iwai &lt;tiwai@suse.de&gt;
</content>
</entry>
<entry>
<title>ALSA: sb: Use DIV_ROUND_UP() instead of open-coding it</title>
<updated>2022-09-29T06:11:55Z</updated>
<author>
<name>Shang XiaoJing</name>
</author>
<published>2022-09-27T14:11:10Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=eefe77fdc0de86480f5dbb6bc721396d82d095d3'/>
<id>urn:sha1:eefe77fdc0de86480f5dbb6bc721396d82d095d3</id>
<content type='text'>
Use DIV_ROUND_UP() instead of open-coding it, which intents and makes
it more clear what is going on for the casual reviewer.

The Coccinelle references Commit e4d8aef21403 ("ALSA: usb: Use
DIV_ROUND_UP() instead of open-coding it").

Signed-off-by: Shang XiaoJing &lt;shangxiaojing@huawei.com&gt;
Link: https://lore.kernel.org/r/20220927141110.18033-1-shangxiaojing@huawei.com
Signed-off-by: Takashi Iwai &lt;tiwai@suse.de&gt;
</content>
</entry>
<entry>
<title>Merge branch 'for-linus' into for-next</title>
<updated>2021-08-02T07:04:48Z</updated>
<author>
<name>Takashi Iwai</name>
</author>
<published>2021-08-02T07:04:48Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=01099b1ad9101ca3f41071a87b9c496d9ea1d2ad'/>
<id>urn:sha1:01099b1ad9101ca3f41071a87b9c496d9ea1d2ad</id>
<content type='text'>
</content>
</entry>
<entry>
<title>ALSA: sb: Allocate resources with device-managed APIs</title>
<updated>2021-07-19T14:17:14Z</updated>
<author>
<name>Takashi Iwai</name>
</author>
<published>2021-07-15T07:59:16Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5eab6cb0344d06dc654f3f98a44359e07fc98179'/>
<id>urn:sha1:5eab6cb0344d06dc654f3f98a44359e07fc98179</id>
<content type='text'>
This patch converts the resource management in ISA sb drivers with
devres as a clean up.  Each manual resource management is converted
with the corresponding devres helper, and the card object release is
managed now via card-&gt;private_free instead of a lowlevel snd_device.

This should give no user-visible functional changes.

Link: https://lore.kernel.org/r/20210715075941.23332-55-tiwai@suse.de
Signed-off-by: Takashi Iwai &lt;tiwai@suse.de&gt;
</content>
</entry>
<entry>
<title>ALSA: sb: Fix potential ABBA deadlock in CSP driver</title>
<updated>2021-07-17T07:55:10Z</updated>
<author>
<name>Takashi Iwai</name>
</author>
<published>2021-07-16T13:27:23Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=1c2b9519159b470ef24b2638f4794e86e2952ab7'/>
<id>urn:sha1:1c2b9519159b470ef24b2638f4794e86e2952ab7</id>
<content type='text'>
SB16 CSP driver may hit potentially a typical ABBA deadlock in two
code paths:

 In snd_sb_csp_stop():
     spin_lock_irqsave(&amp;p-&gt;chip-&gt;mixer_lock, flags);
     spin_lock(&amp;p-&gt;chip-&gt;reg_lock);

 In snd_sb_csp_load():
     spin_lock_irqsave(&amp;p-&gt;chip-&gt;reg_lock, flags);
     spin_lock(&amp;p-&gt;chip-&gt;mixer_lock);

Also the similar pattern is seen in snd_sb_csp_start().

Although the practical impact is very small (those states aren't
triggered in the same running state and this happens only on a real
hardware, decades old ISA sound boards -- which must be very difficult
to find nowadays), it's a real scenario and has to be fixed.

This patch addresses those deadlocks by splitting the locks in
snd_sb_csp_start() and snd_sb_csp_stop() for avoiding the nested
locks.

Reported-by: Jia-Ju Bai &lt;baijiaju1990@gmail.com&gt;
Cc: &lt;stable@vger.kernel.org&gt;
Link: https://lore.kernel.org/r/7b0fcdaf-cd4f-4728-2eae-48c151a92e10@gmail.com
Link: https://lore.kernel.org/r/20210716132723.13216-1-tiwai@suse.de
Signed-off-by: Takashi Iwai &lt;tiwai@suse.de&gt;
</content>
</entry>
<entry>
<title>Merge tag 'asoc-fix-v5.13-rc7' of https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-next</title>
<updated>2021-06-24T08:02:45Z</updated>
<author>
<name>Takashi Iwai</name>
</author>
<published>2021-06-24T08:02:45Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5c89c2c7fbfa9124dd521c375b9c82b9ed75bc28'/>
<id>urn:sha1:5c89c2c7fbfa9124dd521c375b9c82b9ed75bc28</id>
<content type='text'>
ASoC: Fixes for v5.13

A final batch of fixes for v5.13, this is larger than I'd like due to
the fixes for a series of suspend issues that Intel turned up in their
testing this week.
</content>
</entry>
<entry>
<title>ALSA: sb: Fix potential double-free of CSP mixer elements</title>
<updated>2021-06-09T15:29:38Z</updated>
<author>
<name>Takashi Iwai</name>
</author>
<published>2021-06-08T14:04:37Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=c305366a37441c2ac90b08711cb6f032b43672f2'/>
<id>urn:sha1:c305366a37441c2ac90b08711cb6f032b43672f2</id>
<content type='text'>
snd_sb_qsound_destroy() contains the calls of removing the previously
created mixer controls, but it doesn't clear the pointers.  As
snd_sb_qsound_destroy() itself may be repeatedly called via ioctl,
this could lead to double-free potentially.

Fix it by clearing the struct fields properly afterwards.

Link: https://lore.kernel.org/r/20210608140540.17885-4-tiwai@suse.de
Signed-off-by: Takashi Iwai &lt;tiwai@suse.de&gt;
</content>
</entry>
<entry>
<title>ALSA: sb: Minor coding style fixes</title>
<updated>2021-06-09T15:29:37Z</updated>
<author>
<name>Takashi Iwai</name>
</author>
<published>2021-06-08T14:04:36Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=36e7b12b219dc30a4db046756d81745bc9d69167'/>
<id>urn:sha1:36e7b12b219dc30a4db046756d81745bc9d69167</id>
<content type='text'>
The handling of snd_ctl_new1() and snd_ctl_add() can be sometimes
tricky, as snd_ctl_add() automatically removes the passed object at
its error path.  The recent fix addressed an overlooked issue that is
relevant with that in SB driver code, and it can be a bit more
simplified by assigning to a temporary variable, i.e. storing to the
struct field only after the creation succeeds.

Link: https://lore.kernel.org/r/20210608140540.17885-3-tiwai@suse.de
Signed-off-by: Takashi Iwai &lt;tiwai@suse.de&gt;
</content>
</entry>
</feed>
