public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 01/10] gpio: adp5588-gpio: irq_data conversion.
       [not found] <cover.1292240053.git.buytenh@wantstofly.org>
@ 2010-12-13 12:02 ` Lennert Buytenhek
  2010-12-13 12:29   ` Hennerich, Michael
  2010-12-13 12:02 ` [PATCH 02/10] gpio: langwell_gpio: " Lennert Buytenhek
                   ` (8 subsequent siblings)
  9 siblings, 1 reply; 16+ messages in thread
From: Lennert Buytenhek @ 2010-12-13 12:02 UTC (permalink / raw)
  To: Michael Hennerich, Mike Frysinger; +Cc: Andrew Morton, linux-kernel

Signed-off-by: Lennert Buytenhek <buytenh@secretlab.ca>
---
 drivers/gpio/adp5588-gpio.c |   39 ++++++++++++++++++++-------------------
 1 files changed, 20 insertions(+), 19 deletions(-)

diff --git a/drivers/gpio/adp5588-gpio.c b/drivers/gpio/adp5588-gpio.c
index 0871f78..33fc685 100644
--- a/drivers/gpio/adp5588-gpio.c
+++ b/drivers/gpio/adp5588-gpio.c
@@ -146,9 +146,10 @@ static int adp5588_gpio_to_irq(struct gpio_chip *chip, unsigned off)
 	return dev->irq_base + off;
 }
 
-static void adp5588_irq_bus_lock(unsigned int irq)
+static void adp5588_irq_bus_lock(struct irq_data *d)
 {
-	struct adp5588_gpio *dev = get_irq_chip_data(irq);
+	struct adp5588_gpio *dev = irq_data_get_irq_chip_data(d);
+
 	mutex_lock(&dev->irq_lock);
 }
 
@@ -160,9 +161,9 @@ static void adp5588_irq_bus_lock(unsigned int irq)
   * and unlocks the bus.
   */
 
-static void adp5588_irq_bus_sync_unlock(unsigned int irq)
+static void adp5588_irq_bus_sync_unlock(struct irq_data *d)
 {
-	struct adp5588_gpio *dev = get_irq_chip_data(irq);
+	struct adp5588_gpio *dev = irq_data_get_irq_chip_data(d);
 	int i;
 
 	for (i = 0; i <= ADP5588_BANK(ADP5588_MAXGPIO); i++)
@@ -175,31 +176,31 @@ static void adp5588_irq_bus_sync_unlock(unsigned int irq)
 	mutex_unlock(&dev->irq_lock);
 }
 
-static void adp5588_irq_mask(unsigned int irq)
+static void adp5588_irq_mask(struct irq_data *d)
 {
-	struct adp5588_gpio *dev = get_irq_chip_data(irq);
-	unsigned gpio = irq - dev->irq_base;
+	struct adp5588_gpio *dev = irq_data_get_irq_chip_data(d);
+	unsigned gpio = d->irq - dev->irq_base;
 
 	dev->irq_mask[ADP5588_BANK(gpio)] &= ~ADP5588_BIT(gpio);
 }
 
-static void adp5588_irq_unmask(unsigned int irq)
+static void adp5588_irq_unmask(struct irq_data *d)
 {
-	struct adp5588_gpio *dev = get_irq_chip_data(irq);
-	unsigned gpio = irq - dev->irq_base;
+	struct adp5588_gpio *dev = irq_data_get_irq_chip_data(d);
+	unsigned gpio = d->irq - dev->irq_base;
 
 	dev->irq_mask[ADP5588_BANK(gpio)] |= ADP5588_BIT(gpio);
 }
 
-static int adp5588_irq_set_type(unsigned int irq, unsigned int type)
+static int adp5588_irq_set_type(struct irq_data *d, unsigned int type)
 {
-	struct adp5588_gpio *dev = get_irq_chip_data(irq);
-	uint16_t gpio = irq - dev->irq_base;
+	struct adp5588_gpio *dev = irq_data_get_irq_chip_data(d);
+	uint16_t gpio = d->irq - dev->irq_base;
 	unsigned bank, bit;
 
 	if ((type & IRQ_TYPE_EDGE_BOTH)) {
 		dev_err(&dev->client->dev, "irq %d: unsupported type %d\n",
-			irq, type);
+			d->irq, type);
 		return -EINVAL;
 	}
 
@@ -222,11 +223,11 @@ static int adp5588_irq_set_type(unsigned int irq, unsigned int type)
 
 static struct irq_chip adp5588_irq_chip = {
 	.name			= "adp5588",
-	.mask			= adp5588_irq_mask,
-	.unmask			= adp5588_irq_unmask,
-	.bus_lock		= adp5588_irq_bus_lock,
-	.bus_sync_unlock	= adp5588_irq_bus_sync_unlock,
-	.set_type		= adp5588_irq_set_type,
+	.irq_mask		= adp5588_irq_mask,
+	.irq_unmask		= adp5588_irq_unmask,
+	.irq_bus_lock		= adp5588_irq_bus_lock,
+	.irq_bus_sync_unlock	= adp5588_irq_bus_sync_unlock,
+	.irq_set_type		= adp5588_irq_set_type,
 };
 
 static int adp5588_gpio_read_intstat(struct i2c_client *client, u8 *buf)
-- 
1.7.1


^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH 02/10] gpio: langwell_gpio: irq_data conversion.
       [not found] <cover.1292240053.git.buytenh@wantstofly.org>
  2010-12-13 12:02 ` [PATCH 01/10] gpio: adp5588-gpio: irq_data conversion Lennert Buytenhek
@ 2010-12-13 12:02 ` Lennert Buytenhek
  2010-12-13 12:02 ` [PATCH 03/10] gpio: max732x: " Lennert Buytenhek
                   ` (7 subsequent siblings)
  9 siblings, 0 replies; 16+ messages in thread
From: Lennert Buytenhek @ 2010-12-13 12:02 UTC (permalink / raw)
  To: Alan Cox, Yin Kangkai, Alek Du; +Cc: Andrew Morton, linux-kernel

Signed-off-by: Lennert Buytenhek <buytenh@secretlab.ca>
---
 drivers/gpio/langwell_gpio.c |   16 ++++++++--------
 1 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/drivers/gpio/langwell_gpio.c b/drivers/gpio/langwell_gpio.c
index 64db9dc..d81cc74 100644
--- a/drivers/gpio/langwell_gpio.c
+++ b/drivers/gpio/langwell_gpio.c
@@ -134,10 +134,10 @@ static int lnw_gpio_to_irq(struct gpio_chip *chip, unsigned offset)
 	return lnw->irq_base + offset;
 }
 
-static int lnw_irq_type(unsigned irq, unsigned type)
+static int lnw_irq_type(struct irq_data *d, unsigned type)
 {
-	struct lnw_gpio *lnw = get_irq_chip_data(irq);
-	u32 gpio = irq - lnw->irq_base;
+	struct lnw_gpio *lnw = irq_data_get_irq_chip_data(d);
+	u32 gpio = d->irq - lnw->irq_base;
 	unsigned long flags;
 	u32 value;
 	void __iomem *grer = gpio_reg(&lnw->chip, gpio, GRER);
@@ -162,19 +162,19 @@ static int lnw_irq_type(unsigned irq, unsigned type)
 	return 0;
 }
 
-static void lnw_irq_unmask(unsigned irq)
+static void lnw_irq_unmask(struct irq_data *d)
 {
 }
 
-static void lnw_irq_mask(unsigned irq)
+static void lnw_irq_mask(struct irq_data *d)
 {
 }
 
 static struct irq_chip lnw_irqchip = {
 	.name		= "LNW-GPIO",
-	.mask		= lnw_irq_mask,
-	.unmask		= lnw_irq_unmask,
-	.set_type	= lnw_irq_type,
+	.irq_mask	= lnw_irq_mask,
+	.irq_unmask	= lnw_irq_unmask,
+	.irq_set_type	= lnw_irq_type,
 };
 
 static DEFINE_PCI_DEVICE_TABLE(lnw_gpio_ids) = {   /* pin number */
-- 
1.7.1


^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH 03/10] gpio: max732x: irq_data conversion.
       [not found] <cover.1292240053.git.buytenh@wantstofly.org>
  2010-12-13 12:02 ` [PATCH 01/10] gpio: adp5588-gpio: irq_data conversion Lennert Buytenhek
  2010-12-13 12:02 ` [PATCH 02/10] gpio: langwell_gpio: " Lennert Buytenhek
@ 2010-12-13 12:02 ` Lennert Buytenhek
  2010-12-14 11:24   ` Marc Zyngier
  2010-12-13 12:02 ` [PATCH 04/10] gpio: pca953x: " Lennert Buytenhek
                   ` (6 subsequent siblings)
  9 siblings, 1 reply; 16+ messages in thread
From: Lennert Buytenhek @ 2010-12-13 12:02 UTC (permalink / raw)
  To: Marc Zyngier, Eric Miao; +Cc: Andrew Morton, linux-kernel

