• Ian Munsie's avatar
    cxl: Ensure PSL interrupt is configured for contexts with no AFU IRQs · 3c206fa7
    Ian Munsie authored
    In the cxl kernel API, it is possible to create a context and start it
    without allocating any interrupts. Since we assign or allocate the PSL
    interrupt when allocating AFU interrupts this will lead to a situation
    where we start the context with no means to take any faults.
    
    The user API is not affected as it always goes through the cxl interrupt
    allocation code paths and will have the PSL interrupt allocated or
    assigned, even if no AFU interrupts were requested.
    
    This checks that at least one interrupt is configured at the time of
    attach, and if not it will assign the multiplexed PSL interrupt for
    powernv, or allocate a single interrupt for PowerVM.
    Signed-off-by: default avatarIan Munsie <imunsie@au1.ibm.com>
    Reviewed-by: default avatarFrederic Barrat <fbarrat@linux.vnet.ibm.com>
    Signed-off-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
    3c206fa7
guest.c 26.9 KB