From patchwork Thu Mar 19 15:12:17 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anton Vorontsov X-Patchwork-Id: 24686 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 DE436DE0B6 for ; Fri, 20 Mar 2009 02:12:38 +1100 (EST) X-Original-To: linuxppc-dev@ozlabs.org Delivered-To: linuxppc-dev@ozlabs.org Received: from buildserver.ru.mvista.com (unknown [213.79.90.228]) by ozlabs.org (Postfix) with ESMTP id BEABDDDE22 for ; Fri, 20 Mar 2009 02:12:19 +1100 (EST) Received: from localhost (unknown [10.150.0.9]) by buildserver.ru.mvista.com (Postfix) with ESMTP id 31A7B8815; Thu, 19 Mar 2009 20:12:40 +0400 (SAMT) Date: Thu, 19 Mar 2009 18:12:17 +0300 From: Anton Vorontsov To: David Miller Subject: [PATCH -next] gianfar: Fix build with CONFIG_PM enabled Message-ID: <20090319151217.GA11465@oksana.dev.rtsoft.ru> MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.18 (2008-05-17) Cc: netdev@vger.kernel.org, Andy Fleming , linuxppc-dev@ozlabs.org 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: , Sender: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@ozlabs.org Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@ozlabs.org commit 4826857f1bf07f9c0f1495e9b05d125552c88a85 ("gianfar: pass the proper dev to DMA ops") introduced this build breakage: CC drivers/net/gianfar.o drivers/net/gianfar.c: In function 'gfar_suspend': drivers/net/gianfar.c:552: error: 'struct gfar_private' has no member named 'dev' drivers/net/gianfar.c: In function 'gfar_resume': drivers/net/gianfar.c:601: error: 'struct gfar_private' has no member named 'dev' make[2]: *** [drivers/net/gianfar.o] Error 1 Fix this by converting suspend and resume routines to use gfar_private->ndev. Signed-off-by: Anton Vorontsov Acked-by: Kumar Gala --- drivers/net/gianfar.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/gianfar.c b/drivers/net/gianfar.c index 8659833..8a51df0 100644 --- a/drivers/net/gianfar.c +++ b/drivers/net/gianfar.c @@ -549,7 +549,7 @@ static int gfar_remove(struct of_device *ofdev) static int gfar_suspend(struct of_device *ofdev, pm_message_t state) { struct gfar_private *priv = dev_get_drvdata(&ofdev->dev); - struct net_device *dev = priv->dev; + struct net_device *dev = priv->ndev; unsigned long flags; u32 tempval; @@ -598,7 +598,7 @@ static int gfar_suspend(struct of_device *ofdev, pm_message_t state) static int gfar_resume(struct of_device *ofdev) { struct gfar_private *priv = dev_get_drvdata(&ofdev->dev); - struct net_device *dev = priv->dev; + struct net_device *dev = priv->ndev; unsigned long flags; u32 tempval; int magic_packet = priv->wol_en &&