From 44c65d169c5d2e5c872581ebc65f12710d7c3b71 Mon Sep 17 00:00:00 2001 From: Mark Lord Date: Mon, 6 Apr 2009 12:29:49 -0400 Subject: sata_mv: revert SoC irq breakage Revert most of commit 6be96ac1d5e4d913e1f48299db083ada5321803b2, originally from Lennert Buijtenheck (Marvell) and Saeed Bishara (Marvell), since that commit causes sata_mv to oops at startup on SOC "Kirkwood". The SOC variants do not have the hpriv->irq_{cause,mask}_ofs registers, so don't try to write to them! This patch should also be considered for -stable. Reported-by: Maxime Bizon Signed-off-by: Mark Lord Signed-off-by: Jeff Garzik --- drivers/ata/sata_mv.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'drivers/ata') diff --git a/drivers/ata/sata_mv.c b/drivers/ata/sata_mv.c index a377226b81c..be9ae4fc5cb 100644 --- a/drivers/ata/sata_mv.c +++ b/drivers/ata/sata_mv.c @@ -3734,11 +3734,13 @@ static int mv_init_host(struct ata_host *host, unsigned int board_idx) writelfl(0, hc_mmio + HC_IRQ_CAUSE_OFS); } - /* Clear any currently outstanding host interrupt conditions */ - writelfl(0, mmio + hpriv->irq_cause_ofs); + if (!IS_SOC(hpriv)) { + /* Clear any currently outstanding host interrupt conditions */ + writelfl(0, mmio + hpriv->irq_cause_ofs); - /* and unmask interrupt generation for host regs */ - writelfl(hpriv->unmask_all_irqs, mmio + hpriv->irq_mask_ofs); + /* and unmask interrupt generation for host regs */ + writelfl(hpriv->unmask_all_irqs, mmio + hpriv->irq_mask_ofs); + } /* * enable only global host interrupts for now. -- cgit v1.2.3-70-g09d2