Guruplug gpio
Rafal Jaworowski
raj at semihalf.com
Sat Oct 30 13:18:57 UTC 2010
On 2010-10-30, at 00:37, Milan Obuch wrote:
> Hi,
>
> after solving mge1 problem I decided to work a bit with Guruplug's gpio. There
> are some of them accessible via u-snap connector and some of them are used to
> controll status LEDs.
As mentioned in another email, Marvell GPIO driver does not get hooks for the new framework, so this needs to be provided first before you'd be able to controll LEDs from userspace etc.
> there is some description in file bindings-gpio.txt, but I did not find
> something used in dts files, so I only guessed gpios could be defined the
> following way:
>
> GPIO: gpio at 10100
> {#gpio-cells = <3>;
> compatible = "mrvl,gpio";
> reg = <0x10100 0x20>;
> gpio-controller;
> interrupts = <35 36 37 38 39 40 41>;
> interrupt-parent = <&PIC>;
> gpios =
> <&GPIO 46 2 0x00000000 /* GPIO[46]: OUT */
> &GPIO 47 2 0x00000000 /* GPIO[47]: OUT */
> &GPIO 48 2 0x00000000 /* GPIO[48]: OUT */
> &GPIO 49 2 0x00000000 /* GPIO[49]: OUT */
>> ;
> };
The "gpios" property cannot be part of the GPIO controller node -- it belongs to the node, which is a consumer of GPIO lines which belong to some GPIO controller. For example, when PCI IRQs are routed through GPIO lines: it is the PCI node that should contain the "gpios" prop referencing their parent GPIO controller and specifying which GPIO lines are used and how they are configured (polarity, trigger and other attributes).
Rafal
More information about the freebsd-arm
mailing list