diff --git a/drivers/i386/vga.c b/drivers/i386/vga.c index dfadeba..07971eb 100644 --- a/drivers/i386/vga.c +++ b/drivers/i386/vga.c @@ -1,6 +1,6 @@ #include #include "../vga.h" -#define xy_to_mem(x,y) ((x+(y*height))*2) +#define xy_to_indx(x,y) ((x+(y*height))*2) char* screen; int width; int height; @@ -8,8 +8,8 @@ vga_colors fg_color; vga_colors bg_color; void vga_set_char(int x,int y,char c) { - screen[xy_to_mem(x,y)]=c; - screen[xy_to_mem(x,y)+1]=(bg_color<<4)|fg_color; + screen[xy_to_indx(x,y)]=c; + screen[xy_to_indx(x,y)+1]=(bg_color<<4)|fg_color; } void vga_init(text_fb_info framebuffer_info) {