From mboxrd@z Thu Jan 1 00:00:00 1970 From: Takashi Iwai Subject: Re: [PATCH 1/5] ALSA: hda - Add fixup_forced flag Date: Mon, 26 May 2014 11:10:59 +0200 Message-ID: References: <1401092564-14293-1-git-send-email-hui.wang@canonical.com> Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mx2.suse.de (cantor2.suse.de [195.135.220.15]) by alsa0.perex.cz (Postfix) with ESMTP id 5318826170F for ; Mon, 26 May 2014 11:11:00 +0200 (CEST) In-Reply-To: <1401092564-14293-1-git-send-email-hui.wang@canonical.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org To: Hui Wang Cc: alsa-devel@alsa-project.org, david.henningsson@canonical.com List-Id: alsa-devel@alsa-project.org At Mon, 26 May 2014 16:22:40 +0800, Hui Wang wrote: > > From: David Henningsson > > The "fixup_forced" flag will indicate whether a specific fixup > (or nofixup) has been set by the user, to override the driver's > default. > This flag will help future patches. > > Signed-off-by: David Henningsson In general, when you submit a patch, *you* need to sign off the patch in addition. It's no big problem in this case since I already got the same patches from David, though. In anyway, I applied all patches now. Thanks. Takashi > --- > sound/pci/hda/hda_auto_parser.c | 9 ++++++--- > sound/pci/hda/hda_codec.h | 1 + > 2 files changed, 7 insertions(+), 3 deletions(-) > > diff --git a/sound/pci/hda/hda_auto_parser.c b/sound/pci/hda/hda_auto_parser.c > index 90d2fda..36961ab 100644 > --- a/sound/pci/hda/hda_auto_parser.c > +++ b/sound/pci/hda/hda_auto_parser.c > @@ -852,15 +852,17 @@ void snd_hda_pick_fixup(struct hda_codec *codec, > if (codec->modelname && !strcmp(codec->modelname, "nofixup")) { > codec->fixup_list = NULL; > codec->fixup_id = -1; > + codec->fixup_forced = 1; > return; > } > > if (codec->modelname && models) { > while (models->name) { > if (!strcmp(codec->modelname, models->name)) { > - id = models->id; > - name = models->name; > - break; > + codec->fixup_id = models->id; > + codec->fixup_name = models->name; > + codec->fixup_forced = 1; > + return; > } > models++; > } > @@ -889,6 +891,7 @@ void snd_hda_pick_fixup(struct hda_codec *codec, > } > } > > + codec->fixup_forced = 0; > codec->fixup_id = id; > if (id >= 0) { > codec->fixup_list = fixlist; > diff --git a/sound/pci/hda/hda_codec.h b/sound/pci/hda/hda_codec.h > index a423313..5825aa1 100644 > --- a/sound/pci/hda/hda_codec.h > +++ b/sound/pci/hda/hda_codec.h > @@ -402,6 +402,7 @@ struct hda_codec { > > /* fix-up list */ > int fixup_id; > + unsigned int fixup_forced:1; /* fixup explicitly set by user */ > const struct hda_fixup *fixup_list; > const char *fixup_name; > > -- > 1.8.1.2 >