media: atomisp: don't produce errs for ignored IRQs
authorMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Wed, 20 May 2020 06:46:17 +0000 (08:46 +0200)
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Wed, 20 May 2020 13:02:58 +0000 (15:02 +0200)
Depending on the ISP-specific HAS_NO_INPUT_FORMATTER macro,
some IRQs will be ignored by the driver. Yet, those keep
happening, as reported by this debug print:

[   61.620746] atomisp-isp2 0000:00:03.0: atomisp_css_irq_enable: css irq info 0x00000004: disable.

Causing this warning:
[   61.620749] atomisp-isp2 0000:00:03.0: atomisp_css_irq_enable:Invalid irq info.

Well, if this is a normal situation, just ignore it without
warnings.

Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
drivers/staging/media/atomisp/pci/sh_css.c

index af77fb5..05b3565 100644 (file)
@@ -2660,11 +2660,16 @@ enum ia_css_err ia_css_irq_enable(
        case IA_CSS_IRQ_INFO_INPUT_SYSTEM_ERROR:
                irq = virq_isys_csi;
                break;
-#endif
-#if !defined(HAS_NO_INPUT_FORMATTER)
        case IA_CSS_IRQ_INFO_IF_ERROR:
                irq = virq_ifmt0_id;
                break;
+#else
+       case IA_CSS_IRQ_INFO_CSS_RECEIVER_SOF:
+       case IA_CSS_IRQ_INFO_CSS_RECEIVER_EOF:
+       case IA_CSS_IRQ_INFO_INPUT_SYSTEM_ERROR:
+       case IA_CSS_IRQ_INFO_IF_ERROR:
+               /* Just ignore those unused IRQs without printing errors */
+               return IA_CSS_SUCCESS;
 #endif
        case IA_CSS_IRQ_INFO_DMA_ERROR:
                irq = virq_dma;