summaryrefslogtreecommitdiff
path: root/include/sound
diff options
context:
space:
mode:
authorOswald Buddenhagen <oswald.buddenhagen@gmx.de>2023-04-21 16:10:06 +0200
committerTakashi Iwai <tiwai@suse.de>2023-04-22 10:41:25 +0200
commit02a0d9c281401d4e1eb0f83ed337c8c6a70194d2 (patch)
tree07f0b78c33775af9cf5227f1952e420665b74f50 /include/sound
parent14a5c5a44b61953b3f84a01152fe1d40838f5d91 (diff)
ALSA: emu10k1: clean up P16V part somewhat
Detach it better from the main PCM driver, which it really doesn't have much in common with. In particular, this moves the interrupt handler implementation into p16v.c, and makes it access the substream runtime status more directly, so it doesn't need to abuse structs snd_emu10k1_pcm and snd_emu10k1_voice any more. We don't need private pcm runtime data at all, as the only thing it was used for (except the back-link to the substream) was the `running` flag. So store that directly in runtime->private_data. This somewhat radical strip-down shows that this driver contains some complexity that was never actually utilized. I suppose the right way to fully utilize the hardware in a simple way would be introducing more substreams. This wouldn't require any of the removed code. Signed-off-by: Oswald Buddenhagen <oswald.buddenhagen@gmx.de> Link: https://lore.kernel.org/r/20230421141006.1005452-7-oswald.buddenhagen@gmx.de Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'include/sound')
-rw-r--r--include/sound/emu10k1.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/include/sound/emu10k1.h b/include/sound/emu10k1.h
index a1ea022bcdc8..ba2d48b38710 100644
--- a/include/sound/emu10k1.h
+++ b/include/sound/emu10k1.h
@@ -1735,8 +1735,6 @@ struct snd_emu10k1 {
spinlock_t i2c_lock; /* serialises access to i2c port */
struct snd_emu10k1_voice voices[NUM_G];
- struct snd_emu10k1_voice p16v_voices[4];
- struct snd_emu10k1_voice p16v_capture_voice;
int p16v_device_offset;
u32 p16v_capture_source;
u32 p16v_capture_channel;
@@ -1756,6 +1754,7 @@ struct snd_emu10k1 {
void (*capture_efx_interrupt)(struct snd_emu10k1 *emu, unsigned int status);
void (*spdif_interrupt)(struct snd_emu10k1 *emu, unsigned int status);
void (*dsp_interrupt)(struct snd_emu10k1 *emu);
+ void (*p16v_interrupt)(struct snd_emu10k1 *emu);
struct snd_pcm_substream *pcm_capture_substream;
struct snd_pcm_substream *pcm_capture_mic_substream;