Jump to content

Guide: Getting NVidia cards to work on Leopard with QE / CI


  • Please log in to reply
21 replies to this topic

#1
Maci

Maci

    InsanelyMac Protégé

  • Just Joined
  • Pip
  • 4 posts
Guide: Getting NVidia cards to work on Leopard with QE / CI

First off props to various people in #leoamd and massive kudos to Gotoh for elaborating on a few bits here and there.

My Install on AMD is up and running courtesy of Prawker's guide Leopard 9A581 on AMD

In this post I'll try to steer you in the right direction to get Geforce 7xxx series cards working on Leopard.
Take note that this guide goes thru the process of simply forcing drivers onto devices by means of ID matching in kernel extensions. This process is generic in that it can be applied for any device that's PCI based be it onboard like an ATA bus or a plug-in PCI device like a network card provided there's a driver of course.

If followed properly you should have QE / CI Acceleration and Dual Head support at the end of it all.

First things you'll need:
- A working Leopard install that atleast boots to framebuffer mode
- A working Tiger install or another OS that will allow you to read out PCI ID's
- (Tiger is nice to have, in case of an emergency and single user boot fails for some odd reason)
- Copy of NVinject 0.1.3 for Leopard (nvinject.free.fr)
- Knowing your way around in Terminal.app is a very big help

Disclaimer:
Most of this is based on my experience over the weekend with getting Leopard to run on my AMD X2 4200+ System that runs of an Albatron KM51PV Nforce 4 based board. Everything noted is how I assume it works deep within the Heart of the Beast and based on what I've read and talked about with various sources. YMMV in how accurate I am. I normally use an MDD G4 and an Mac Pro to earn my daily bread and getting it to run on this X86-based machine has sofar been an amusing experiment on expanding my knowledge of OS X besides doing the usuall POSIX based antics in OS X's UNIX underpinnings. Should your box all of a sudden radiate in a green glow, kill the neighbours dog, or cause any harm being it analog or digital it's not my problem B)

- Let's start off with some obligatory Q&A -

Q: WTF is a framebuffer mode and why do I need it?

A: A Framebuffer is the most basic video display method available that runs off the VBE video standard. Effectively it allows advanced higher resolutions without the need for accelerated video drivers. It's like a safe mode on steroids.

Leopard out of the box kernel panics with the NVidia drivers are active so in order for us to atleast have a framebuffer we need to make sure the NVidia drivers are off so the system is forced to framebuffer mode. This is a big help for people who don't have multiple machines at their dispose and like to read the guide while editing step by step. For you Hardcore POSIX Individuals, by all means go into single user mode and summon the power of VI :)

Q: WTF is a PCI ID and why do I want to know ?

A: Every operating system scans the PCI subsystem to see which devices are present and will then pass this list over to what ever hardware driver manager kit takes care of loading the drivers or kexts in our case. In order to avoid loading an ATI driver on an NVidia card it looks for matching ID's in it's driver library. As soon as the manager sees the Vendor ID "10de" coming by it knows it's dealing with something from NVidia. Then the next step it will do is look at the Device ID which in my case is "0295" for a GeForce 7950 this makes the final detection ID of "0x029510de". With this code it knows to load up Geforce.kext / NVDANV40HAL.kext / NVDAResMan.kext so it can enable full acceleration.

Q: So why won't things work out of the box like it did in Tiger with just adding NVInject / Titan / Natit / etc?

A: It seems that Leopard gets confused on what to do with all the PCI info it gets. From what I've gathered this issue is especially prelevalent for people using NForce boards. Leopard will come accross multiple Nvidia ID's and will try to match up / detect what ever it's got and then do not much at all or confuse the heck out of it self. Which is where this guide comes in.

- We are such Stuff as Dreams are Made Of -

Provided you've met the above requirements and have a booting Leopard and a Tiger as a bonus we shall begin.

First off you'll need your Vendor and Device ID. If you have Tiger this is easy:

- Open up System Profiler
- Click Graphics / Displays

You should see your Vendor ID / Device ID right in front of you split over two lines.
Take note of these as we'll need them.

