Back to home page

OSCL-LXR

 
 

    


0001 /* SPDX-License-Identifier: GPL-2.0 */
0002 /*
0003  *  Access to VGA videoram
0004  *
0005  *  (c) 1998 Martin Mares <mj@ucw.cz>
0006  */
0007 #ifndef __ASM_GENERIC_VGA_H
0008 #define __ASM_GENERIC_VGA_H
0009 
0010 /*
0011  *  On most architectures that support VGA, we can just
0012  *  recalculate addresses and then access the videoram
0013  *  directly without any black magic.
0014  *
0015  *  Everyone else needs to ioremap the address and use
0016  *  proper I/O accesses.
0017  */
0018 #ifndef VGA_MAP_MEM
0019 #define VGA_MAP_MEM(x, s) (unsigned long)phys_to_virt(x)
0020 #endif
0021 
0022 #define vga_readb(x) (*(x))
0023 #define vga_writeb(x, y) (*(y) = (x))
0024 
0025 #endif /* _ASM_GENERIC_VGA_H */