diff options
Diffstat (limited to 'include/linux/fb.h')
-rw-r--r-- | include/linux/fb.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/include/linux/fb.h b/include/linux/fb.h index dab3a4decb44..a973be2cfe61 100644 --- a/include/linux/fb.h +++ b/include/linux/fb.h | |||
@@ -835,6 +835,18 @@ struct fb_info { | |||
835 | 835 | ||
836 | #endif | 836 | #endif |
837 | 837 | ||
838 | #if defined (__BIG_ENDIAN) | ||
839 | #define FB_LEFT_POS(bpp) (32 - bpp) | ||
840 | #define FB_SHIFT_HIGH(val, bits) ((val) >> (bits)) | ||
841 | #define FB_SHIFT_LOW(val, bits) ((val) << (bits)) | ||
842 | #define FB_BIT_NR(b) (7 - (b)) | ||
843 | #else | ||
844 | #define FB_LEFT_POS(bpp) (0) | ||
845 | #define FB_SHIFT_HIGH(val, bits) ((val) << (bits)) | ||
846 | #define FB_SHIFT_LOW(val, bits) ((val) >> (bits)) | ||
847 | #define FB_BIT_NR(b) (b) | ||
848 | #endif | ||
849 | |||
838 | /* | 850 | /* |
839 | * `Generic' versions of the frame buffer device operations | 851 | * `Generic' versions of the frame buffer device operations |
840 | */ | 852 | */ |