diff options
author | Tejun Heo <htejun@gmail.com> | 2008-03-24 23:22:47 -0400 |
---|---|---|
committer | Jeff Garzik <jgarzik@redhat.com> | 2008-04-17 15:44:16 -0400 |
commit | 358f9a77a668660729e705fde9c3cf69f013aa98 (patch) | |
tree | a249660fdd9f252925eff9eaac3ed7836c839f91 /drivers/ata/sata_qstor.c | |
parent | c1bc899f5805771926c9198e2ab4d77122c356a1 (diff) |
libata: implement and use ata_noop_irq_clear()
->irq_clear() is used to clear IRQ bit of a SFF controller and isn't
useful for drivers which don't use libata SFF HSM implementation.
However, it's a required callback and many drivers implement their own
noop version as placeholder. This patch implements ata_noop_irq_clear
and use it to replace those custom placeholders.
Also, SFF drivers which don't support BMDMA don't need to use
ata_bmdma_irq_clear(). It becomes noop if BMDMA address isn't
initialized. Convert them to use ata_noop_irq_clear().
Signed-off-by: Tejun Heo <htejun@gmail.com>
Diffstat (limited to 'drivers/ata/sata_qstor.c')
-rw-r--r-- | drivers/ata/sata_qstor.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/drivers/ata/sata_qstor.c b/drivers/ata/sata_qstor.c index 91cc12c82040..3c8e97f251f9 100644 --- a/drivers/ata/sata_qstor.c +++ b/drivers/ata/sata_qstor.c | |||
@@ -121,7 +121,6 @@ static unsigned int qs_qc_issue(struct ata_queued_cmd *qc); | |||
121 | static int qs_check_atapi_dma(struct ata_queued_cmd *qc); | 121 | static int qs_check_atapi_dma(struct ata_queued_cmd *qc); |
122 | static void qs_bmdma_stop(struct ata_queued_cmd *qc); | 122 | static void qs_bmdma_stop(struct ata_queued_cmd *qc); |
123 | static u8 qs_bmdma_status(struct ata_port *ap); | 123 | static u8 qs_bmdma_status(struct ata_port *ap); |
124 | static void qs_irq_clear(struct ata_port *ap); | ||
125 | static void qs_freeze(struct ata_port *ap); | 124 | static void qs_freeze(struct ata_port *ap); |
126 | static void qs_thaw(struct ata_port *ap); | 125 | static void qs_thaw(struct ata_port *ap); |
127 | static void qs_error_handler(struct ata_port *ap); | 126 | static void qs_error_handler(struct ata_port *ap); |
@@ -157,7 +156,7 @@ static const struct ata_port_operations qs_ata_ops = { | |||
157 | .freeze = qs_freeze, | 156 | .freeze = qs_freeze, |
158 | .thaw = qs_thaw, | 157 | .thaw = qs_thaw, |
159 | .error_handler = qs_error_handler, | 158 | .error_handler = qs_error_handler, |
160 | .irq_clear = qs_irq_clear, | 159 | .irq_clear = ata_noop_irq_clear, |
161 | .irq_on = ata_irq_on, | 160 | .irq_on = ata_irq_on, |
162 | .scr_read = qs_scr_read, | 161 | .scr_read = qs_scr_read, |
163 | .scr_write = qs_scr_write, | 162 | .scr_write = qs_scr_write, |
@@ -211,11 +210,6 @@ static u8 qs_bmdma_status(struct ata_port *ap) | |||
211 | return 0; | 210 | return 0; |
212 | } | 211 | } |
213 | 212 | ||
214 | static void qs_irq_clear(struct ata_port *ap) | ||
215 | { | ||
216 | /* nothing */ | ||
217 | } | ||
218 | |||
219 | static inline void qs_enter_reg_mode(struct ata_port *ap) | 213 | static inline void qs_enter_reg_mode(struct ata_port *ap) |
220 | { | 214 | { |
221 | u8 __iomem *chan = qs_mmio_base(ap->host) + (ap->port_no * 0x4000); | 215 | u8 __iomem *chan = qs_mmio_base(ap->host) + (ap->port_no * 0x4000); |