From 601752d5a7bef087e755da5a2b158fa35cb51ccb Mon Sep 17 00:00:00 2001 From: Dag-Erling Smørgrav Date: Mon, 12 Apr 1999 13:34:58 +0000 Subject: Centralize and reorganize a few macros. --- sys/dev/fb/fbreg.h | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) (limited to 'sys/dev/fb') diff --git a/sys/dev/fb/fbreg.h b/sys/dev/fb/fbreg.h index 46f0343d0edd1..561ac5758cce6 100644 --- a/sys/dev/fb/fbreg.h +++ b/sys/dev/fb/fbreg.h @@ -23,7 +23,7 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $Id: fbreg.h,v 1.1 1999/01/09 02:44:49 yokota Exp $ + * $Id: fbreg.h,v 1.2 1999/01/19 11:31:11 yokota Exp $ */ #ifndef _DEV_FB_FBREG_H_ @@ -99,6 +99,23 @@ typedef struct video_switch { vi_diag_t *diag; } video_switch_t; +#define save_palette(adp, pal) \ + (*vidsw[(adp)->va_index]->save_palette)((adp), (pal)) +#define load_palette(adp, pal) \ + (*vidsw[(adp)->va_index]->load_palette)((adp), (pal)) +#define get_mode_info(adp, mode, buf) \ + (*vidsw[(adp)->va_index]->get_info)((adp), (mode), (buf)) +#define set_video_mode(adp, mode) \ + (*vidsw[(adp)->va_index]->set_mode)((adp), (mode)) +#if 0 /* XXX conflicts with syscons' set_border() */ +#define set_border(adp, border) \ + (*vidsw[(adp)->va_index]->set_border)((adp), (border)) +#endif +#define set_origin(adp, o) \ + (*vidsw[(adp)->va_index]->set_win_org)(adp, o) + +/* XXX - add more macros */ + /* video driver */ typedef struct video_driver { char *name; -- cgit v1.3