Signed-off-by: Lennert Buytenhek <buytenh@secretlab.ca>
---
 drivers/gpio/max732x.c |   38 +++++++++++++++++++-------------------
 1 files changed, 19 insertions(+), 19 deletions(-)

diff --git a/drivers/gpio/max732x.c b/drivers/gpio/max732x.c
index 9cad60f..9e1d01f 100644
--- a/drivers/gpio/max732x.c
+++ b/drivers/gpio/max732x.c
@@ -327,40 +327,40 @@ static int max732x_gpio_to_irq(struct gpio_chip *gc, unsigned off)
 	return chip->irq_base + off;
 }
 
-static void max732x_irq_mask(unsigned int irq)
+static void max732x_irq_mask(struct irq_data *d)
 {
-	struct max732x_chip *chip = get_irq_chip_data(irq);
+	struct max732x_chip *chip = irq_data_get_irq_chip_data(d);
 
-	chip->irq_mask_cur &= ~(1 << (irq - chip->irq_base));
+	chip->irq_mask_cur &= ~(1 << (d->irq - chip->irq_base));
 }
 
-static void max732x_irq_unmask(unsigned int irq)
+static void max732x_irq_unmask(struct irq_data *d)
 {
-	struct max732x_chip *chip = get_irq_chip_data(irq);
+	struct max732x_chip *chip = irq_data_get_irq_chip_data(d);
 
-	chip->irq_mask_cur |= 1 << (irq - chip->irq_base);
+	chip->irq_mask_cur |= 1 << (d->irq - chip->irq_base);
 }
 
-static void max732x_irq_bus_lock(unsigned int irq)
+static void max732x_irq_bus_lock(struct irq_data *d)
 {
-	struct max732x_chip *chip = get_irq_chip_data(irq);
+	struct max732x_chip *chip = irq_data_get_irq_chip_data(d);
 
 	mutex_lock(&chip->irq_lock);
 	chip->irq_mask_cur = chip->irq_mask;
 }
 
-static void max732x_irq_bus_sync_unlock(unsigned int irq)
+static void max732x_irq_bus_sync_unlock(struct irq_data *d)
 {
-	struct max732x_chip *chip = get_irq_chip_data(irq);
+	struct max732x_chip *chip = irq_data_get_irq_chip_data(d);
 
 	max732x_irq_update_mask(chip);
 	mutex_unlock(&chip->irq_lock);
 }
 
-static int max732x_irq_set_type(unsigned int irq, unsigned int type)
+static int max732x_irq_set_type(struct irq_data *d, unsigned int type)
 {
-	struct max732x_chip *chip = get_irq_chip_data(irq);
-	uint16_t off = irq - chip->irq_base;
+	struct max732x_chip *chip = irq_data_get_irq_chip_data(d);
+	uint16_t off = d->irq - chip->irq_base;
 	uint16_t mask = 1 << off;
 
 	if (!(mask & chip->dir_input)) {
@@ -371,7 +371,7 @@ static int max732x_irq_set_type(unsigned int irq, unsigned int type)
 
 	if (!(type & IRQ_TYPE_EDGE_BOTH)) {
 		dev_err(&chip->client->dev, "irq %d: unsupported type %d\n",
-			irq, type);
+			d->irq, type);
 		return -EINVAL;
 	}
 
@@ -390,11 +390,11 @@ static int max732x_irq_set_type(unsigned int irq, unsigned int type)
 
 static struct irq_chip max732x_irq_chip = {
 	.name			= "max732x",
-	.mask			= max732x_irq_mask,
-	.unmask			= max732x_irq_unmask,
-	.bus_lock		= max732x_irq_bus_lock,
-	.bus_sync_unlock	= max732x_irq_bus_sync_unlock,
-	.set_type		= max732x_irq_set_type,
+	.irq_mask		= max732x_irq_mask,
+	.irq_unmask		= max732x_irq_unmask,
+	.irq_bus_lock		= max732x_irq_bus_lock,
+	.irq_bus_sync_unlock	= max732x_irq_bus_sync_unlock,
+	.irq_set_type		= max732x_irq_set_type,
 };
 
 static uint8_t max732x_irq_pending(struct max732x_chip *chip)
-- 
1.7.1


^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH 04/10] gpio: pca953x: irq_data conversion.
       [not found] <cover.1292240053.git.buytenh@wantstofly.org>
                   ` (2 preceding siblings ...)
  2010-12-13 12:02 ` [PATCH 03/10] gpio: max732x: " Lennert Buytenhek
