diff mbox

[v3,04/13] davinci: vpif: fix setting of data width in config_vpif_params() function

Message ID 1340622455-10419-5-git-send-email-manjunath.hadli@ti.com (mailing list archive)
State Awaiting Upstream
Headers show

Commit Message

Manjunath Hadli June 25, 2012, 11:07 a.m. UTC
fix setting of data width in config_vpif_params() function,
which was wrongly set.

Signed-off-by: Manjunath Hadli <manjunath.hadli@ti.com>
Signed-off-by: Lad, Prabhakar <prabhakar.lad@ti.com>
---
 drivers/media/video/davinci/vpif.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

Comments

Sergei Shtylyov June 26, 2012, 10:36 a.m. UTC | #1
Hello.

On 25-06-2012 15:07, Manjunath Hadli wrote:

> fix setting of data width in config_vpif_params() function,
> which was wrongly set.

> Signed-off-by: Manjunath Hadli<manjunath.hadli@ti.com>
> Signed-off-by: Lad, Prabhakar<prabhakar.lad@ti.com>
> ---
>   drivers/media/video/davinci/vpif.c |    2 +-
>   1 files changed, 1 insertions(+), 1 deletions(-)

> diff --git a/drivers/media/video/davinci/vpif.c b/drivers/media/video/davinci/vpif.c
> index 774bcd3..08fb81f 100644
> --- a/drivers/media/video/davinci/vpif.c
> +++ b/drivers/media/video/davinci/vpif.c
> @@ -346,7 +346,7 @@ static void config_vpif_params(struct vpif_params *vpifparams,
>
>   			value = regr(reg);
>   			/* Set data width */
> -			value&= ((~(unsigned int)(0x3))<<
> +			value&= ~(((unsigned int)(0x3))<<

    Why not just 0x3u instead of (unsigned int)(0x3)?

WBR, Sergei
diff mbox

Patch

diff --git a/drivers/media/video/davinci/vpif.c b/drivers/media/video/davinci/vpif.c
index 774bcd3..08fb81f 100644
--- a/drivers/media/video/davinci/vpif.c
+++ b/drivers/media/video/davinci/vpif.c
@@ -346,7 +346,7 @@  static void config_vpif_params(struct vpif_params *vpifparams,
 
 			value = regr(reg);
 			/* Set data width */
-			value &= ((~(unsigned int)(0x3)) <<
+			value &= ~(((unsigned int)(0x3)) <<
 					VPIF_CH_DATA_WIDTH_BIT);
 			value |= ((vpifparams->params.data_sz) <<
 						     VPIF_CH_DATA_WIDTH_BIT);