Subject: Re: supporting a new video card
To: Steven Hascall <steve@ezl.com>
From: Allen Briggs <briggs@wasabisystems.com>
List: port-mac68k
Date: 12/29/2000 03:37:03
On Sat, Dec 23, 2000 at 10:54:42PM -0600, Steven Hascall wrote:
> I have a SuperMac Thunder II video card I'd like to get working under
> X11 on NetBSD. How can I go about adding support for it? For whatever
> reason it probes at video address 0xe0100000. Simply telling machdep.c
> to use that address has no effect, though, and I'm not even sure why it
> needs an interrupt defined for it in nubus.h, nubus.c etc. Can somone
> please shed some light on this process or point me to some good
> documentation on this subject? I haven't looked at the X server code,
> but it shouldn't need any modification, right? Thanks.

Hi, Steve.  There are two separate issues here:

	* Video cards & X11...  X11 under NetBSD/mac68k just uses a
	  flat framebuffer to access the screen.  This means that it
	  just needs to know the address of the base of the video
	  memory and roughly how it's laid out.  If the console is
	  working, X should be working--at least in B&W.  It would be
	  great to have much better X support for various nubus cards,
	  but it'll take a fair bit of work...

	* Video cards & interrupts...  While interrupts might be
	  necessary for better X11 code for nubus cards (i.e., if we
	  need to update the palette or the h/w cursor during a vertical
	  blank interrupt), the current X code doesn't care.  However,
	  the nubus architecture of the macs requires us to know how to
	  clear interrupts for all nubus devices if interrupts are enabled
	  for any nubus device.  If you have an ethernet card (the only
	  other nubus device that's currently supported), you need
	  interrupts enabled.  If you have an 'unsupported' video card
	  that is also generating interrupts along with an ethernet card,
	  you'll get a hang just after the ethernet card is configured
	  and nubus interrupts are enabled.

I don't know if this helps your understanding or not...  :-(

-allen

-- 
 Allen Briggs                     briggs@wasabisystems.com
 http://www.wasabisystems.com/    Quality NetBSD CDs, Sales, Support, Service