On Wed 20 March 2013 20:24:41 Frank Schäfer wrote:
> Function audio_mux() actually deals with two types of mute: gpio mute and
> subdevice muting.
> This patch claryfies the meaning of these values, but mainly prepares the 
> code for
> the next patch.
> 
> Signed-off-by: Frank Schäfer <fschaefer....@googlemail.com>

Acked-by: Hans Verkuil <hans.verk...@cisco.com>

Regards,

        Hans

> ---
>  drivers/media/pci/bt8xx/bttv-driver.c |    8 ++++----
>  1 Datei geändert, 4 Zeilen hinzugefügt(+), 4 Zeilen entfernt(-)
> 
> diff --git a/drivers/media/pci/bt8xx/bttv-driver.c 
> b/drivers/media/pci/bt8xx/bttv-driver.c
> index 8610b6a..a584d82 100644
> --- a/drivers/media/pci/bt8xx/bttv-driver.c
> +++ b/drivers/media/pci/bt8xx/bttv-driver.c
> @@ -992,7 +992,7 @@ static char *audio_modes[] = {
>  static int
>  audio_mux(struct bttv *btv, int input, int mute)
>  {
> -     int gpio_val, signal;
> +     int gpio_val, signal, mute_gpio;
>       struct v4l2_ctrl *ctrl;
>  
>       gpio_inout(bttv_tvcards[btv->c.type].gpiomask,
> @@ -1003,10 +1003,10 @@ audio_mux(struct bttv *btv, int input, int mute)
>       btv->audio = input;
>  
>       /* automute */
> -     mute = mute || (btv->opt_automute && (!signal || !btv->users)
> +     mute_gpio = mute || (btv->opt_automute && (!signal || !btv->users)
>                               && !btv->has_radio_tuner);
>  
> -     if (mute)
> +     if (mute_gpio)
>               gpio_val = bttv_tvcards[btv->c.type].gpiomute;
>       else
>               gpio_val = bttv_tvcards[btv->c.type].gpiomux[input];
> @@ -1022,7 +1022,7 @@ audio_mux(struct bttv *btv, int input, int mute)
>       }
>  
>       if (bttv_gpio)
> -             bttv_gpio_tracking(btv, audio_modes[mute ? 4 : input]);
> +             bttv_gpio_tracking(btv, audio_modes[mute_gpio ? 4 : input]);
>       if (in_interrupt())
>               return 0;
>  
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to