diff options
Diffstat (limited to 'arch/mips/lasat/picvue.c')
| -rw-r--r-- | arch/mips/lasat/picvue.c | 49 |
1 files changed, 25 insertions, 24 deletions
diff --git a/arch/mips/lasat/picvue.c b/arch/mips/lasat/picvue.c index 9ae82c3ffb0..d613b97cd51 100644 --- a/arch/mips/lasat/picvue.c +++ b/arch/mips/lasat/picvue.c @@ -9,7 +9,6 @@ #include <asm/bootinfo.h> #include <asm/lasat/lasat.h> #include <linux/module.h> -#include <linux/init.h> #include <linux/errno.h> #include <linux/string.h> @@ -20,9 +19,7 @@ #define PVC_DISPMEM 80 #define PVC_LINELEN PVC_DISPMEM / PVC_NLINES -struct pvc_defs *picvue = NULL; - -DECLARE_MUTEX(pvc_sem); +struct pvc_defs *picvue; static void pvc_reg_write(u32 val) { @@ -159,47 +156,51 @@ int pvc_program_cg(int charnum, u8 bitmap[BM_SIZE]) addr = charnum * 8; pvc_write(0x40 | addr, MODE_INST); - for (i=0; i<BM_SIZE; i++) + for (i = 0; i < BM_SIZE; i++) pvc_write(bitmap[i], MODE_DATA); return 0; } #define FUNC_SET_CMD 0x20 -#define EIGHT_BYTE (1 << 4) -#define FOUR_BYTE 0 -#define TWO_LINES (1 << 3) -#define ONE_LINE 0 -#define LARGE_FONT (1 << 2) -#define SMALL_FONT 0 +#define EIGHT_BYTE (1 << 4) +#define FOUR_BYTE 0 +#define TWO_LINES (1 << 3) +#define ONE_LINE 0 +#define LARGE_FONT (1 << 2) +#define SMALL_FONT 0 + static void pvc_funcset(u8 cmd) { - pvc_write(FUNC_SET_CMD | (cmd & (EIGHT_BYTE|TWO_LINES|LARGE_FONT)), MODE_INST); + pvc_write(FUNC_SET_CMD | (cmd & (EIGHT_BYTE|TWO_LINES|LARGE_FONT)), + MODE_INST); } #define ENTRYMODE_CMD 0x4 -#define AUTO_INC (1 << 1) -#define AUTO_DEC 0 -#define CURSOR_FOLLOWS_DISP (1 << 0) +#define AUTO_INC (1 << 1) +#define AUTO_DEC 0 +#define CURSOR_FOLLOWS_DISP (1 << 0) + static void pvc_entrymode(u8 cmd) { - pvc_write(ENTRYMODE_CMD | (cmd & (AUTO_INC|CURSOR_FOLLOWS_DISP)), MODE_INST); + pvc_write(ENTRYMODE_CMD | (cmd & (AUTO_INC|CURSOR_FOLLOWS_DISP)), + MODE_INST); } #define DISP_CNT_CMD 0x08 -#define DISP_OFF 0 -#define DISP_ON (1 << 2) -#define CUR_ON (1 << 1) -#define CUR_BLINK (1 << 0) +#define DISP_OFF 0 +#define DISP_ON (1 << 2) +#define CUR_ON (1 << 1) +#define CUR_BLINK (1 << 0) void pvc_dispcnt(u8 cmd) { pvc_write(DISP_CNT_CMD | (cmd & (DISP_ON|CUR_ON|CUR_BLINK)), MODE_INST); } #define MOVE_CMD 0x10 -#define DISPLAY (1 << 3) -#define CURSOR 0 -#define RIGHT (1 << 2) -#define LEFT 0 +#define DISPLAY (1 << 3) +#define CURSOR 0 +#define RIGHT (1 << 2) +#define LEFT 0 void pvc_move(u8 cmd) { pvc_write(MOVE_CMD | (cmd & (DISPLAY|RIGHT)), MODE_INST); |
