Subject: Re: [PATCH net-next 1/7] net: ipa: change ipa_interrupt_config() prototype

From: Simon Horman <[email-masked]>
Date: Fri, 1 Mar 2024 16:26:28 +0000

On Thu, Feb 29, 2024 at 02:55:48PM -0600, Alex Elder wrote:
> Change the return type of ipa_interrupt_config() to be an error
> code rather than an IPA interrupt structure pointer, and assign the
> the pointer within that function.
> 
> Change ipa_interrupt_deconfig() to take the IPA pointer as argument
> and have it invalidate the ipa->interrupt pointer.
> 
> Signed-off-by: Alex Elder <[email-masked]>
> ---
>  drivers/net/ipa/ipa_interrupt.c | 15 ++++++++++-----
>  drivers/net/ipa/ipa_interrupt.h | 10 +++++-----
>  drivers/net/ipa/ipa_main.c      | 13 ++++---------
>  3 files changed, 19 insertions(+), 19 deletions(-)
> 
> diff --git a/drivers/net/ipa/ipa_interrupt.c b/drivers/net/ipa/ipa_interrupt.c
> index 4d80bf77a5323..a298d922dd871 100644
> --- a/drivers/net/ipa/ipa_interrupt.c
> +++ b/drivers/net/ipa/ipa_interrupt.c
> @@ -236,7 +236,7 @@ void ipa_interrupt_simulate_suspend(struct ipa_interrupt *interrupt)
>  }
>  
>  /* Configure the IPA interrupt framework */
> -struct ipa_interrupt *ipa_interrupt_config(struct ipa *ipa)
> +int ipa_interrupt_config(struct ipa *ipa)

Hi Alex,

There are two cases where this function still returns a pointer.

Around line 250:

	ret = platform_get_irq_byname(ipa->pdev, "ipa");
	if (ret <= 0) {
		dev_err(dev, "DT error %d getting \"ipa\" IRQ property\n",
			ret);
		return ERR_PTR(ret ? : -EINVAL);
	}

And around line 280:

	return interrupt;

This does seem to be resolved in patch 2/7.
But as it is, this patch breaks bisection.

...