@ 2010-12-13 12:02 ` Lennert Buytenhek
  2010-12-13 12:02 ` [PATCH 05/10] gpio: pl061: " Lennert Buytenhek
                   ` (5 subsequent siblings)
  9 siblings, 0 replies; 16+ messages in thread
From: Lennert Buytenhek @ 2010-12-13 12:02 UTC (permalink / raw)
  To: Alek Du, Alan Cox; +Cc: Andrew Morton, linux-kernel

Signed-off-by: Lennert Buytenhek <buytenh@secretlab.ca>
---
 drivers/gpio/pca953x.c |   38 +++++++++++++++++++-------------------
 1 files changed, 19 insertions(+), 19 deletions(-)

diff --git a/drivers/gpio/pca953x.c b/drivers/gpio/pca953x.c
index 5018666..a261972 100644
--- a/drivers/gpio/pca953x.c
+++ b/drivers/gpio/pca953x.c
@@ -228,30 +228,30 @@ static int pca953x_gpio_to_irq(struct gpio_chip *gc, unsigned off)
 	return chip->irq_base + off;
 }
 
-static void pca953x_irq_mask(unsigned int irq)
+static void pca953x_irq_mask(struct irq_data *d)
 {
-	struct pca953x_chip *chip = get_irq_chip_data(irq);
+	struct pca953x_chip *chip = irq_data_get_irq_chip_data(d);
 
-	chip->irq_mask &= ~(1 << (irq - chip->irq_base));
+	chip->irq_mask &= ~(1 << (d->irq - chip->irq_base));
 }
 
-static void pca953x_irq_unmask(unsigned int irq)
+static void pca953x_irq_unmask(struct irq_data *d)
 {
-	struct pca953x_chip *chip = get_irq_chip_data(irq);
+	struct pca953x_chip *chip = irq_data_get_irq_chip_data(d);
 
-	chip->irq_mask |= 1 << (irq - chip->irq_base);
+	chip->irq_mask |= 1 << (d->irq - chip->irq_base);
 }
 
-static void pca953x_irq_bus_lock(unsigned int irq)
+static void pca953x_irq_bus_lock(struct irq_data *d)
 {
-	struct pca953x_chip *chip = get_irq_chip_data(irq);
+	struct pca953x_chip *chip = irq_data_get_irq_chip_data(d);
 
 	mutex_lock(&chip->irq_lock);
 }
 
-static void pca953x_irq_bus_sync_unlock(unsigned int irq)
+static void pca953x_irq_bus_sync_unlock(struct irq_data *d)
 {
-	struct pca953x_chip *chip = get_irq_chip_data(irq);
+	struct pca953x_chip *chip = irq_data_get_irq_chip_data(d);
 	uint16_t new_irqs;
 	uint16_t level;
 
@@ -268,15 +268,15 @@ static void pca953x_irq_bus_sync_unlock(unsigned int irq)
 	mutex_unlock(&chip->irq_lock);
 }
 
-static int pca953x_irq_set_type(unsigned int irq, unsigned int type)
+static int pca953x_irq_set_type(struct irq_data *d, unsigned int type)
 {
-	struct pca953x_chip *chip = get_irq_chip_data(irq);
-	uint16_t level = irq - chip->irq_base;
+	struct pca953x_chip *chip = irq_data_get_irq_chip_data(d);
+	uint16_t level = d->irq - chip->irq_base;
 	uint16_t mask = 1 << level;
 
 	if (!(type & IRQ_TYPE_EDGE_BOTH)) {
 		dev_err(&chip->client->dev, "irq %d: unsupported type %d\n",
-			irq, type);
+			d->irq, type);
 		return -EINVAL;
 	}
 
@@ -295,11 +295,11 @@ static int pca953x_irq_set_type(unsigned int irq, unsigned int type)
 
 static struct irq_chip pca953x_irq_chip = {
 	.name			= "pca953x",
-	.mask			= pca953x_irq_mask,
-	.unmask			= pca953x_irq_unmask,
-	.bus_lock		= pca953x_irq_bus_lock,
-	.bus_sync_unlock	= pca953x_irq_bus_sync_unlock,
-	.set_type		= pca953x_irq_set_type,
+	.irq_mask		= pca953x_irq_mask,
+	.irq_unmask		= pca953x_irq_unmask,
+	.irq_bus_lock		= pca953x_irq_bus_lock,
+	.irq_bus_sync_unlock	= pca953x_irq_bus_sync_unlock,
+	.irq_set_type		= pca953x_irq_set_type,
 };
 
 static uint16_t pca953x_irq_pending(struct pca953x_chip *chip)
-- 
1.7.1


^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH 05/10] gpio: pl061: irq_data conversion.
       [not found] <cover.1292240053.git.buytenh@wantstofly.org>
                   ` (3 preceding siblings ...)
  2010-12-13 12:02 ` [PATCH 04/10] gpio: pca953x: " Lennert Buytenhek
@ 2010-12-13 12:02 ` Lennert Buytenhek
  2010-12-13 12:48   ` Baruch Siach
  2010-12-13 12:02 ` [PATCH 06/10] gpio: stmpe-gpio: " Lennert Buytenhek
                   ` (4 subsequent siblings)
  9 siblings, 1 reply; 16+ messages in thread
From: Lennert Buytenhek @ 2010-12-13 12:02 UTC (permalink / raw)
  To: Baruch Siach, David Brownell; +Cc: Andrew Morton, linux-kernel

Signed-off-by: Lennert Buytenhek <buytenh@secretlab.ca>
---
 drivers/gpio/pl061.c |   28 ++++++++++++++--------------
 1 files changed, 14 insertions(+), 14 deletions(-)

diff --git a/drivers/gpio/pl061.c b/drivers/gpio/pl061.c
index 5005990..2975d22 100644
--- a/drivers/gpio/pl061.c
+++ b/drivers/gpio/pl061.c
@@ -129,10 +129,10 @@ static int pl061_to_irq(struct gpio_chip *gc, unsigned offset)
 /*
  * PL061 GPIO IRQ
  */
-static void pl061_irq_disable(unsigned irq)
+static void pl061_irq_disable(struct irq_data *d)
 {
-	struct pl061_gpio *chip = get_irq_chip_data(irq);
-	int offset = irq - chip->irq_base;
+	struct pl061_gpio *chip = irq_data_get_irq_chip_data(d);
+	int offset = d->irq - chip->irq_base;
 	unsigned long flags;
 	u8 gpioie;
 
@@ -143,10 +143,10 @@ static void pl061_irq_disable(unsigned irq)
 	spin_unlock_irqrestore(&chip->irq_lock, flags);
 }
 
-static void pl061_irq_enable(unsigned irq)
+static void pl061_irq_enable(struct irq_data *d)
 {
-	struct pl061_gpio *chip = get_irq_chip_data(irq);
-	int offset = irq - chip->irq_base;
+	struct pl061_gpio *chip = irq_data_get_irq_chip_data(d);
+	int offset = d->irq - chip->irq_base;
 	unsigned long flags;
 	u8 gpioie;
 
@@ -157,10 +157,10 @@ static void pl061_irq_enable(unsigned irq)
 	spin_unlock_irqrestore(&chip->irq_lock, flags);
 }
 
-static int pl061_irq_type(unsigned irq, unsigned trigger)
+static int pl061_irq_type(struct irq_data *d, unsigned trigger)
 {
-	struct pl061_gpio *chip = get_irq_chip_data(irq);
-	int offset = irq - chip->irq_base;
+	struct pl061_gpio *chip = irq_data_get_irq_chip_data(d);
+	int offset = d->irq - chip->irq_base;
 	unsigned long flags;
 	u8 gpiois, gpioibe, gpioiev;
 
@@ -203,9 +203,9 @@ static int pl061_irq_type(unsigned irq, unsigned trigger)
 
 static struct irq_chip pl061_irqchip = {
 	.name		= "GPIO",
-	.enable		= pl061_irq_enable,
-	.disable	= pl061_irq_disable,
-	.set_type	= pl061_irq_type,
+	.irq_enable	= pl061_irq_enable,
+	.irq_disable	= pl061_irq_disable,
+	.irq_set_type	= pl061_irq_type,
 };
 
 static void pl061_irq_handler(unsigned irq, struct irq_desc *desc)
@@ -214,7 +214,7 @@ static void pl061_irq_handler(unsigned irq, struct irq_desc *desc)
 	struct list_head *ptr;
 	struct pl061_gpio *chip;
 
-	desc->chip->ack(irq);
+	desc->irq_data.chip->irq_ack(&desc->irq_data);
 	list_for_each(ptr, chip_list) {
 		unsigned long pending;
 		int offset;
@@ -229,7 +229,7 @@ static void pl061_irq_handler(unsigned irq, struct irq_desc *desc)
 		for_each_set_bit(offset, &pending, PL061_GPIO_NR)
 			generic_handle_irq(pl061_to_irq(&chip->gc, offset));
 	}
-	desc->chip->unmask(irq);
+	desc->irq_data.chip->irq_unmask(&desc->irq_data);
 }
 
 static int pl061_probe(struct amba_device *dev, struct amba_id *id)
-- 
1.7.1


^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH 06/10] gpio: stmpe-gpio: irq_data conversion.
       [not found] <cover.1292240053.git.buytenh@wantstofly.org>
                   ` (4 preceding siblings ...)
  2010-12-13 12:02 ` [PATCH 05/10] gpio: pl061: " Lennert Buytenhek
@ 2010-12-13 12:02 ` Lennert Buytenhek
  2010-12-13 12:07   ` Rabin Vincent
  2010-12-13 12:03 ` [PATCH 07/10] gpio: sx150x: " Lennert Buytenhek
                   ` (3 subsequent siblings)
  9 siblings, 1 reply; 16+ messages in thread
From: Lennert Buytenhek @ 2010-12-13 12:02 UTC (permalink / raw)
  To: Rabin Vincent, Luotao Fu, Linus Walleij; +Cc: Andrew Morton, linux-kernel

Signed-off-by: Lennert Buytenhek <buytenh@secretlab.ca>
---
 drivers/gpio/stmpe-gpio.c |   36 ++++++++++++++++++------------------
 1 files changed, 18 insertions(+), 18 deletions(-)

diff --git a/drivers/gpio/stmpe-gpio.c b/drivers/gpio/stmpe-gpio.c
index 7c9e6a0..eb2901f 100644
--- a/drivers/gpio/stmpe-gpio.c
+++ b/drivers/gpio/stmpe-gpio.c
@@ -122,10 +122,10 @@ static struct gpio_chip template_chip = {
 	.can_sleep		= 1,
 };
 
-static int stmpe_gpio_irq_set_type(unsigned int irq, unsigned int type)
+static int stmpe_gpio_irq_set_type(struct irq_data *d, unsigned int type)
 {
-	struct stmpe_gpio *stmpe_gpio = get_irq_chip_data(irq);
-	int offset = irq - stmpe_gpio->irq_base;
+	struct stmpe_gpio *stmpe_gpio = irq_data_get_irq_chip_data(d);
+	int offset = d->irq - stmpe_gpio->irq_base;
 	int regoffset = offset / 8;
 	int mask = 1 << (offset % 8);
 
@@ -145,16 +145,16 @@ static int stmpe_gpio_irq_set_type(unsigned int irq, unsigned int type)
 	return 0;
 }
 
-static void stmpe_gpio_irq_lock(unsigned int irq)
+static void stmpe_gpio_irq_lock(struct irq_data *d)
 {
-	struct stmpe_gpio *stmpe_gpio = get_irq_chip_data(irq);
+	struct stmpe_gpio *stmpe_gpio = irq_data_get_irq_chip_data(d);
 
 	mutex_lock(&stmpe_gpio->irq_lock);
 }
 
-static void stmpe_gpio_irq_sync_unlock(unsigned int irq)
+static void stmpe_gpio_irq_sync_unlock(struct irq_data *d)
 {
-	struct stmpe_gpio *stmpe_gpio = get_irq_chip_data(irq);
+	struct stmpe_gpio *stmpe_gpio = irq_data_get_irq_chip_data(d);
 	struct stmpe *stmpe = stmpe_gpio->stmpe;
 	int num_banks = DIV_ROUND_UP(stmpe->num_gpios, 8);
 	static const u8 regmap[] = {
@@ -180,20 +180,20 @@ static void stmpe_gpio_irq_sync_unlock(unsigned int irq)
 	mutex_unlock(&stmpe_gpio->irq_lock);
 }
 
-static void stmpe_gpio_irq_mask(unsigned int irq)
+static void stmpe_gpio_irq_mask(struct irq_data *d)
 {
-	struct stmpe_gpio *stmpe_gpio = get_irq_chip_data(irq);
-	int offset = irq - stmpe_gpio->irq_base;
+	struct stmpe_gpio *stmpe_gpio = irq_data_get_irq_chip_data(d);
+	int offset = d->irq - stmpe_gpio->irq_base;
 	int regoffset = offset / 8;
 	int mask = 1 << (offset % 8);
 
 	stmpe_gpio->regs[REG_IE][regoffset] &= ~mask;
 }
 
-static void stmpe_gpio_irq_unmask(unsigned int irq)
+static void stmpe_gpio_irq_unmask(struct irq_data *d)
 {
-	struct stmpe_gpio *stmpe_gpio = get_irq_chip_data(irq);
-	int offset = irq - stmpe_gpio->irq_base;
+	struct stmpe_gpio *stmpe_gpio = irq_data_get_irq_chip_data(d);
+	int offset = d->irq - stmpe_gpio->irq_base;
 	int regoffset = offset / 8;
 	int mask = 1 << (offset % 8);
 
@@ -202,11 +202,11 @@ static void stmpe_gpio_irq_unmask(unsigned int irq)
 
 static struct irq_chip stmpe_gpio_irq_chip = {
 	.name			= "stmpe-gpio",
-	.bus_lock		= stmpe_gpio_irq_lock,
-	.bus_sync_unlock	= stmpe_gpio_irq_sync_unlock,
-	.mask			= stmpe_gpio_irq_mask,
-	.unmask			= stmpe_gpio_irq_unmask,
-	.set_type		= stmpe_gpio_irq_set_type,
+	.irq_bus_lock		= stmpe_gpio_irq_lock,
+	.irq_bus_sync_unlock	= stmpe_gpio_irq_sync_unlock,
+	.irq_mask		= stmpe_gpio_irq_mask,
+	.irq_unmask		= stmpe_gpio_irq_unmask,
+	.irq_set_type		= stmpe_gpio_irq_set_type,
 };
 
 static irqreturn_t stmpe_gpio_irq(int irq, void *dev)
-- 
1.7.1


^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH 07/10] gpio: sx150x: irq_data conversion.
       [not found] <cover.1292240053.git.buytenh@wantstofly.org>
                   ` (5 preceding siblings ...)
  2010-12-13 12:02 ` [PATCH 06/10] gpio: stmpe-gpio: " Lennert Buytenhek
@ 2010-12-13 12:03 ` Lennert Buytenhek
  2010-12-15 19:58   ` Rohit Vaswani
  2010-12-13 12:03 ` [PATCH 08/10] gpio: tc35892-gpio: " Lennert Buytenhek
                   ` (2 subsequent siblings)
  9 siblings, 1 reply; 16+ messages in thread
From: Lennert Buytenhek @ 2010-12-13 12:03 UTC (permalink / raw)
  To: Gregory Bean; +Cc: Andrew Morton, linux-kernel

Signed-off-by: Lennert Buytenhek <buytenh@secretlab.ca>
---
 drivers/gpio/sx150x.c |   46 +++++++++++++++++++++++-----------------------
 1 files changed, 23 insertions(+), 23 deletions(-)

diff --git a/drivers/gpio/sx150x.c b/drivers/gpio/sx150x.c
index 823559a..e60be00 100644
--- a/drivers/gpio/sx150x.c
+++ b/drivers/gpio/sx150x.c
@@ -304,36 +304,36 @@ static int sx150x_gpio_to_irq(struct gpio_chip *gc, unsigned offset)
 	return chip->irq_base + offset;
 }
 
-static void sx150x_irq_mask(unsigned int irq)
+static void sx150x_irq_mask(struct irq_data *d)
 {
-	struct irq_chip *ic = get_irq_chip(irq);
+	struct irq_chip *ic = irq_data_get_irq_chip(d);
 	struct sx150x_chip *chip;
 	unsigned n;
 
 	chip = container_of(ic, struct sx150x_chip, irq_chip);
-	n = irq - chip->irq_base;
+	n = d->irq - chip->irq_base;
 
 	sx150x_write_cfg(chip, n, 1, chip->dev_cfg->reg_irq_mask, 1);
 	sx150x_write_cfg(chip, n, 2, chip->dev_cfg->reg_sense, 0);
 }
 
-static void sx150x_irq_unmask(unsigned int irq)
+static void sx150x_irq_unmask(struct irq_data *d)
 {
-	struct irq_chip *ic = get_irq_chip(irq);
+	struct irq_chip *ic = irq_data_get_irq_chip(d);
 	struct sx150x_chip *chip;
 	unsigned n;
 
 	chip = container_of(ic, struct sx150x_chip, irq_chip);
-	n = irq - chip->irq_base;
+	n = d->irq - chip->irq_base;
 
 	sx150x_write_cfg(chip, n, 1, chip->dev_cfg->reg_irq_mask, 0);
 	sx150x_write_cfg(chip, n, 2, chip->dev_cfg->reg_sense,
 			 chip->irq_sense >> (n * 2));
 }
 
-static int sx150x_irq_set_type(unsigned int irq, unsigned int flow_type)
+static int sx150x_irq_set_type(struct irq_data *d, unsigned int flow_type)
 {
-	struct irq_chip *ic = get_irq_chip(irq);
+	struct irq_chip *ic = irq_data_get_irq_chip(d);
 	struct sx150x_chip *chip;
 	unsigned n, val = 0;
 
@@ -341,7 +341,7 @@ static int sx150x_irq_set_type(unsigned int irq, unsigned int flow_type)
 		return -EINVAL;
 
 	chip = container_of(ic, struct sx150x_chip, irq_chip);
-	n = irq - chip->irq_base;
+	n = d->irq - chip->irq_base;
 
 	if (flow_type & IRQ_TYPE_EDGE_RISING)
 		val |= 0x1;
@@ -386,9 +386,9 @@ static irqreturn_t sx150x_irq_thread_fn(int irq, void *dev_id)
 	return (nhandled > 0 ? IRQ_HANDLED : IRQ_NONE);
 }
 
-static void sx150x_irq_bus_lock(unsigned int irq)
+static void sx150x_irq_bus_lock(struct irq_data *d)
 {
-	struct irq_chip *ic = get_irq_chip(irq);
+	struct irq_chip *ic = irq_data_get_irq_chip(d);
 	struct sx150x_chip *chip;
 
 	chip = container_of(ic, struct sx150x_chip, irq_chip);
@@ -396,9 +396,9 @@ static void sx150x_irq_bus_lock(unsigned int irq)
 	mutex_lock(&chip->lock);
 }
 
-static void sx150x_irq_bus_sync_unlock(unsigned int irq)
+static void sx150x_irq_bus_sync_unlock(struct irq_data *d)
 {
-	struct irq_chip *ic = get_irq_chip(irq);
+	struct irq_chip *ic = irq_data_get_irq_chip(d);
 	struct sx150x_chip *chip;
 	unsigned n;
 
@@ -437,16 +437,16 @@ static void sx150x_init_chip(struct sx150x_chip *chip,
 	if (pdata->oscio_is_gpo)
 		++chip->gpio_chip.ngpio;
 
-	chip->irq_chip.name            = client->name;
-	chip->irq_chip.mask            = sx150x_irq_mask;
-	chip->irq_chip.unmask          = sx150x_irq_unmask;
-	chip->irq_chip.set_type        = sx150x_irq_set_type;
-	chip->irq_chip.bus_lock        = sx150x_irq_bus_lock;
-	chip->irq_chip.bus_sync_unlock = sx150x_irq_bus_sync_unlock;
-	chip->irq_summary              = -1;
-	chip->irq_base                 = -1;
-	chip->irq_sense                = 0;
-	chip->irq_set_type_pending     = 0;
+	chip->irq_chip.name                = client->name;
+	chip->irq_chip.irq_mask            = sx150x_irq_mask;
+	chip->irq_chip.irq_unmask          = sx150x_irq_unmask;
+	chip->irq_chip.irq_set_type        = sx150x_irq_set_type;
+	chip->irq_chip.irq_bus_lock        = sx150x_irq_bus_lock;
+	chip->irq_chip.irq_bus_sync_unlock = sx150x_irq_bus_sync_unlock;
+	chip->irq_summary                  = -1;
+	chip->irq_base                     = -1;
+	chip->irq_sense                    = 0;
+	chip->irq_set_type_pending         = 0;
 }
 
 static int sx150x_init_io(struct sx150x_chip *chip, u8 base, u16 cfg)
-- 
1.7.1


^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH 08/10] gpio: tc35892-gpio: irq_data conversion.
       [not found] <cover.1292240053.git.buytenh@wantstofly.org>
                   ` (6 preceding siblings ...)
  2010-12-13 12:03 ` [PATCH 07/10] gpio: sx150x: " Lennert Buytenhek
@ 2010-12-13 12:03 ` Lennert Buytenhek
  2010-12-13 12:08   ` Rabin Vincent
  2010-12-13 12:03 ` [PATCH 09/10] gpio: timbgpio: " Lennert Buytenhek
  2010-12-13 12:03 ` [PATCH 10/10] gpio: vr41xx_giu: " Lennert Buytenhek
  9 siblings, 1 reply; 16+ messages in thread
From: Lennert Buytenhek @ 2010-12-13 12:03 UTC (permalink / raw)
  To: Rabin Vincent; +Cc: Andrew Morton, linux-kernel

Signed-off-by: Lennert Buytenhek <buytenh@secretlab.ca>
---
 drivers/gpio/tc35892-gpio.c |   36 ++++++++++++++++++------------------
 1 files changed, 18 insertions(+), 18 deletions(-)

diff --git a/drivers/gpio/tc35892-gpio.c b/drivers/gpio/tc35892-gpio.c
index 7e10c93..867e44b 100644
--- a/drivers/gpio/tc35892-gpio.c
+++ b/drivers/gpio/tc35892-gpio.c
@@ -110,10 +110,10 @@ static struct gpio_chip template_chip = {
 	.can_sleep		= 1,
 };
 
-static int tc35892_gpio_irq_set_type(unsigned int irq, unsigned int type)
+static int tc35892_gpio_irq_set_type(struct irq_data *d, unsigned int type)
 {
-	struct tc35892_gpio *tc35892_gpio = get_irq_chip_data(irq);
-	int offset = irq - tc35892_gpio->irq_base;
+	struct tc35892_gpio *tc35892_gpio = irq_data_get_irq_chip_data(d);
+	int offset = d->irq - tc35892_gpio->irq_base;
 	int regoffset = offset / 8;
 	int mask = 1 << (offset % 8);
 
@@ -137,16 +137,16 @@ static int tc35892_gpio_irq_set_type(unsigned int irq, unsigned int type)
 	return 0;
 }
 
-static void tc35892_gpio_irq_lock(unsigned int irq)
+static void tc35892_gpio_irq_lock(struct irq_data *d)
 {
-	struct tc35892_gpio *tc35892_gpio = get_irq_chip_data(irq);
+	struct tc35892_gpio *tc35892_gpio = irq_data_get_irq_chip_data(d);
 
 	mutex_lock(&tc35892_gpio->irq_lock);
 }
 
-static void tc35892_gpio_irq_sync_unlock(unsigned int irq)
+static void tc35892_gpio_irq_sync_unlock(struct irq_data *d)
 {
-	struct tc35892_gpio *tc35892_gpio = get_irq_chip_data(irq);
+	struct tc35892_gpio *tc35892_gpio = irq_data_get_irq_chip_data(d);
 	struct tc35892 *tc35892 = tc35892_gpio->tc35892;
 	static const u8 regmap[] = {
 		[REG_IBE]	= TC35892_GPIOIBE0,
@@ -172,20 +172,20 @@ static void tc35892_gpio_irq_sync_unlock(unsigned int irq)
 	mutex_unlock(&tc35892_gpio->irq_lock);
 }
 
-static void tc35892_gpio_irq_mask(unsigned int irq)
+static void tc35892_gpio_irq_mask(struct irq_data *d)
 {
-	struct tc35892_gpio *tc35892_gpio = get_irq_chip_data(irq);
-	int offset = irq - tc35892_gpio->irq_base;
+	struct tc35892_gpio *tc35892_gpio = irq_data_get_irq_chip_data(d);
+	int offset = d->irq - tc35892_gpio->irq_base;
 	int regoffset = offset / 8;
 	int mask = 1 << (offset % 8);
 
 	tc35892_gpio->regs[REG_IE][regoffset] &= ~mask;
 }
 
-static void tc35892_gpio_irq_unmask(unsigned int irq)
+static void tc35892_gpio_irq_unmask(struct irq_data *d)
 {
-	struct tc35892_gpio *tc35892_gpio = get_irq_chip_data(irq);
-	int offset = irq - tc35892_gpio->irq_base;
+	struct tc35892_gpio *tc35892_gpio = irq_data_get_irq_chip_data(d);
+	int offset = d->irq - tc35892_gpio->irq_base;
 	int regoffset = offset / 8;
 	int mask = 1 << (offset % 8);
 
@@ -194,11 +194,11 @@ static void tc35892_gpio_irq_unmask(unsigned int irq)
 
 static struct irq_chip tc35892_gpio_irq_chip = {
 	.name			= "tc35892-gpio",
-	.bus_lock		= tc35892_gpio_irq_lock,
-	.bus_sync_unlock	= tc35892_gpio_irq_sync_unlock,
-	.mask			= tc35892_gpio_irq_mask,
-	.unmask			= tc35892_gpio_irq_unmask,
-	.set_type		= tc35892_gpio_irq_set_type,
+	.irq_bus_lock		= tc35892_gpio_irq_lock,
+	.irq_bus_sync_unlock	= tc35892_gpio_irq_sync_unlock,
+	.irq_mask		= tc35892_gpio_irq_mask,
+	.irq_unmask		= tc35892_gpio_irq_unmask,
+	.irq_set_type		= tc35892_gpio_irq_set_type,
 };
 
 static irqreturn_t tc35892_gpio_irq(int irq, void *dev)
-- 
1.7.1


^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH 09/10] gpio: timbgpio: irq_data conversion.
       [not found] <cover.1292240053.git.buytenh@wantstofly.org>
                   ` (7 preceding siblings ...)
  2010-12-13 12:03 ` [PATCH 08/10] gpio: tc35892-gpio: " Lennert Buytenhek
@ 2010-12-13 12:03 ` Lennert Buytenhek
  2010-12-13 12:03 ` [PATCH 10/10] gpio: vr41xx_giu: " Lennert Buytenhek
  9 siblings, 0 replies; 16+ messages in thread
From: Lennert Buytenhek @ 2010-12-13 12:03 UTC (permalink / raw)
  To: Richard Röjfors; +Cc: Andrew Morton, linux-kernel

Signed-off-by: Lennert Buytenhek <buytenh@secretlab.ca>
---
 drivers/gpio/timbgpio.c |   30 +++++++++++++++---------------
 1 files changed, 15 insertions(+), 15 deletions(-)

diff --git a/drivers/gpio/timbgpio.c b/drivers/gpio/timbgpio.c
index 4529366..349131e 100644
--- a/drivers/gpio/timbgpio.c
+++ b/drivers/gpio/timbgpio.c
@@ -109,10 +109,10 @@ static int timbgpio_to_irq(struct gpio_chip *gpio, unsigned offset)
 /*
  * GPIO IRQ
  */
-static void timbgpio_irq_disable(unsigned irq)
+static void timbgpio_irq_disable(struct irq_data *d)
 {
-	struct timbgpio *tgpio = get_irq_chip_data(irq);
-	int offset = irq - tgpio->irq_base;
+	struct timbgpio *tgpio = irq_data_get_irq_chip_data(d);
+	int offset = d->irq - tgpio->irq_base;
 	unsigned long flags;
 
 	spin_lock_irqsave(&tgpio->lock, flags);
@@ -121,10 +121,10 @@ static void timbgpio_irq_disable(unsigned irq)
 	spin_unlock_irqrestore(&tgpio->lock, flags);
 }
 
-static void timbgpio_irq_enable(unsigned irq)
+static void timbgpio_irq_enable(struct irq_data *d)
 {
-	struct timbgpio *tgpio = get_irq_chip_data(irq);
-	int offset = irq - tgpio->irq_base;
+	struct timbgpio *tgpio = irq_data_get_irq_chip_data(d);
+	int offset = d->irq - tgpio->irq_base;
 	unsigned long flags;
 
 	spin_lock_irqsave(&tgpio->lock, flags);
@@ -133,10 +133,10 @@ static void timbgpio_irq_enable(unsigned irq)
 	spin_unlock_irqrestore(&tgpio->lock, flags);
 }
 
-static int timbgpio_irq_type(unsigned irq, unsigned trigger)
+static int timbgpio_irq_type(struct irq_data *d, unsigned trigger)
 {
-	struct timbgpio *tgpio = get_irq_chip_data(irq);
-	int offset = irq - tgpio->irq_base;
+	struct timbgpio *tgpio = irq_data_get_irq_chip_data(d);
+	int offset = d->irq - tgpio->irq_base;
 	unsigned long flags;
 	u32 lvr, flr, bflr = 0;
 	u32 ver;
@@ -193,13 +193,13 @@ out:
 	return ret;
 }
 
-static void timbgpio_irq(unsigned int irq, struct irq_desc *desc)
+static void timbgpio_irq(struct irq_data *d, struct irq_desc *desc)
 {
-	struct timbgpio *tgpio = get_irq_data(irq);
+	struct timbgpio *tgpio = irq_data_get_irq_data(d);
 	unsigned long ipr;
 	int offset;
 
-	desc->chip->ack(irq);
+	desc->irq_data.chip->ack(irq_get_irq_data(d));
 	ipr = ioread32(tgpio->membase + TGPIO_IPR);
 	iowrite32(ipr, tgpio->membase + TGPIO_ICR);
 
@@ -217,9 +217,9 @@ static void timbgpio_irq(unsigned int irq, struct irq_desc *desc)
 
 static struct irq_chip timbgpio_irqchip = {
 	.name		= "GPIO",
-	.enable		= timbgpio_irq_enable,
-	.disable	= timbgpio_irq_disable,
-	.set_type	= timbgpio_irq_type,
+	.irq_enable	= timbgpio_irq_enable,
+	.irq_disable	= timbgpio_irq_disable,
+	.irq_set_type	= timbgpio_irq_type,
 };
 
 static int __devinit timbgpio_probe(struct platform_device *pdev)
-- 
1.7.1


^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH 10/10] gpio: vr41xx_giu: irq_data conversion.
       [not found] <cover.1292240053.git.buytenh@wantstofly.org>
                   ` (8 preceding siblings ...)
  2010-12-13 12:03 ` [PATCH 09/10] gpio: timbgpio: " Lennert Buytenhek
@ 2010-12-13 12:03 ` Lennert Buytenhek
  9 siblings, 0 replies; 16+ messages in thread
