From patchwork Wed Nov 25 17:10:24 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bartlomiej Zolnierkiewicz X-Patchwork-Id: 39382 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by ozlabs.org (Postfix) with ESMTP id 39AD2B7067 for ; Thu, 26 Nov 2009 04:22:32 +1100 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933349AbZKYRRP (ORCPT ); Wed, 25 Nov 2009 12:17:15 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S933481AbZKYRLH (ORCPT ); Wed, 25 Nov 2009 12:11:07 -0500 Received: from mail-fx0-f213.google.com ([209.85.220.213]:33678 "EHLO mail-fx0-f213.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933227AbZKYRLD (ORCPT ); Wed, 25 Nov 2009 12:11:03 -0500 Received: by fxm5 with SMTP id 5so7213254fxm.28 for ; Wed, 25 Nov 2009 09:11:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:cc:date:message-id :in-reply-to:references:subject; bh=Y7frANgpWEPWazm8BwreTF8KICmJecysA5R4jDuhfo4=; b=wE2AbGS3CI9DZnJRlCNMK61OFhrun1V/5aVuEq2YIXvqRTsGFcj0uJEkTlfSgSKuf9 Kr/IglRUDjcZ+xGnDsu+JZZOxUosQlSb03VcXxzoYmbrjkJGKJ1aMmUhn58uNLHXm1MA AzXn1mYbhekg3bq3yVaYi6OjeeKBxm5roUU6M= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:date:message-id:in-reply-to:references:subject; b=WhgzXXCy2/Yh2nAnxgyXijQO3kqZ9xWhksgM8g5DbDbudTE6xF1lUNYbUysEIxOBb4 nHzQZRuicX1nJOkxyGt3KtoQ2LMCbXi2bRZlJDKpl0K0qeFxVUpxwGruPDdgFXdxBzeH 9BaXaFq/yIaRAEUJRoEBg/H3e7UHYyEcypxOE= Received: by 10.216.91.13 with SMTP id g13mr394108wef.36.1259169068591; Wed, 25 Nov 2009 09:11:08 -0800 (PST) Received: from ?127.0.0.1? (chello089079027028.chello.pl [89.79.27.28]) by mx.google.com with ESMTPS id i35sm14686866gve.26.2009.11.25.09.11.07 (version=TLSv1/SSLv3 cipher=RC4-MD5); Wed, 25 Nov 2009 09:11:07 -0800 (PST) From: Bartlomiej Zolnierkiewicz To: linux-ide@vger.kernel.org Cc: Bartlomiej Zolnierkiewicz , linux-kernel@vger.kernel.org Date: Wed, 25 Nov 2009 18:10:24 +0100 Message-Id: <20091125171024.5446.80108.sendpatchset@localhost> In-Reply-To: <20091125170218.5446.13513.sendpatchset@localhost> References: <20091125170218.5446.13513.sendpatchset@localhost> Subject: [PATCH 67/86] pata_rz1000: Power Management fix Sender: linux-ide-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-ide@vger.kernel.org From: Bartlomiej Zolnierkiewicz Subject: [PATCH] pata_rz1000: Power Management fix Fix ->resume method to re-enable & re-init PCI device properly before doing chipset specific setup. Signed-off-by: Bartlomiej Zolnierkiewicz --- drivers/ata/pata_rz1000.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) -- To unsubscribe from this list: send the line "unsubscribe linux-ide" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Index: b/drivers/ata/pata_rz1000.c =================================================================== --- a/drivers/ata/pata_rz1000.c +++ b/drivers/ata/pata_rz1000.c @@ -107,11 +107,20 @@ static int rz1000_init_one (struct pci_d #ifdef CONFIG_PM static int rz1000_reinit_one(struct pci_dev *pdev) { + struct ata_host *host = dev_get_drvdata(&pdev->dev); + int rc; + + rc = ata_pci_device_do_resume(pdev); + if (rc) + return rc; + /* If this fails on resume (which is a "cant happen" case), we must stop as any progress risks data loss */ if (rz1000_fifo_disable(pdev)) panic("rz1000 fifo"); - return ata_pci_device_resume(pdev); + + ata_host_resume(host); + return 0; } #endif