In windows you should be able to chase up the Vendor ID / Device ID from the Device Manager and hitting up the properties of your card. keep an eye out for "10de" and there's a good chance you'll find your remaining 4 lucky digits.

--

Assuming you've properly patched and added the CPUID's into the NVidia kexts courtesy of Marvin's AMD Utility and various lists that are floating around we can start editing them.

Copy all the GeForce named kext files into /System/Library/Extensions/
Copy all the NVDAResMan.kext and NVDANV40.HAL into /System/Library/Extensions

(NVDANV10/20/30/50 do not apply for the 7xxx Series but you can of course always try to muck around with them if you don't have a 7xxx Series card)

If you want to compare / verify that you got the right kexts compare with the following listings. Open up Terminal.app found in /Applications/Utilities/

Proceed with the following set of commands one by one:

cd /
cd /System/Library/Extensions/
ls -l | grep 'GeForce'
ls -l | grep 'NVDA'

End result should be similar to:

Rawr-Dono:Extensions maci$ ls -l | grep 'GeForce'
drwxr-xr-x  3 root  wheel  102  4 Nov 17:33 GeForce.kext
drwxr-xr-x  3 root  wheel  102  4 Nov 17:33 GeForce2MXGLDriver.bundle
drwxr-xr-x  3 root  wheel  102  4 Nov 17:33 GeForce3GLDriver.bundle
drwxr-xr-x  3 root  wheel  102  4 Nov 17:33 GeForce8xxxGLDriver.bundle
drwxr-xr-x  3 root  wheel  102  4 Nov 17:33 GeForceFXGLDriver.bundle
drwxr-xr-x  3 root  wheel  102  4 Nov 17:33 GeForceGA.plugin
drwxr-xr-x  3 root  wheel  102  4 Nov 17:32 GeForceVADriver.bundle
Rawr-Dono:Extensions maci$ ls -l | grep 'NVDA'
drwxr-xr-x  3 root  wheel  102  4 Nov 17:32 NVDANV40Hal.kext
drwxr-xr-x  3 root  wheel  102  4 Nov 17:32 NVDAResman.kext

Open up your Leopard Hard Drive and go into
System > Library > Extensions

- Geforce.kext -

Right Click (or CTRL + left click) on Geforce.kext and select "Show Package Contents"
Go into the Contents Folder
Open up the Info.plist

Scroll down and look for the following entry:
<key>IOPCIMatch</key>
						<string>0x000010de&0x0000ffff</string>

Here we see "10de" again being NVidia's Vendor ID, the 0000ffff defines a device search range, don't worry about this since we don't need it you'll see this coming up in the other kext we have to edit in larger numbers. Assuming you have an Geforce 7950 replace it with the following

<key>IOPCIMatch</key>
			<string>0x029510de</string>

As you can see with the Device ID + Vendor ID we aquired earlier we have our own magic string now. So effectively we're retargeting the kexts specifically to a device instead of letting leopard do any guess work. 1 down 2 more to go.

And Save.

- NVDANV40HAL.kext -

Right Click (or CTRL + left click) on NVDANV40HAL.kext and select "Show Package Contents"
Go into the Contents Folder
Open up the Info.plist

Scroll down and look for the following entry:
<key>IOPCIPrimaryMatch</key>
						<string>0x004010de&0xfff0ffff 0x00f010de&0xfff0f
fff 0x022010de&0xfff0ffff 0x014010de&0xfff0ffff 0x016010de&0xfff0fff
f 0x009010de&0xfff0ffff 0x01d010de&0xfff0ffff 0x039010de&0xfff0ffff 
0x029010de&0xfff0ffff</string>

As you can see NV40 targets a wide range of cards. replace all of this with your magic string so it looks like this. Once again the ID you see is for my 7950.

<key>IOPCIPrimaryMatch</key>
			<string>0x029510de</string>

And Save.

- NVDAResman.kext -

Right Click (or CTRL + left click) on NVDARedman.kext and select "Show Package Contents"
Go into the Contents Folder
Open up the Info.plist

Scroll down and look for the following entry:
<key>IOPCIPrimaryMatch</key>
						<string>0x011010de&0xfff8ffff 0x017010de&0xfff8f
fff 0x017910de 0x018010de&0xfff8ffff 0x018810de 0x018910de 0x020010de&0x
fff8ffff 0x025010de&0xfff8ffff 0x028010de&0xfff8ffff 0x030010de&0xff
f8ffff 0x031010de&0xfff8ffff 0x031910de 0x034910de</string>

Again we're going to trim it down. Put your own magic string in place.

<key>IOPCIPrimaryMatch</key>
			<string>0x029510de</string>

And Save.

- Taking the path less travelled -

Now we need to make sure that OS X will initialize the kexts right. Open up Terminal.app found in /Applications/Utilities/

Proceed with the following set of commands one by one, ignore the line with the # in front of it.

sudo -s
#Give it your account password for root
cd /System/Library/Extensions
chmod -R 755 * && chown -R root:wheel *
cd ..
rm -r Extensions.mkext
kextcache -a i386 -e

Type exit and close the Terminal.

Now reboot and start hitting F8 furiously so you can change the darwin bootloader.

Now boot your Leopard with -f -v -legacy

- Do I see clearly now the rain has gone ? -

If all is right and your back in OS X you should have a transparant menu bar and if you go into System Preferences > Screen Saver. You should now see Arabesque / Shell / RSS and a host of others pop up (since these run via Core Animation which only works when QE / CI is supported). You should also have full ability to change your resolution and also use multiple displays if your card supports it.

See screenshot here for my current setup running in 1600x1200 perfectly. Screenie

- My glasses... Where are my Glasses! -

So you've gone thru all the effort and still no luck ? here are some pointers to look at.

Make sure your using a recent monitor that supports EDID (some monitors need this turned on manually). This is a system that will tell OS X what kind of monitor you have so it knows what resolutions and settings it can use.
Make sure your using a normal D-SUB (VGA) cable or DVI if your using a LCD panel.
Make sure you have no weird adapters in your video chain. In my particular case I had an old Apple BNC video cable hooked to a Mac > VGA converter and then again into a VGA > DVI plug onto my card. Suffice to say EDID does NOT travel over BNC :)
Make sure you didn't kill the XML syntax <blah> and </blah> see how things are defined, opened, and closed ?

