return error;
 }
 
-#ifdef CONFIG_DEBUG_IOREMAP
-static unsigned long last = 0;
-
-void gsc_bad_addr(unsigned long addr)
-{
-       if (time_after(jiffies, last + HZ*10)) {
-               printk("gsc_foo() called with bad address 0x%lx\n", addr);
-               dump_stack();
-               last = jiffies;
-       }
-}
-EXPORT_SYMBOL(gsc_bad_addr);
-
-void __raw_bad_addr(const volatile void __iomem *addr)
-{
-       if (time_after(jiffies, last + HZ*10)) {
-               printk("__raw_foo() called with bad address 0x%p\n", addr);
-               dump_stack();
-               last = jiffies;
-       }
-}
-EXPORT_SYMBOL(__raw_bad_addr);
-#endif
-
 /*
  * Generic mapping function (not visible outside):
  */
 
  *   eg dev->hpa or 0xfee00000.
  */
 
-#ifdef CONFIG_DEBUG_IOREMAP
-#define NYBBLE_SHIFT (BITS_PER_LONG - 4)
-extern void gsc_bad_addr(unsigned long addr);
-extern void __raw_bad_addr(const volatile void __iomem *addr);
-#define gsc_check_addr(addr)                                   \
-       if ((addr >> NYBBLE_SHIFT) != 0xf) {                    \
-               gsc_bad_addr(addr);                             \
-               addr |= 0xfUL << NYBBLE_SHIFT;                  \
-       }
-#define __raw_check_addr(addr)                                 \
-       if (((unsigned long)addr >> NYBBLE_SHIFT) != 0xe)       \
-               __raw_bad_addr(addr);                   \
-       addr = (void __iomem *)((unsigned long)addr | (0xfUL << NYBBLE_SHIFT));
-#else
-#define gsc_check_addr(addr)
-#define __raw_check_addr(addr)
-#endif
-
 static inline unsigned char gsc_readb(unsigned long addr)
 {
        long flags;
        unsigned char ret;
 
-       gsc_check_addr(addr);
-
        __asm__ __volatile__(
        "       rsm     2,%0\n"
        "       ldbx    0(%2),%1\n"
        long flags;
        unsigned short ret;
 
-       gsc_check_addr(addr);
-
        __asm__ __volatile__(
        "       rsm     2,%0\n"
        "       ldhx    0(%2),%1\n"
 {
        u32 ret;
 
-       gsc_check_addr(addr);
-
        __asm__ __volatile__(
        "       ldwax   0(%1),%0\n"
        : "=r" (ret) : "r" (addr) );
 static inline unsigned long long gsc_readq(unsigned long addr)
 {
        unsigned long long ret;
-       gsc_check_addr(addr);
 
 #ifdef __LP64__
        __asm__ __volatile__(
 static inline void gsc_writeb(unsigned char val, unsigned long addr)
 {
        long flags;
-       gsc_check_addr(addr);
-
        __asm__ __volatile__(
        "       rsm     2,%0\n"
        "       stbs    %1,0(%2)\n"
 static inline void gsc_writew(unsigned short val, unsigned long addr)
 {
        long flags;
-       gsc_check_addr(addr);
-
        __asm__ __volatile__(
        "       rsm     2,%0\n"
        "       sths    %1,0(%2)\n"
 
 static inline void gsc_writel(unsigned int val, unsigned long addr)
 {
-       gsc_check_addr(addr);
-
        __asm__ __volatile__(
        "       stwas   %0,0(%1)\n"
        : :  "r" (val), "r" (addr) );
 
 static inline void gsc_writeq(unsigned long long val, unsigned long addr)
 {
-       gsc_check_addr(addr);
-
 #ifdef __LP64__
        __asm__ __volatile__(
        "       stda    %0,0(%1)\n"
 
 
          If unsure, say N.
 
-config DEBUG_IOREMAP
-       bool "Enable ioremap() debugging"
-       depends on DEBUG_KERNEL && PARISC
-       help
-         Enabling this option will cause the kernel to distinguish between
-         ioremapped and physical addresses.  It will print a backtrace (at
-         most one every 10 seconds), hopefully allowing you to see which
-         drivers need work.  Fixing all these problems is a prerequisite
-         for turning on USE_HPPA_IOREMAP.  The warnings are harmless;
-         the kernel has enough information to fix the broken drivers
-         automatically, but we'd like to make it more efficient by not
-         having to do that.
-
 config DEBUG_FS
        bool "Debug Filesystem"
        depends on SYSFS