[SCSI] st: Move buffer pointer back when data could not be written.
[linux-2.6/x86.git] / include / asm-powerpc / ide.h
blob1aaf27be8741a3ab9f52a3e538376a38978be779
1 /*
2 * Copyright (C) 1994-1996 Linus Torvalds & authors
4 * This file contains the powerpc architecture specific IDE code.
5 */
6 #ifndef _ASM_POWERPC_IDE_H
7 #define _ASM_POWERPC_IDE_H
9 #ifdef __KERNEL__
11 #ifndef __powerpc64__
12 #include <linux/sched.h>
13 #include <asm/mpc8xx.h>
14 #endif
15 #include <asm/io.h>
17 #define __ide_mm_insw(p, a, c) readsw((void __iomem *)(p), (a), (c))
18 #define __ide_mm_insl(p, a, c) readsl((void __iomem *)(p), (a), (c))
19 #define __ide_mm_outsw(p, a, c) writesw((void __iomem *)(p), (a), (c))
20 #define __ide_mm_outsl(p, a, c) writesl((void __iomem *)(p), (a), (c))
22 #ifndef __powerpc64__
23 #include <linux/hdreg.h>
24 #include <linux/ioport.h>
26 /* FIXME: use ide_platform host driver */
27 static __inline__ int ide_default_irq(unsigned long base)
29 #ifdef CONFIG_PPLUS
30 switch (base) {
31 case 0x1f0: return 14;
32 case 0x170: return 15;
34 #endif
35 return 0;
38 /* FIXME: use ide_platform host driver */
39 static __inline__ unsigned long ide_default_io_base(int index)
41 #ifdef CONFIG_PPLUS
42 switch (index) {
43 case 0: return 0x1f0;
44 case 1: return 0x170;
46 #endif
47 return 0;
50 #ifdef CONFIG_BLK_DEV_MPC8xx_IDE
51 #define IDE_ARCH_ACK_INTR 1
52 #define ide_ack_intr(hwif) ((hwif)->ack_intr ? (hwif)->ack_intr(hwif) : 1)
53 #endif
55 #endif /* __powerpc64__ */
57 #endif /* __KERNEL__ */
59 #endif /* _ASM_POWERPC_IDE_H */