From: Lennert Buytenhek @ 2010-12-13 12:03 UTC (permalink / raw)
  To: Yoichi Yuasa; +Cc: Andrew Morton, linux-kernel

Signed-off-by: Lennert Buytenhek <buytenh@secretlab.ca>
---
 drivers/gpio/vr41xx_giu.c |   48 ++++++++++++++++++++++----------------------
 1 files changed, 24 insertions(+), 24 deletions(-)

diff --git a/drivers/gpio/vr41xx_giu.c b/drivers/gpio/vr41xx_giu.c
index b16c9a8..cffa3bd 100644
--- a/drivers/gpio/vr41xx_giu.c
+++ b/drivers/gpio/vr41xx_giu.c
@@ -111,69 +111,69 @@ static inline u16 giu_clear(u16 offset, u16 clear)
 	return data;
 }
 
-static void ack_giuint_low(unsigned int irq)
+static void ack_giuint_low(struct irq_data *d)
 {
-	giu_write(GIUINTSTATL, 1 << GPIO_PIN_OF_IRQ(irq));
+	giu_write(GIUINTSTATL, 1 << GPIO_PIN_OF_IRQ(d->irq));
 }
 
-static void mask_giuint_low(unsigned int irq)
+static void mask_giuint_low(struct irq_data *d)
 {
-	giu_clear(GIUINTENL, 1 << GPIO_PIN_OF_IRQ(irq));
+	giu_clear(GIUINTENL, 1 << GPIO_PIN_OF_IRQ(d->irq));
 }
 
