]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - include/asm-blackfin/mach-common/def_LPBlackfin.h
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
[linux-2.6-omap-h63xx.git] / include / asm-blackfin / mach-common / def_LPBlackfin.h
index 260515d152803d9796faf14d2ede4084a0398663..e8967f6124f7ea2eb0a3878ec9fbc70c142e9c9d 100644 (file)
@@ -46,7 +46,7 @@
 #endif
 
 #define bfin_read8(addr) ({ \
-       uint8_t __v; \
+       uint32_t __v; \
        __asm__ __volatile__( \
                NOP_PAD_ANOMALY_05000198 \
                "%0 = b[%1] (z);" \
@@ -56,7 +56,7 @@
        __v; })
 
 #define bfin_read16(addr) ({ \
-       uint16_t __v; \
+       uint32_t __v; \
        __asm__ __volatile__( \
                NOP_PAD_ANOMALY_05000198 \
                "%0 = w[%1] (z);" \
@@ -80,7 +80,7 @@
                NOP_PAD_ANOMALY_05000198 \
                "b[%0] = %1;" \
                : \
-               : "a" (addr), "d" (val) \
+               : "a" (addr), "d" ((uint8_t)(val)) \
                : "memory" \
        )
 
@@ -89,7 +89,7 @@
                NOP_PAD_ANOMALY_05000198 \
                "w[%0] = %1;" \
                : \
-               : "a" (addr), "d" (val) \
+               : "a" (addr), "d" ((uint16_t)(val)) \
                : "memory" \
        )
 
 #define CPLB_USER_RD       0x00000004  /* 0=no read access, 1=read access
                                         * allowed (user mode)
                                         */
+
 #define PAGE_SIZE_1KB      0x00000000  /* 1 KB page size */
 #define PAGE_SIZE_4KB      0x00010000  /* 4 KB page size */
 #define PAGE_SIZE_1MB      0x00020000  /* 1 MB page size */
                                         */
 #define CPLB_WT            0x00004000  /* 0=write-back, 1=write-through */
 
+#define CPLB_ALL_ACCESS CPLB_SUPV_WR | CPLB_USER_RD | CPLB_USER_WR
+
 /* TBUFCTL Masks */
 #define TBUFPWR            0x0001
 #define TBUFEN             0x0002