X-Git-Url: http://wien.tomnetworks.com/gitweb/?a=blobdiff_plain;f=vgasrc%2Fvgahw.h;h=1101e510737a1f9510be364f9fc8334d47fd7009;hb=34203cdf8a89c747e221005850a4558252235360;hp=d34b0e75927e5e0fe250c1e62aaa3b02b8df4976;hpb=161d201affa5dd23a39a0de9a0743b857448c4b6;p=seabios.git diff --git a/vgasrc/vgahw.h b/vgasrc/vgahw.h index d34b0e7..1101e51 100644 --- a/vgasrc/vgahw.h +++ b/vgasrc/vgahw.h @@ -7,7 +7,15 @@ #include "clext.h" // clext_set_mode #include "bochsvga.h" // bochsvga_set_mode #include "stdvga.h" // stdvga_set_mode -#include "geodelx.h" // geodelx_init +#include "geodevga.h" // geodevga_init + +static inline struct vgamode_s *vgahw_find_mode(int mode) { + if (CONFIG_VGA_CIRRUS) + return clext_find_mode(mode); + if (CONFIG_VGA_BOCHS) + return bochsvga_find_mode(mode); + return stdvga_find_mode(mode); +} static inline int vgahw_set_mode(int mode, int flags) { if (CONFIG_VGA_CIRRUS) @@ -17,13 +25,22 @@ static inline int vgahw_set_mode(int mode, int flags) { return stdvga_set_mode(mode, flags); } +static inline void vgahw_list_modes(u16 seg, u16 *dest, u16 *last) { + if (CONFIG_VGA_CIRRUS) + clext_list_modes(seg, dest, last); + else if (CONFIG_VGA_BOCHS) + bochsvga_list_modes(seg, dest, last); + else + stdvga_list_modes(seg, dest, last); +} + static inline int vgahw_init(void) { if (CONFIG_VGA_CIRRUS) return clext_init(); if (CONFIG_VGA_BOCHS) return bochsvga_init(); - if (CONFIG_VGA_GEODELX) - return geodelx_init(); + if (CONFIG_VGA_GEODEGX2 || CONFIG_VGA_GEODELX) + return geodevga_init(); return stdvga_init(); }