Date: Wed, 20 May 1998 18:54:31 +0200 (MEST)
From: Bernd Harries <bharries@vossnet.de>
X-Sender: bharries@hexe.bis.uni-oldenburg.de
To: "Scott J. Kolodzieski" <scott@dmi.stevens-tech.edu>
cc: harries@dsit03.atlas.de, Geert.Uytterhoeven@cs.kuleuven.ac.be,
        pstehlik@zln.cz, linux-m68k@lists.linux-m68k.org
Subject: Re: L68K: Re: atyfb....
In-Reply-To: <199805201252.IAA01798@hades.dmi.stevens-tech.edu>
Sender: owner-linux-m68k@phil.uni-sb.de

Hello world!

This is specially meant for the guys with Mach64 cards in Ataris.

Here is a diff for atyfb.c to apply after Geert's 2.1.101 diff and a diff
for fbmem.c which adds some verbosity. Apply the 2nd only if you like.



Bernd Harries

bharries@freeyellow.com  http://www.freeyellow.com/members/bharries
bharries@vossnet.de      Tel.: +49 421 809 7351  priv. | Linux-m68k
harries@atlas.de               +49 421 457 3966  offi. | Medusa T40
bernd@linux-m68k.org


--- drivers/video/atyfb.c_21101	Tue May 19 19:23:20 1998
+++ drivers/video/atyfb.c	Wed May 20 17:44:56 1998
@@ -1532,8 +1532,13 @@
 	    default:
 		info->total_vram = 0x80000;
 	}
-#ifdef CONFIG_ATARI /* this is definately the wrong way to set this */
-    info->total_vram -= 0x00080000;
+#ifdef CONFIG_ATARI /* this is definately not the wrong way to set this */
+    if((info->total_vram == 0x400000) || (info->total_vram == 0x800000))
+    {
+      /* protect GUI-regs if complete Aperture is VRAM */
+      info->total_vram -= 0x00001000;
+    }
+    /*endif*/
 #endif
 
 #if 1

--- drivers/char/fbmem.c_21101	Thu May 14 22:13:00 1998
+++ drivers/char/fbmem.c	Wed May 20 17:32:40 1998
@@ -73,6 +73,8 @@
 extern void hpfb_setup(char *options, int *ints);
 extern void vgafb_init(void);
 extern void vgafb_setup(char *options, int *ints);
+extern unsigned long mach64fb_init(unsigned long mem_start);
+extern void mach64fb_setup(char *options, int *ints);
 
 
 static struct {
@@ -110,6 +112,9 @@
 #ifdef CONFIG_FB_ATY
 	{ "atyfb", atyfb_init, atyfb_setup },
 #endif
+#ifdef CONFIG_FB_MACH64
+      { "mach64", mach64fb_init, mach64fb_setup },
+#endif
 #ifdef CONFIG_APOLLO
 	{ "apollo", dnfb_init, NULL },
 #endif
@@ -448,6 +453,8 @@
 	int i, j;
 	static int fb_ever_opened[FB_MAX];
 
+  printk("register_framebuffer() \n");
+
 	if (num_registered_fb == FB_MAX)
 		return -ENXIO;
 	num_registered_fb++;
@@ -492,6 +499,8 @@
 __initfunc(void
 fbmem_init(void))
 {
+  printk("fbmem_init() \n");
+
 #ifdef CONFIG_PROC_FS
 	proc_fbmem = create_proc_entry("fb", 0, 0);
 	if (proc_fbmem)
@@ -543,6 +552,8 @@
 {
     int i;
 
+  printk("probe_framebuffers($%08lX) \n", kmem_start);
+
     for (i = 0; i < num_pref_init_funcs; i++)
 	    kmem_start = pref_init_funcs[i](kmem_start);
 
@@ -550,6 +561,7 @@
 	    if (fb_drivers[i].init)
 		    kmem_start = fb_drivers[i].init(kmem_start);
 
+  printk("probe_framebuffers() %d total \n", num_registered_fb);
     return kmem_start;
 }
 
@@ -561,6 +573,8 @@
 __initfunc(void video_setup(char *options, int *ints))
 {
     int i, j;
+
+  printk("video_setup() '%s'\n", options);
 
     if (!options || !*options)
 	    return;

