Browse Source

Make vga_font const to avoid warning about large symbol

tags/v0.9.3
Michael Brown 19 years ago
parent
commit
462234f373
1 changed files with 12 additions and 12 deletions
  1. 12
    12
      src/core/btext.c

+ 12
- 12
src/core/btext.c View File

29
 static void scrollscreen(void);
29
 static void scrollscreen(void);
30
 #endif
30
 #endif
31
 
31
 
32
-static void draw_byte(unsigned char c, u32 locX, u32 locY);
32
+static void draw_byte(const unsigned char c, u32 locX, u32 locY);
33
 #if 0
33
 #if 0
34
-static void draw_byte_32(unsigned char *bits, u32 *base, u32 rb);
35
-static void draw_byte_16(unsigned char *bits, u32 *base, u32 rb);
34
+static void draw_byte_32(const unsigned char *bits, u32 *base, u32 rb);
35
+static void draw_byte_16(const unsigned char *bits, u32 *base, u32 rb);
36
 #endif
36
 #endif
37
-static void draw_byte_8(unsigned char *bits, u32 *base, u32 rb);
37
+static void draw_byte_8(const unsigned char *bits, u32 *base, u32 rb);
38
 
38
 
39
 static u32 g_loc_X;
39
 static u32 g_loc_X;
40
 static u32 g_loc_Y;
40
 static u32 g_loc_Y;
49
 #define cmapsz  (16*96)
49
 #define cmapsz  (16*96)
50
 #endif
50
 #endif
51
 
51
 
52
-static unsigned char vga_font[cmapsz];
52
+static const unsigned char vga_font[cmapsz];
53
 
53
 
54
 u32 boot_text_mapped;
54
 u32 boot_text_mapped;
55
 
55
 
275
 #endif
275
 #endif
276
 
276
 
277
 static void BTEXT
277
 static void BTEXT
278
-draw_byte(unsigned char c, u32 locX, u32 locY)
278
+draw_byte(const unsigned char c, u32 locX, u32 locY)
279
 {
279
 {
280
 	boot_infos_t* bi	= &disp_bi;
280
 	boot_infos_t* bi	= &disp_bi;
281
 	unsigned char *base	= calc_base(bi, locX << 3, locY << 4);
281
 	unsigned char *base	= calc_base(bi, locX << 3, locY << 4);
282
 #if CHAR_256==1
282
 #if CHAR_256==1
283
-        unsigned char *font     = &vga_font[(((u32)c)) * 16];
283
+        unsigned const char *font     = &vga_font[(((u32)c)) * 16];
284
 #else
284
 #else
285
-	unsigned char *font	= &vga_font[(((u32)c-0x20)) * 16];
285
+	unsigned const char *font	= &vga_font[(((u32)c-0x20)) * 16];
286
 #endif
286
 #endif
287
 
287
 
288
 	u32 rb			= bi->dispDeviceRowBytes;
288
 	u32 rb			= bi->dispDeviceRowBytes;
331
 #endif
331
 #endif
332
 #if 0
332
 #if 0
333
 static void BTEXT
333
 static void BTEXT
334
-draw_byte_32(unsigned char *font, u32 *base, u32 rb)
334
+draw_byte_32(const unsigned char *font, u32 *base, u32 rb)
335
 {
335
 {
336
 	u32 l, bits;
336
 	u32 l, bits;
337
 	u32 fg = 0xFFFFFFFF;
337
 	u32 fg = 0xFFFFFFFF;
353
 }
353
 }
354
 
354
 
355
 static void BTEXT
355
 static void BTEXT
356
-draw_byte_16(unsigned char *font, u32 *base, u32 rb)
356
+draw_byte_16(const unsigned char *font, u32 *base, u32 rb)
357
 {
357
 {
358
 	u32 l, bits;
358
 	u32 l, bits;
359
 	u32 fg = 0xFFFFFFFF;
359
 	u32 fg = 0xFFFFFFFF;
372
 }
372
 }
373
 #endif
373
 #endif
374
 static void BTEXT
374
 static void BTEXT
375
-draw_byte_8(unsigned char *font, u32 *base, u32 rb)
375
+draw_byte_8(const unsigned char *font, u32 *base, u32 rb)
376
 {
376
 {
377
 	u32 l, bits;
377
 	u32 l, bits;
378
 	u32 fg = 0x0F0F0F0F;
378
 	u32 fg = 0x0F0F0F0F;
450
 /**********************************************/
450
 /**********************************************/
451
 
451
 
452
 
452
 
453
-static unsigned char vga_font[cmapsz] BTDATA = {
453
+static const unsigned char vga_font[cmapsz] BTDATA = {
454
 #if CHAR_256==1
454
 #if CHAR_256==1
455
 	/* 0 0x00 '^@' */
455
 	/* 0 0x00 '^@' */
456
 	0x00, /* 00000000 */
456
 	0x00, /* 00000000 */

Loading…
Cancel
Save