From 0dadd95216d56cec01cef066eebe6354f069ff34 Mon Sep 17 00:00:00 2001 From: Diana Craciun Date: Tue, 29 Sep 2020 11:54:39 +0300 Subject: bus/fsl-mc: Export IRQ pool handling functions to be used by VFIO The IRQ pool handling functions can be used by both DPRC driver and VFIO. Adapt and export those functions. Reviewed-by: Laurentiu Tudor Acked-by: Laurentiu Tudor Signed-off-by: Diana Craciun Link: https://lore.kernel.org/r/20200929085441.17448-12-diana.craciun@oss.nxp.com Signed-off-by: Greg Kroah-Hartman --- include/linux/fsl/mc.h | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'include/linux/fsl') diff --git a/include/linux/fsl/mc.h b/include/linux/fsl/mc.h index e99d181ee4cd..f791fe38c251 100644 --- a/include/linux/fsl/mc.h +++ b/include/linux/fsl/mc.h @@ -542,6 +542,17 @@ int dprc_cleanup(struct fsl_mc_device *mc_dev); int dprc_setup(struct fsl_mc_device *mc_dev); +/** + * Maximum number of total IRQs that can be pre-allocated for an MC bus' + * IRQ pool + */ +#define FSL_MC_IRQ_POOL_MAX_TOTAL_IRQS 256 + +int fsl_mc_populate_irq_pool(struct fsl_mc_device *mc_bus_dev, + unsigned int irq_count); + +void fsl_mc_cleanup_irq_pool(struct fsl_mc_device *mc_bus_dev); + /* * Data Path Buffer Pool (DPBP) API * Contains initialization APIs and runtime control APIs for DPBP -- cgit v1.2.3