X-Git-Url: http://git.rot13.org/?a=blobdiff_plain;f=sound%2Fpci%2Fhda%2Fpatch_si3054.c;h=8f8840e6002bccc6023b679a67dc02051c502a76;hb=a3aefd883dc8c17c2231d763630ffe5cd118d7e8;hp=c41fb9acdce49389c52fe1f16f8837aee32d7410;hpb=ec9e1c5c9c7350cc8214f8b9c529f9678036d9a8;p=powerpc.git diff --git a/sound/pci/hda/patch_si3054.c b/sound/pci/hda/patch_si3054.c index c41fb9acdc..8f8840e600 100644 --- a/sound/pci/hda/patch_si3054.c +++ b/sound/pci/hda/patch_si3054.c @@ -3,7 +3,7 @@ * * HD audio interface patch for Silicon Labs 3054/5 modem codec * - * Copyright (c) 2005 Sasha Khapyorsky + * Copyright (c) 2005 Sasha Khapyorsky * Takashi Iwai * * @@ -95,8 +95,8 @@ struct si3054_spec { #define PRIVATE_REG(val) ((val>>16)&0xffff) #define PRIVATE_MASK(val) (val&0xffff) -static int si3054_switch_info(snd_kcontrol_t *kcontrol, - snd_ctl_elem_info_t *uinfo) +static int si3054_switch_info(struct snd_kcontrol *kcontrol, + struct snd_ctl_elem_info *uinfo) { uinfo->type = SNDRV_CTL_ELEM_TYPE_BOOLEAN; uinfo->count = 1; @@ -105,8 +105,8 @@ static int si3054_switch_info(snd_kcontrol_t *kcontrol, return 0; } -static int si3054_switch_get(snd_kcontrol_t *kcontrol, - snd_ctl_elem_value_t *uvalue) +static int si3054_switch_get(struct snd_kcontrol *kcontrol, + struct snd_ctl_elem_value *uvalue) { struct hda_codec *codec = snd_kcontrol_chip(kcontrol); u16 reg = PRIVATE_REG(kcontrol->private_value); @@ -115,8 +115,8 @@ static int si3054_switch_get(snd_kcontrol_t *kcontrol, return 0; } -static int si3054_switch_put(snd_kcontrol_t *kcontrol, - snd_ctl_elem_value_t *uvalue) +static int si3054_switch_put(struct snd_kcontrol *kcontrol, + struct snd_ctl_elem_value *uvalue) { struct hda_codec *codec = snd_kcontrol_chip(kcontrol); u16 reg = PRIVATE_REG(kcontrol->private_value); @@ -138,7 +138,7 @@ static int si3054_switch_put(snd_kcontrol_t *kcontrol, } -static snd_kcontrol_new_t si3054_modem_mixer[] = { +static struct snd_kcontrol_new si3054_modem_mixer[] = { SI3054_KCONTROL("Off-hook Switch", SI3054_GPIO_CONTROL, SI3054_GPIO_OH), SI3054_KCONTROL("Caller ID Switch", SI3054_GPIO_CONTROL, SI3054_GPIO_CID), {} @@ -158,7 +158,7 @@ static int si3054_pcm_prepare(struct hda_pcm_stream *hinfo, struct hda_codec *codec, unsigned int stream_tag, unsigned int format, - snd_pcm_substream_t *substream) + struct snd_pcm_substream *substream) { u16 val; @@ -175,10 +175,10 @@ static int si3054_pcm_prepare(struct hda_pcm_stream *hinfo, static int si3054_pcm_open(struct hda_pcm_stream *hinfo, struct hda_codec *codec, - snd_pcm_substream_t *substream) + struct snd_pcm_substream *substream) { static unsigned int rates[] = { 8000, 9600, 16000 }; - static snd_pcm_hw_constraint_list_t hw_constraints_rates = { + static struct snd_pcm_hw_constraint_list hw_constraints_rates = { .count = ARRAY_SIZE(rates), .list = rates, .mask = 0, @@ -283,7 +283,7 @@ static struct hda_codec_ops si3054_patch_ops = { static int patch_si3054(struct hda_codec *codec) { - struct si3054_spec *spec = kcalloc(1, sizeof(*spec), GFP_KERNEL); + struct si3054_spec *spec = kzalloc(sizeof(*spec), GFP_KERNEL); if (spec == NULL) return -ENOMEM; codec->spec = spec; @@ -295,6 +295,7 @@ static int patch_si3054(struct hda_codec *codec) * patch entries */ struct hda_codec_preset snd_hda_preset_si3054[] = { + { .id = 0x163c3055, .name = "Si3054", .patch = patch_si3054 }, { .id = 0x163c3155, .name = "Si3054", .patch = patch_si3054 }, {} };