- SET_FARVAR(seg, info->bytes_per_scanline, modeinfo.linesize);
- SET_FARVAR(seg, info->xres, modeinfo.width);
- SET_FARVAR(seg, info->yres, modeinfo.height);
+ int width = GET_GLOBAL(vmode_g->width);
+ int height = GET_GLOBAL(vmode_g->height);
+ int linesize = width * DIV_ROUND_UP(depth, 8); // XXX - not always true
+ SET_FARVAR(seg, info->bytes_per_scanline, linesize);
+ SET_FARVAR(seg, info->xres, width);
+ SET_FARVAR(seg, info->yres, height);