Re: [PATCH] staging: media: atomisp: clean up atomisp_v4l2.c style warnings
From: Andy Shevchenko
Date: Sat Jul 04 2026 - 12:48:43 EST
On Sat, Jul 4, 2026 at 5:01 PM Ruziev Miraly <miraly.dev@xxxxxxxxx> wrote:
>
> Fix checkpatch.pl warnings in atomisp_v4l2.c regarding unnecessary
> ftrace-like logging and redundant else statements after return.
>
> Remove dev_dbg() calls that only log function entry, as ftrace should
> be preferred for this purpose. Also, remove the unnecessary else block
> following a return statement to flatten the code structure.
...
> @@ -468,22 +464,18 @@ static int atomisp_mrfld_pre_power_down(struct atomisp_device *isp)
> __func__, irq);
^^^
> spin_unlock_irqrestore(&isp->lock, flags);
> return -EAGAIN;
> - } else {
> - pci_read_config_dword(pdev, PCI_INTERRUPT_CTRL, &irq);
> - irq &= BIT(INTR_IIR);
> - pci_write_config_dword(pdev, PCI_INTERRUPT_CTRL, irq);
> -
> - pci_read_config_dword(pdev, PCI_INTERRUPT_CTRL, &irq);
> - if (!(irq & BIT(INTR_IIR))) {
> - atomisp_css2_hw_store_32(MRFLD_INTR_ENABLE_REG, 0x0);
> - goto done;
> - }
> - dev_err(isp->dev,
> - "%s: error in iunit interrupt. status reg=0x%x\n",
> - __func__, irq);
You removed this one and the above branch seems to have the similar
one. Be consistent.
> - spin_unlock_irqrestore(&isp->lock, flags);
> - return -EAGAIN;
> }
> + pci_read_config_dword(pdev, PCI_INTERRUPT_CTRL, &irq);
> + irq &= BIT(INTR_IIR);
> + pci_write_config_dword(pdev, PCI_INTERRUPT_CTRL, irq);
> +
> + pci_read_config_dword(pdev, PCI_INTERRUPT_CTRL, &irq);
> + if (!(irq & BIT(INTR_IIR))) {
> + atomisp_css2_hw_store_32(MRFLD_INTR_ENABLE_REG, 0x0);
> + goto done;
> + }
> + spin_unlock_irqrestore(&isp->lock, flags);
> + return -EAGAIN;
--
With Best Regards,
Andy Shevchenko