9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: "Russ Cox" <rsc@plan9.bell-labs.com>
To: 9fans@cse.psu.edu
Subject: Re: [9fans] magicgraph 128 ZV
Date: Fri, 27 Dec 2002 06:34:44 -0500	[thread overview]
Message-ID: <99b249533ab26e79161b6b9c3fef26df@plan9.bell-labs.com> (raw)
In-Reply-To: <3E0C28CD.3090108@csh.rit.edu>

> That's an understatement.  Reading that code is like pulling teeth.
>  I've also been using the slightly more readable, but less full featured
> neofb.c in the linux kernel.  (seems to have similar syntax and layout).
>  I have no idea even where to start to figure out why the images are
> garbled...

The images are garbled because you are setting some register
wrong.  The trick is to figure out which register.  The relevant file
is neo_driver.c, and you want to find out what executes when
nPtr->NeoChipset == NM2093 (or NM2097, if you have a ZV+)
that's different from the NM2160 and the NM2200.

Quickly scanning through, it looks like you might try commenting out:

	vgaxo(Grx, PanelHorizCenterReg4, vga->graphics[PanelHorizCenterReg4]);
	vgaxo(Grx, PanelVertCenterReg5, vga->graphics[PanelVertCenterReg5]);
	vgaxo(Grx, PanelHorizCenterReg5, vga->graphics[PanelHorizCenterReg5]);

because those registers are only written for the later chipsets.

Also, what did you put in as the f[1], vmz, and apz values?
It looks to me like it should say

	vga->f[1] = 80000000;
	vga->vmz = 1152*1024;
	vga->apz = 16*1042*1024;

If you were using f[1] = 90000000 (like the 128 XD in the driver)
then that might explain your garbled screen.

I'm very suspicious of vga->apz being that large.
It looks to me like it's actually much smaller for
all the cards, but as long as we don't touch memory
that isn't there, nothing bad will happen.  What does
the "pci" command print on your system?

Russ



  reply	other threads:[~2002-12-27 11:34 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-12-27  7:09 George Gensure
2002-12-27  4:19 ` Russ Cox
2002-12-27 10:17   ` George Gensure
2002-12-27 11:34     ` Russ Cox [this message]
2002-12-27 20:31       ` George Gensure
  -- strict thread matches above, loose matches on Subject: below --
1970-01-22 10:56 George Gensure

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=99b249533ab26e79161b6b9c3fef26df@plan9.bell-labs.com \
    --to=rsc@plan9.bell-labs.com \
    --cc=9fans@cse.psu.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).