Merge branch 'master' of git://git.denx.de/u-boot-net
[oweals/u-boot.git] / cpu / mpc83xx / qe_io.c
index ebe348711200e70be58b91b1d7a5a2fefc89037f..db94f00098e216edf0927915dfe7e383585c1335 100644 (file)
@@ -25,7 +25,6 @@
 #include "asm/io.h"
 #include "asm/immap_83xx.h"
 
-#if defined(CONFIG_QE)
 #define        NUM_OF_PINS     32
 void qe_config_iopin(u8 port, u8 pin, int dir, int open_drain, int assign)
 {
@@ -34,8 +33,8 @@ void qe_config_iopin(u8 port, u8 pin, int dir, int open_drain, int assign)
        u32                     pin_2bit_assign;
        u32                     pin_1bit_mask;
        u32                     tmp_val;
-       volatile immap_t        *im = (volatile immap_t *)CFG_IMMR;
-       volatile gpio83xx_t     *par_io =(volatile gpio83xx_t *)&im->gpio;
+       volatile immap_t        *im = (volatile immap_t *)CONFIG_SYS_IMMR;
+       volatile qepio83xx_t    *par_io = (volatile qepio83xx_t *)&im->qepio;
 
        /* Caculate pin location and 2bit mask and dir */
        pin_2bit_mask = (u32)(0x3 << (NUM_OF_PINS-(pin%(NUM_OF_PINS/2)+1)*2));
@@ -81,5 +80,3 @@ void qe_config_iopin(u8 port, u8 pin, int dir, int open_drain, int assign)
                out_be32(&par_io->ioport[port].ppar1, pin_2bit_assign | tmp_val);
        }
 }
-
-#endif /* CONFIG_QE */