overdue-scratch

Author Topic: ATI and possibly nVIDIA resolution patch (based on prasys' 915resolution port)  (Read 115137 times)

0 Members and 1 Guest are viewing this topic.

diebuche

  • VoodooLabs
  • Posts: 30
thx, i added that part

Azimutz

  • VoodooLabs
  • Posts: 420
  • Paranoid Android
Removed stuff about the rev i was working on.

Diebuche, checked your branch again, you're still missing a line on gui.c from Lebidou's diff. I didn't had it on my sources at the time i made the other diff because it doesn't seem to be needed!? Going to do some more tests with that stuff. Yep, your branch and "my" rev are pretty similar... took some typo fixes from yours :)
« Last Edit: April 05, 2010, 12:39:14 AM by Azimutz »
 System & Patches: http://goo.gl/i961
 Chameleon:
- trunk builds: http://goo.gl/9G1Hq
- pref pane: http://goo.gl/OL2UT

CEOS

  • Member
  • Posts: 49
@ Azimutz

your modifications look really intresting.
i would like to try it  :)

could you provide a pre compiled boot file ?
My Hackintosh: • Intel Core2Quad Q6600 (g0) • PNY 8800gts 512 (g92) • Gigabyte Ga EP45-DS3R (Rev 1; BIOS v. f11e) • 2x2gb OCZ 1066MHz DDR3 • D-Link DWA 547 RangeBooster N

Drives: • HL-DT-STDVD-RAM GH22LS30  • SAMSUNG HD250HJ : Windows 7 Ultimate x64 • SAMSUNG HD161HJ :  Snow Leopard 10.6.3 • SAMSUNG HD103UJ : Backup

diebuche

  • VoodooLabs
  • Posts: 30
It doesn't add anything in terms of autoRes, but its patched to a more current cham version.
@azimuth, heres the diff between our versions
« Last Edit: March 19, 2010, 09:26:09 PM by diebuche »

lebidou

  • Resident
  • Posts: 133
I made a lots of changes, mainly code cleaning. Links in first post.
Now it doesn't try to patch to native resolution, but turns VESA modes to fit aspect for everyone, including ATI and Intel. It doesn't patch the full modeline for anyone, just the horizontal active and vertical active (with minus one values for NVIDIA). So Id' like to know if it still works for NVIDIA, it shouldn't make a lot of changes for ATI.
Also it doesn't patch modes equal or below 800x600, and corrects the 1400 and 1600 resolution to 1440 and 1680 respectively.

I moved the "reapply" code out from ExecKernel and back to bootcommon, and rearanged it, should be safer. It was likely to produce errors (I hope there is no more hanging, ati.c is untouched).
Most importantly, for coders:
 I renamed the file from 915resolution.c/.h to autoresolution.c/.h because it didn't make sense anymore.
 I moved vendor specific code to files named accordingly: ati_resolution.c/.h nvidia_resolution.c/.h and gma_resolution.c/.h
 I removed lots of little remaining parts of various and vain older trials.
 The getMode function is gone, it's not used any more. cvt calculation is still there, just in case, but will probably be removed.
 The useless stuff in gui.c has been removed.
 I still have to merge shortatombios.h to ati_resolution.h, there is no reason to have two headers when others have one.
 
It won't change lots of stuff but it was beginning to be a real mess, particularly in open_vbios, where code for ATI and NVidia were mixed with code for Intel GMA. Now there is a different function for each of them, in their respective files, the same for set_mode (now patch_vbios, more accurate). The patch_vbios function is rearranged to avoid duplicate code (there is still some). The patch procedure is the same for ATI and Intel, NVidia differs because of the two tables.

It is a bit easier to read (at least, it is for me).

Voilà! I hope it is still working for every one, and that coders will appreciate to know when they're reading code for ATI, Intel, Nvidia or all of them.

P.S. @ Azimutz and diebuche, could you post a diff against my sources so I can upload a better precompiled booter? I attached the whole thing.
« Last Edit: March 20, 2010, 02:47:42 AM by lebidou »

