Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 123572
b: refs/heads/master
c: 6de2c31
h: refs/heads/master
v: v3
  • Loading branch information
Russell King authored and Russell King committed Nov 28, 2008
1 parent dbb63fc commit accb2cb
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 47 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: ccaec3ec78d0f1840a67acce6aaeeab99f2d88bf
refs/heads/master: 6de2c31d3dad7384b3efa03674bd6ed479d58cb2
47 changes: 1 addition & 46 deletions trunk/arch/arm/mach-rpc/include/mach/io.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,49 +17,6 @@

#define IO_SPACE_LIMIT 0xffffffff

/*
* GCC is totally crap at loading/storing data. We try to persuade it
* to do the right thing by using these whereever possible instead of
* the above.
*/
#define __arch_base_getb(b,o) \
({ \
unsigned int __v, __r = (b); \
__asm__ __volatile__( \
"ldrb %0, [%1, %2]" \
: "=r" (__v) \
: "r" (__r), "Ir" (o)); \
__v; \
})

#define __arch_base_getl(b,o) \
({ \
unsigned int __v, __r = (b); \
__asm__ __volatile__( \
"ldr %0, [%1, %2]" \
: "=r" (__v) \
: "r" (__r), "Ir" (o)); \
__v; \
})

#define __arch_base_putb(v,b,o) \
({ \
unsigned int __r = (b); \
__asm__ __volatile__( \
"strb %0, [%1, %2]" \
: \
: "r" (v), "r" (__r), "Ir" (o));\
})

#define __arch_base_putl(v,b,o) \
({ \
unsigned int __r = (b); \
__asm__ __volatile__( \
"str %0, [%1, %2]" \
: \
: "r" (v), "r" (__r), "Ir" (o));\
})

/*
* We use two different types of addressing - PC style addresses, and ARM
* addresses. PC style accesses the PC hardware with the normal PC IO
Expand Down Expand Up @@ -232,15 +189,13 @@ DECLARE_IO(int,l,"")
result; \
})

#define __ioaddrc(port) __ioaddr(port)

#define inb(p) (__builtin_constant_p((p)) ? __inbc(p) : __inb(p))
#define inw(p) (__builtin_constant_p((p)) ? __inwc(p) : __inw(p))
#define inl(p) (__builtin_constant_p((p)) ? __inlc(p) : __inl(p))
#define outb(v,p) (__builtin_constant_p((p)) ? __outbc(v,p) : __outb(v,p))
#define outw(v,p) (__builtin_constant_p((p)) ? __outwc(v,p) : __outw(v,p))
#define outl(v,p) (__builtin_constant_p((p)) ? __outlc(v,p) : __outl(v,p))
#define __ioaddr(p) (__builtin_constant_p((p)) ? __ioaddr(p) : __ioaddrc(p))

/* the following macro is deprecated */
#define ioaddr(port) ((unsigned long)__ioaddr((port)))

Expand Down

0 comments on commit accb2cb

Please sign in to comment.