ALSA: korg1212: Replace the pending stop check code with sync_stop PCM ops
authorTakashi Iwai <tiwai@suse.de>
Tue, 15 Apr 2025 15:55:21 +0000 (17:55 +0200)
committerTakashi Iwai <tiwai@suse.de>
Tue, 29 Apr 2025 12:53:54 +0000 (14:53 +0200)
commit26d87c55d19a4f4a76e5cc4b4188640badc3bbb1
treee1f346ad859b9f7519f4f782a3c159088ee5d5e9
parentbdd9ea9187c4722d3256055de683a85341157a53
ALSA: korg1212: Replace the pending stop check code with sync_stop PCM ops

The korg1212 driver has an overly complex code with the timer API to
check the pending stop operation and to sync at the prepare stage.
This very same thing can be achieved more simply by the PCM sync_stop
ops without timer, and this patch implements it.

Along with the rewrite to sync_stop ops, the flag
dsp_stop_is_processed is replaced with dsp_stop_processing to indicate
the stop operation is pending, not to indicate it's finished.  In that
way, wait_for_event() can be used more straightforwardly.

Link: https://lore.kernel.org/590769506CF46967+20250414042629.63019-5-wangyuli@uniontech.com
Link: https://patch.msgid.link/20250415155522.7998-1-tiwai@suse.de
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/pci/korg1212/korg1212.c