Commit a7e09d3e authored by Sergio Paracuellos's avatar Sergio Paracuellos Committed by Greg Kroah-Hartman

staging: mt7621-gpio: update #interrupt-cells for the gpio node

Most gpio chips have two cells for interrupts and this should be also.
Set this property in the device tree accordly fixing this up. In order
to make this working properly the xlate function for the irq_domain must
be updated to use the  'irq_domain_xlate_twocell' one in the driver.
One more minimal change is needed two refer gpio's interrupt-parent from
other nodes which is to add new 'gpio' label in the device tree.
Signed-off-by: default avatarSergio Paracuellos <sergio.paracuellos@gmail.com>
Reviewed-by: default avatarNeilBrown <neil@brown.name>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 94832e07
...@@ -60,7 +60,7 @@ wdt: wdt@100 { ...@@ -60,7 +60,7 @@ wdt: wdt@100 {
reg = <0x100 0x100>; reg = <0x100 0x100>;
}; };
gpio@600 { gpio: gpio@600 {
#address-cells = <1>; #address-cells = <1>;
#size-cells = <0>; #size-cells = <0>;
...@@ -70,7 +70,7 @@ gpio@600 { ...@@ -70,7 +70,7 @@ gpio@600 {
interrupt-parent = <&gic>; interrupt-parent = <&gic>;
interrupts = <GIC_SHARED 12 IRQ_TYPE_LEVEL_HIGH>; interrupts = <GIC_SHARED 12 IRQ_TYPE_LEVEL_HIGH>;
interrupt-controller; interrupt-controller;
#interrupt-cells = <1>; #interrupt-cells = <2>;
gpio0: bank@0 { gpio0: bank@0 {
reg = <0>; reg = <0>;
......
...@@ -317,7 +317,7 @@ mediatek_gpio_gpio_map(struct irq_domain *d, unsigned int irq, ...@@ -317,7 +317,7 @@ mediatek_gpio_gpio_map(struct irq_domain *d, unsigned int irq,
} }
static const struct irq_domain_ops irq_domain_ops = { static const struct irq_domain_ops irq_domain_ops = {
.xlate = irq_domain_xlate_onecell, .xlate = irq_domain_xlate_twocell,
.map = mediatek_gpio_gpio_map, .map = mediatek_gpio_gpio_map,
}; };
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment