Jump to content

Enable nVidia drivers


  • Please log in to reply
28 replies to this topic

#1
oldnapalm

oldnapalm

    InsanelyMac V.I.P.

  • Moderators
  • 6,858 posts
  • Gender:Male
  • Location:Brazil
You can use a patch to enable nVidia drivers by injecting the needed properties in DSDT.

Posted Image

Please see this topic for more information about device-properties
http://www.insanelym...howtopic=228733

To find out where to insert the patch, you can use IORegistryExplorer.

Posted Image

Sample code to be inserted (into P0P2 in the above example)
Device (GFX0)                {                    Name (_ADR, Zero)                    Method (_DSM, 4, NotSerialized)                    {                        Store (Package ()                            {                                "@0,compatible",                                 Buffer ()                                {                                    "NVDA,NVMac"                                },                                 "@0,device_type",                                 Buffer ()                                {                                    "display"                                },                                 "@0,name",                                 Buffer ()                                {                                    "NVDA,Display-A"                                },                                 "@1,compatible",                                 Buffer ()                                {                                    "NVDA,NVMac"                                },                                 "@1,device_type",                                 Buffer ()                                {                                    "display"                                },                                 "@1,name",                                 Buffer ()                                {                                    "NVDA,Display-B"                                },                                 "NVCAP",                                 Buffer ()                                {                                    /* 0000 */    0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00,                                     /* 0008 */    0x1C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0A,                                     /* 0010 */    0x00, 0x00, 0x00, 0x00                                },                                 "NVPM",                                 Buffer ()                                {                                    /* 0000 */    0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,                                     /* 0008 */    0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,                                     /* 0010 */    0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,                                     /* 0018 */    0x00, 0x00, 0x00, 0x00                                },                                 "VRAM,totalsize",                                 Buffer ()                                {                                    0x00, 0x00, 0x00, 0x20                                },                                 "device_type",                                 Buffer ()                                {                                    "NVDA,Parent"                                },                                 "model",                                 Buffer ()                                {                                    "nVidia GeForce 9800 GTX"                                },                                 "rom-revision",                                 Buffer ()                                {                                    "nVidia GeForce 9800 GTX OpenGL Engine"                                }                            }, Local0)                        DTGP (Arg0, Arg1, Arg2, Arg3, RefOf (Local0))                        Return (Local0)                    }                }

In some motherboards the device where GFX0 resides is not present in DSDT, so you need to insert it as well (into PCI0)
Device (PEG1)
			{
				Name (_ADR, 0x00010000)
				Device (GFX0)
				{
					... same as above
				}
			}

Sample patches to be applied using DSDT Editor:

Asus motherboards
Attached File  nVidia_9800_GTX_512_MB.txt   2.59KB   213 downloads
Gigabyte motherboards
Attached File  nVidia_9600_GT_1GB_PCI0.txt   3.45KB   224 downloads

#2
.::Fabio::.

.::Fabio::.

    InsanelyMac Legend

  • Moderators
  • 8,901 posts
  • Gender:Male
  • Location:Italy
Hello I can explain how you have to compile the dsdt video card.
To be precise this part, I point out your example for the marked in red.
I apologize for English.

                               "NVCAP", 
Buffer ()
{
/* 0000 */ 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00,
/* 0008 */ 0x1C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0A,
/* 0010 */ 0x00, 0x00, 0x00, 0x00
},

"NVPM",
Buffer ()
{
/* 0000 */ 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
/* 0008 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
/* 0010 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
/* 0018 */ 0x00, 0x00, 0x00, 0x00
},

"VRAM,totalsize",
Buffer ()
{
0x00, 0x00, 0x00, 0x20
}, [/color]

"device_type",
Buffer ()
{
"NVDA,Parent"
},

"model",
Buffer ()
{
"nVidia GeForce 9800 GTX"
},

"rom-revision",
Buffer ()
{
"nVidia GeForce 9800 GTX OpenGL Engine"
}
}, Local0)
DTGP (Arg0, Arg1, Arg2, Arg3, RefOf (Local0))
Return (Local0)
}
}
_linenums:0'>Device (GFX0) { Name (_ADR, Zero) Method (_DSM, 4, NotSerialized) { Store (Package () { "@0,compatible", Buffer () { "NVDA,NVMac" }, "@0,device_type", Buffer () { "display" }, "@0,name", Buffer () { "NVDA,Display-A" }, "@1,compatible", Buffer () { "NVDA,NVMac" }, "@1,device_type", Buffer () { "display" }, "@1,name", Buffer () { "NVDA,Display-B" }, "NVCAP", Buffer () { /* 0000 */ 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, /* 0008 */ 0x1C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0A, /* 0010 */ 0x00, 0x00, 0x00, 0x00 }, "NVPM", Buffer () { /* 0000 */ 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0008 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0010 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0018 */ 0x00, 0x00, 0x00, 0x00 }, "VRAM,totalsize", Buffer () { 0x00, 0x00, 0x00, 0x20 }, [/color] "device_type", Buffer () { "NVDA,Parent" }, "model", Buffer () { "nVidia GeForce 9800 GTX" }, "rom-revision", Buffer () { "nVidia GeForce 9800 GTX OpenGL Engine" } }, Local0) DTGP (Arg0, Arg1, Arg2, Arg3, RefOf (Local0)) Return (Local0) } }

Thank you

#3
MacFanatic76

MacFanatic76

    InsanelyMac Protégé

  • Members
  • PipPip
  • 62 posts
  • Gender:Male
Thanx for sharing, Oldnapalm !

But, what about the situation we now have - Chameleon includes already
an automatic power management and graphics card detection,
are EFI-strings, kext-injectors and your way through DSDT obsolete methods ?

Thanx in advance for a clarification.

Cheers

#4
oldnapalm

oldnapalm

    InsanelyMac V.I.P.

  • Moderators
  • 6,858 posts
  • Gender:Male
  • Location:Brazil
@iFabios71

Sorry, I don't understand your question. Please note this is only a sample and values are not valid for all cards.


@MacFanatic76

If you use Chameleon's GraphicsEnabler you don't need EFI strings or this DSDT method, this is only a sample I posted as part of this basic nVidia injection guide. It may be useful in other situations, like if you are booting Lion with a boot loader that doesn't have the GraphicsEnabler feature (XPC, iBoot).

#5
MacFanatic76

MacFanatic76

    InsanelyMac Protégé

  • Members
  • PipPip
  • 62 posts
  • Gender:Male
Great, thanx again, Oldnapalm !

#6
buoo

buoo

    The Prodigal Son

  • Moderators
  • 4,541 posts
  • Gender:Male
  • Location:Italy

Hello I can explain how you have to compile the dsdt video card.
To be precise this part, I point out your example for the marked in red.
I apologize for English.

                               "NVCAP", 
Buffer ()
{
/* 0000 */ 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00,
/* 0008 */ 0x1C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0A,
/* 0010 */ 0x00, 0x00, 0x00, 0x00
},

"NVPM",
Buffer ()
{
/* 0000 */ 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
/* 0008 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
/* 0010 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
/* 0018 */ 0x00, 0x00, 0x00, 0x00
},

"VRAM,totalsize",
Buffer ()
{
0x00, 0x00, 0x00, 0x20
},

"device_type",
Buffer ()
{
"NVDA,Parent"
},

"model",
Buffer ()
{
"nVidia GeForce 9800 GTX"
},