Azimutz

  • VoodooLabs
  • Posts: 420
  • Paranoid Android
Removed stuff about the rev i was working on.

@lebidou, read ya. Will check your changes and post a diff asap.
« Last Edit: April 05, 2010, 12:41:06 AM by Azimutz »
 System & Patches: http://goo.gl/i961
 Chameleon:
- trunk builds: http://goo.gl/9G1Hq
- pref pane: http://goo.gl/OL2UT

Azimutz

  • VoodooLabs
  • Posts: 420
  • Paranoid Android
@lebidou, the diff: Removed; outdated.
« Last Edit: April 05, 2010, 12:41:44 AM by Azimutz »
 System & Patches: http://goo.gl/i961
 Chameleon:
- trunk builds: http://goo.gl/9G1Hq
- pref pane: http://goo.gl/OL2UT

lebidou

  • Resident
  • Posts: 133
Thank you very much. I'll have a look at that tomorrow.

Azimutz

  • VoodooLabs
  • Posts: 420
  • Paranoid Android
It's working, mate :) i went straight to the "normal" pre-compiled, having troubles compiling the sources you posted... i get:
Code: [Select]
gui.c: In function ‘initGUI’:
gui.c:499: warning: unused variable ‘count’
not sure how to fix it!?
« Last Edit: April 05, 2010, 12:42:56 AM by Azimutz »
 System & Patches: http://goo.gl/i961
 Chameleon:
- trunk builds: http://goo.gl/9G1Hq
- pref pane: http://goo.gl/OL2UT

CEOS

  • Member
  • Posts: 49
@ lebidou

don't work here
just show some debug lines, but nothing happens
My Hackintosh: • Intel Core2Quad Q6600 (g0) • PNY 8800gts 512 (g92) • Gigabyte Ga EP45-DS3R (Rev 1; BIOS v. f11e) • 2x2gb OCZ 1066MHz DDR3 • D-Link DWA 547 RangeBooster N

Drives: • HL-DT-STDVD-RAM GH22LS30  • SAMSUNG HD250HJ : Windows 7 Ultimate x64 • SAMSUNG HD161HJ :  Snow Leopard 10.6.3 • SAMSUNG HD103UJ : Backup

lebidou

  • Resident
  • Posts: 133
@Azimutz try "make emdetheme" instead of just "make".

@CEOS, I'll try to fix it.

diebuche

  • VoodooLabs
  • Posts: 30
the latest changes are in the svn. builds fine; works fine for ati; couldn't test nvidia. Attaching boot based on rev118 from trunk & patched with lebidou's
« Last Edit: March 20, 2010, 01:46:14 PM by diebuche »

lebidou

  • Resident
  • Posts: 133
Hopefully, Nvidia is fixed now.

CEOS

  • Member
  • Posts: 49
the latest changes are in the svn. builds fine; works fine for ati; couldn't test nvidia. Attaching boot based on rev118 from trunk & patched with lebidou's
this just give me a blinking cursor.

Hopefully, Nvidia is fixed now.
the bootloader is working again, but the grapic patch not.
resolution is low, something like 800x600...
it says: 0 modes to patch
« Last Edit: March 20, 2010, 02:27:04 PM by CEOS »
My Hackintosh: • Intel Core2Quad Q6600 (g0) • PNY 8800gts 512 (g92) • Gigabyte Ga EP45-DS3R (Rev 1; BIOS v. f11e) • 2x2gb OCZ 1066MHz DDR3 • D-Link DWA 547 RangeBooster N

Drives: • HL-DT-STDVD-RAM GH22LS30  • SAMSUNG HD250HJ : Windows 7 Ultimate x64 • SAMSUNG HD161HJ :  Snow Leopard 10.6.3 • SAMSUNG HD103UJ : Backup

diebuche

  • VoodooLabs
  • Posts: 30
@le bidou
here's ur patch, modified so it can be patched to the the latest cham version...