forked from luck/tmp_suning_uos_patched
ALSA: pci: Constify snd_rawmidi_ops
Now snd_rawmidi_ops is maintained as a const pointer in snd_rawmidi, we can constify the definitions. Reviewed-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de>
This commit is contained in:
parent
9021b2b8fd
commit
485885b9d0
|
@ -255,14 +255,14 @@ static void ca_midi_output_trigger(struct snd_rawmidi_substream *substream, int
|
|||
}
|
||||
}
|
||||
|
||||
static struct snd_rawmidi_ops ca_midi_output =
|
||||
static const struct snd_rawmidi_ops ca_midi_output =
|
||||
{
|
||||
.open = ca_midi_output_open,
|
||||
.close = ca_midi_output_close,
|
||||
.trigger = ca_midi_output_trigger,
|
||||
};
|
||||
|
||||
static struct snd_rawmidi_ops ca_midi_input =
|
||||
static const struct snd_rawmidi_ops ca_midi_input =
|
||||
{
|
||||
.open = ca_midi_input_open,
|
||||
.close = ca_midi_input_close,
|
||||
|
|
|
@ -1767,14 +1767,14 @@ static void snd_cs4281_midi_output_trigger(struct snd_rawmidi_substream *substre
|
|||
spin_unlock_irqrestore(&chip->reg_lock, flags);
|
||||
}
|
||||
|
||||
static struct snd_rawmidi_ops snd_cs4281_midi_output =
|
||||
static const struct snd_rawmidi_ops snd_cs4281_midi_output =
|
||||
{
|
||||
.open = snd_cs4281_midi_output_open,
|
||||
.close = snd_cs4281_midi_output_close,
|
||||
.trigger = snd_cs4281_midi_output_trigger,
|
||||
};
|
||||
|
||||
static struct snd_rawmidi_ops snd_cs4281_midi_input =
|
||||
static const struct snd_rawmidi_ops snd_cs4281_midi_input =
|
||||
{
|
||||
.open = snd_cs4281_midi_input_open,
|
||||
.close = snd_cs4281_midi_input_close,
|
||||
|
|
|
@ -2683,14 +2683,14 @@ static void snd_cs46xx_midi_output_trigger(struct snd_rawmidi_substream *substre
|
|||
spin_unlock_irqrestore(&chip->reg_lock, flags);
|
||||
}
|
||||
|
||||
static struct snd_rawmidi_ops snd_cs46xx_midi_output =
|
||||
static const struct snd_rawmidi_ops snd_cs46xx_midi_output =
|
||||
{
|
||||
.open = snd_cs46xx_midi_output_open,
|
||||
.close = snd_cs46xx_midi_output_close,
|
||||
.trigger = snd_cs46xx_midi_output_trigger,
|
||||
};
|
||||
|
||||
static struct snd_rawmidi_ops snd_cs46xx_midi_input =
|
||||
static const struct snd_rawmidi_ops snd_cs46xx_midi_input =
|
||||
{
|
||||
.open = snd_cs46xx_midi_input_open,
|
||||
.close = snd_cs46xx_midi_input_close,
|
||||
|
|
|
@ -288,13 +288,13 @@ static int snd_echo_midi_output_close(struct snd_rawmidi_substream *substream)
|
|||
|
||||
|
||||
|
||||
static struct snd_rawmidi_ops snd_echo_midi_input = {
|
||||
static const struct snd_rawmidi_ops snd_echo_midi_input = {
|
||||
.open = snd_echo_midi_input_open,
|
||||
.close = snd_echo_midi_input_close,
|
||||
.trigger = snd_echo_midi_input_trigger,
|
||||
};
|
||||
|
||||
static struct snd_rawmidi_ops snd_echo_midi_output = {
|
||||
static const struct snd_rawmidi_ops snd_echo_midi_output = {
|
||||
.open = snd_echo_midi_output_open,
|
||||
.close = snd_echo_midi_output_close,
|
||||
.trigger = snd_echo_midi_output_trigger,
|
||||
|
|
|
@ -1486,14 +1486,14 @@ static void snd_emu10k1x_midi_output_trigger(struct snd_rawmidi_substream *subst
|
|||
|
||||
*/
|
||||
|
||||
static struct snd_rawmidi_ops snd_emu10k1x_midi_output =
|
||||
static const struct snd_rawmidi_ops snd_emu10k1x_midi_output =
|
||||
{
|
||||
.open = snd_emu10k1x_midi_output_open,
|
||||
.close = snd_emu10k1x_midi_output_close,
|
||||
.trigger = snd_emu10k1x_midi_output_trigger,
|
||||
};
|
||||
|
||||
static struct snd_rawmidi_ops snd_emu10k1x_midi_input =
|
||||
static const struct snd_rawmidi_ops snd_emu10k1x_midi_input =
|
||||
{
|
||||
.open = snd_emu10k1x_midi_input_open,
|
||||
.close = snd_emu10k1x_midi_input_close,
|
||||
|
|
|
@ -308,14 +308,14 @@ static void snd_emu10k1_midi_output_trigger(struct snd_rawmidi_substream *substr
|
|||
|
||||
*/
|
||||
|
||||
static struct snd_rawmidi_ops snd_emu10k1_midi_output =
|
||||
static const struct snd_rawmidi_ops snd_emu10k1_midi_output =
|
||||
{
|
||||
.open = snd_emu10k1_midi_output_open,
|
||||
.close = snd_emu10k1_midi_output_close,
|
||||
.trigger = snd_emu10k1_midi_output_trigger,
|
||||
};
|
||||
|
||||
static struct snd_rawmidi_ops snd_emu10k1_midi_input =
|
||||
static const struct snd_rawmidi_ops snd_emu10k1_midi_input =
|
||||
{
|
||||
.open = snd_emu10k1_midi_input_open,
|
||||
.close = snd_emu10k1_midi_input_close,
|
||||
|
|
|
@ -2317,14 +2317,14 @@ static void snd_ensoniq_midi_output_trigger(struct snd_rawmidi_substream *substr
|
|||
spin_unlock_irqrestore(&ensoniq->reg_lock, flags);
|
||||
}
|
||||
|
||||
static struct snd_rawmidi_ops snd_ensoniq_midi_output =
|
||||
static const struct snd_rawmidi_ops snd_ensoniq_midi_output =
|
||||
{
|
||||
.open = snd_ensoniq_midi_output_open,
|
||||
.close = snd_ensoniq_midi_output_close,
|
||||
.trigger = snd_ensoniq_midi_output_trigger,
|
||||
};
|
||||
|
||||
static struct snd_rawmidi_ops snd_ensoniq_midi_input =
|
||||
static const struct snd_rawmidi_ops snd_ensoniq_midi_input =
|
||||
{
|
||||
.open = snd_ensoniq_midi_input_open,
|
||||
.close = snd_ensoniq_midi_input_close,
|
||||
|
|
|
@ -367,7 +367,7 @@ static void vt1724_midi_output_drain(struct snd_rawmidi_substream *s)
|
|||
} while (time_after(timeout, jiffies));
|
||||
}
|
||||
|
||||
static struct snd_rawmidi_ops vt1724_midi_output_ops = {
|
||||
static const struct snd_rawmidi_ops vt1724_midi_output_ops = {
|
||||
.open = vt1724_midi_output_open,
|
||||
.close = vt1724_midi_output_close,
|
||||
.trigger = vt1724_midi_output_trigger,
|
||||
|
@ -402,7 +402,7 @@ static void vt1724_midi_input_trigger(struct snd_rawmidi_substream *s, int up)
|
|||
spin_unlock_irqrestore(&ice->reg_lock, flags);
|
||||
}
|
||||
|
||||
static struct snd_rawmidi_ops vt1724_midi_input_ops = {
|
||||
static const struct snd_rawmidi_ops vt1724_midi_input_ops = {
|
||||
.open = vt1724_midi_input_open,
|
||||
.close = vt1724_midi_input_close,
|
||||
.trigger = vt1724_midi_input_trigger,
|
||||
|
|
|
@ -1510,14 +1510,14 @@ static int snd_hdsp_midi_output_close(struct snd_rawmidi_substream *substream)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static struct snd_rawmidi_ops snd_hdsp_midi_output =
|
||||
static const struct snd_rawmidi_ops snd_hdsp_midi_output =
|
||||
{
|
||||
.open = snd_hdsp_midi_output_open,
|
||||
.close = snd_hdsp_midi_output_close,
|
||||
.trigger = snd_hdsp_midi_output_trigger,
|
||||
};
|
||||
|
||||
static struct snd_rawmidi_ops snd_hdsp_midi_input =
|
||||
static const struct snd_rawmidi_ops snd_hdsp_midi_input =
|
||||
{
|
||||
.open = snd_hdsp_midi_input_open,
|
||||
.close = snd_hdsp_midi_input_close,
|
||||
|
|
|
@ -2043,14 +2043,14 @@ static int snd_hdspm_midi_output_close(struct snd_rawmidi_substream *substream)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static struct snd_rawmidi_ops snd_hdspm_midi_output =
|
||||
static const struct snd_rawmidi_ops snd_hdspm_midi_output =
|
||||
{
|
||||
.open = snd_hdspm_midi_output_open,
|
||||
.close = snd_hdspm_midi_output_close,
|
||||
.trigger = snd_hdspm_midi_output_trigger,
|
||||
};
|
||||
|
||||
static struct snd_rawmidi_ops snd_hdspm_midi_input =
|
||||
static const struct snd_rawmidi_ops snd_hdspm_midi_input =
|
||||
{
|
||||
.open = snd_hdspm_midi_input_open,
|
||||
.close = snd_hdspm_midi_input_close,
|
||||
|
|
Loading…
Reference in New Issue
Block a user