162306a36Sopenharmony_ci# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
262306a36Sopenharmony_ci%YAML 1.2
362306a36Sopenharmony_ci---
462306a36Sopenharmony_ci$id: http://devicetree.org/schemas/pci/intel,ixp4xx-pci.yaml#
562306a36Sopenharmony_ci$schema: http://devicetree.org/meta-schemas/core.yaml#
662306a36Sopenharmony_ci
762306a36Sopenharmony_cititle: Intel IXP4xx PCI controller
862306a36Sopenharmony_ci
962306a36Sopenharmony_cimaintainers:
1062306a36Sopenharmony_ci  - Linus Walleij <linus.walleij@linaro.org>
1162306a36Sopenharmony_ci
1262306a36Sopenharmony_cidescription: PCI host controller found in the Intel IXP4xx SoC series.
1362306a36Sopenharmony_ci
1462306a36Sopenharmony_ciallOf:
1562306a36Sopenharmony_ci  - $ref: /schemas/pci/pci-bus.yaml#
1662306a36Sopenharmony_ci
1762306a36Sopenharmony_ciproperties:
1862306a36Sopenharmony_ci  compatible:
1962306a36Sopenharmony_ci    items:
2062306a36Sopenharmony_ci      - enum:
2162306a36Sopenharmony_ci          - intel,ixp42x-pci
2262306a36Sopenharmony_ci          - intel,ixp43x-pci
2362306a36Sopenharmony_ci    description: The two supported variants are ixp42x and ixp43x,
2462306a36Sopenharmony_ci      though more variants may exist.
2562306a36Sopenharmony_ci
2662306a36Sopenharmony_ci  reg:
2762306a36Sopenharmony_ci    items:
2862306a36Sopenharmony_ci      - description: IXP4xx-specific registers
2962306a36Sopenharmony_ci
3062306a36Sopenharmony_ci  interrupts:
3162306a36Sopenharmony_ci    items:
3262306a36Sopenharmony_ci      - description: Main PCI interrupt
3362306a36Sopenharmony_ci      - description: PCI DMA interrupt 1
3462306a36Sopenharmony_ci      - description: PCI DMA interrupt 2
3562306a36Sopenharmony_ci
3662306a36Sopenharmony_ci  ranges:
3762306a36Sopenharmony_ci    maxItems: 2
3862306a36Sopenharmony_ci    description: Typically one memory range of 64MB and one IO
3962306a36Sopenharmony_ci      space range of 64KB.
4062306a36Sopenharmony_ci
4162306a36Sopenharmony_ci  dma-ranges:
4262306a36Sopenharmony_ci    maxItems: 1
4362306a36Sopenharmony_ci    description: The DMA range tells the PCI host which addresses
4462306a36Sopenharmony_ci      the RAM is at. It can map only 64MB so if the RAM is bigger
4562306a36Sopenharmony_ci      than 64MB the DMA access has to be restricted to these
4662306a36Sopenharmony_ci      addresses.
4762306a36Sopenharmony_ci
4862306a36Sopenharmony_ci  "#interrupt-cells": true
4962306a36Sopenharmony_ci
5062306a36Sopenharmony_ci  interrupt-map: true
5162306a36Sopenharmony_ci
5262306a36Sopenharmony_ci  interrupt-map-mask:
5362306a36Sopenharmony_ci    items:
5462306a36Sopenharmony_ci      - const: 0xf800
5562306a36Sopenharmony_ci      - const: 0
5662306a36Sopenharmony_ci      - const: 0
5762306a36Sopenharmony_ci      - const: 7
5862306a36Sopenharmony_ci
5962306a36Sopenharmony_cirequired:
6062306a36Sopenharmony_ci  - compatible
6162306a36Sopenharmony_ci  - reg
6262306a36Sopenharmony_ci  - dma-ranges
6362306a36Sopenharmony_ci  - "#interrupt-cells"
6462306a36Sopenharmony_ci  - interrupt-map
6562306a36Sopenharmony_ci  - interrupt-map-mask
6662306a36Sopenharmony_ci
6762306a36Sopenharmony_ciunevaluatedProperties: false
6862306a36Sopenharmony_ci
6962306a36Sopenharmony_ciexamples:
7062306a36Sopenharmony_ci  - |
7162306a36Sopenharmony_ci    pci@c0000000 {
7262306a36Sopenharmony_ci      compatible = "intel,ixp43x-pci";
7362306a36Sopenharmony_ci      reg = <0xc0000000 0x1000>;
7462306a36Sopenharmony_ci      #address-cells = <3>;
7562306a36Sopenharmony_ci      #size-cells = <2>;
7662306a36Sopenharmony_ci      device_type = "pci";
7762306a36Sopenharmony_ci      bus-range = <0x00 0xff>;
7862306a36Sopenharmony_ci
7962306a36Sopenharmony_ci      ranges =
8062306a36Sopenharmony_ci        <0x02000000 0 0x48000000 0x48000000 0 0x04000000>,
8162306a36Sopenharmony_ci        <0x01000000 0 0x00000000 0x4c000000 0 0x00010000>;
8262306a36Sopenharmony_ci      dma-ranges =
8362306a36Sopenharmony_ci        <0x02000000 0 0x00000000 0x00000000 0 0x04000000>;
8462306a36Sopenharmony_ci
8562306a36Sopenharmony_ci      #interrupt-cells = <1>;
8662306a36Sopenharmony_ci      interrupt-map-mask = <0xf800 0 0 7>;
8762306a36Sopenharmony_ci      interrupt-map =
8862306a36Sopenharmony_ci        <0x0800 0 0 1 &gpio0 11 3>, /* INT A on slot 1 is irq 11 */
8962306a36Sopenharmony_ci        <0x0800 0 0 2 &gpio0 10 3>, /* INT B on slot 1 is irq 10 */
9062306a36Sopenharmony_ci        <0x0800 0 0 3 &gpio0 9  3>, /* INT C on slot 1 is irq 9 */
9162306a36Sopenharmony_ci        <0x0800 0 0 4 &gpio0 8  3>, /* INT D on slot 1 is irq 8 */
9262306a36Sopenharmony_ci        <0x1000 0 0 1 &gpio0 10 3>, /* INT A on slot 2 is irq 10 */
9362306a36Sopenharmony_ci        <0x1000 0 0 2 &gpio0 9  3>, /* INT B on slot 2 is irq 9 */
9462306a36Sopenharmony_ci        <0x1000 0 0 3 &gpio0 8  3>, /* INT C on slot 2 is irq 8 */
9562306a36Sopenharmony_ci        <0x1000 0 0 4 &gpio0 11 3>, /* INT D on slot 2 is irq 11 */
9662306a36Sopenharmony_ci        <0x1800 0 0 1 &gpio0 9  3>, /* INT A on slot 3 is irq 9 */
9762306a36Sopenharmony_ci        <0x1800 0 0 2 &gpio0 8  3>, /* INT B on slot 3 is irq 8 */
9862306a36Sopenharmony_ci        <0x1800 0 0 3 &gpio0 11 3>, /* INT C on slot 3 is irq 11 */
9962306a36Sopenharmony_ci        <0x1800 0 0 4 &gpio0 10 3>; /* INT D on slot 3 is irq 10 */
10062306a36Sopenharmony_ci    };
101