Commit graph

8 commits

Author SHA1 Message Date
Sergio Paracuellos a7e09d3e8f 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: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Reviewed-by: NeilBrown <neil@brown.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-06-01 13:16:23 +02:00
Sergio Paracuellos f910cc46f4 staging: mt7621-dts: add missing properties to gpio node
In order to let other devices reference the GPIO interrupts
if necessary properties 'interrupt-controller' and
'#interrupt-cells' becomes necessary. Add both of them to
complete gpio device tree node.

Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Reviewed-by: NeilBrown <neil@brown.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-06-01 11:17:05 +02:00
Sergio Paracuellos c7092ed794 staging: mt7621-dts: add interrupt device tree nodes for the gpio controller
The GPIO controller of mt7621 can receive interrupts on any
of the GPIOs, either edge or level. It then interrupts the CPU using
GIC INT12. Update device tree accordly.

Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Reviewed-by: NeilBrown <neil@brown.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:49:32 +02:00
Sergio Paracuellos 81ca7c496f staging: mt7621-dts: update gpios related entries to use 'mediatek'
Gpio driver for mt7621 is using 'mtk' as binding but in the kernel
is already defined one for this maker which is 'mediatek'. Update
device tree to use the correct one.

Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Reviewed-by: NeilBrown <neil@brown.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:49:32 +02:00
NeilBrown ab56a0d024 staging: mt7621-dts: update nor-flash info for gnubee1
The GNUBEE has 32MB flash, so set partitions accordingly.
Also remove "m25p,chunked-io" which isn't documented or
used anywhere (outside of freewrt).

Signed-off-by: NeilBrown <neil@brown.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-06 19:09:24 -07:00
NeilBrown 46d093124d staging: mt7621-pci: improve interrupt mapping
As the Interrupts for the PCI adapters are listed in
devicetree we shouldn't need to have them explicit in the code.

The simplest way to do this is to use of_irq_parse_and_map_pci()
and specify an interrupt-map which identifies the different
PCI hosts by bus/slot numbers.
This has the advantage that the hwirq number are mapped to virq
numbers for us, so the ugly hack can go.

Signed-off-by: NeilBrown <neil@brown.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-06 19:09:23 -07:00
Nishka Dasgupta 8e2ff0e4b5 staging: mt7621-dts: Replace spaces with tabs in indentation
Replace spaces with tabs in indentation.
Issue found with checkpatch.

Signed-off-by: Nishka Dasgupta <nishka.dasgupta_ug18@ashoka.edu.in>
Acked-by: Julia Lawall <julia.lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-03-29 11:52:25 +02:00
NeilBrown d59578da2b staging: mt7621-dts: add dts files
Add device tree source for mt7621 and gnubee1 to
make testing easier.

Signed-off-by: NeilBrown <neil@brown.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-03-19 19:56:02 +01:00