Rev 2515 | Rev 3490 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
| Rev 2515 | Rev 2726 | ||
|---|---|---|---|
| Line 38... | Line 38... | ||
| 38 | #include <config.h> |
38 | #include <config.h> |
| 39 | #include <arch/types.h> |
39 | #include <arch/types.h> |
| 40 | #include <arch/register.h> |
40 | #include <arch/register.h> |
| 41 | 41 | ||
| 42 | 42 | ||
| 43 | #define IA64_IOSPACE_ADDRESS 0xE0000FFFFC000000ULL |
43 | #define IA64_IOSPACE_ADDRESS 0xE001000000000000ULL |
| 44 | 44 | ||
| 45 | static inline void outb(uint64_t port,uint8_t v) |
45 | static inline void outb(uint64_t port,uint8_t v) |
| 46 | { |
46 | { |
| 47 | *((char *)(IA64_IOSPACE_ADDRESS + ( (port & 0xfff) | ( (port >> 2) << 12 )))) = v; |
47 | *((char *)(IA64_IOSPACE_ADDRESS + ( (port & 0xfff) | ( (port >> 2) << 12 )))) = v; |
| - | 48 | ||
| 48 | asm volatile ("mf\n" ::: "memory"); |
49 | asm volatile ("mf\n" ::: "memory"); |
| 49 | } |
50 | } |
| 50 | 51 | ||
| 51 | 52 | ||
| 52 | static inline uint8_t inb(uint64_t port) |
53 | static inline uint8_t inb(uint64_t port) |
| 53 | { |
54 | { |
| 54 | asm volatile ("mf\n" ::: "memory"); |
55 | asm volatile ("mf\n" ::: "memory"); |
| - | 56 | ||
| 55 | return *((char *)(IA64_IOSPACE_ADDRESS + ( (port & 0xfff) | ( (port >> 2) << 12 )))); |
57 | return *((char *)(IA64_IOSPACE_ADDRESS + ( (port & 0xfff) | ( (port >> 2) << 12 )))); |
| 56 | } |
58 | } |
| 57 | 59 | ||
| 58 | 60 | ||
| 59 | 61 | ||