"rom-revision",
Buffer ()
{
"nVidia GeForce 9800 GTX OpenGL Engine"
}
}, Local0)
DTGP (Arg0, Arg1, Arg2, Arg3, RefOf (Local0))
Return (Local0)
}
}
_linenums:0'>Device (GFX0) { Name (_ADR, Zero) Method (_DSM, 4, NotSerialized) { Store (Package () { "@0,compatible", Buffer () { "NVDA,NVMac" }, "@0,device_type", Buffer () { "display" }, "@0,name", Buffer () { "NVDA,Display-A" }, "@1,compatible", Buffer () { "NVDA,NVMac" }, "@1,device_type", Buffer () { "display" }, "@1,name", Buffer () { "NVDA,Display-B" }, "NVCAP", Buffer () { /* 0000 */ 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, /* 0008 */ 0x1C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0A, /* 0010 */ 0x00, 0x00, 0x00, 0x00 }, "NVPM", Buffer () { /* 0000 */ 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0008 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0010 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* 0018 */ 0x00, 0x00, 0x00, 0x00 }, "VRAM,totalsize", Buffer () { 0x00, 0x00, 0x00, 0x20 }, "device_type", Buffer () { "NVDA,Parent" }, "model", Buffer () { "nVidia GeForce 9800 GTX" }, "rom-revision", Buffer () { "nVidia GeForce 9800 GTX OpenGL Engine" } }, Local0) DTGP (Arg0, Arg1, Arg2, Arg3, RefOf (Local0)) Return (Local0) } }

Thank you


Hi Fabios :D

• You can read the NVCAP from IORegistry

Posted Image


• The NVPM is the same for every Nvidia Cards:

/* 0000 */	0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
/* 0008 */	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
/* 0010 */	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
/* 0018 */	0x00, 0x00, 0x00, 0x00



• Instead the VRAM depends of RAM of the card

512MB
0x00, 0x00, 0x00, 0x20

1GB
0x00, 0x00, 0x00, 0x40

1,5GB
0x00, 0x00, 0x00, 0x60


• In the end you can add the reg to complete your work

Posted Image

"reg", 
					Buffer (0x78)
					{
						/* 0000 */	0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 
						/* 0008 */	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
						/* 0010 */	0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x01, 0x02, 
						/* 0018 */	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
						/* 0020 */	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 
						/* 0028 */	0x14, 0x00, 0x01, 0x42, 0x00, 0x00, 0x00, 0x00, 
						/* 0030 */	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
						/* 0038 */	0x00, 0x00, 0x00, 0x10, 0x1C, 0x00, 0x01, 0x02, 
						/* 0040 */	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
						/* 0048 */	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 
						/* 0050 */	0x24, 0x00, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 
						/* 0058 */	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
						/* 0060 */	0x80, 0x00, 0x00, 0x00, 0x30, 0x00, 0x01, 0x02, 
						/* 0068 */	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
						/* 0070 */	0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00
					}
				}, Local0)
			DTGP (Arg0, Arg1, Arg2, Arg3, RefOf (Local0))


#7
.::Fabio::.

.::Fabio::.

    InsanelyMac Legend

  • Moderators
  • 8,901 posts
  • Gender:Male
  • Location:Italy
Thank you for your reply and sorry if I have not answered before

#8
Romker

Romker

    InsanelyMac Protégé

  • Members
  • Pip
  • 15 posts
  • Gender:Male
  • Location:Moscow, Zimbabve
Please attach full *.dsl (disassembled dsdt.aml file) file for example (tnx).
I already have information in P0P2 section. New section overwritten old info, or add to the end of section?
Code, present in DSDT:
Device (P0P2)
			{
				Name (_ADR, 0x00010000)
				Method (_PRW, 0, NotSerialized)
				{
					Return (GPRW (0x09, 0x04))
				}

				Method (_PRT, 0, NotSerialized)
				{
					If (PICM)
					{
						Return (AR02)
					}

					Return (PR02)
				}
			}
Thanx.
My DSDT in attachment.

Attached Files



#9
oldnapalm

oldnapalm

    InsanelyMac V.I.P.

  • Moderators
  • 6,858 posts
  • Gender:Male
  • Location:Brazil
Add to the end of section (make sure your video device is under P0P2)
Attached File  dsdt.dsl.zip   30.21KB   43 downloads

#10
Romker

Romker

    InsanelyMac Protégé

  • Members
  • Pip
  • 15 posts
  • Gender:Male
  • Location:Moscow, Zimbabve

Add to the end of section (make sure your video device is under P0P2)
Attached File  dsdt.dsl.zip   30.21KB   43 downloads

