Skip to content

Commit

Permalink
dt-bindings: gpio: Add bindings for gpio-virtio
Browse files Browse the repository at this point in the history
This patch adds binding for virtio GPIO controller, it is based on
virtio-device bindings.

Reviewed-by: Arnd Bergmann <[email protected]>
Signed-off-by: Viresh Kumar <[email protected]>
Link: https://lore.kernel.org/r/acf7402ef4aabc0ad6295c32846f2bef1cd9b56a.1627362340.git.viresh.kumar@linaro.org
Signed-off-by: Michael S. Tsirkin <[email protected]>
Reviewed-by: Rob Herring <[email protected]>
  • Loading branch information
vireshk authored and mstsirkin committed Sep 5, 2021
1 parent 7f815fc commit f3a66dc
Showing 1 changed file with 59 additions and 0 deletions.
59 changes: 59 additions & 0 deletions Documentation/devicetree/bindings/gpio/gpio-virtio.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/gpio/gpio-virtio.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: Virtio GPIO controller

maintainers:
- Viresh Kumar <[email protected]>

allOf:
- $ref: /schemas/virtio/virtio-device.yaml#

description:
Virtio GPIO controller, see /schemas/virtio/virtio-device.yaml for more
details.

properties:
$nodename:
const: gpio

compatible:
const: virtio,device29

gpio-controller: true

"#gpio-cells":
const: 2

interrupt-controller: true

"#interrupt-cells":
const: 2

required:
- compatible
- gpio-controller
- "#gpio-cells"

unevaluatedProperties: false

examples:
- |
virtio@3000 {
compatible = "virtio,mmio";
reg = <0x3000 0x100>;
interrupts = <41>;
gpio {
compatible = "virtio,device29";
gpio-controller;
#gpio-cells = <2>;
interrupt-controller;
#interrupt-cells = <2>;
};
};
...

0 comments on commit f3a66dc

Please sign in to comment.