netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Thomas Falcon <tlfalcon@linux.ibm.com>
To: "Cédric Le Goater" <clg@kaod.org>,
	"Juliet Kim" <julietk@linux.vnet.ibm.com>
Cc: John Allen <jallen@linux.ibm.com>,
	Michael Ellerman <mpe@ellerman.id.au>,
	linuxppc-dev@lists.ozlabs.org,
	"David S . Miller" <davem@davemloft.net>,
	netdev@vger.kernel.org
Subject: Re: [PATCH] net/ibmvnic: Fix EOI when running in XIVE mode.
Date: Fri, 11 Oct 2019 13:48:03 -0500	[thread overview]
Message-ID: <755ed199-0579-2b59-f033-91ac9582a233@linux.ibm.com> (raw)
In-Reply-To: <20191011055254.8347-1-clg@kaod.org>

On 10/11/19 12:52 AM, Cédric Le Goater wrote:
> pSeries machines on POWER9 processors can run with the XICS (legacy)
> interrupt mode or with the XIVE exploitation interrupt mode. These
> interrupt contollers have different interfaces for interrupt
> management : XICS uses hcalls and XIVE loads and stores on a page.
> H_EOI being a XICS interface the enable_scrq_irq() routine can fail
> when the machine runs in XIVE mode.
>
> Fix that by calling the EOI handler of the interrupt chip.
>
> Fixes: f23e0643cd0b ("ibmvnic: Clear pending interrupt after device reset")
> Signed-off-by: Cédric Le Goater <clg@kaod.org>
> ---

Thank you for this fix, Cedric!

Tom

>   drivers/net/ethernet/ibm/ibmvnic.c | 8 +++-----
>   1 file changed, 3 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/net/ethernet/ibm/ibmvnic.c b/drivers/net/ethernet/ibm/ibmvnic.c
> index 2b073a3c0b84..f59d9a8e35e2 100644
> --- a/drivers/net/ethernet/ibm/ibmvnic.c
> +++ b/drivers/net/ethernet/ibm/ibmvnic.c
> @@ -2878,12 +2878,10 @@ static int enable_scrq_irq(struct ibmvnic_adapter *adapter,
>   
>   	if (test_bit(0, &adapter->resetting) &&
>   	    adapter->reset_reason == VNIC_RESET_MOBILITY) {
> -		u64 val = (0xff000000) | scrq->hw_irq;
> +		struct irq_desc *desc = irq_to_desc(scrq->irq);
> +		struct irq_chip *chip = irq_desc_get_chip(desc);
>   
> -		rc = plpar_hcall_norets(H_EOI, val);
> -		if (rc)
> -			dev_err(dev, "H_EOI FAILED irq 0x%llx. rc=%ld\n",
> -				val, rc);
> +		chip->irq_eoi(&desc->irq_data);
>   	}
>   
>   	rc = plpar_hcall_norets(H_VIOCTL, adapter->vdev->unit_address,

  reply	other threads:[~2019-10-11 18:48 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-10-11  5:52 [PATCH] net/ibmvnic: Fix EOI when running in XIVE mode Cédric Le Goater
2019-10-11 18:48 ` Thomas Falcon [this message]
2019-10-13 18:19 ` David Miller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=755ed199-0579-2b59-f033-91ac9582a233@linux.ibm.com \
    --to=tlfalcon@linux.ibm.com \
    --cc=clg@kaod.org \
    --cc=davem@davemloft.net \
    --cc=jallen@linux.ibm.com \
    --cc=julietk@linux.vnet.ibm.com \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=mpe@ellerman.id.au \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).