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>
This commit is contained in:
@@ -121,7 +121,6 @@ static unsigned int qs_qc_issue(struct ata_queued_cmd *qc);
|
||||
static int qs_check_atapi_dma(struct ata_queued_cmd *qc);
|
||||
static void qs_bmdma_stop(struct ata_queued_cmd *qc);
|
||||
static u8 qs_bmdma_status(struct ata_port *ap);
|
||||
static void qs_irq_clear(struct ata_port *ap);
|
||||
static void qs_freeze(struct ata_port *ap);
|
||||
static void qs_thaw(struct ata_port *ap);
|
||||
static void qs_error_handler(struct ata_port *ap);
|
||||
@@ -157,7 +156,7 @@ static const struct ata_port_operations qs_ata_ops = {
|
||||
.freeze = qs_freeze,
|
||||
.thaw = qs_thaw,
|
||||
.error_handler = qs_error_handler,
|
||||
.irq_clear = qs_irq_clear,
|
||||
.irq_clear = ata_noop_irq_clear,
|
||||
.irq_on = ata_irq_on,
|
||||
.scr_read = qs_scr_read,
|
||||
.scr_write = qs_scr_write,
|
||||
@@ -211,11 +210,6 @@ static u8 qs_bmdma_status(struct ata_port *ap)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void qs_irq_clear(struct ata_port *ap)
|
||||
{
|
||||
/* nothing */
|
||||
}
|
||||
|
||||
static inline void qs_enter_reg_mode(struct ata_port *ap)
|
||||
{
|
||||
u8 __iomem *chan = qs_mmio_base(ap->host) + (ap->port_no * 0x4000);
|
||||
|
Reference in New Issue
Block a user