Skip to content

Commit

Permalink
schemas: Add MSI consumer schema
Browse files Browse the repository at this point in the history
The only property so far for consumers is 'msi-parent'. As it depends on
the provider '#msi-cells', dtb decoding needs to handle it as well.

Signed-off-by: Rob Herring <robh@kernel.org>
  • Loading branch information
robherring committed Jul 28, 2022
1 parent ef7924a commit 59f2e31
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 0 deletions.
1 change: 1 addition & 0 deletions dtschema/dtb.py
Expand Up @@ -250,6 +250,7 @@ def fdt_scan_node(fdt, nodename, offset):
'interconnects': '#interconnect-cells',
'mboxes': '#mbox-cells',
'sound-dai': '#sound-dai-cells',
'msi-parent': '#msi-cells',
'gpio-ranges': 3,

'nvmem-cells': None,
Expand Down
34 changes: 34 additions & 0 deletions dtschema/schemas/msi-consumer.yaml
@@ -0,0 +1,34 @@
# SPDX-License-Identifier: BSD-2-Clause
# Copyright 2022 Arm Ltd.
$id: http://devicetree.org/schemas/msi-consumer.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: MSI consumer properties

maintainers:
- Rob Herring <robh@kernel.org>

# always select the core schema
select: true

properties:
msi-parent:
description: |
A list of phandle + msi-specifier pairs, one for each MSI controller which the
device is capable of using.
This property is unordered, and MSIs may be allocated from any combination of
MSI controllers listed in the msi-parent property.
If a device has restrictions on the allocation of MSIs, these restrictions
must be described with additional properties.
When #msi-cells is non-zero, busses with an msi-parent will require
additional properties to describe the relationship between devices on the bus
and the set of MSIs they can potentially generate.
$ref: types.yaml#/definitions/phandle-array
items:
minItems: 1
maxItems: 2

additionalProperties: true

0 comments on commit 59f2e31

Please sign in to comment.