Home Home > GIT Browse
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBartlomiej Zolnierkiewicz <b.zolnierkiewicz@elka.pw.edu.pl>2004-02-15 21:47:02 -0800
committerLinus Torvalds <torvalds@evo.osdl.org>2004-02-15 21:47:02 -0800
commit22e84a6bf688e7078f28df5261e31894256abbbe (patch)
tree0f4dce38e5e5c416f6bd0c1d7f46e34f6d9d73a1
parent6e14119e8beff9bf947c003cee0d9b8b0429a9d9 (diff)
[PATCH] remove __ide_dma_count() and ide_hwif_t->ide_dma_count
->ide_dma_count() was introduced in kernel 2.5.35 and was meant to add support for host FIFO counters (for VDMA), but is only a wrapper for ->ide_dma_begin() (even for siimage.c b/c SIIMAGE_VIRTUAL_DMAPIO is undefined). Moreover it should be possible to add VDMA code directly to ->ide_dma_begin().
-rw-r--r--drivers/ide/arm/icside.c6
-rw-r--r--drivers/ide/ide-dma.c17
-rw-r--r--drivers/ide/ide.c1
-rw-r--r--drivers/ide/pci/sgiioc4.c1
-rw-r--r--drivers/ide/pci/siimage.c3
-rw-r--r--drivers/ide/pci/trm290.c4
-rw-r--r--drivers/ide/ppc/pmac.c7
-rw-r--r--include/linux/ide.h3
8 files changed, 6 insertions, 36 deletions
diff --git a/drivers/ide/arm/icside.c b/drivers/ide/arm/icside.c
index 09d3f9414e8f..3d8cdcaa3a36 100644
--- a/drivers/ide/arm/icside.c
+++ b/drivers/ide/arm/icside.c
@@ -428,11 +428,6 @@ static int icside_dma_begin(ide_drive_t *drive)
return 0;
}
-static int icside_dma_count(ide_drive_t *drive)
-{
- return icside_dma_begin(drive);
-}
-
/*
* dma_intr() is the handler for disk read/write DMA interrupts
*/
@@ -653,7 +648,6 @@ static int icside_dma_init(ide_hwif_t *hwif)
hwif->ide_dma_on = icside_dma_on;
hwif->ide_dma_read = icside_dma_read;
hwif->ide_dma_write = icside_dma_write;
- hwif->ide_dma_count = icside_dma_count;
hwif->ide_dma_begin = icside_dma_begin;
hwif->ide_dma_end = icside_dma_end;
hwif->ide_dma_test_irq = icside_dma_test_irq;
diff --git a/drivers/ide/ide-dma.c b/drivers/ide/ide-dma.c
index b934574f2f8e..2048af2952cf 100644
--- a/drivers/ide/ide-dma.c
+++ b/drivers/ide/ide-dma.c
@@ -662,7 +662,7 @@ int __ide_dma_read (ide_drive_t *drive /*, struct request *rq */)
/* issue cmd to drive */
ide_execute_command(drive, command, &ide_dma_intr, 2*WAIT_CMD, dma_timer_expiry);
- return HWIF(drive)->ide_dma_count(drive);
+ return hwif->ide_dma_begin(drive);
}
EXPORT_SYMBOL(__ide_dma_read);
@@ -694,7 +694,7 @@ int __ide_dma_write (ide_drive_t *drive /*, struct request *rq */)
/* issue cmd to drive */
ide_execute_command(drive, command, &ide_dma_intr, 2*WAIT_CMD, dma_timer_expiry);
- return HWIF(drive)->ide_dma_count(drive);
+ return hwif->ide_dma_begin(drive);
}
EXPORT_SYMBOL(__ide_dma_write);
@@ -791,17 +791,6 @@ int __ide_dma_good_drive (ide_drive_t *drive)
EXPORT_SYMBOL(__ide_dma_good_drive);
#ifdef CONFIG_BLK_DEV_IDEDMA_PCI
-/*
- * Used for HOST FIFO counters for VDMA
- * PIO over DMA, effective ATA-Bridge operator.
- */
-int __ide_dma_count (ide_drive_t *drive)
-{
- return HWIF(drive)->ide_dma_begin(drive);
-}
-
-EXPORT_SYMBOL(__ide_dma_count);
-
int __ide_dma_verbose (ide_drive_t *drive)
{
struct hd_driveid *id = drive->id;
@@ -1076,8 +1065,6 @@ void ide_setup_dma (ide_hwif_t *hwif, unsigned long dma_base, unsigned int num_p
hwif->ide_dma_read = &__ide_dma_read;
if (!hwif->ide_dma_write)
hwif->ide_dma_write = &__ide_dma_write;
- if (!hwif->ide_dma_count)
- hwif->ide_dma_count = &__ide_dma_count;
if (!hwif->ide_dma_begin)
hwif->ide_dma_begin = &__ide_dma_begin;
if (!hwif->ide_dma_end)
diff --git a/drivers/ide/ide.c b/drivers/ide/ide.c
index 7dee5ae9d2ac..8054a12c17ec 100644
--- a/drivers/ide/ide.c
+++ b/drivers/ide/ide.c
@@ -844,7 +844,6 @@ void ide_unregister (unsigned int index)
hwif->ide_dma_test_irq = old_hwif.ide_dma_test_irq;
hwif->ide_dma_host_on = old_hwif.ide_dma_host_on;
hwif->ide_dma_host_off = old_hwif.ide_dma_host_off;
- hwif->ide_dma_count = old_hwif.ide_dma_count;
hwif->ide_dma_verbose = old_hwif.ide_dma_verbose;
hwif->ide_dma_lostirq = old_hwif.ide_dma_lostirq;
hwif->ide_dma_timeout = old_hwif.ide_dma_timeout;
diff --git a/drivers/ide/pci/sgiioc4.c b/drivers/ide/pci/sgiioc4.c
index 9579b225a3b3..1466a3de8ec7 100644
--- a/drivers/ide/pci/sgiioc4.c
+++ b/drivers/ide/pci/sgiioc4.c
@@ -649,7 +649,6 @@ ide_init_sgiioc4(ide_hwif_t * hwif)
hwif->ide_dma_test_irq = &sgiioc4_ide_dma_test_irq;
hwif->ide_dma_host_on = &sgiioc4_ide_dma_host_on;
hwif->ide_dma_host_off = &sgiioc4_ide_dma_host_off;
- hwif->ide_dma_count = &__ide_dma_count;
hwif->ide_dma_verbose = &sgiioc4_ide_dma_verbose;
hwif->ide_dma_lostirq = &sgiioc4_ide_dma_lostirq;
hwif->ide_dma_timeout = &__ide_dma_timeout;
diff --git a/drivers/ide/pci/siimage.c b/drivers/ide/pci/siimage.c
index 74521e43d6a0..04b0de07ec39 100644
--- a/drivers/ide/pci/siimage.c
+++ b/drivers/ide/pci/siimage.c
@@ -545,6 +545,7 @@ static int siimage_io_ide_dma_test_irq (ide_drive_t *drive)
return 0;
}
+#if 0
/**
* siimage_mmio_ide_dma_count - DMA bytes done
* @drive
@@ -572,6 +573,7 @@ static int siimage_mmio_ide_dma_count (ide_drive_t *drive)
#endif /* SIIMAGE_VIRTUAL_DMAPIO */
return __ide_dma_count(drive);
}
+#endif
/**
* siimage_mmio_ide_dma_test_irq - check we caused an IRQ
@@ -1133,7 +1135,6 @@ static void __init init_hwif_siimage (ide_hwif_t *hwif)
hwif->udma_four = ata66_siimage(hwif);
if (hwif->mmio) {
- hwif->ide_dma_count = &siimage_mmio_ide_dma_count;
hwif->ide_dma_test_irq = &siimage_mmio_ide_dma_test_irq;
hwif->ide_dma_verbose = &siimage_mmio_ide_dma_verbose;
} else {
diff --git a/drivers/ide/pci/trm290.c b/drivers/ide/pci/trm290.c
index b1ed3605928d..fa94f9b85c88 100644
--- a/drivers/ide/pci/trm290.c
+++ b/drivers/ide/pci/trm290.c
@@ -225,7 +225,7 @@ static int trm290_ide_dma_write (ide_drive_t *drive /*, struct request *rq */)
#endif
/* issue cmd to drive */
hwif->OUTB(command, IDE_COMMAND_REG);
- return HWIF(drive)->ide_dma_count(drive);
+ return hwif->ide_dma_begin(drive);
}
static int trm290_ide_dma_read (ide_drive_t *drive /*, struct request *rq */)
@@ -269,7 +269,7 @@ static int trm290_ide_dma_read (ide_drive_t *drive /*, struct request *rq */)
#endif
/* issue cmd to drive */
hwif->OUTB(command, IDE_COMMAND_REG);
- return HWIF(drive)->ide_dma_count(drive);
+ return hwif->ide_dma_begin(drive);
}
static int trm290_ide_dma_begin (ide_drive_t *drive)
diff --git a/drivers/ide/ppc/pmac.c b/drivers/ide/ppc/pmac.c
index 43d93b527a6d..bf4f9bcd66ba 100644
--- a/drivers/ide/ppc/pmac.c
+++ b/drivers/ide/ppc/pmac.c
@@ -1988,12 +1988,6 @@ pmac_ide_dma_write (ide_drive_t *drive)
return pmac_ide_dma_begin(drive);
}
-static int __pmac
-pmac_ide_dma_count (ide_drive_t *drive)
-{
- return HWIF(drive)->ide_dma_begin(drive);
-}
-
/*
* Kick the DMA controller into life after the DMA command has been issued
* to the drive.
@@ -2165,7 +2159,6 @@ pmac_ide_setup_dma(pmac_ide_hwif_t *pmif, ide_hwif_t *hwif)
hwif->ide_dma_check = &pmac_ide_dma_check;
hwif->ide_dma_read = &pmac_ide_dma_read;
hwif->ide_dma_write = &pmac_ide_dma_write;
- hwif->ide_dma_count = &pmac_ide_dma_count;
hwif->ide_dma_begin = &pmac_ide_dma_begin;
hwif->ide_dma_end = &pmac_ide_dma_end;
hwif->ide_dma_test_irq = &pmac_ide_dma_test_irq;
diff --git a/include/linux/ide.h b/include/linux/ide.h
index 1c75a4f3c8b6..69db00c97a66 100644
--- a/include/linux/ide.h
+++ b/include/linux/ide.h
@@ -795,7 +795,6 @@ typedef struct ide_dma_ops_s {
int (*ide_dma_test_irq)(ide_drive_t *drive);
int (*ide_dma_host_on)(ide_drive_t *drive);
int (*ide_dma_host_off)(ide_drive_t *drive);
- int (*ide_dma_count)(ide_drive_t *drive);
int (*ide_dma_verbose)(ide_drive_t *drive);
int (*ide_dma_lostirq)(ide_drive_t *drive);
int (*ide_dma_timeout)(ide_drive_t *drive);
@@ -932,7 +931,6 @@ typedef struct hwif_s {
int (*ide_dma_test_irq)(ide_drive_t *drive);
int (*ide_dma_host_on)(ide_drive_t *drive);
int (*ide_dma_host_off)(ide_drive_t *drive);
- int (*ide_dma_count)(ide_drive_t *drive);
int (*ide_dma_verbose)(ide_drive_t *drive);
int (*ide_dma_lostirq)(ide_drive_t *drive);
int (*ide_dma_timeout)(ide_drive_t *drive);
@@ -1618,7 +1616,6 @@ extern int __ide_dma_write(ide_drive_t *);
extern int __ide_dma_begin(ide_drive_t *);
extern int __ide_dma_end(ide_drive_t *);
extern int __ide_dma_test_irq(ide_drive_t *);
-extern int __ide_dma_count(ide_drive_t *);
extern int __ide_dma_verbose(ide_drive_t *);
extern int __ide_dma_lostirq(ide_drive_t *);
extern int __ide_dma_timeout(ide_drive_t *);