[PATCH] sata: fsl: save irqs while coalescing
Scott Wood
scottwood at freescale.com
Tue Aug 20 10:21:08 EST 2013
On Mon, 2013-08-19 at 12:15 -0600, Anthony Foiani wrote:
> diff --git a/drivers/ata/sata_fsl.c b/drivers/ata/sata_fsl.c
> index 19720a0..851bd3f 100644
> --- a/drivers/ata/sata_fsl.c
> +++ b/drivers/ata/sata_fsl.c
> @@ -293,6 +293,7 @@ static void fsl_sata_set_irq_coalescing(struct ata_host *host,
> {
> struct sata_fsl_host_priv *host_priv = host->private_data;
> void __iomem *hcr_base = host_priv->hcr_base;
> + unsigned long flags;
>
> if (count > ICC_MAX_INT_COUNT_THRESHOLD)
> count = ICC_MAX_INT_COUNT_THRESHOLD;
> @@ -305,12 +306,12 @@ static void fsl_sata_set_irq_coalescing(struct ata_host *host,
> (count > ICC_MIN_INT_COUNT_THRESHOLD))
> ticks = ICC_SAFE_INT_TICKS;
>
> - spin_lock(&host->lock);
> + spin_lock_irqsave(&host->lock, flags);
> iowrite32((count << 24 | ticks), hcr_base + ICC);
>
> intr_coalescing_count = count;
> intr_coalescing_ticks = ticks;
> - spin_unlock(&host->lock);
> + spin_unlock_irqrestore(&host->lock, flags);
This should go to the SATA list and maintainer.
-Scott
More information about the Linuxppc-dev
mailing list