mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git
synced 2026-04-18 03:23:53 -04:00
Like SG2042, SG2044 also uses an external MSI controller to provide
MSI interrupt for PCIe controllers. The difference between these
two MSI controllers are:
1. SG2044 acks the interrupt by writing 0, SG2042 by setting the
bit related to the interrupt.
2. SG2044 uses interrupt number modulo 32 as MSI message data, but
SG2042 uses the bit related to the interrupt.
Add support for the SG2044 MSI controller.
Signed-off-by: Inochi Amaoto <inochiama@gmail.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Tested-by: Chen Wang <wangchen20@iscas.ac.cn> # SG2042
Reviewed-by: Chen Wang <unicorn_wang@outlook.com>
Acked-by: Conor Dooley <conor.dooley@microchip.com>
Link: https://lore.kernel.org/all/20250413224922.69719-2-inochiama@gmail.com
64 lines
1.3 KiB
YAML
64 lines
1.3 KiB
YAML
# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
|
|
%YAML 1.2
|
|
---
|
|
$id: http://devicetree.org/schemas/interrupt-controller/sophgo,sg2042-msi.yaml#
|
|
$schema: http://devicetree.org/meta-schemas/core.yaml#
|
|
|
|
title: Sophgo SG2042 MSI Controller
|
|
|
|
maintainers:
|
|
- Chen Wang <unicorn_wang@outlook.com>
|
|
|
|
description:
|
|
This interrupt controller is in Sophgo SG2042 for transforming interrupts from
|
|
PCIe MSI to PLIC interrupts.
|
|
|
|
allOf:
|
|
- $ref: /schemas/interrupt-controller/msi-controller.yaml#
|
|
|
|
properties:
|
|
compatible:
|
|
enum:
|
|
- sophgo,sg2042-msi
|
|
- sophgo,sg2044-msi
|
|
|
|
reg:
|
|
items:
|
|
- description: clear register
|
|
- description: msi doorbell address
|
|
|
|
reg-names:
|
|
items:
|
|
- const: clr
|
|
- const: doorbell
|
|
|
|
msi-controller: true
|
|
|
|
msi-ranges:
|
|
maxItems: 1
|
|
|
|
"#msi-cells":
|
|
const: 0
|
|
|
|
required:
|
|
- compatible
|
|
- reg
|
|
- reg-names
|
|
- msi-controller
|
|
- msi-ranges
|
|
- "#msi-cells"
|
|
|
|
unevaluatedProperties: false
|
|
|
|
examples:
|
|
- |
|
|
#include <dt-bindings/interrupt-controller/irq.h>
|
|
msi-controller@30000000 {
|
|
compatible = "sophgo,sg2042-msi";
|
|
reg = <0x30000000 0x4>, <0x30000008 0x4>;
|
|
reg-names = "clr", "doorbell";
|
|
msi-controller;
|
|
#msi-cells = <0>;
|
|
msi-ranges = <&plic 64 IRQ_TYPE_LEVEL_HIGH 32>;
|
|
};
|