GPIO support for HTC Dream

Joe Perches joe at perches.com
Tue Dec 8 17:03:32 EST 2009


On Tue, 2009-12-08 at 22:46 +0100, Pavel Machek wrote:
> Add GPIO support for HTC Dream.

Hi Pavel.  Thanks for this.

Maybe it'd be nicer to use pr_<level> and add
#define pr_fmt(fmt) KBUILD_MODNAME ":%s: " fmt, __func__
?

> +++ b/arch/arm/mach-msm/board-dream-gpio.c
> +static int dream_gpio_write(struct gpio_chip *chip, unsigned n, unsigned on)
[]
> +		printk(KERN_ERR "dream_gpio_write called on input %d\n", n);
		pr_err("called on input %d\n", n);
[]
> +static void dream_gpio_irq_handler(unsigned int irq, struct irq_desc *desc)
[]
> +			printk(KERN_ERR "dream_gpio_irq_handler: got masked "
			pr_err("got masked interrupt: %d:%02x\n"
> +++ b/arch/arm/mach-msm/generic_gpio.c
[]
> +int register_gpio_chip(struct gpio_chip *new_gpio_chip)
[]
> +		printk(KERN_ERR "register_gpio_chip: failed to allocate state\n");
		pr_err("failed to allocate state\n");
> +			printk(KERN_ERR "register_gpio_chip: failed to allocate array\n");
			pr_err("failed to allocate array\n");
[]
> +			printk(KERN_ERR "register_gpio_source %u-%u overlaps with %u-%u\n",
Wrong function name?
			pr_err("%u-%u overlaps with %u-%u\n",




More information about the linux-arm-kernel mailing list