* Add in the gpio/gpioled drivers into AR91XX_BASE.

* Add in a default GPIO section for AR91XX_BASE.hints, which doesn't
  define the GPIO function masks or any GPIO pines.
* Add in the GPIO line definitions for LEDs and GPIO pins for the
  TP-WR1043nd.

I've verified the LEDs work fine using gpioset.
This commit is contained in:
adrian 2011-12-15 01:05:38 +00:00
parent 1af383c5f6
commit 4b16f2dc46
3 changed files with 49 additions and 0 deletions

View File

@ -109,3 +109,5 @@ device md
device bpf
device random
device if_bridge
device gpio
device gpioled

View File

@ -51,3 +51,9 @@ hint.mx25l.0.cs=0
# Watchdog
hint.ar71xx_wdog.0.at="nexus0"
# The GPIO function and pin mask is configured per-board
hint.gpio.0.at="apb0"
hint.gpio.0.maddr=0x18040000
hint.gpio.0.msize=0x1000
hint.gpio.0.irq=2

View File

@ -75,3 +75,44 @@ hint.map.4.start=0x007f0000
hint.map.4.end=0x00800000
hint.map.4.name="art"
hint.map.4.readonly=1
# GPIO specific configuration block
# Don't flip on anything that isn't already enabled.
# This includes leaving the SPI CS1/CS2 pins as GPIO pins as they're
# not used here.
hint.gpio.0.function_set=0x00000000
hint.gpio.0.function_clear=0x00000000
# These are the GPIO LEDs and buttons which can be software controlled.
hint.gpio.0.pinmask=0x001c02ae
# pin 1 - USB (LED)
# pin 2 - System (LED)
# Pin 3 - Reset (input)
# Pin 5 - QSS (LED)
# Pin 7 - QSS Button (input)
# Pin 8 - wired into the chip reset line
# Pin 9 - WLAN
# Pin 10 - UART TX (not GPIO)
# Pin 13 - UART RX (not GPIO)
# Pin 18 - RTL8366RB switch data line
# Pin 19 - RTL8366RB switch clock line
# Pin 20 - "GPIO20"
# LEDs are configured separately and driven by the LED device
hint.gpioled.0.at="gpiobus0"
hint.gpioled.0.name="usb"
hint.gpioled.0.pins=0x0002
hint.gpioled.1.at="gpiobus0"
hint.gpioled.1.name="system"
hint.gpioled.1.pins=0x0004
hint.gpioled.2.at="gpiobus0"
hint.gpioled.2.name="qss"
hint.gpioled.2.pins=0x0020
hint.gpioled.3.at="gpiobus0"
hint.gpioled.3.name="wlan"
hint.gpioled.3.pins=0x0200