changeset 101:7fe6855f19cd

mga_ram_size=x works with hard-coded ramsize too (szabi)
author arpi_esp
date Tue, 13 Mar 2001 00:23:52 +0000
parents 201c2f931497
children 5978ada9505e
files drivers/mga_vid.c
diffstat 1 files changed, 7 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/drivers/mga_vid.c	Tue Mar 13 00:14:47 2001 +0000
+++ b/drivers/mga_vid.c	Tue Mar 13 00:23:52 2001 +0000
@@ -157,7 +157,6 @@
 
 MODULE_PARM(mga_ram_size, "i");
 
-
 static struct pci_dev *pci_dev;
 
 static mga_vid_config_t mga_config; 
@@ -733,15 +732,16 @@
 
 //	temp = (card_option >> 10) & 0x17;
 
-#ifdef MGA_MEMORY_SIZE
-	mga_ram_size = MGA_MEMORY_SIZE;
-	printk(KERN_INFO "mga_vid: hard-coded RAMSIZE is %d MB\n", (unsigned int) mga_ram_size);
-
-#else
 	if (mga_ram_size) {
 		printk(KERN_INFO "mga_vid: RAMSIZE forced to %d MB\n", mga_ram_size);
 	} else {
 
+#ifdef MGA_MEMORY_SIZE
+	    mga_ram_size = MGA_MEMORY_SIZE;
+	    printk(KERN_INFO "mga_vid: hard-coded RAMSIZE is %d MB\n", (unsigned int) mga_ram_size);
+
+#else
+
 	    if (is_g400){
 		switch((card_option>>10)&0x17){
 		    // SDRAM:
@@ -778,9 +778,9 @@
 	    }
 #endif
 	    printk(KERN_INFO "mga_vid: detected RAMSIZE is %d MB\n", (unsigned int) mga_ram_size);
+#endif
         }
 
-#endif
 
 #ifdef MGA_ALLOW_IRQ
 	if ( mga_irq != -1 ) {