-static void mask_ack_giuint_low(unsigned int irq)
+static void mask_ack_giuint_low(struct irq_data *d)
 {
 	unsigned int pin;
 
-	pin = GPIO_PIN_OF_IRQ(irq);
+	pin = GPIO_PIN_OF_IRQ(d->irq);
 	giu_clear(GIUINTENL, 1 << pin);
 	giu_write(GIUINTSTATL, 1 << pin);
 }
 
-static void unmask_giuint_low(unsigned int irq)
+static void unmask_giuint_low(struct irq_data *d)
 {
-	giu_set(GIUINTENL, 1 << GPIO_PIN_OF_IRQ(irq));
+	giu_set(GIUINTENL, 1 << GPIO_PIN_OF_IRQ(d->irq));
 }
 
 static struct irq_chip giuint_low_irq_chip = {
 	.name		= "GIUINTL",
-	.ack		= ack_giuint_low,
-	.mask		= mask_giuint_low,
-	.mask_ack	= mask_ack_giuint_low,
-	.unmask		= unmask_giuint_low,
+	.irq_ack	= ack_giuint_low,
+	.irq_mask	= mask_giuint_low,
+	.irq_mask_ack	= mask_ack_giuint_low,
+	.irq_unmask	= unmask_giuint_low,
 };
 
