diff options
author | root <root@lamia.panaceas.james.local> | 2017-03-15 13:50:51 +0000 |
---|---|---|
committer | root <root@lamia.panaceas.james.local> | 2017-03-15 13:50:51 +0000 |
commit | 2dd7ea9b7a34fd02c10b67bccebfb3c04b7ab3bf (patch) | |
tree | f145c6f6ad2dd52e271f1b84a4cfb8b8f0c6ce07 /tboot/vga.c | |
parent | f327ade1d0333deee519b2c2977f8edae5b9fa3d (diff) | |
download | tboot-master.tar.gz tboot-master.tar.bz2 tboot-master.zip |
Diffstat (limited to 'tboot/vga.c')
-rw-r--r-- | tboot/vga.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/tboot/vga.c b/tboot/vga.c index 8ddc2f5..19e99f3 100644 --- a/tboot/vga.c +++ b/tboot/vga.c @@ -61,12 +61,13 @@ static inline void reset_screen(void) static void scroll_screen(void) { - for ( long long y = 1; y < MAX_LINES; y++ ) { - for ( long long x = 0; x < MAX_COLS; x++ ) + long long x,y; + for ( y = 1; y < MAX_LINES; y++ ) { + for ( x = 0; x < MAX_COLS; x++ ) writew(VGA_ADDR(x, y-1), readw(VGA_ADDR(x, y))); } /* clear last line */ - for ( long long x = 0; x < MAX_COLS; x++ ) + for ( x = 0; x < MAX_COLS; x++ ) writew(VGA_ADDR(x, MAX_LINES-1), 0x720); } |