If you've never used your card under Tiger or Leopard and it's a 512MB model, Read up on NVinject's rom modding (Not for the weak of heart) so it's compatible with the Darwin Bootloader
If your card works under Tiger, double check you've got your Vendor ID + Device ID combo right, it's easy to mistype afterall.

Should you find yourself completely locked up and ending up in a kernel panic. Boot up OS X with -s -legacy after it's done you should see -sh3.0#

Proceed as follows:

mount -uw /
mkdir /ExtOff/
mv /System/Library/Extensions/NVDAResman.kext /ExtOff/
rm -r /System/Library/Extensions/Extensions.mkext
cd /
shutdown -r now

Your machine will now reboot and will switch back to framebuffer mode as Geforce.kext and NV40 are depended on NVresman to bring everything up to fullspeed.
Should you still KP then try booting with -f -v -legacy

- I find your lack of faith disturbing... -

If all above fails, there's a chance you may fail at being a noob or do not posess the patience to read something thru.
(Of course I'm willing to except that I've overlooked something I'm human afterall. So they say atleast. :)

Sincerely Yours,

Maci

#2
mattcamp

mattcamp

    InsanelyMac Protégé

  • Just Joined
  • Pip
  • 2 posts
Will this work with an 8600GT, or just 7x00 series?

#3
thomaske

thomaske

    InsanelyMac Protégé

  • Members
  • PipPip
  • 57 posts
when is start up after doing all those things, i get 3 messages
they all say that the .kext files are not installed :wacko: :(

#4
InorganicMatter

InorganicMatter

    InsanelyMac Legend

  • Members
  • PipPipPipPipPipPipPip
  • 523 posts
Wow, I didn't have to do ANY of that on my laptop. It's a Quadro NVS aka 7300GS, and it just worked with full QE/CI right out the shot.

#5
kingroach

kingroach

    InsanelyMac Protégé

  • Members
  • Pip
  • 22 posts
does this method show AGP cards as pci or as AGP. I know Agpgart doesnt woth leopard.. I got my 6800 ultra working just with nvinject with CI/QE but it shows as pci graphics card.

#6
Yun Yuuzhan

Yun Yuuzhan

    InsanelyMac Protégé

  • Members
  • Pip
  • 5 posts
Hello, firstly, really thank you for this excellent guide.

I have an NVidia GeForce 7500 LE and after research on google, my id device may be 0x01dd...10de ... I've done all change in kext files but after the reboot, and after the apple screen, i have a black screen with my cursor, i can move but i don't see anything.

I don't understand where is the problem.. Any Idea ?

#7
andytof47

andytof47

    InsanelyMac Protégé

  • Members
  • PipPip
  • 61 posts
I have just bought two cards one 8600gt which clearly doesn't work (yet) and one 7200gs(However leopard seems to call it a 7300gs for some reason in the System Profiler)

with a device id of 0x01d3 will this work at all????? My wifes going to kill me if I tell her I screewed up two purchases of VGA cards.......


PLEASE TELL ME THERE IS SOMETHING THAT CAN BE DONE>>>>>>>>

Cheers All

#8
Dense

Dense

    InsanelyMac Geek

  • Members
  • PipPipPipPip
  • 230 posts
In Leopard the only file you need to edit is the NVDANVxxHal.kext, you don't need to touch GeForce.kext and NVDAResMan.kext anymore.

#9
andytof47

andytof47

    InsanelyMac Protégé

  • Members
  • PipPip
  • 61 posts

In Leopard the only file you need to edit is the NVDANVxxHal.kext, you don't need to touch GeForce.kext and NVDAResMan.kext anymore.


Ok I have edited the files for my 7200gs but still don't have QE????

I have installed NVinject ------ should I get rid of it???? I thought it was a driver initially but i'm starting to understand the way this works with the more info I gather---- so again do I just delete that particular kext and then it's gone???

Also why did Dense state

In Leopard the only file you need to edit is the NVDANVxxHal.kext, you don't need to touch GeForce.kext and NVDAResMan.kext anymore.


I have edited the files that were available, but I have no NVResMan.kext because I deleted it when I intalled Leopard because I was getting a black screen.... Do I need it???

and Do I need to edit all the files or just the ones Dense said need to be edited ------ ?

Also when I go to the terminal and finally execute
kextcache -a i386 -e
I get an error first saying
kextcache: / locked; waiting for lock
kextcache : proceeeding

then I get
/System/Library/Extensions/GeForce.kext is missing dependencies (including in cache anyway; but may be available elsewhere)
this also happens with
NVDANV10.Hal.kext,
NVDANV20.Hal.kext,
NVDANV30.Hal.kext,
NVDANV40.Hal.kext,
NVDANV50.Hal.kext,

What does this error mean? does it shed light on why i'm not getting QE?

I've been trying to do this for ages and would really appreciate any help..




many thanks

#10
plprado

plprado

    InsanelyMac Geek

  • Members
  • PipPipPip
  • 106 posts

Guide: Getting NVidia cards to work on Leopard with QE / CI

First off props to various people in #leoamd and massive kudos to Gotoh for elaborating on a few bits here and there.

My Install on AMD is up and running courtesy of Prawker's guide Leopard 9A581 on AMD...


First, thanks a lot for sharing your knowledge with us.
Well, I had already done everything exactly how you explained and got my FX5500 working with CI/QE, but NO dual-display or TV-OUT. On the TV, the screen is black, wich means some signal is going there (otherwise it would be blue)... But it is not recognized, as it was in tiger (using Natit 0.1), and theres no dual-display options in system preferences.

Please, can you help me in any way? I have no clue what else I could try. thanks!

#11
andytof47

andytof47

    InsanelyMac Protégé

  • Members
  • PipPip
  • 61 posts
re installed leopard all is well with a 7300gs -_-:):):):)

#12
idividebyzero

idividebyzero

    InsanelyMac Sage

  • Members
  • PipPipPipPipPip
  • 374 posts
You forgot to mention what to do with NVinject. You just say that you need a copy of it but then dont mention it again or how to install it.

#13
dafart

dafart

    InsanelyMac Protégé

  • Members
  • Pip
  • 16 posts
Yeah it should also be mentioned that you do the following:
NVInject guide: http://nvinject.free...ewtopic.php?t=4

#14
mpir

mpir

    InsanelyMac Protégé

  • Members
  • Pip
  • 17 posts
Hello, first of all I want to thank all the people helping around here.

Yesterday I posted in another thread regarding my 7600gt XFX video card, and later came around this thread.

I tried following the instructions given here regarding the NVinject.kext, but when trying to setup permissions with terminal in sudo su mode I was denied to do so even though I was logged in as the administrator.

So I decided to try with Natit and editing the Geforce.kext, NVDANV40HAL.kext and NVDAResman.kext manually like described, so now when booting with -f -v -legacy I am able to get my dual screen working (tried to do the same giving the NVinject.kext permissions manually but it didn't work either).

And here is my question, is there a way to bypass the -f -v -legacy process when booting?

I tried this too at the end when doing the NVinject.kext thing:

sudo -s
#Give it your account password for root
cd /System/Library/Extensions
chmod -R 755 * && chown -R root:wheel *
cd ..
rm -r Extensions.mkext
kextcache -a i386 -e

but was denied permission several times too with the commands again.


Well, if anyone can help me it would be really great, because I want to do a fresh set-up in this new machine. The Tiger I am using was done in a different computer, and gets kinda slow from time to time.

Thx

#15
used003

used003

    InsanelyMac Protégé

  • Members
  • Pip
  • 8 posts
  • Location:grand rapids, mi
  • Interests:painting, linux and general computer stuffs
and what about a geforce 6150??

#16
fayze

fayze

    InsanelyMac Geek

  • Members
  • PipPipPip
  • 174 posts
  • Gender:Male
@ Maci

Thanks for the post, worked perfect for my 7900 GT. full QE/CI now.

#17
justinvathje

justinvathje

    InsanelyMac Protégé

  • Just Joined
  • Pip
  • 4 posts
did everything like you said and now everything is clear! i cant see the text. what do i do?

#18
exoxe

exoxe

    InsanelyMac Protégé

  • Just Joined
  • Pip
  • 3 posts
and what about a geforce 6150??

I cant drive my 6150 le

#19
jhunter

jhunter

    InsanelyMac Protégé

  • Members
  • Pip
  • 5 posts
AMD Athlon64 4000+
NVIDIA 7900 GS 256MB RAM
MSI K8N-Neo4
2 GB RAM
Zephyroth Leopard 10.5.2

Install was perfect. Everything was running smoothly with the exception of my lack of Quartz Extreme, which I need to run Final Cut Studio 2. I did everything in this tutorial, and after reboot, my USB mouse and USB keyboard are frozen. Is there anything I do besides reinstall?

EDIT: After taking another stab at editing the .plist files, I realized my error. I was mistakingly adding ONLY my device ID to the lists. NVDANV40Hal.kext and NVDAResman.kext have a string of characters after the device ID that are crucial for the system to work. My bad.

#20
csir

csir

    InsanelyMac Protégé

  • Members
  • Pip
  • 9 posts
Maci Thank you. After pulling hairs for the best part of two days I got CI/QE working perfect, luckily everything else worked out the box.

I have one problem. On restarting my pc (after all is working) I got a hold button down to restart PC screen. Looked like a picture loaded into frame buffer. Few translations on the screen too.

Did that and get a blank screen now. I followed your guide to the dot. Any ideas to what I am doing wrong or possible problem?





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

© 2014 InsanelyMac  |   News  |   Forum  |   Downloads  |   OSx86 Wiki  |   Mac Netbook  |   PHP hosting by CatN  |   Designed by Ed Gain  |   Logo by irfan  |   Privacy Policy