-static void ack_giuint_high(unsigned int irq)
+static void ack_giuint_high(struct irq_data *d)
 {
 	giu_write(GIUINTSTATH,
-		  1 << (GPIO_PIN_OF_IRQ(irq) - GIUINT_HIGH_OFFSET));
+		  1 << (GPIO_PIN_OF_IRQ(d->irq) - GIUINT_HIGH_OFFSET));
 }
 
-static void mask_giuint_high(unsigned int irq)
+static void mask_giuint_high(struct irq_data *d)
 {
-	giu_clear(GIUINTENH, 1 << (GPIO_PIN_OF_IRQ(irq) - GIUINT_HIGH_OFFSET));
+	giu_clear(GIUINTENH, 1 << (GPIO_PIN_OF_IRQ(d->irq) - GIUINT_HIGH_OFFSET));
 }
 
-static void mask_ack_giuint_high(unsigned int irq)
+static void mask_ack_giuint_high(struct irq_data *d)
 {
 	unsigned int pin;
 
-	pin = GPIO_PIN_OF_IRQ(irq) - GIUINT_HIGH_OFFSET;
+	pin = GPIO_PIN_OF_IRQ(d->irq) - GIUINT_HIGH_OFFSET;
 	giu_clear(GIUINTENH, 1 << pin);
 	giu_write(GIUINTSTATH, 1 << pin);
 }
 
-static void unmask_giuint_high(unsigned int irq)
+static void unmask_giuint_high(struct irq_data *d)
 {
-	giu_set(GIUINTENH, 1 << (GPIO_PIN_OF_IRQ(irq) - GIUINT_HIGH_OFFSET));
+	giu_set(GIUINTENH, 1 << (GPIO_PIN_OF_IRQ(d->irq) - GIUINT_HIGH_OFFSET));
 }
 
 static struct irq_chip giuint_high_irq_chip = {
 	.name		= "GIUINTH",
-	.ack		= ack_giuint_high,
-	.mask		= mask_giuint_high,
-	.mask_ack	= mask_ack_giuint_high,
-	.unmask		= unmask_giuint_high,
+	.irq_ack	= ack_giuint_high,
+	.irq_mask	= mask_giuint_high,
+	.irq_mask_ack	= mask_ack_giuint_high,
+	.irq_unmask	= unmask_giuint_high,
 };
 
 static int giu_get_irq(unsigned int irq)
-- 
1.7.1

^ permalink raw reply related	[flat|nested] 16+ messages in thread

* Re: [PATCH 06/10] gpio: stmpe-gpio: irq_data conversion.
  2010-12-13 12:02 ` [PATCH 06/10] gpio: stmpe-gpio: " Lennert Buytenhek
@ 2010-12-13 12:07   ` Rabin Vincent
  0 siblings, 0 replies; 16+ messages in thread
From: Rabin Vincent @ 2010-12-13 12:07 UTC (permalink / raw)
  To: Lennert Buytenhek
  Cc: Luotao Fu, Linus WALLEIJ, Andrew Morton,
	linux-kernel@vger.kernel.org

On Mon, Dec 13, 2010 at 13:02:59 +0100, Lennert Buytenhek wrote:
> Signed-off-by: Lennert Buytenhek <buytenh@secretlab.ca>
> ---
>  drivers/gpio/stmpe-gpio.c |   36 ++++++++++++++++++------------------
>  1 files changed, 18 insertions(+), 18 deletions(-)

Acked-by: Rabin Vincent <rabin.vincent@stericsson.com>

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH 08/10] gpio: tc35892-gpio: irq_data conversion.
  2010-12-13 12:03 ` [PATCH 08/10] gpio: tc35892-gpio: " Lennert Buytenhek
@ 2010-12-13 12:08   ` Rabin Vincent
  0 siblings, 0 replies; 16+ messages in thread
From: Rabin Vincent @ 2010-12-13 12:08 UTC (permalink / raw)
  To: Lennert Buytenhek; +Cc: Andrew Morton, linux-kernel@vger.kernel.org

On Mon, Dec 13, 2010 at 13:03:05 +0100, Lennert Buytenhek wrote:
> Signed-off-by: Lennert Buytenhek <buytenh@secretlab.ca>
> ---
>  drivers/gpio/tc35892-gpio.c |   36 ++++++++++++++++++------------------
>  1 files changed, 18 insertions(+), 18 deletions(-)

Acked-by: Rabin Vincent <rabin.vincent@stericsson.com>

^ permalink raw reply	[flat|nested] 16+ messages in thread

* RE: [PATCH 01/10] gpio: adp5588-gpio: irq_data conversion.
  2010-12-13 12:02 ` [PATCH 01/10] gpio: adp5588-gpio: irq_data conversion Lennert Buytenhek
@ 2010-12-13 12:29   ` Hennerich, Michael
  0 siblings, 0 replies; 16+ messages in thread
From: Hennerich, Michael @ 2010-12-13 12:29 UTC (permalink / raw)
  To: Lennert Buytenhek, Mike Frysinger,
	broonie@opensource.wolfsonmicro.com
  Cc: Andrew Morton, linux-kernel@vger.kernel.org,
	device-drivers-devel@blackfin.uclinux.org

Lennert Buytenhek wrote on 2010-12-13:
> Signed-off-by: Lennert Buytenhek <buytenh@secretlab.ca>

Mark Brown submitted a similar patch yesterday.
I'm going to ACK his one.

-Michael


