From patchwork Tue Jan 6 20:52:51 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kumar Gala X-Patchwork-Id: 16853 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from ozlabs.org (localhost [127.0.0.1]) by ozlabs.org (Postfix) with ESMTP id 9B2AF47501 for ; Wed, 7 Jan 2009 07:56:04 +1100 (EST) X-Original-To: linuxppc-dev@ozlabs.org Delivered-To: linuxppc-dev@ozlabs.org Received: from gate.crashing.org (gate.crashing.org [63.228.1.57]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id F0101DE4E3 for ; Wed, 7 Jan 2009 07:55:02 +1100 (EST) Received: from localhost (localhost.localdomain [127.0.0.1]) by gate.crashing.org (8.14.1/8.13.8) with ESMTP id n06KqpGs011155; Tue, 6 Jan 2009 14:52:52 -0600 From: Kumar Gala To: netdev@vger.kernel.org Subject: [PATCH] gianfar: ensure ECNTRL[R100] is cleared on link state change Date: Tue, 6 Jan 2009 14:52:51 -0600 Message-Id: <1231275171-21388-1-git-send-email-galak@kernel.crashing.org> X-Mailer: git-send-email 1.5.6.5 Cc: Leo Li , linuxppc-dev@ozlabs.org, afleming@freescale.com, davem@davemloft.net X-BeenThere: linuxppc-dev@ozlabs.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@ozlabs.org Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@ozlabs.org From: Leo Li When changing the link between 100Mbps and 1Gbps in SGMII mode it was found out that the link would stop working. The issue is that ECNTRL[R100] needs to be cleared when in 1Gbps mode. Older reference manuals didn't require the explicitly clearing but has since been found it that it is needed. Signed-off-by: Li Yang Signed-off-by: Kumar Gala Acked-by: Andy Fleming --- Dave, Please apply for 2.6.29 as it addresses a "HW" bug in real systems. thanks - k drivers/net/gianfar.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/drivers/net/gianfar.c b/drivers/net/gianfar.c index c672ecf..7fcc3af 100644 --- a/drivers/net/gianfar.c +++ b/drivers/net/gianfar.c @@ -1973,6 +1973,8 @@ static void adjust_link(struct net_device *dev) case 1000: tempval = ((tempval & ~(MACCFG2_IF)) | MACCFG2_GMII); + + ecntrl &= ~(ECNTRL_R100); break; case 100: case 10: