forked from torvalds/linux
-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
irqchip/gic-v3-its: Provide MSI parent infrastructure
To support per device MSI domains the ITS must provide MSI parent domain functionality. Provide the basic skeleton for this: - msi_parent_ops - child domain init callback - the MSI parent flag set in irqdomain::flags This does not make ITS a functional parent domain as there is no bit set in the bus_select_mask yet, but it provides the base to implement PCI and platform MSI support gradually on top. Signed-off-by: Thomas Gleixner <[email protected]> Signed-off-by: Anna-Maria Behnsen <[email protected]> Signed-off-by: Shivamurthy Shastri <[email protected]> Signed-off-by: Thomas Gleixner <[email protected]> Link: https://lore.kernel.org/r/[email protected]
- Loading branch information
Showing
5 changed files
with
41 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
// SPDX-License-Identifier: GPL-2.0-only | ||
// Copyright (C) 2022 Linutronix GmbH | ||
// Copyright (C) 2022 Intel | ||
|
||
#include "irq-gic-common.h" | ||
#include "irq-msi-lib.h" | ||
|
||
#define ITS_MSI_FLAGS_REQUIRED (MSI_FLAG_USE_DEF_DOM_OPS | \ | ||
MSI_FLAG_USE_DEF_CHIP_OPS) | ||
|
||
#define ITS_MSI_FLAGS_SUPPORTED (MSI_GENERIC_FLAGS_MASK | \ | ||
MSI_FLAG_PCI_MSIX | \ | ||
MSI_FLAG_MULTI_PCI_MSI | \ | ||
MSI_FLAG_PCI_MSI_MASK_PARENT) | ||
|
||
static bool its_init_dev_msi_info(struct device *dev, struct irq_domain *domain, | ||
struct irq_domain *real_parent, struct msi_domain_info *info) | ||
{ | ||
if (!msi_lib_init_dev_msi_info(dev, domain, real_parent, info)) | ||
return false; | ||
|
||
return true; | ||
} | ||
|
||
const struct msi_parent_ops gic_v3_its_msi_parent_ops = { | ||
.supported_flags = ITS_MSI_FLAGS_SUPPORTED, | ||
.required_flags = ITS_MSI_FLAGS_REQUIRED, | ||
.bus_select_token = DOMAIN_BUS_NEXUS, | ||
.prefix = "ITS-", | ||
.init_dev_msi_info = its_init_dev_msi_info, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters