# HG changeset patch # User rfelker # Date 1013047649 0 # Node ID 5dc383bb1c827d41089e6a5ac86dcc0687f0e2bb # Parent aac57ef92bab50209e1a048a28b2d7eb5581c109 added mga_top_reserved module parameter to skip a configurable amount of space at the top of video memory. this is needed to prevent corruption of the kernel's console font when using the "fastfont" option with matroxfb. diff -r aac57ef92bab -r 5dc383bb1c82 drivers/mga_vid.c --- a/drivers/mga_vid.c Wed Feb 06 22:55:57 2002 +0000 +++ b/drivers/mga_vid.c Thu Feb 07 02:07:29 2002 +0000 @@ -246,9 +246,12 @@ static uint32_t mga_ram_size = 0; // how much megabytes videoram we have +static uint32_t mga_top_reserved = 0; // reserved space for console font (matroxfb + fastfont) + //static int mga_force_memsize = 0; MODULE_PARM(mga_ram_size, "i"); +MODULE_PARM(mga_top_reserved, "i"); static struct pci_dev *pci_dev; @@ -1167,7 +1170,7 @@ return(-EFAULT); } - mga_src_base = (mga_ram_size*0x100000-mga_config.num_frames*mga_config.frame_size); + mga_src_base = (mga_ram_size*0x100000-mga_config.num_frames*mga_config.frame_size-mga_top_reserved); if(mga_src_base<0){ printk(KERN_ERR "mga_vid: not enough memory for frames!\n"); return(-EFAULT);