Linux ATA/IDE development
 help / color / mirror / Atom feed
* [RFC] ata/core: don't enable the interrupt while activating the host
@ 2010-03-11 22:04 Sebastian Andrzej Siewior
  2010-03-25  0:30 ` Tejun Heo
  0 siblings, 1 reply; 9+ messages in thread
From: Sebastian Andrzej Siewior @ 2010-03-11 22:04 UTC (permalink / raw)
  To: linux-ide

I just migrated from ide_platform to pata_platform on my Swarm/Mips
board. This resulted in "nobody cared" during request_irq().
The only difference I noticed between ATA and IDE before registering the
interrupt handler is that IDE does not enable the interrupt.
After removing the flag it looks like the controller is working with the
ATA layer.

If I flip the polarity of the interrupt, I see the "nobody cared"
message shortly after seeing ata_sff_softreset() during boot. So I tried
to perform the software reset with ATA_SRST before requesting the
interrupt hoping that it makes interrupt go away. It did not so.

Does anyone have an idea what might go wrong here?

Signed-off-by: Sebastian Andrzej Siewior <sebastian@breakpoint.cc>
---
 drivers/ata/libata-core.c |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)

diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c
index 6728328..8484223 100644
--- a/drivers/ata/libata-core.c
+++ b/drivers/ata/libata-core.c
@@ -6274,6 +6274,13 @@ int ata_host_activate(struct ata_host *host, int irq,
 		return ata_host_register(host, sht);
 	}
 
+	for (i = 0; i < host->n_ports; i++) {
+		struct ata_port *ap;
+
+		ap = host->ports[i];
+		iowrite8(ap->ctl & ~ATA_NIEN, ap->ioaddr.ctl_addr);
+	}
+
 	rc = devm_request_irq(host->dev, irq, irq_handler, irq_flags,
 			      dev_driver_string(host->dev), host);
 	if (rc)
-- 
1.6.6


^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2010-04-13 14:38 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-03-11 22:04 [RFC] ata/core: don't enable the interrupt while activating the host Sebastian Andrzej Siewior
2010-03-25  0:30 ` Tejun Heo
2010-03-25 22:04   ` Sebastian Andrzej Siewior
2010-03-25 23:54     ` Tejun Heo
2010-04-06  9:45       ` Sebastian Andrzej Siewior
2010-04-06 10:00         ` Sergei Shtylyov
2010-04-06 21:56           ` Tejun Heo
2010-04-07  7:52             ` Sebastian Andrzej Siewior
2010-04-13 14:38               ` Sebastian Andrzej Siewior

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox