From: Prashant Sreedharan <prashant@broadcom.com>
To: Gavin Shan <gwshan@linux.vnet.ibm.com>
Cc: <netdev@vger.kernel.org>, <davem@davemloft.net>, <mchan@broadcom.com>
Subject: Re: [PATCH] net/tg3: Release IRQs on permanent error
Date: Fri, 24 Apr 2015 14:59:19 -0700 [thread overview]
Message-ID: <1429912759.26841.1.camel@prashant> (raw)
In-Reply-To: <1429852943-28953-1-git-send-email-gwshan@linux.vnet.ibm.com>
On Fri, 2015-04-24 at 15:22 +1000, Gavin Shan wrote:
> When having permanent EEH error, the PCI device will be removed
> from the system. For this case, we shouldn't set pcierr_recovery
> to true wrongly, which blocks the driver to release the allocated
> interrupts and their handlers. Eventually, we can't disable MSI
> or MSIx successfully because of the MSI or MSIx interrupts still
> have associated interrupt actions, which is turned into following
> stack dump.
>
> Oops: Exception in kernel mode, sig: 5 [#1]
> :
> [c0000000003b76a8] .free_msi_irqs+0x80/0x1a0 (unreliable)
> [c00000000039f388] .pci_remove_bus_device+0x98/0x110
> [c0000000000790f4] .pcibios_remove_pci_devices+0x9c/0x128
> [c000000000077b98] .handle_eeh_events+0x2d8/0x4b0
> [c0000000000782d0] .eeh_event_handler+0x130/0x1c0
> [c000000000022bd4] .kernel_thread+0x54/0x70
>
> Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com>
> ---
> drivers/net/ethernet/broadcom/tg3.c | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/net/ethernet/broadcom/tg3.c b/drivers/net/ethernet/broadcom/tg3.c
> index 1270b18..069952f 100644
> --- a/drivers/net/ethernet/broadcom/tg3.c
> +++ b/drivers/net/ethernet/broadcom/tg3.c
> @@ -18129,7 +18129,9 @@ static pci_ers_result_t tg3_io_error_detected(struct pci_dev *pdev,
>
> rtnl_lock();
>
> - tp->pcierr_recovery = true;
> + /* We needn't recover from permanent error */
> + if (state == pci_channel_io_frozen)
> + tp->pcierr_recovery = true;
>
> /* We probably don't have netdev yet */
> if (!netdev || !netif_running(netdev))
Acked-by: Prashant Sreedharan <prashant@broadcom.com>
next prev parent reply other threads:[~2015-04-24 22:09 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-04-24 5:22 [PATCH] net/tg3: Release IRQs on permanent error Gavin Shan
2015-04-24 21:59 ` Prashant Sreedharan [this message]
2015-04-25 18:42 ` 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=1429912759.26841.1.camel@prashant \
--to=prashant@broadcom.com \
--cc=davem@davemloft.net \
--cc=gwshan@linux.vnet.ibm.com \
--cc=mchan@broadcom.com \
--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).