Big Thanx, Comrade.
But no full resolution and OpenGL not present :(.

#11
LatinMcG

LatinMcG

    Insanely digesting DSDT

  • Members
  • PipPipPipPipPipPipPipPipPipPipPip
  • 2,509 posts
  • Gender:Male
  • Location:Tampa, Florida
i believe it might be the pciroot 1 or 0 ? hmm in dsdt the Device (PCI0)
does it have _ADR and _UID ? or one or the other.. is it 1 or zero ?

sometimes its best to see where the graphiccs card is with ioregistryexplorer

#12
Romker

Romker

    InsanelyMac Protégé

  • Members
  • Pip
  • 15 posts
  • Gender:Male
  • Location:Moscow, Zimbabve
I think PCIRoot=0.
Pix in attachment.
Full file here.

Attached Files



#13
bergoulle

bergoulle

    InsanelyMac Protégé

  • Members
  • PipPip
  • 82 posts
  • Gender:Male
Thank's. 100% working for Asus EN8600 GT 256.

#14
krypto

krypto

    InsanelyMac Protégé

  • Members
  • PipPip
  • 58 posts
Need help adding this for Nvidia GTX 560 , will the same Method work ?

#15
Riley Freeman

Riley Freeman

    InsanelyMac Legend

  • Members
  • PipPipPipPipPipPipPip
  • 935 posts
  • Gender:Male
  • Location:The Streets
I had my GTX 460 working fine with GraphicsEnabler but seeing as I'm already loading a DSDT I figured it'd be no harm to use this method instead. It works fine but there's one minor (cosmetic) difference. The PCIe slot isn't listed in System Profiler. Here's how it looks with GraphicEnabler

Posted Image

I figure this could be done by adding the "Slot-1" entry to PEG1, but I'm not savvy enough with DSDT editing to figure out how to do this yet.

#16
oldnapalm

oldnapalm

    InsanelyMac V.I.P.

  • Moderators
  • 6,858 posts
  • Gender:Male
  • Location:Brazil
I guess you have to add

                                "AAPL,slot-name", 
                                Buffer ()
                                {
                                    "Slot-1"
                                }, 


#17
Riley Freeman

Riley Freeman

    InsanelyMac Legend

  • Members
  • PipPipPipPipPipPipPip
  • 935 posts
  • Gender:Male
  • Location:The Streets
Yep I was just going to reply with that. I'm getting better at this stuff :)

"AAPL,slot-name",
								Buffer (0x07)
								{
									"Slot-1"
								}

I thought it might have to go under PEG1, but it's actually under GFX0.

Adding this also makes the card show up under PCI Cards. Without this it doesn't.

#18
Maroc-OS

Maroc-OS

    InsanelyMac Protégé

  • Members
  • Pip
  • 29 posts
  • Gender:Male
  • Location:Casablanca, Casablanca, Morocco
  • Interests:P5KPL-AM SE
see here : http://www.insanelym...dpost&p=1792180

#19
Riley Freeman

Riley Freeman

    InsanelyMac Legend

  • Members
  • PipPipPipPipPipPipPip
  • 935 posts
  • Gender:Male
  • Location:The Streets
This silly Slot-1 thing has reared it's head again. I'm on a new board and try as I might i can't get it to change the slot name from PCIEX1_1 (which is wrong anyway as it's in the PCIEX16_1 slot) to Slot-1. Chameleon's graphics enabler can do it just fine, but the DSDT edit doesn't.

#20
Rampage Dev

Rampage Dev

    InsanelyMac Deity

  • Local Moderators
  • 2,074 posts
  • Gender:Male
  • Interests:AKern@RampageDev.com

This silly Slot-1 thing has reared it's head again. I'm on a new board and try as I might i can't get it to change the slot name from PCIEX1_1 (which is wrong anyway as it's in the PCIEX16_1 slot) to Slot-1. Chameleon's graphics enabler can do it just fine, but the DSDT edit doesn't.


We are all cosmetic nuts.





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