From: Sagar Borikar <sagar.borikar@gmail.com>
To: Jeff Garzik <jeff@garzik.org>
Cc: linux-ide@vger.kernel.org, LKML <linux-kernel@vger.kernel.org>,
Alan Cox <alan@lxorguk.ukuu.org.uk>,
d.harrison@sutus.com
Subject: Re: [PATCH 2/2] sata_sil: disable DMA engine in ->freeze
Date: Wed, 8 Apr 2009 10:43:31 +0530 [thread overview]
Message-ID: <3fb94e50904072213n637525b1w4b032544dcef3618@mail.gmail.com> (raw)
In-Reply-To: <20090407232331.GA16190@havoc.gtf.org>
This patch works for our platform.
Thanks
Sagar
On Wed, Apr 8, 2009 at 4:53 AM, Jeff Garzik <jeff@garzik.org> wrote:
>
> Dustin, please see if these two patches solve your problem?
>
>
> commit a6a2da59f2a4ba834a6e20e2d2a4d030bb9371ea
> Author: Jeff Garzik <jeff@garzik.org>
> Date: Tue Apr 7 19:18:32 2009 -0400
>
> [libata] sata_sil: disable DMA engine in sil_freeze()
>
> We must disable the DMA engine before accessing taskfile registers.
>
> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
>
> diff --git a/drivers/ata/sata_sil.c b/drivers/ata/sata_sil.c
> index e67ce8e..896975f 100644
> --- a/drivers/ata/sata_sil.c
> +++ b/drivers/ata/sata_sil.c
> @@ -565,6 +565,19 @@ static void sil_freeze(struct ata_port *ap)
> tmp |= SIL_MASK_IDE0_INT << ap->port_no;
> writel(tmp, mmio_base + SIL_SYSCFG);
> readl(mmio_base + SIL_SYSCFG); /* flush */
> +
> + /* Ensure DMA_ENABLE is off.
> + *
> + * This is because the controller will not give us access to the
> + * taskfile registers while a DMA is in progress
> + */
> + iowrite8(ioread8(ap->ioaddr.bmdma_addr) & ~SIL_DMA_ENABLE,
> + ap->ioaddr.bmdma_addr);
> +
> + /* According to ata_bmdma_stop, an HDMA transition requires
> + * on PIO cycle. But we can't read a taskfile register.
> + */
> + ioread8(ap->ioaddr.bmdma_addr);
> }
>
> static void sil_thaw(struct ata_port *ap)
>
next prev parent reply other threads:[~2009-04-08 5:13 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-04-07 23:22 [PATCH 1/2] libata EH: freeze port before aborting commands Jeff Garzik
2009-04-07 23:23 ` [PATCH 2/2] sata_sil: disable DMA engine in ->freeze Jeff Garzik
2009-04-08 5:13 ` Sagar Borikar [this message]
2009-04-08 5:17 ` Jeff Garzik
2009-04-08 5:31 ` Sagar Borikar
2009-04-08 19:37 ` Dustin Harrison
2009-04-08 19:49 ` Jeff Garzik
2009-04-08 20:40 ` Tejun Heo
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=3fb94e50904072213n637525b1w4b032544dcef3618@mail.gmail.com \
--to=sagar.borikar@gmail.com \
--cc=alan@lxorguk.ukuu.org.uk \
--cc=d.harrison@sutus.com \
--cc=jeff@garzik.org \
--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
all inboxes | Powered by JetHome®