<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">
From: "Antonino A. Daplas" &lt;adaplas@hotpop.com&gt;

The current code in rivafb will not accept modes other than 640x480-60 if
the the EDID block is absent.

This patch changes the behavior to the opposite, if without an EDID, rivafb
will accept all modelines coming from userspace (2.4 behavior).

Signed-off-by: Antonino Daplas &lt;adaplas@pol.net&gt;
Signed-off-by: Andrew Morton &lt;akpm@osdl.org&gt;
---

 25-akpm/drivers/video/riva/fbdev.c |    3 +--
 1 files changed, 1 insertion(+), 2 deletions(-)

diff -puN drivers/video/riva/fbdev.c~fbdev-fix-mode-handling-in-rivafb-if-with-no-edid drivers/video/riva/fbdev.c
--- 25/drivers/video/riva/fbdev.c~fbdev-fix-mode-handling-in-rivafb-if-with-no-edid	2004-11-07 16:32:19.748837456 -0800
+++ 25-akpm/drivers/video/riva/fbdev.c	2004-11-07 16:32:19.754836544 -0800
@@ -1126,7 +1126,7 @@ static int rivafb_check_var(struct fb_va
 		}
 	}
 
-	if (!mode_valid &amp;&amp; !list_empty(&amp;info-&gt;modelist))
+	if (!mode_valid &amp;&amp; info-&gt;monspecs.modedb_len)
 		return -EINVAL;
 
 	if (var-&gt;xres_virtual &lt; var-&gt;xres)
@@ -2017,7 +2017,6 @@ static int __devinit rivafb_probe(struct
 	}
 
 	fb_destroy_modedb(info-&gt;monspecs.modedb);
-	info-&gt;monspecs.modedb_len = 0;
 	info-&gt;monspecs.modedb = NULL;
 	if (register_framebuffer(info) &lt; 0) {
 		printk(KERN_ERR PFX
_
</pre></body></html>