Skip to content

Commit

Permalink
[ARM] rpc: remove obsolete IO accessors
Browse files Browse the repository at this point in the history
Remove __arch_base_xxx() and __ioaddrc() macros; they're obsolete and
unused.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
  • Loading branch information
Russell King authored and Russell King committed Nov 28, 2008
1 parent ccaec3e commit 6de2c31
Showing 1 changed file with 1 addition and 46 deletions.
47 changes: 1 addition & 46 deletions 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 6de2c31

Please sign in to comment.