Re: [PATCH 03/32 v2] dmaengine: ste_dma40: Use the BIT macro toreplace ugly '(1 << x)'s
From: Linus Walleij
Date: Wed Apr 24 2013 - 10:54:53 EST
On Thu, Apr 18, 2013 at 2:16 PM, Lee Jones <lee.jones@xxxxxxxxxx> wrote:
> The aim is to make the code that little more readable.
>
> Cc: Vinod Koul <vinod.koul@xxxxxxxxx>
> Cc: Dan Williams <djbw@xxxxxx>
> Cc: Per Forlin <per.forlin@xxxxxxxxxxxxxx>
> Cc: Rabin Vincent <rabin@xxxxxx>
> Acked-by: Arnd Bergmann <arnd@xxxxxxxx>
> Signed-off-by: Lee Jones <lee.jones@xxxxxxxxxx>
>
> diff --git a/drivers/dma/ste_dma40.c b/drivers/dma/ste_dma40.c
> index 3b83dee..ddf5ff1 100644
> --- a/drivers/dma/ste_dma40.c
> +++ b/drivers/dma/ste_dma40.c
> @@ -49,9 +49,9 @@
> #define MAX_LCLA_ALLOC_ATTEMPTS 256
>
> /* Bit markings for allocation map */
> -#define D40_ALLOC_FREE (1 << 31)
> -#define D40_ALLOC_PHY (1 << 30)
> -#define D40_ALLOC_LOG_FREE 0
> +#define D40_ALLOC_FREE BIT(31)
> +#define D40_ALLOC_PHY BIT(30)
> +#define D40_ALLOC_LOG_FREE BIT(0)
No. 0 != BIT(0)
Please fix this...
Yours,
Linus Walleij
--
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/