> ---
>  drivers/gpio/adp5588-gpio.c |   39 ++++++++++++++++++++---------------
>  ---- 1 files changed, 20 insertions(+), 19 deletions(-)
> diff --git a/drivers/gpio/adp5588-gpio.c b/drivers/gpio/adp5588-gpio.c
> index 0871f78..33fc685 100644
> --- a/drivers/gpio/adp5588-gpio.c
> +++ b/drivers/gpio/adp5588-gpio.c
> @@ -146,9 +146,10 @@ static int adp5588_gpio_to_irq(struct gpio_chip
> *chip, unsigned off)
>       return dev->irq_base + off;
>  }
> -static void adp5588_irq_bus_lock(unsigned int irq)
> +static void adp5588_irq_bus_lock(struct irq_data *d)
>  {
> -     struct adp5588_gpio *dev = get_irq_chip_data(irq);
> +     struct adp5588_gpio *dev = irq_data_get_irq_chip_data(d);
> +
>       mutex_lock(&dev->irq_lock);
>  }
> @@ -160,9 +161,9 @@ static void adp5588_irq_bus_lock(unsigned int irq)
>    * and unlocks the bus.
>    */
> -static void adp5588_irq_bus_sync_unlock(unsigned int irq)
> +static void adp5588_irq_bus_sync_unlock(struct irq_data *d)
>  {
> -     struct adp5588_gpio *dev = get_irq_chip_data(irq);
> +     struct adp5588_gpio *dev = irq_data_get_irq_chip_data(d);
>       int i;
>
>       for (i = 0; i <= ADP5588_BANK(ADP5588_MAXGPIO); i++) @@ -175,31
>  +176,31 @@ static void adp5588_irq_bus_sync_unlock(unsigned int irq)
>       mutex_unlock(&dev->irq_lock); }
> -static void adp5588_irq_mask(unsigned int irq)
> +static void adp5588_irq_mask(struct irq_data *d)
>  {
> -     struct adp5588_gpio *dev = get_irq_chip_data(irq);
> -     unsigned gpio = irq - dev->irq_base;
> +     struct adp5588_gpio *dev = irq_data_get_irq_chip_data(d);
> +     unsigned gpio = d->irq - dev->irq_base;
>
>       dev->irq_mask[ADP5588_BANK(gpio)] &= ~ADP5588_BIT(gpio);  }
> -static void adp5588_irq_unmask(unsigned int irq)
> +static void adp5588_irq_unmask(struct irq_data *d)
>  {
> -     struct adp5588_gpio *dev = get_irq_chip_data(irq);
> -     unsigned gpio = irq - dev->irq_base;
> +     struct adp5588_gpio *dev = irq_data_get_irq_chip_data(d);
> +     unsigned gpio = d->irq - dev->irq_base;
>
>       dev->irq_mask[ADP5588_BANK(gpio)] |= ADP5588_BIT(gpio);  }
> -static int adp5588_irq_set_type(unsigned int irq, unsigned int type)
> +static int adp5588_irq_set_type(struct irq_data *d, unsigned int
> +type)
>  {
> -     struct adp5588_gpio *dev = get_irq_chip_data(irq);
> -     uint16_t gpio = irq - dev->irq_base;
> +     struct adp5588_gpio *dev = irq_data_get_irq_chip_data(d);
> +     uint16_t gpio = d->irq - dev->irq_base;
>       unsigned bank, bit;
>
>       if ((type & IRQ_TYPE_EDGE_BOTH)) {
>               dev_err(&dev->client->dev, "irq %d: unsupported type %d\n",
> -                     irq, type);
> +                     d->irq, type);
>               return -EINVAL;
>       }
> @@ -222,11 +223,11 @@ static int adp5588_irq_set_type(unsigned int
> irq, unsigned int type)
>
>  static struct irq_chip adp5588_irq_chip = {
>       .name                   = "adp5588",
> -     .mask                   = adp5588_irq_mask,
> -     .unmask                 = adp5588_irq_unmask,
> -     .bus_lock               = adp5588_irq_bus_lock,
> -     .bus_sync_unlock        = adp5588_irq_bus_sync_unlock,
> -     .set_type               = adp5588_irq_set_type,
> +     .irq_mask               = adp5588_irq_mask,
> +     .irq_unmask             = adp5588_irq_unmask,
> +     .irq_bus_lock           = adp5588_irq_bus_lock,
> +     .irq_bus_sync_unlock    = adp5588_irq_bus_sync_unlock,
> +     .irq_set_type           = adp5588_irq_set_type,
>  };
>
>  static int adp5588_gpio_read_intstat(struct i2c_client *client, u8
> *buf)

Greetings,
Michael

--
Analog Devices GmbH      Wilhelm-Wagenfeld-Str. 6      80807 Muenchen
Sitz der Gesellschaft Muenchen, Registergericht Muenchen HRB 4036 Geschaeftsfuehrer Thomas Wessel, William A. Martin, Margaret Seif


^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH 05/10] gpio: pl061: irq_data conversion.
  2010-12-13 12:02 ` [PATCH 05/10] gpio: pl061: " Lennert Buytenhek
@ 2010-12-13 12:48   ` Baruch Siach
  0 siblings, 0 replies; 16+ messages in thread
From: Baruch Siach @ 2010-12-13 12:48 UTC (permalink / raw)
  To: Lennert Buytenhek
  Cc: David Brownell, Andrew Morton, linux-kernel, linux-arm-kernel

Hi Lennert,

(Added LAKL to Cc).

On Mon, Dec 13, 2010 at 01:02:56PM +0100, Lennert Buytenhek wrote:
> Signed-off-by: Lennert Buytenhek <buytenh@secretlab.ca>

Acked-by: Baruch Siach <baruch@tkos.co.il>

> ---
>  drivers/gpio/pl061.c |   28 ++++++++++++++--------------
>  1 files changed, 14 insertions(+), 14 deletions(-)
> 
> diff --git a/drivers/gpio/pl061.c b/drivers/gpio/pl061.c
> index 5005990..2975d22 100644
> --- a/drivers/gpio/pl061.c
> +++ b/drivers/gpio/pl061.c
> @@ -129,10 +129,10 @@ static int pl061_to_irq(struct gpio_chip *gc, unsigned offset)
>  /*
>   * PL061 GPIO IRQ
>   */
> -static void pl061_irq_disable(unsigned irq)
> +static void pl061_irq_disable(struct irq_data *d)
>  {
> -	struct pl061_gpio *chip = get_irq_chip_data(irq);
> -	int offset = irq - chip->irq_base;
> +	struct pl061_gpio *chip = irq_data_get_irq_chip_data(d);
> +	int offset = d->irq - chip->irq_base;
>  	unsigned long flags;
>  	u8 gpioie;
>  
> @@ -143,10 +143,10 @@ static void pl061_irq_disable(unsigned irq)
>  	spin_unlock_irqrestore(&chip->irq_lock, flags);
>  }
>  
> -static void pl061_irq_enable(unsigned irq)
> +static void pl061_irq_enable(struct irq_data *d)
>  {
> -	struct pl061_gpio *chip = get_irq_chip_data(irq);
> -	int offset = irq - chip->irq_base;
> +	struct pl061_gpio *chip = irq_data_get_irq_chip_data(d);
> +	int offset = d->irq - chip->irq_base;
>  	unsigned long flags;
>  	u8 gpioie;
>  
> @@ -157,10 +157,10 @@ static void pl061_irq_enable(unsigned irq)
>  	spin_unlock_irqrestore(&chip->irq_lock, flags);
>  }
>  
> -static int pl061_irq_type(unsigned irq, unsigned trigger)
> +static int pl061_irq_type(struct irq_data *d, unsigned trigger)
>  {
> -	struct pl061_gpio *chip = get_irq_chip_data(irq);
> -	int offset = irq - chip->irq_base;
> +	struct pl061_gpio *chip = irq_data_get_irq_chip_data(d);
> +	int offset = d->irq - chip->irq_base;
>  	unsigned long flags;
>  	u8 gpiois, gpioibe, gpioiev;
>  
> @@ -203,9 +203,9 @@ static int pl061_irq_type(unsigned irq, unsigned trigger)
>  
>  static struct irq_chip pl061_irqchip = {
>  	.name		= "GPIO",
> -	.enable		= pl061_irq_enable,
> -	.disable	= pl061_irq_disable,
> -	.set_type	= pl061_irq_type,
> +	.irq_enable	= pl061_irq_enable,
> +	.irq_disable	= pl061_irq_disable,
> +	.irq_set_type	= pl061_irq_type,
>  };
>  
>  static void pl061_irq_handler(unsigned irq, struct irq_desc *desc)
> @@ -214,7 +214,7 @@ static void pl061_irq_handler(unsigned irq, struct irq_desc *desc)
>  	struct list_head *ptr;
>  	struct pl061_gpio *chip;
>  
> -	desc->chip->ack(irq);
> +	desc->irq_data.chip->irq_ack(&desc->irq_data);
>  	list_for_each(ptr, chip_list) {
>  		unsigned long pending;
>  		int offset;
> @@ -229,7 +229,7 @@ static void pl061_irq_handler(unsigned irq, struct irq_desc *desc)
>  		for_each_set_bit(offset, &pending, PL061_GPIO_NR)
>  			generic_handle_irq(pl061_to_irq(&chip->gc, offset));
>  	}
> -	desc->chip->unmask(irq);
> +	desc->irq_data.chip->irq_unmask(&desc->irq_data);
>  }
>  
>  static int pl061_probe(struct amba_device *dev, struct amba_id *id)
> -- 
> 1.7.1
> 

