Rev 3755 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 3755 | Rev 3766 | ||
---|---|---|---|
Line 80... | Line 80... | ||
80 | _memsetw(videoram, SCREEN, 0x0720); |
80 | _memsetw(videoram, SCREEN, 0x0720); |
81 | 81 | ||
82 | chardev_initialize("ega_out", &ega_console, &ega_ops); |
82 | chardev_initialize("ega_out", &ega_console, &ega_ops); |
83 | stdout = &ega_console; |
83 | stdout = &ega_console; |
84 | 84 | ||
85 | - | ||
86 | ega_parea.pbase = VIDEORAM & 0xffffffff; |
85 | ega_parea.pbase = VIDEORAM & 0xffffffff; |
87 | ega_parea.vbase = (uintptr_t) videoram; |
86 | ega_parea.vbase = (uintptr_t) videoram; |
88 | ega_parea.frames = 1; |
87 | ega_parea.frames = 1; |
89 | ega_parea.cacheable = false; |
88 | ega_parea.cacheable = false; |
90 | ddi_parea_register(&ega_parea); |
89 | ddi_parea_register(&ega_parea); |
91 | 90 | ||
92 | - | ||
93 | sysinfo_set_item_val("fb", NULL, true); |
91 | sysinfo_set_item_val("fb", NULL, true); |
94 | sysinfo_set_item_val("fb.kind", NULL, 2); |
92 | sysinfo_set_item_val("fb.kind", NULL, 2); |
95 | sysinfo_set_item_val("fb.width", NULL, ROW); |
93 | sysinfo_set_item_val("fb.width", NULL, ROW); |
96 | sysinfo_set_item_val("fb.height", NULL, ROWS); |
94 | sysinfo_set_item_val("fb.height", NULL, ROWS); |
97 | sysinfo_set_item_val("fb.blinking", NULL, true); |
95 | sysinfo_set_item_val("fb.blinking", NULL, true); |
98 | sysinfo_set_item_val("fb.address.physical", NULL, VIDEORAM & 0xffffffff); |
96 | sysinfo_set_item_val("fb.address.physical", NULL, |
- | 97 | VIDEORAM & 0xffffffff); |
|
99 | 98 | ||
100 | #ifndef CONFIG_FB |
99 | #ifndef CONFIG_FB |
101 | putchar('\n'); |
100 | putchar('\n'); |
102 | #endif |
101 | #endif |
103 | } |
102 | } |
Line 114... | Line 113... | ||
114 | static void ega_check_cursor(void) |
113 | static void ega_check_cursor(void) |
115 | { |
114 | { |
116 | if (ega_cursor < SCREEN) |
115 | if (ega_cursor < SCREEN) |
117 | return; |
116 | return; |
118 | 117 | ||
119 | memmove((void *) videoram, (void *) (videoram + ROW * 2), (SCREEN - ROW) * 2); |
118 | memmove((void *) videoram, (void *) (videoram + ROW * 2), |
- | 119 | (SCREEN - ROW) * 2); |
|
120 | _memsetw(videoram + (SCREEN - ROW) * 2, ROW, 0x0720); |
120 | _memsetw(videoram + (SCREEN - ROW) * 2, ROW, 0x0720); |
121 | ega_cursor = ega_cursor - ROW; |
121 | ega_cursor = ega_cursor - ROW; |
122 | } |
122 | } |
123 | 123 | ||
124 | void ega_putchar(chardev_t *d, const char ch) |
124 | void ega_putchar(chardev_t *d, const char ch) |