diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2008-04-18 11:39:24 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-04-18 11:39:24 -0400 |
commit | 188da98800893691e47eea9335a234378e32aceb (patch) | |
tree | 57dbf491d23676e011b4946ec1867a6d55a02eef /drivers/ide/ide-taskfile.c | |
parent | 07fe944e87d79f8d7e1b090913fe9f2ace78f41d (diff) | |
parent | 273b8385e5817a4765f82257004c5ec661a6a5b2 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/bart/ide-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/bart/ide-2.6: (58 commits)
ide: remove ide_init_default_irq() macro
ide: move default IDE ports setup to ide_generic host driver
ide: remove obsoleted "idex=noprobe" kernel parameter (take 2)
ide: remove needless hwif->irq check from ide_hwif_configure()
ide: init hwif->{io_ports,irq} explicitly in legacy VLB host drivers
ide: limit legacy VLB host drivers to alpha, x86 and mips
cmd640: init hwif->{io_ports,irq} explicitly
cmd640: cleanup setup_device_ptrs()
ide: add ide-4drives host driver (take 3)
ide: remove ppc ifdef from init_ide_data()
ide: remove ide_default_io_ctl() macro
ide: remove CONFIG_IDE_ARCH_OBSOLETE_INIT
ide: add CONFIG_IDE_ARCH_OBSOLETE_DEFAULTS (take 2)
ppc/pmac: remove no longer needed IDE quirk
ppc: don't include <linux/ide.h>
ppc: remove ppc_ide_md
ppc/pplus: remove ppc_ide_md.ide_init_hwif hook
ppc/sandpoint: remove ppc_ide_md hooks
ppc/lopec: remove ppc_ide_md hooks
ppc/mpc8xx: remove ppc_ide_md hooks
...
Diffstat (limited to 'drivers/ide/ide-taskfile.c')
-rw-r--r-- | drivers/ide/ide-taskfile.c | 29 |
1 files changed, 16 insertions, 13 deletions
diff --git a/drivers/ide/ide-taskfile.c b/drivers/ide/ide-taskfile.c index 4c86a8d84b4c..155cc904f4eb 100644 --- a/drivers/ide/ide-taskfile.c +++ b/drivers/ide/ide-taskfile.c | |||
@@ -59,32 +59,34 @@ void ide_tf_load(ide_drive_t *drive, ide_task_t *task) | |||
59 | SELECT_MASK(drive, 0); | 59 | SELECT_MASK(drive, 0); |
60 | 60 | ||
61 | if (task->tf_flags & IDE_TFLAG_OUT_DATA) | 61 | if (task->tf_flags & IDE_TFLAG_OUT_DATA) |
62 | hwif->OUTW((tf->hob_data << 8) | tf->data, IDE_DATA_REG); | 62 | hwif->OUTW((tf->hob_data << 8) | tf->data, |
63 | hwif->io_ports[IDE_DATA_OFFSET]); | ||
63 | 64 | ||
64 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_FEATURE) | 65 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_FEATURE) |
65 | hwif->OUTB(tf->hob_feature, IDE_FEATURE_REG); | 66 | hwif->OUTB(tf->hob_feature, hwif->io_ports[IDE_FEATURE_OFFSET]); |
66 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_NSECT) | 67 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_NSECT) |
67 | hwif->OUTB(tf->hob_nsect, IDE_NSECTOR_REG); | 68 | hwif->OUTB(tf->hob_nsect, hwif->io_ports[IDE_NSECTOR_OFFSET]); |
68 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_LBAL) | 69 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_LBAL) |
69 | hwif->OUTB(tf->hob_lbal, IDE_SECTOR_REG); | 70 | hwif->OUTB(tf->hob_lbal, hwif->io_ports[IDE_SECTOR_OFFSET]); |
70 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_LBAM) | 71 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_LBAM) |
71 | hwif->OUTB(tf->hob_lbam, IDE_LCYL_REG); | 72 | hwif->OUTB(tf->hob_lbam, hwif->io_ports[IDE_LCYL_OFFSET]); |
72 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_LBAH) | 73 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_LBAH) |
73 | hwif->OUTB(tf->hob_lbah, IDE_HCYL_REG); | 74 | hwif->OUTB(tf->hob_lbah, hwif->io_ports[IDE_HCYL_OFFSET]); |
74 | 75 | ||
75 | if (task->tf_flags & IDE_TFLAG_OUT_FEATURE) | 76 | if (task->tf_flags & IDE_TFLAG_OUT_FEATURE) |
76 | hwif->OUTB(tf->feature, IDE_FEATURE_REG); | 77 | hwif->OUTB(tf->feature, hwif->io_ports[IDE_FEATURE_OFFSET]); |
77 | if (task->tf_flags & IDE_TFLAG_OUT_NSECT) | 78 | if (task->tf_flags & IDE_TFLAG_OUT_NSECT) |
78 | hwif->OUTB(tf->nsect, IDE_NSECTOR_REG); | 79 | hwif->OUTB(tf->nsect, hwif->io_ports[IDE_NSECTOR_OFFSET]); |
79 | if (task->tf_flags & IDE_TFLAG_OUT_LBAL) | 80 | if (task->tf_flags & IDE_TFLAG_OUT_LBAL) |
80 | hwif->OUTB(tf->lbal, IDE_SECTOR_REG); | 81 | hwif->OUTB(tf->lbal, hwif->io_ports[IDE_SECTOR_OFFSET]); |
81 | if (task->tf_flags & IDE_TFLAG_OUT_LBAM) | 82 | if (task->tf_flags & IDE_TFLAG_OUT_LBAM) |
82 | hwif->OUTB(tf->lbam, IDE_LCYL_REG); | 83 | hwif->OUTB(tf->lbam, hwif->io_ports[IDE_LCYL_OFFSET]); |
83 | if (task->tf_flags & IDE_TFLAG_OUT_LBAH) | 84 | if (task->tf_flags & IDE_TFLAG_OUT_LBAH) |
84 | hwif->OUTB(tf->lbah, IDE_HCYL_REG); | 85 | hwif->OUTB(tf->lbah, hwif->io_ports[IDE_HCYL_OFFSET]); |
85 | 86 | ||
86 | if (task->tf_flags & IDE_TFLAG_OUT_DEVICE) | 87 | if (task->tf_flags & IDE_TFLAG_OUT_DEVICE) |
87 | hwif->OUTB((tf->device & HIHI) | drive->select.all, IDE_SELECT_REG); | 88 | hwif->OUTB((tf->device & HIHI) | drive->select.all, |
89 | hwif->io_ports[IDE_SELECT_OFFSET]); | ||
88 | } | 90 | } |
89 | 91 | ||
90 | int taskfile_lib_get_identify (ide_drive_t *drive, u8 *buf) | 92 | int taskfile_lib_get_identify (ide_drive_t *drive, u8 *buf) |
@@ -152,7 +154,8 @@ ide_startstop_t do_rw_taskfile (ide_drive_t *drive, ide_task_t *task) | |||
152 | switch (task->data_phase) { | 154 | switch (task->data_phase) { |
153 | case TASKFILE_MULTI_OUT: | 155 | case TASKFILE_MULTI_OUT: |
154 | case TASKFILE_OUT: | 156 | case TASKFILE_OUT: |
155 | hwif->OUTBSYNC(drive, tf->command, IDE_COMMAND_REG); | 157 | hwif->OUTBSYNC(drive, tf->command, |
158 | hwif->io_ports[IDE_COMMAND_OFFSET]); | ||
156 | ndelay(400); /* FIXME */ | 159 | ndelay(400); /* FIXME */ |
157 | return pre_task_out_intr(drive, task->rq); | 160 | return pre_task_out_intr(drive, task->rq); |
158 | case TASKFILE_MULTI_IN: | 161 | case TASKFILE_MULTI_IN: |