[PATCH 2/7] ARM: SAMSUNG: Add CLK Macro for clkdev support

Russell King - ARM Linux linux at arm.linux.org.uk
Fri Sep 23 16:26:06 EDT 2011


On Fri, Sep 23, 2011 at 05:23:42PM +0530, Padmavathi Venna wrote:
> diff --git a/arch/arm/plat-samsung/include/plat/clock.h b/arch/arm/plat-samsung/include/plat/clock.h
> index 73c66d4..c864825 100644
> --- a/arch/arm/plat-samsung/include/plat/clock.h
> +++ b/arch/arm/plat-samsung/include/plat/clock.h
> @@ -17,6 +17,13 @@
>  
>  struct clk;
>  
> +#define CLK(dev, con, ck)	\
> +	{			\
> +		.dev_id = dev,	\
> +		.con_id = con,	\
> +		.clk = ck,	\
> +	}
> +

How about a patch series which moves this to include/linux/clkdev.h,
preferably called CLKDEV_INIT() ?

There's versions of this already in:
arch/arm/mach-ux500/clock.h
arch/arm/mach-tegra/tegra2_clocks.c
arch/arm/mach-nomadik/clock.c
arch/arm/mach-davinci/clock.h

so let's have it standardized instead of everyone inventing their own.

(Remember, that's what we're supposed to already being looking out for
since Linus' whinge about how ARM stuff tends to grow out of control...)



More information about the linux-arm-kernel mailing list