diff options
| author | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2011-03-18 23:38:50 -0700 | 
|---|---|---|
| committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2011-03-18 23:38:50 -0700 | 
| commit | 97eb3f24352ec6632c2127b35d8087d2a809a9b9 (patch) | |
| tree | 722948059bbd325bbca232269490124231df80d4 /arch/arm/mach-tegra/gpio.c | |
| parent | 439581ec07fa9cf3f519dd461a2cf41cfd3adcb4 (diff) | |
| parent | def179c271ac9b5020deca798470521f14d11edd (diff) | |
Merge branch 'next' into for-linus
Diffstat (limited to 'arch/arm/mach-tegra/gpio.c')
| -rw-r--r-- | arch/arm/mach-tegra/gpio.c | 42 | 
1 files changed, 21 insertions, 21 deletions
diff --git a/arch/arm/mach-tegra/gpio.c b/arch/arm/mach-tegra/gpio.c index 0775265e69f5..ad8048801513 100644 --- a/arch/arm/mach-tegra/gpio.c +++ b/arch/arm/mach-tegra/gpio.c @@ -142,31 +142,31 @@ static struct gpio_chip tegra_gpio_chip = {  	.ngpio			= TEGRA_NR_GPIOS,  }; -static void tegra_gpio_irq_ack(unsigned int irq) +static void tegra_gpio_irq_ack(struct irq_data *d)  { -	int gpio = irq - INT_GPIO_BASE; +	int gpio = d->irq - INT_GPIO_BASE;  	__raw_writel(1 << GPIO_BIT(gpio), GPIO_INT_CLR(gpio));  } -static void tegra_gpio_irq_mask(unsigned int irq) +static void tegra_gpio_irq_mask(struct irq_data *d)  { -	int gpio = irq - INT_GPIO_BASE; +	int gpio = d->irq - INT_GPIO_BASE;  	tegra_gpio_mask_write(GPIO_MSK_INT_ENB(gpio), gpio, 0);  } -static void tegra_gpio_irq_unmask(unsigned int irq) +static void tegra_gpio_irq_unmask(struct irq_data *d)  { -	int gpio = irq - INT_GPIO_BASE; +	int gpio = d->irq - INT_GPIO_BASE;  	tegra_gpio_mask_write(GPIO_MSK_INT_ENB(gpio), gpio, 1);  } -static int tegra_gpio_irq_set_type(unsigned int irq, unsigned int type) +static int tegra_gpio_irq_set_type(struct irq_data *d, unsigned int type)  { -	int gpio = irq - INT_GPIO_BASE; -	struct tegra_gpio_bank *bank = get_irq_chip_data(irq); +	int gpio = d->irq - INT_GPIO_BASE; +	struct tegra_gpio_bank *bank = irq_data_get_irq_chip_data(d);  	int port = GPIO_PORT(gpio);  	int lvl_type;  	int val; @@ -207,9 +207,9 @@ static int tegra_gpio_irq_set_type(unsigned int irq, unsigned int type)  	spin_unlock_irqrestore(&bank->lvl_lock[port], flags);  	if (type & (IRQ_TYPE_LEVEL_LOW | IRQ_TYPE_LEVEL_HIGH)) -		__set_irq_handler_unlocked(irq, handle_level_irq); +		__set_irq_handler_unlocked(d->irq, handle_level_irq);  	else if (type & (IRQ_TYPE_EDGE_FALLING | IRQ_TYPE_EDGE_RISING)) -		__set_irq_handler_unlocked(irq, handle_edge_irq); +		__set_irq_handler_unlocked(d->irq, handle_edge_irq);  	return 0;  } @@ -221,7 +221,7 @@ static void tegra_gpio_irq_handler(unsigned int irq, struct irq_desc *desc)  	int pin;  	int unmasked = 0; -	desc->chip->ack(irq); +	desc->irq_data.chip->irq_ack(&desc->irq_data);  	bank = get_irq_data(irq); @@ -240,7 +240,7 @@ static void tegra_gpio_irq_handler(unsigned int irq, struct irq_desc *desc)  			 */  			if (lvl & (0x100 << pin)) {  				unmasked = 1; -				desc->chip->unmask(irq); +				desc->irq_data.chip->irq_unmask(&desc->irq_data);  			}  			generic_handle_irq(gpio_to_irq(gpio + pin)); @@ -248,7 +248,7 @@ static void tegra_gpio_irq_handler(unsigned int irq, struct irq_desc *desc)  	}  	if (!unmasked) -		desc->chip->unmask(irq); +		desc->irq_data.chip->irq_unmask(&desc->irq_data);  } @@ -316,21 +316,21 @@ void tegra_gpio_suspend(void)  	local_irq_restore(flags);  } -static int tegra_gpio_wake_enable(unsigned int irq, unsigned int enable) +static int tegra_gpio_wake_enable(struct irq_data *d, unsigned int enable)  { -	struct tegra_gpio_bank *bank = get_irq_chip_data(irq); +	struct tegra_gpio_bank *bank = irq_data_get_irq_chip_data(d);  	return set_irq_wake(bank->irq, enable);  }  #endif  static struct irq_chip tegra_gpio_irq_chip = {  	.name		= "GPIO", -	.ack		= tegra_gpio_irq_ack, -	.mask		= tegra_gpio_irq_mask, -	.unmask		= tegra_gpio_irq_unmask, -	.set_type	= tegra_gpio_irq_set_type, +	.irq_ack	= tegra_gpio_irq_ack, +	.irq_mask	= tegra_gpio_irq_mask, +	.irq_unmask	= tegra_gpio_irq_unmask, +	.irq_set_type	= tegra_gpio_irq_set_type,  #ifdef CONFIG_PM -	.set_wake	= tegra_gpio_wake_enable, +	.irq_set_wake	= tegra_gpio_wake_enable,  #endif  };  | 
