mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 19:51:31 -04:00
iommu, x86: Provide irq_remapping_cap() interface
Add a new interface irq_remapping_cap() to detect whether irq remapping supports new features, such as VT-d Posted-Interrupts. Export the function, so that KVM code can check this and use this mechanism properly. Signed-off-by: Feng Wu <[email protected]> Reviewed-by: Jiang Liu <[email protected]> Reviewed-by: Thomas Gleixner <[email protected]> Acked-by: Joerg Roedel <[email protected]> Cc: [email protected] Cc: [email protected] Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Thomas Gleixner <[email protected]>
This commit is contained in:
parent
3d9b98f4ec
commit
959c870f73
2 changed files with 11 additions and 0 deletions
|
|
@ -81,6 +81,15 @@ void set_irq_remapping_broken(void)
|
|||
irq_remap_broken = 1;
|
||||
}
|
||||
|
||||
bool irq_remapping_cap(enum irq_remap_cap cap)
|
||||
{
|
||||
if (!remap_ops || disable_irq_post)
|
||||
return 0;
|
||||
|
||||
return (remap_ops->capability & (1 << cap));
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(irq_remapping_cap);
|
||||
|
||||
int __init irq_remapping_prepare(void)
|
||||
{
|
||||
if (disable_irq_remap)
|
||||
|
|
|
|||
Loading…
Reference in a new issue