linux-ide.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sergei Shtylyov <sshtylyov@mvista.com>
To: JiSheng Zhang <jszhang3@gmail.com>
Cc: jgarzik@pobox.com, linux-ide@vger.kernel.org,
	avorontsov@mvista.com, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] ahci_platform: add suspend & resume support
Date: Sun, 30 Oct 2011 21:16:25 +0200	[thread overview]
Message-ID: <4EADA289.8040200@mvista.com> (raw)
In-Reply-To: <20111030142122.560216e2@ustc>

Hello.

On 30.10.2011 8:21, JiSheng Zhang wrote:

> Signed-off-by: JiSheng Zhang<jszhang3@gmail.com>
> ---
>   drivers/ata/ahci_platform.c |   54 +++++++++++++++++++++++++++++++++++++++++++
>   1 files changed, 54 insertions(+), 0 deletions(-)
>
> diff --git a/drivers/ata/ahci_platform.c b/drivers/ata/ahci_platform.c
> index c03277d..60ff9eb 100644
> --- a/drivers/ata/ahci_platform.c
> +++ b/drivers/ata/ahci_platform.c
> @@ -202,12 +202,66 @@ static int __devexit ahci_remove(struct platform_device *pdev)
>   	return 0;
>   }
>
> +#ifdef CONFIG_PM
> +static int ahci_suspend(struct platform_device *pdev, pm_message_t mesg)
> +{
> +	struct ata_host *host = dev_get_drvdata(&pdev->dev);

    You can also call platform_get_drvdata(pdev).

> +static int ahci_resume(struct platform_device *pdev)
> +{
> +	struct device *dev =&pdev->dev;
> +	struct ahci_platform_data *pdata = dev->platform_data;

    There's dev_get_platdata().

WBR, Sergei


      parent reply	other threads:[~2011-10-30 19:16 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-10-30  6:21 [PATCH] ahci_platform: add suspend & resume support JiSheng Zhang
2011-10-30 15:23 ` Srivatsa S. Bhat
2011-10-30 19:16 ` Sergei Shtylyov [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4EADA289.8040200@mvista.com \
    --to=sshtylyov@mvista.com \
    --cc=avorontsov@mvista.com \
    --cc=jgarzik@pobox.com \
    --cc=jszhang3@gmail.com \
    --cc=linux-ide@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).