From patchwork Tue Oct 9 04:18:21 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ajit Khaparde X-Patchwork-Id: 190192 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id AF2F62C00B0 for ; Tue, 9 Oct 2012 15:18:26 +1100 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750997Ab2JIESX (ORCPT ); Tue, 9 Oct 2012 00:18:23 -0400 Received: from cmexedge2.ext.emulex.com ([138.239.224.100]:29375 "EHLO CMEXEDGE2.ext.emulex.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750981Ab2JIESW (ORCPT ); Tue, 9 Oct 2012 00:18:22 -0400 Received: from CMEXHTCAS1.ad.emulex.com (138.239.115.217) by CMEXEDGE2.ext.emulex.com (138.239.224.100) with Microsoft SMTP Server (TLS) id 14.2.318.1; Mon, 8 Oct 2012 21:18:30 -0700 Received: from akhaparde-VBox (138.239.131.80) by smtp.emulex.com (138.239.115.207) with Microsoft SMTP Server id 14.2.318.1; Mon, 8 Oct 2012 21:18:21 -0700 Date: Mon, 8 Oct 2012 23:18:21 -0500 From: Ajit Khaparde To: , Subject: [PATCH] be2net: Remove code that stops further access to BE NIC based on UE bits Message-ID: <20121009041821.GA16595@akhaparde-VBox> Reply-To: Ajit Khaparde MIME-Version: 1.0 Content-Disposition: inline X-URL: http://www.emulex.com Organization: Emulex Corp User-Agent: "Ajit's Mutt" X-OS: Linux i686 Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org On certain platforms, BE hardware could falsely indicate UE. For BE family of NICs, do not set hw_error based on the UE bits. If there was a real fatal error, the corresponding h/w block will automatically go offline and stop traffic. Signed-off-by: Ajit Khaparde --- drivers/net/ethernet/emulex/benet/be_main.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/emulex/benet/be_main.c b/drivers/net/ethernet/emulex/benet/be_main.c index eb3f2cb..d1b6cc5 100644 --- a/drivers/net/ethernet/emulex/benet/be_main.c +++ b/drivers/net/ethernet/emulex/benet/be_main.c @@ -2129,8 +2129,11 @@ void be_detect_error(struct be_adapter *adapter) ue_hi = (ue_hi & ~ue_hi_mask); } - if (ue_lo || ue_hi || - sliport_status & SLIPORT_STATUS_ERR_MASK) { + /* On certain platforms BE hardware can indicate spurious UEs. + * Allow the h/w to stop working completely in case of a real UE. + * Hence not setting the hw_error for UE detection. + */ + if (sliport_status & SLIPORT_STATUS_ERR_MASK) { adapter->hw_error = true; dev_err(&adapter->pdev->dev, "Error detected in the card\n");