• Jon Hunter's avatar
    genirq: Ensure IRQ descriptor is valid when setting-up the IRQ · 9b5d585d
    Jon Hunter authored
    In the function, setup_irq(), we don't check that the descriptor
    returned from irq_to_desc() is valid before we start using it. For
    example chip_bus_lock() called from setup_irq(), assumes that the
    descriptor pointer is valid and doesn't check before dereferencing it.
    
    In many other functions including setup/free_percpu_irq() we do check
    that the descriptor returned is not NULL and therefore add the same test
    to setup_irq() to ensure the descriptor returned is valid.
    Signed-off-by: default avatarJon Hunter <jonathanh@nvidia.com>
    Signed-off-by: default avatarMarc Zyngier <marc.zyngier@arm.com>
    9b5d585d
manage.c 52.6 KB