diff options
| author | Guenter Roeck <linux@roeck-us.net> | 2013-08-30 09:03:10 -0400 |
|---|---|---|
| committer | Guenter Roeck <linux@roeck-us.net> | 2013-09-16 21:19:04 -0400 |
| commit | 77da71b3a03ebb2bd06500ca1d85e1c5083bb005 (patch) | |
| tree | 7c5126a512e244133e78572dbea8d6544178995f /drivers/ide | |
| parent | 4b08478422040ae8cb11acc15d51f1cdb0ac39c8 (diff) | |
ide: Drop H8/300 driver
Architecture is gone, so there is no need to keep its ide driver around.
Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Acked-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Diffstat (limited to 'drivers/ide')
| -rw-r--r-- | drivers/ide/Kconfig | 7 | ||||
| -rw-r--r-- | drivers/ide/Makefile | 2 | ||||
| -rw-r--r-- | drivers/ide/ide-h8300.c | 109 |
3 files changed, 0 insertions, 118 deletions
diff --git a/drivers/ide/Kconfig b/drivers/ide/Kconfig index 02906ca99b41..5dba90a8a27c 100644 --- a/drivers/ide/Kconfig +++ b/drivers/ide/Kconfig | |||
| @@ -722,13 +722,6 @@ config BLK_DEV_IDE_RAPIDE | |||
| 722 | Say Y here if you want to support the Yellowstone RapIDE controller | 722 | Say Y here if you want to support the Yellowstone RapIDE controller |
| 723 | manufactured for use with Acorn computers. | 723 | manufactured for use with Acorn computers. |
| 724 | 724 | ||
| 725 | config IDE_H8300 | ||
| 726 | tristate "H8300 IDE support" | ||
| 727 | depends on H8300 | ||
| 728 | default y | ||
| 729 | help | ||
| 730 | Enables the H8300 IDE driver. | ||
| 731 | |||
| 732 | config BLK_DEV_GAYLE | 725 | config BLK_DEV_GAYLE |
| 733 | tristate "Amiga Gayle IDE interface support" | 726 | tristate "Amiga Gayle IDE interface support" |
| 734 | depends on AMIGA | 727 | depends on AMIGA |
diff --git a/drivers/ide/Makefile b/drivers/ide/Makefile index af8d016c37ea..a04ee82f1c8f 100644 --- a/drivers/ide/Makefile +++ b/drivers/ide/Makefile | |||
| @@ -78,8 +78,6 @@ obj-$(CONFIG_BLK_DEV_CMD640) += cmd640.o | |||
| 78 | 78 | ||
| 79 | obj-$(CONFIG_BLK_DEV_IDE_PMAC) += pmac.o | 79 | obj-$(CONFIG_BLK_DEV_IDE_PMAC) += pmac.o |
| 80 | 80 | ||
| 81 | obj-$(CONFIG_IDE_H8300) += ide-h8300.o | ||
| 82 | |||
| 83 | obj-$(CONFIG_IDE_GENERIC) += ide-generic.o | 81 | obj-$(CONFIG_IDE_GENERIC) += ide-generic.o |
| 84 | obj-$(CONFIG_BLK_DEV_IDEPNP) += ide-pnp.o | 82 | obj-$(CONFIG_BLK_DEV_IDEPNP) += ide-pnp.o |
| 85 | 83 | ||
diff --git a/drivers/ide/ide-h8300.c b/drivers/ide/ide-h8300.c deleted file mode 100644 index 520f42c5445a..000000000000 --- a/drivers/ide/ide-h8300.c +++ /dev/null | |||
| @@ -1,109 +0,0 @@ | |||
| 1 | /* | ||
| 2 | * H8/300 generic IDE interface | ||
| 3 | */ | ||
| 4 | |||
| 5 | #include <linux/init.h> | ||
| 6 | #include <linux/ide.h> | ||
| 7 | |||
| 8 | #include <asm/io.h> | ||
| 9 | #include <asm/irq.h> | ||
| 10 | |||
| 11 | #define DRV_NAME "ide-h8300" | ||
| 12 | |||
| 13 | #define bswap(d) \ | ||
| 14 | ({ \ | ||
| 15 | u16 r; \ | ||
| 16 | __asm__("mov.b %w1,r1h\n\t" \ | ||
| 17 | "mov.b %x1,r1l\n\t" \ | ||
| 18 | "mov.w r1,%0" \ | ||
| 19 | :"=r"(r) \ | ||
| 20 | :"r"(d) \ | ||
| 21 | :"er1"); \ | ||
| 22 | (r); \ | ||
| 23 | }) | ||
| 24 | |||
| 25 | static void mm_outsw(unsigned long addr, void *buf, u32 len) | ||
| 26 | { | ||
| 27 | unsigned short *bp = (unsigned short *)buf; | ||
| 28 | for (; len > 0; len--, bp++) | ||
| 29 | *(volatile u16 *)addr = bswap(*bp); | ||
| 30 | } | ||
| 31 | |||
| 32 | static void mm_insw(unsigned long addr, void *buf, u32 len) | ||
| 33 | { | ||
| 34 | unsigned short *bp = (unsigned short *)buf; | ||
| 35 | for (; len > 0; len--, bp++) | ||
| 36 | *bp = bswap(*(volatile u16 *)addr); | ||
| 37 | } | ||
| 38 | |||
| 39 | static void h8300_input_data(ide_drive_t *drive, struct ide_cmd *cmd, | ||
| 40 | void *buf, unsigned int len) | ||
| 41 | { | ||
| 42 | mm_insw(drive->hwif->io_ports.data_addr, buf, (len + 1) / 2); | ||
| 43 | } | ||
| 44 | |||
| 45 | static void h8300_output_data(ide_drive_t *drive, struct ide_cmd *cmd, | ||
| 46 | void *buf, unsigned int len) | ||
| 47 | { | ||
| 48 | mm_outsw(drive->hwif->io_ports.data_addr, buf, (len + 1) / 2); | ||
| 49 | } | ||
| 50 | |||
| 51 | static const struct ide_tp_ops h8300_tp_ops = { | ||
| 52 | .exec_command = ide_exec_command, | ||
| 53 | .read_status = ide_read_status, | ||
| 54 | .read_altstatus = ide_read_altstatus, | ||
| 55 | .write_devctl = ide_write_devctl, | ||
| 56 | |||
| 57 | .dev_select = ide_dev_select, | ||
| 58 | .tf_load = ide_tf_load, | ||
| 59 | .tf_read = ide_tf_read, | ||
| 60 | |||
| 61 | .input_data = h8300_input_data, | ||
| 62 | .output_data = h8300_output_data, | ||
| 63 | }; | ||
| 64 | |||
| 65 | #define H8300_IDE_GAP (2) | ||
| 66 | |||
| 67 | static inline void hw_setup(struct ide_hw *hw) | ||
| 68 | { | ||
| 69 | int i; | ||
| 70 | |||
| 71 | memset(hw, 0, sizeof(*hw)); | ||
| 72 | for (i = 0; i <= 7; i++) | ||
| 73 | hw->io_ports_array[i] = CONFIG_H8300_IDE_BASE + H8300_IDE_GAP*i; | ||
| 74 | hw->io_ports.ctl_addr = CONFIG_H8300_IDE_ALT; | ||
| 75 | hw->irq = EXT_IRQ0 + CONFIG_H8300_IDE_IRQ; | ||
| 76 | } | ||
| 77 | |||
| 78 | static const struct ide_port_info h8300_port_info = { | ||
| 79 | .tp_ops = &h8300_tp_ops, | ||
| 80 | .host_flags = IDE_HFLAG_NO_IO_32BIT | IDE_HFLAG_NO_DMA, | ||
| 81 | .chipset = ide_generic, | ||
| 82 | }; | ||
| 83 | |||
| 84 | static int __init h8300_ide_init(void) | ||
| 85 | { | ||
| 86 | struct ide_hw hw, *hws[] = { &hw }; | ||
| 87 | |||
| 88 | printk(KERN_INFO DRV_NAME ": H8/300 generic IDE interface\n"); | ||
| 89 | |||
| 90 | if (!request_region(CONFIG_H8300_IDE_BASE, H8300_IDE_GAP*8, "ide-h8300")) | ||
| 91 | goto out_busy; | ||
| 92 | if (!request_region(CONFIG_H8300_IDE_ALT, H8300_IDE_GAP, "ide-h8300")) { | ||
| 93 | release_region(CONFIG_H8300_IDE_BASE, H8300_IDE_GAP*8); | ||
| 94 | goto out_busy; | ||
| 95 | } | ||
| 96 | |||
| 97 | hw_setup(&hw); | ||
| 98 | |||
| 99 | return ide_host_add(&h8300_port_info, hws, 1, NULL); | ||
| 100 | |||
| 101 | out_busy: | ||
| 102 | printk(KERN_ERR "ide-h8300: IDE I/F resource already used.\n"); | ||
| 103 | |||
| 104 | return -EBUSY; | ||
| 105 | } | ||
| 106 | |||
| 107 | module_init(h8300_ide_init); | ||
| 108 | |||
| 109 | MODULE_LICENSE("GPL"); | ||
