Message ID | 20211217202717.10041-1-s.shtylyov@omp.ru |
---|---|
Headers | show |
Series | Add IRQ check to the Meson MMC/SD drivers | expand |
On Fri, Dec 17, 2021 at 9:27 PM Sergey Shtylyov <s.shtylyov@omp.ru> wrote: > > The driver neglects to check the result of platform_get_irq()'s call and > blithely passes the negative error codes to devm_request_threaded_irq() > (which takes *unsigned* IRQ #), causing it to fail with -EINVAL, overriding > an original error code. Stop calling devm_request_threaded_irq() with the > invalid IRQ #s. > > Fixes: e4bf1b0970ef ("mmc: host: meson-mx-sdhc: new driver for the Amlogic Meson SDHC host") > Signed-off-by: Sergey Shtylyov <s.shtylyov@omp.ru> Reviewed-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com> Thank you for catching this and for submitting a fix!
On Fri, 17 Dec 2021 at 21:27, Sergey Shtylyov <s.shtylyov@omp.ru> wrote: > > Here are 2 patches against the 'fixes' branch of Ulf Hansson's 'mmc.git' repo. > The affected drivers call platform_get_irq() but forget to check for the error > case and blithely pass the negative error codes to devm_request_threaded_irq() > (which takes *unsigned* IRQ #). Now stop calling devm_request_threaded_irq() > with the invalid IRQ #s! > > Sergey Shtylyov (2): > mmc: meson-mx-sdhc: add IRQ check > mmc: meson-mx-sdio: add IRQ check > > drivers/mmc/host/meson-mx-sdhc-mmc.c | 5 +++++ > drivers/mmc/host/meson-mx-sdio.c | 5 +++++ > 2 files changed, 10 insertions(+) > Applied for next, thanks! Kind regards Uffe