Re: [PATCH] sound/pci/au88x0/au88x0_synth.c: fix incorrect left shift

From: Takashi Iwai
Date: Mon Jan 07 2013 - 11:30:22 EST


At Sat, 5 Jan 2013 14:14:08 -0500,
Nickolai Zeldovich wrote:
>
> vortex_wt_setdsout performs bit-negation on the bit position (wt&0x1f)
> rather than on the resulting bitmask. This code is never actually
> invoked (vortex_wt_setdsout is always called with en=1), so this does
> not currently cause any problem, and this patch is simply cleanup.
>
> Signed-off-by: Nickolai Zeldovich <nickolai@xxxxxxxxxxxxx>

Thanks, applied.


Takashi

> ---
> sound/pci/au88x0/au88x0_synth.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/sound/pci/au88x0/au88x0_synth.c b/sound/pci/au88x0/au88x0_synth.c
> index 2805e34..8bef473 100644
> --- a/sound/pci/au88x0/au88x0_synth.c
> +++ b/sound/pci/au88x0/au88x0_synth.c
> @@ -58,7 +58,7 @@ static void vortex_wt_setdsout(vortex_t * vortex, u32 wt, int en)
> if (en)
> temp |= (1 << (wt & 0x1f));
> else
> - temp &= (1 << ~(wt & 0x1f));
> + temp &= ~(1 << (wt & 0x1f));
> hwwrite(vortex->mmio, WT_DSREG((wt >= 0x20) ? 1 : 0), temp);
> }
>
> --
> 1.7.10.4
>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/