From patchwork Fri Dec 13 09:20:25 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sebastian Hesselbarth X-Patchwork-Id: 300950 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 40EB82C00A6 for ; Fri, 13 Dec 2013 20:21:09 +1100 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752299Ab3LMJUo (ORCPT ); Fri, 13 Dec 2013 04:20:44 -0500 Received: from mail-ea0-f173.google.com ([209.85.215.173]:41878 "EHLO mail-ea0-f173.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751654Ab3LMJUj (ORCPT ); Fri, 13 Dec 2013 04:20:39 -0500 Received: by mail-ea0-f173.google.com with SMTP id o10so724587eaj.18 for ; Fri, 13 Dec 2013 01:20:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=exKjvqljSgSLm+L36VcURt/GxTBRCt9dGsai1v1pBEA=; b=nCA0b3FtU46Ba+uJItF4eTuipI1UoCpLcP6TxORE/6zhDNmsapuYdKJAUlWDfhMSV2 dqSHLjQB6fqcKJtkQ42CVAvQpkzW+utaS5anXT7YnCFOFFIF0MhQAmSWx+xR65wzP/i1 Y4NpC+ZltgDemu7GrIzlrLrJlJmWwW0WJD3RoqMxCcCv1qfOF8xTHSvlsB1yDpp+AwNk HQh150JZoIK7l3FbLRtlYJcllVmUgSKptU/iCxlAKBo3EKuBeoEy9X/2h2ukhQ6T9M/n N1S9x0wroImF+OLndry59akvkZT9f8RW2mZ1e9Yk02ATD5bfdPqehOVgxuRXmU9Cj4+t 2i9w== X-Received: by 10.14.218.69 with SMTP id j45mr1744763eep.22.1386926438704; Fri, 13 Dec 2013 01:20:38 -0800 (PST) Received: from topkick.lan (dslc-082-083-251-183.pools.arcor-ip.net. [82.83.251.183]) by mx.google.com with ESMTPSA id 44sm4558877eek.5.2013.12.13.01.20.36 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 13 Dec 2013 01:20:36 -0800 (PST) From: Sebastian Hesselbarth To: Sebastian Hesselbarth Cc: Sebastian Hesselbarth , David Miller , Florian Fainelli , Mugunthan V N , netdev@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 1/5] net: mv643xx_eth: properly start/stop phy device Date: Fri, 13 Dec 2013 10:20:25 +0100 Message-Id: <1386926429-28818-2-git-send-email-sebastian.hesselbarth@gmail.com> In-Reply-To: <1386513631-11284-1-git-send-email-sebastian.hesselbarth@gmail.com> References: <1386513631-11284-1-git-send-email-sebastian.hesselbarth@gmail.com> Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org When using phydev, it should be phy_start/phy_stop'ed properly. This driver doesn't do that, so add the corresponding calls to port_start/ stop respectively. Signed-off-by: Sebastian Hesselbarth Acked-by: Mugunthan V N Reviewed-by: Florian Fainelli --- Cc: David Miller Cc: Florian Fainelli Cc: Mugunthan V N Cc: netdev@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org Cc: linux-kernel@vger.kernel.org --- drivers/net/ethernet/marvell/mv643xx_eth.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/drivers/net/ethernet/marvell/mv643xx_eth.c b/drivers/net/ethernet/marvell/mv643xx_eth.c index 61088a6..3aa706f 100644 --- a/drivers/net/ethernet/marvell/mv643xx_eth.c +++ b/drivers/net/ethernet/marvell/mv643xx_eth.c @@ -2098,6 +2098,7 @@ static void port_start(struct mv643xx_eth_private *mp) mv643xx_eth_get_settings(mp->dev, &cmd); phy_reset(mp); mv643xx_eth_set_settings(mp->dev, &cmd); + phy_start(mp->phy); } /* @@ -2293,7 +2294,8 @@ static int mv643xx_eth_stop(struct net_device *dev) del_timer_sync(&mp->rx_oom); netif_carrier_off(dev); - + if (mp->phy) + phy_stop(mp->phy); free_irq(dev->irq, dev); port_reset(mp);