lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20160831094044.1c3227d6@scratchpost.org>
Date:   Wed, 31 Aug 2016 09:40:44 +0200
From:   Danny Milosavljevic <dannym@...atchpost.org>
To:     Chen-Yu Tsai <wens@...e.org>
Cc:     Maxime Ripard <maxime.ripard@...e-electrons.com>,
        Mark Brown <broonie@...nel.org>,
        linux-kernel <linux-kernel@...r.kernel.org>,
        linux-arm-kernel <linux-arm-kernel@...ts.infradead.org>,
        Linux-ALSA <alsa-devel@...a-project.org>,
        Jaroslav Kysela <perex@...ex.cz>,
        Takashi Iwai <tiwai@...e.com>,
        Liam Girdwood <lgirdwood@...il.com>,
        linux-sunxi <linux-sunxi@...glegroups.com>
Subject: Re: [linux-sunxi] Re: [PATCH v9 2/2] Add mixer controls: Line-In,
 FM-In, Mic 2, Capture Source, Differential Line-In.

> And what about microphone bias?

Would this be OK?

static int sun4i_codec_handle_mic_bias_event(struct snd_soc_dapm_widget *w,
                                             struct snd_kcontrol *k, int event)
{
        struct sun4i_codec *scodec = snd_soc_card_get_drvdata(w->dapm->card);
        if (SND_SOC_DAPM_EVENT_ON(event))
                regmap_update_bits(scodec->regmap,
                                   SUN4I_CODEC_ADC_ACTL,
                                   BIT(SUN4I_CODEC_ADC_ACTL_VMICEN),
                                   BIT(SUN4I_CODEC_ADC_ACTL_VMICEN));
        else
                regmap_update_bits(scodec->regmap,
                                   SUN4I_CODEC_ADC_ACTL,
                                   BIT(SUN4I_CODEC_ADC_ACTL_VMICEN),
                                   0);
}

static const struct snd_soc_dapm_widget sun4i_codec_codec_dapm_widgets[] = {
...
        SND_SOC_DAPM_MIC("Mic1", sun4i_codec_handle_mic_bias_event),
        SND_SOC_DAPM_MIC("Mic2", sun4i_codec_handle_mic_bias_event),

Do I then remove

         SND_SOC_DAPM_SUPPLY("VMIC", SUN4I_CODEC_ADC_ACTL,
                            SUN4I_CODEC_ADC_ACTL_VMICEN, 0, NULL, 0),

completely? What about the routes?

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