Re: [PATCH 09/11] OMAP: GPIO: Introduce support for OMAP2PLUS chip GPIO init

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Charulatha V <charu@xxxxxx> writes:

> This patch adds support for handling GPIO as a HWMOD FW adapted
> platform device for OMAP2PLUS chips.
>
> Signed-off-by: Charulatha V <charu@xxxxxx>

[...]

> +/*
> + * gpio_init needs to be done before
> + * machine_init functions access gpio APIs.
> + * Hence gpio_init is a postcore_initcall.
> + */
> +#ifdef CONFIG_ARCH_OMAP2
> +static int __init omap242x_gpio_init(void)
> +{	if (!cpu_is_omap2420())
> +		return -EINVAL;
> +
> +	return gpio_init(METHOD_GPIO_24XX);
> +}
> +postcore_initcall(omap242x_gpio_init);
> +
> +static int __init omap243x_gpio_init(void)
> +{
> +	if (!cpu_is_omap2430())
> +		return -EINVAL;
> +
> +	return gpio_init(METHOD_GPIO_24XX);
> +}
> +postcore_initcall(omap243x_gpio_init);
> +#endif

Minor nit: you don't need separate functions for 2420 and 2430?
A single one for OMAP2 with 'if (!cpu_is_omap24xx())' should do.

Kevin
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Arm (vger)]     [ARM Kernel]     [ARM MSM]     [Linux Tegra]     [Linux WPAN Networking]     [Linux Wireless Networking]     [Maemo Users]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux