From 6d4706d26cb3248bca9315b01c70ae525b8db369 Mon Sep 17 00:00:00 2001 From: Yourtion Date: Wed, 10 Sep 2014 17:44:42 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BD=BF=E7=94=A8=E7=AE=AD=E5=A4=B4=E6=96=B9?= =?UTF-8?q?=E6=B3=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- 05_day/bootpack.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/05_day/bootpack.c b/05_day/bootpack.c index b3de470..386a0dd 100644 --- a/05_day/bootpack.c +++ b/05_day/bootpack.c @@ -34,17 +34,10 @@ struct BOOTINFO { void HariMain(void) { - char *vram;/* 声明变量vram、用于BYTE [...]地址 */ - int xsize, ysize; - struct BOOTINFO *binfo; + struct BOOTINFO *binfo = (struct BOOTINFO *) 0x0ff0; init_palette(); - binfo = (struct BOOTINFO *) 0x0ff0; - xsize = (*binfo).scrnx; - ysize = (*binfo).scrny; - vram = (*binfo).vram; - - init_screen(vram, xsize, ysize); + init_screen(binfo->vram, binfo->scrnx, binfo->scrny); for (;;) { io_hlt();