aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@woody.linux-foundation.org>2008-02-05 22:06:25 -0500
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2008-02-05 22:06:25 -0500
commit551e4fb2465b87de9d4aa1669b27d624435443bb (patch)
tree316a5816b833a7536071a4ee0913a9b51b4faff8 /include
parentb297d520b9af536d5580ac505dd316be4cf5560c (diff)
parentdfe799364e7a500389559e1dcd331d995cdc18ea (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: (29 commits) ide-tape: bump minor driver version ide-tape: cleanup the remaining codestyle issues ide-tape: fix syntax error in idetape_identify_device() ide-tape: remove leftover OnStream support warning ide-tape: collect module-related macro calls at the end ide-tape: include proper headers ide-tape: remove unused "length" arg from idetape_create_read_buffer_cmd() ide-tape: remove struct idetape_id_gcw ide-tape: cleanup and fix comments ide-tape: shorten some function names ide-tape: remove idetape_increase_max_pipeline_stages() ide-tape: struct idetape_tape_t: shorten member names v2 ide-tape: struct idetape_tape_t: remove unused members ide-tape: remove typedef idetape_chrdev_direction_t ide-tape: simplify code branching in the interrupt handler ide-tape: remove unreachable code chunk ide-tape: remove struct idetape_read_position_result_t ide-tape: refactor the debug logging facility ide: add ide_read_error() inline helper ide: add ide_read_[alt]status() inline helpers ...
Diffstat (limited to 'include')
-rw-r--r--include/asm-powerpc/mediabay.h8
-rw-r--r--include/linux/ide.h42
2 files changed, 28 insertions, 22 deletions
diff --git a/include/asm-powerpc/mediabay.h b/include/asm-powerpc/mediabay.h
index 9daa3252d7b6..de83fe196309 100644
--- a/include/asm-powerpc/mediabay.h
+++ b/include/asm-powerpc/mediabay.h
@@ -18,14 +18,14 @@
18#define MB_NO 7 /* media bay contains nothing */ 18#define MB_NO 7 /* media bay contains nothing */
19 19
20int check_media_bay(struct device_node *which_bay, int what); 20int check_media_bay(struct device_node *which_bay, int what);
21int check_media_bay_by_base(unsigned long base, int what);
22 21
23/* Number of bays in the machine or 0 */ 22/* Number of bays in the machine or 0 */
24extern int media_bay_count; 23extern int media_bay_count;
25 24
26/* called by pmac-ide.c to register IDE controller for media bay */ 25int check_media_bay_by_base(unsigned long base, int what);
27extern int media_bay_set_ide_infos(struct device_node* which_bay, 26/* called by IDE PMAC host driver to register IDE controller for media bay */
28 unsigned long base, int irq, int index); 27int media_bay_set_ide_infos(struct device_node *which_bay, unsigned long base,
28 int irq, int index);
29 29
30#endif /* __KERNEL__ */ 30#endif /* __KERNEL__ */
31#endif /* _PPC_MEDIABAY_H */ 31#endif /* _PPC_MEDIABAY_H */
diff --git a/include/linux/ide.h b/include/linux/ide.h
index 367c17084a28..acec99da832d 100644
--- a/include/linux/ide.h
+++ b/include/linux/ide.h
@@ -115,10 +115,6 @@ typedef unsigned char byte; /* used everywhere */
115#define SATA_ERROR_OFFSET (1) 115#define SATA_ERROR_OFFSET (1)
116#define SATA_CONTROL_OFFSET (2) 116#define SATA_CONTROL_OFFSET (2)
117 117
118#define SATA_MISC_OFFSET (0)
119#define SATA_PHY_OFFSET (1)
120#define SATA_IEN_OFFSET (2)
121
122/* 118/*
123 * Our Physical Region Descriptor (PRD) table should be large enough 119 * Our Physical Region Descriptor (PRD) table should be large enough
124 * to handle the biggest I/O request we are likely to see. Since requests 120 * to handle the biggest I/O request we are likely to see. Since requests
@@ -173,7 +169,7 @@ enum { ide_unknown, ide_generic, ide_pci,
173 ide_rz1000, ide_trm290, 169 ide_rz1000, ide_trm290,
174 ide_cmd646, ide_cy82c693, ide_4drives, 170 ide_cmd646, ide_cy82c693, ide_4drives,
175 ide_pmac, ide_etrax100, ide_acorn, 171 ide_pmac, ide_etrax100, ide_acorn,
176 ide_au1xxx, ide_forced 172 ide_au1xxx, ide_palm3710, ide_forced
177}; 173};
178 174
179typedef u8 hwif_chipset_t; 175typedef u8 hwif_chipset_t;
@@ -198,17 +194,6 @@ struct ide_drive_s;
198int ide_register_hw(hw_regs_t *, void (*)(struct ide_drive_s *), 194int ide_register_hw(hw_regs_t *, void (*)(struct ide_drive_s *),
199 struct hwif_s **); 195 struct hwif_s **);
200 196
201void ide_setup_ports( hw_regs_t *hw,
202 unsigned long base,
203 int *offsets,
204 unsigned long ctrl,
205 unsigned long intr,
206 ide_ack_intr_t *ack_intr,
207#if 0
208 ide_io_ops_t *iops,
209#endif
210 int irq);
211
212static inline void ide_std_init_ports(hw_regs_t *hw, 197static inline void ide_std_init_ports(hw_regs_t *hw,
213 unsigned long io_addr, 198 unsigned long io_addr,
214 unsigned long ctl_addr) 199 unsigned long ctl_addr)
@@ -473,7 +458,6 @@ typedef struct hwif_s {
473 /* task file registers for pata and sata */ 458 /* task file registers for pata and sata */
474 unsigned long io_ports[IDE_NR_PORTS]; 459 unsigned long io_ports[IDE_NR_PORTS];
475 unsigned long sata_scr[SATA_NR_PORTS]; 460 unsigned long sata_scr[SATA_NR_PORTS];
476 unsigned long sata_misc[SATA_NR_PORTS];
477 461
478 ide_drive_t drives[MAX_DRIVES]; /* drive info */ 462 ide_drive_t drives[MAX_DRIVES]; /* drive info */
479 463
@@ -1014,7 +998,8 @@ extern int __ide_pci_register_driver(struct pci_driver *driver, struct module *o
1014void ide_pci_setup_ports(struct pci_dev *, const struct ide_port_info *, int, u8 *); 998void ide_pci_setup_ports(struct pci_dev *, const struct ide_port_info *, int, u8 *);
1015void ide_setup_pci_noise(struct pci_dev *, const struct ide_port_info *); 999void ide_setup_pci_noise(struct pci_dev *, const struct ide_port_info *);
1016 1000
1017#ifdef CONFIG_BLK_DEV_IDEDMA_PCI 1001/* FIXME: palm_bk3710 uses BLK_DEV_IDEDMA_PCI without BLK_DEV_IDEPCI! */
1002#if defined(CONFIG_BLK_DEV_IDEPCI) && defined(CONFIG_BLK_DEV_IDEDMA_PCI)
1018void ide_hwif_setup_dma(ide_hwif_t *, const struct ide_port_info *); 1003void ide_hwif_setup_dma(ide_hwif_t *, const struct ide_port_info *);
1019#else 1004#else
1020static inline void ide_hwif_setup_dma(ide_hwif_t *hwif, 1005static inline void ide_hwif_setup_dma(ide_hwif_t *hwif,
@@ -1324,4 +1309,25 @@ static inline void ide_set_irq(ide_drive_t *drive, int on)
1324 drive->hwif->OUTB(drive->ctl | (on ? 0 : 2), IDE_CONTROL_REG); 1309 drive->hwif->OUTB(drive->ctl | (on ? 0 : 2), IDE_CONTROL_REG);
1325} 1310}
1326 1311
1312static inline u8 ide_read_status(ide_drive_t *drive)
1313{
1314 ide_hwif_t *hwif = drive->hwif;
1315
1316 return hwif->INB(hwif->io_ports[IDE_STATUS_OFFSET]);
1317}
1318
1319static inline u8 ide_read_altstatus(ide_drive_t *drive)
1320{
1321 ide_hwif_t *hwif = drive->hwif;
1322
1323 return hwif->INB(hwif->io_ports[IDE_CONTROL_OFFSET]);
1324}
1325
1326static inline u8 ide_read_error(ide_drive_t *drive)
1327{
1328 ide_hwif_t *hwif = drive->hwif;
1329
1330 return hwif->INB(hwif->io_ports[IDE_ERROR_OFFSET]);
1331}
1332
1327#endif /* _IDE_H */ 1333#endif /* _IDE_H */