-- 
                                                     ~. .~   Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
   - baruch@tkos.co.il - tel: +972.2.679.5364, http://www.tkos.co.il -

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH 03/10] gpio: max732x: irq_data conversion.
  2010-12-13 12:02 ` [PATCH 03/10] gpio: max732x: " Lennert Buytenhek
@ 2010-12-14 11:24   ` Marc Zyngier
  0 siblings, 0 replies; 16+ messages in thread
From: Marc Zyngier @ 2010-12-14 11:24 UTC (permalink / raw)
  To: Lennert Buytenhek; +Cc: Eric Miao, Andrew Morton, linux-kernel


On Mon, 13 Dec 2010 13:02:50 +0100, Lennert Buytenhek
<buytenh@wantstofly.org> wrote:
> Signed-off-by: Lennert Buytenhek <buytenh@secretlab.ca>

Acked-by: Marc Zyngier <maz@misterjones.org>
-- 
Who you jivin' with that Cosmik Debris?

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH 07/10] gpio: sx150x: irq_data conversion.
  2010-12-13 12:03 ` [PATCH 07/10] gpio: sx150x: " Lennert Buytenhek
@ 2010-12-15 19:58   ` Rohit Vaswani
  0 siblings, 0 replies; 16+ messages in thread
From: Rohit Vaswani @ 2010-12-15 19:58 UTC (permalink / raw)
  To: Lennert Buytenhek; +Cc: Gregory Bean, Andrew Morton, linux-kernel

On 12/13/2010 4:03 AM, Lennert Buytenhek wrote:
> Signed-off-by: Lennert Buytenhek<buytenh@secretlab.ca>
Tested-by: Rohit Vaswani <rvaswani@codeaurora.org>
> ---
>   drivers/gpio/sx150x.c |   46 +++++++++++++++++++++++-----------------------
>   1 files changed, 23 insertions(+), 23 deletions(-)
>
> diff --git a/drivers/gpio/sx150x.c b/drivers/gpio/sx150x.c
> index 823559a..e60be00 100644
> --- a/drivers/gpio/sx150x.c
> +++ b/drivers/gpio/sx150x.c
> @@ -304,36 +304,36 @@ static int sx150x_gpio_to_irq(struct gpio_chip *gc, unsigned offset)
>   	return chip->irq_base + offset;
>   }
>
> -static void sx150x_irq_mask(unsigned int irq)
> +static void sx150x_irq_mask(struct irq_data *d)
>   {
> -	struct irq_chip *ic = get_irq_chip(irq);
> +	struct irq_chip *ic = irq_data_get_irq_chip(d);
>   	struct sx150x_chip *chip;
>   	unsigned n;
>
>   	chip = container_of(ic, struct sx150x_chip, irq_chip);
> -	n = irq - chip->irq_base;
> +	n = d->irq - chip->irq_base;
>
>   	sx150x_write_cfg(chip, n, 1, chip->dev_cfg->reg_irq_mask, 1);
>   	sx150x_write_cfg(chip, n, 2, chip->dev_cfg->reg_sense, 0);
>   }
>
> -static void sx150x_irq_unmask(unsigned int irq)
> +static void sx150x_irq_unmask(struct irq_data *d)
>   {
> -	struct irq_chip *ic = get_irq_chip(irq);
> +	struct irq_chip *ic = irq_data_get_irq_chip(d);
>   	struct sx150x_chip *chip;
>   	unsigned n;
>
>   	chip = container_of(ic, struct sx150x_chip, irq_chip);
> -	n = irq - chip->irq_base;
> +	n = d->irq - chip->irq_base;
>
>   	sx150x_write_cfg(chip, n, 1, chip->dev_cfg->reg_irq_mask, 0);
>   	sx150x_write_cfg(chip, n, 2, chip->dev_cfg->reg_sense,
>   			 chip->irq_sense>>  (n * 2));
>   }
>
> -static int sx150x_irq_set_type(unsigned int irq, unsigned int flow_type)
> +static int sx150x_irq_set_type(struct irq_data *d, unsigned int flow_type)
>   {
> -	struct irq_chip *ic = get_irq_chip(irq);
> +	struct irq_chip *ic = irq_data_get_irq_chip(d);
>   	struct sx150x_chip *chip;
>   	unsigned n, val = 0;
>
> @@ -341,7 +341,7 @@ static int sx150x_irq_set_type(unsigned int irq, unsigned int flow_type)
>   		return -EINVAL;
>
>   	chip = container_of(ic, struct sx150x_chip, irq_chip);
> -	n = irq - chip->irq_base;
> +	n = d->irq - chip->irq_base;
>
>   	if (flow_type&  IRQ_TYPE_EDGE_RISING)
>   		val |= 0x1;
> @@ -386,9 +386,9 @@ static irqreturn_t sx150x_irq_thread_fn(int irq, void *dev_id)
>   	return (nhandled>  0 ? IRQ_HANDLED : IRQ_NONE);
>   }
>
> -static void sx150x_irq_bus_lock(unsigned int irq)
> +static void sx150x_irq_bus_lock(struct irq_data *d)
>   {
> -	struct irq_chip *ic = get_irq_chip(irq);
> +	struct irq_chip *ic = irq_data_get_irq_chip(d);
>   	struct sx150x_chip *chip;
>
>   	chip = container_of(ic, struct sx150x_chip, irq_chip);
> @@ -396,9 +396,9 @@ static void sx150x_irq_bus_lock(unsigned int irq)
>   	mutex_lock(&chip->lock);
>   }
>
> -static void sx150x_irq_bus_sync_unlock(unsigned int irq)
> +static void sx150x_irq_bus_sync_unlock(struct irq_data *d)
>   {
> -	struct irq_chip *ic = get_irq_chip(irq);
> +	struct irq_chip *ic = irq_data_get_irq_chip(d);
>   	struct sx150x_chip *chip;
>   	unsigned n;
>
> @@ -437,16 +437,16 @@ static void sx150x_init_chip(struct sx150x_chip *chip,
>   	if (pdata->oscio_is_gpo)
>   		++chip->gpio_chip.ngpio;
>
> -	chip->irq_chip.name            = client->name;
> -	chip->irq_chip.mask            = sx150x_irq_mask;
> -	chip->irq_chip.unmask          = sx150x_irq_unmask;
> -	chip->irq_chip.set_type        = sx150x_irq_set_type;
> -	chip->irq_chip.bus_lock        = sx150x_irq_bus_lock;
> -	chip->irq_chip.bus_sync_unlock = sx150x_irq_bus_sync_unlock;
> -	chip->irq_summary              = -1;
> -	chip->irq_base                 = -1;
> -	chip->irq_sense                = 0;
> -	chip->irq_set_type_pending     = 0;
> +	chip->irq_chip.name                = client->name;
> +	chip->irq_chip.irq_mask            = sx150x_irq_mask;
> +	chip->irq_chip.irq_unmask          = sx150x_irq_unmask;
> +	chip->irq_chip.irq_set_type        = sx150x_irq_set_type;
> +	chip->irq_chip.irq_bus_lock        = sx150x_irq_bus_lock;
> +	chip->irq_chip.irq_bus_sync_unlock = sx150x_irq_bus_sync_unlock;
> +	chip->irq_summary                  = -1;
> +	chip->irq_base                     = -1;
> +	chip->irq_sense                    = 0;
> +	chip->irq_set_type_pending         = 0;
>   }
>
>   static int sx150x_init_io(struct sx150x_chip *chip, u8 base, u16 cfg)


Thanks,
Rohit Vaswani

-- 
Sent by an employee of the Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum.


^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2010-12-15 19:58 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <cover.1292240053.git.buytenh@wantstofly.org>
2010-12-13 12:02 ` [PATCH 01/10] gpio: adp5588-gpio: irq_data conversion Lennert Buytenhek
2010-12-13 12:29   ` Hennerich, Michael
2010-12-13 12:02 ` [PATCH 02/10] gpio: langwell_gpio: " Lennert Buytenhek
2010-12-13 12:02 ` [PATCH 03/10] gpio: max732x: " Lennert Buytenhek
2010-12-14 11:24   ` Marc Zyngier
2010-12-13 12:02 ` [PATCH 04/10] gpio: pca953x: " Lennert Buytenhek
2010-12-13 12:02 ` [PATCH 05/10] gpio: pl061: " Lennert Buytenhek
2010-12-13 12:48   ` Baruch Siach
2010-12-13 12:02 ` [PATCH 06/10] gpio: stmpe-gpio: " Lennert Buytenhek
2010-12-13 12:07   ` Rabin Vincent
2010-12-13 12:03 ` [PATCH 07/10] gpio: sx150x: " Lennert Buytenhek
2010-12-15 19:58   ` Rohit Vaswani
2010-12-13 12:03 ` [PATCH 08/10] gpio: tc35892-gpio: " Lennert Buytenhek
2010-12-13 12:08   ` Rabin Vincent
2010-12-13 12:03 ` [PATCH 09/10] gpio: timbgpio: " Lennert Buytenhek
2010-12-13 12:03 ` [PATCH 10/10] gpio: vr41xx_giu: " Lennert Buytenhek

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox