Re: [9fans] vgadb woes

2009-04-16 Thread erik quanstrom
> >i really need to write a driver for integratede modern intel or ati
> >graphics.
> 
> 
> There is an ati radeon driver for the r100-r300 (at least) by Philippe
> Anel, iirc.

i guess english precidence rules don't work that well.  let me try again

integrated modern (intel or ati) graphics.

> It also builds against the Inferno native kernel, but there is no user
> program to drive it (set modes, etc) yet.

mode setting can be harder than the actual driver.

- erik



Re: [9fans] vgadb woes

2009-04-15 Thread Venkatesh Srinivas

i really need to write a driver for integratede modern intel or ati
graphics.



There is an ati radeon driver for the r100-r300 (at least) by Philippe
Anel, iirc.

It also builds against the Inferno native kernel, but there is no user
program to drive it (set modes, etc) yet.

-- vs



Re: [9fans] vgadb woes

2009-04-15 Thread erik quanstrom
On Wed Apr 15 19:32:57 EDT 2009, devon.od...@gmail.com wrote:
> Well, that ends up getting my screen to have a bunch of lines through
> it, staggered -- so I'm not much better off than I was before. I'm
> guessing that's an nVidia driver issue or something. If I had any idea
> about video devices, I'd try to fix it, but I don't. I'll just live
> with a bit low-res VESA for now (all of the VESA modes don't seem to
> work), unless someone has ideas.
> 
> Thanks!
> 
> --dho

i'll put my terrible, awful, reprehensible, reprobate, disgusting nvidia
driver that sort-of works if you squint and set the mode incorrectly
up on sources (/n/sources/contrib/quanstro/src/vga).  you may need to
have a monitor fairly resistant to misset frequencies. i had to hack my
vgadb.  the commented-out line is correct for my montior.  clearly i
don't have the frequency calculations right at all.

213t=1600x1200  # 60 Hz
clock=150
#   shb=1664 ehb=1856 ht=2160
shb=1664 ehb=1856 ht=2058
vrs=1201 vre=1204 vt=1250
hsync=+ vsync=+

i really need to write a driver for integratede modern intel or ati
graphics.

- erik



Re: [9fans] vgadb woes

2009-04-15 Thread Devon H. O'Dell
Well, that ends up getting my screen to have a bunch of lines through
it, staggered -- so I'm not much better off than I was before. I'm
guessing that's an nVidia driver issue or something. If I had any idea
about video devices, I'd try to fix it, but I don't. I'll just live
with a bit low-res VESA for now (all of the VESA modes don't seem to
work), unless someone has ideas.

Thanks!

--dho



Re: [9fans] vgadb woes

2009-04-15 Thread Devon H. O'Dell
Thanks for all the tips, I'll see what I can get working (and perhaps
flesh out the wiki once it's working well, if it ends up being
different from what's already there).

--dho



Re: [9fans] vgadb woes

2009-04-15 Thread Steve Simon
I thought russ posted a program that runs under X11 (on unix)
and prints the video config for the current mode in vgadb form.

I had a search but couldn't find it so perhaps it was wishful
thinking, alternatively perhaps this wil jog somones elses
memory.

-Steve



Re: [9fans] vgadb woes

2009-04-15 Thread Eris Discordia
Try generating a working modeline for your X.Org and then just put the 
numbers from modeline into vgadb. xvidtune should help with generating the 
modeline.


A modeline looks like:

Modeline "mode_name_here" 106.47 1440 1520 1672 1904 900 901 904 932 -HSync 
+Vsync


Numbers are from left to right, :

01. Clock (= pixel clock frequency, 'include' section 'clock')
02. HDisplay (= horizontal resolution)
03. HSyncStart (= 'include' section 'shb')
04. HSyncEnd (= 'include' section 'ehb')
05. HTotal (= 'include' section 'ht')
06. VDisplay (= vertical resolution)
07. VSyncStart (= 'include' section 'vrs')
08. VSyncEnd (= 'include' section 'vre')
09. VTotal (= 'include' section 'vt')
10. HSync (= 'include' section 'hsync', either '+' or '-')
11. VSync (= 'include' section 'vsync', either '+' or '-')

There's almost one-to-one correspondence between these numbers and the 
cryptic numbers referred to in vgadb(6). Translations in parentheses :-)


--On Wednesday, April 15, 2009 3:11 PM -0400 "Devon H. O'Dell" 
 wrote:



I've got a laptop that I (for shits and giggles) decided to put Plan 9
on. Lo and behold, it worked fine (Compal EL80, Core 2 Duo, 2GB RAM,
nVidia video).

So, I'm running at 1280x1024x32 right now in VESA, which is
reasonable, but I'd like to run at my maximum native resolution, which
is 1680x1050 (I believe). After tooling around with Xorg configs, I've
found a horiz/vert refresh rate that should work for me...

...except that I have no idea how to convert that into vgadb lingo.
I've read all the comments in vgadb, and the manpage, which helpfully
suggests that I purchase a rather dated book. I suppose it's at least
available, but in the interest of ``I want it now,'' are there any
hints on translating eg.

Option  "DPMS"
HorizSync   28-84
VertRefresh 43-60

into vgadb(6) lingo?

Only other bit of potentially relevant information I have is that Xorg
reports the monitor as having a ``330.0 MHz pixel clock''.

Thanks,

--dho









Re: [9fans] vgadb woes

2009-04-15 Thread erik quanstrom
> In some of the little I've played with such things, it
> has appeared that the VESA report of available modes
> does not always include resolutions that are out of
> the ordinary, and without that, I doubt the VESA
> driver will be able to put it into that mode.  Not to
> discourage you, but just be aware that your issue
> might go deeper than vgadb.
> 
> BLS

to my suprise, vesa seemed to work well in 1600x1200x32
mode when i last tried it on integrated ati graphics a
few weeks ago.

however, the hw cursor didn't.  since i had other plans
for the machine, i didn't investigate further.  the cursor
worked in some other lower vesa modes.

i get the feeling that some of the high bits in the vga
registers might not be set correctly, especially register 13.
i used this in the nvidia driver to get my obstreperous
card (different machine) working

+   vga->crt[0x13] = (vga->virtx/8)*(mode->z/8);// magic to get cursor 
to work.

that would set it to 0x20, not 0x00. as vga.c currently does.

please don't ask me how i arrived at this magic. ☺

- erik



Re: [9fans] vgadb woes

2009-04-15 Thread blstuart
> I've got a laptop that I (for shits and giggles) decided to put Plan 9
> on. Lo and behold, it worked fine (Compal EL80, Core 2 Duo, 2GB RAM,
> nVidia video).
> 
> So, I'm running at 1280x1024x32 right now in VESA, which is
> reasonable, but I'd like to run at my maximum native resolution, which
> is 1680x1050 (I believe). After tooling around with Xorg configs, I've
> found a horiz/vert refresh rate that should work for me...

In some of the little I've played with such things, it
has appeared that the VESA report of available modes
does not always include resolutions that are out of
the ordinary, and without that, I doubt the VESA
driver will be able to put it into that mode.  Not to
discourage you, but just be aware that your issue
might go deeper than vgadb.

BLS




Re: [9fans] vgadb woes

2009-04-15 Thread john
> I've got a laptop that I (for shits and giggles) decided to put Plan 9
> on. Lo and behold, it worked fine (Compal EL80, Core 2 Duo, 2GB RAM,
> nVidia video).
> 
> So, I'm running at 1280x1024x32 right now in VESA, which is
> reasonable, but I'd like to run at my maximum native resolution, which
> is 1680x1050 (I believe). After tooling around with Xorg configs, I've
> found a horiz/vert refresh rate that should work for me...
> 
> ...except that I have no idea how to convert that into vgadb lingo.
> I've read all the comments in vgadb, and the manpage, which helpfully
> suggests that I purchase a rather dated book. I suppose it's at least
> available, but in the interest of ``I want it now,'' are there any
> hints on translating eg.
> 
>   Option  "DPMS"
>   HorizSync   28-84
>   VertRefresh 43-60
> 
> into vgadb(6) lingo?
> 
> Only other bit of potentially relevant information I have is that Xorg
> reports the monitor as having a ``330.0 MHz pixel clock''.
> 
> Thanks,
> 
> --dho

I got something working for me, so I wrote a wiki page:

http://www.plan9.bell-labs.com/wiki/plan9/Adding_a_monitor_to_vgadb/index.html

Hope that helps; I've tried something similar with a different monitor
and managed to get a setup that causes the screen to jiggle and hurt
my eyes, so your mileage may vary.



John




[9fans] vgadb woes

2009-04-15 Thread Devon H. O'Dell
I've got a laptop that I (for shits and giggles) decided to put Plan 9
on. Lo and behold, it worked fine (Compal EL80, Core 2 Duo, 2GB RAM,
nVidia video).

So, I'm running at 1280x1024x32 right now in VESA, which is
reasonable, but I'd like to run at my maximum native resolution, which
is 1680x1050 (I believe). After tooling around with Xorg configs, I've
found a horiz/vert refresh rate that should work for me...

...except that I have no idea how to convert that into vgadb lingo.
I've read all the comments in vgadb, and the manpage, which helpfully
suggests that I purchase a rather dated book. I suppose it's at least
available, but in the interest of ``I want it now,'' are there any
hints on translating eg.

Option  "DPMS"
HorizSync   28-84
VertRefresh 43-60

into vgadb(6) lingo?

Only other bit of potentially relevant information I have is that Xorg
reports the monitor as having a ``330.0 MHz pixel clock''.

Thanks,

--dho