Jump to content
Andy Vandijck

Decompiled original Apple DSDTs

134 posts in this topic

Recommended Posts

Currently collected:

-iMac5,1

-iMac7,1

-iMac8,1

-MacPro3,1

-MacBook2,1

-MacBook3,1

-MacBook4,1

-MacBookPro5,1

-MacBookAir1,1

 

These could be used for fixing up your devices.

I've used this to enable the Apple ACPI Power adapter to attach properly on the power supply of my Packard Bell EasyNote MZ-35 200 notebook.

You can also add for example the backlight control (APP0003 I think) and then it will enable the driver + control.

Many more is possible...

 

Like I say, a manual DSDT fix saves the day...

 

Enjoy and feast your eyes.

 

NOTE: Any other genuine Mac IORegistryExplorer saves (.ioreg files) are welcome, I can use these for more stuff like this...

If you don't have IORegistryExplorer (from XCode, preferred dump format) please make the dump with the following four commands:

 

echo "IOService:" > [MACHINE_ID].txt

 

ioreg -l -p IOService -w 99999 >> [MACHINE_ID].txt

 

echo "IODeviceTree:" >> [MACHINE_ID].txt

 

ioreg -l -p IODeviceTree -w 99999 >> [MACHINE_ID].txt

 

This will ensure all of the for various things needed data is there...

 

Also added my ioreg files...

Currently collected:

-iMac5,1

-iMac7,1

-iMac10,1

-iMac11,1

-Macmini1,1

-Macmini2,1

-Macmini3,1

-MacPro3,1

-MacPro4,1

-MacPro5,1

-MacBook1,1

-MacBook2,1

-MacBook3,1

-MacBook4,1

-MacBook5,2

-MacBook6,1

-MacBookPro4,1

-MacBookPro5,1

-MacBookPro5,2

-MacBookPro5,3

-MacBookPro5,4

-MacBookPro5,5

-MacBookPro6,1

-MacBookAir1,1

-MacBookAir2,1

More models have been added... (rapidshare link listed below).

http://rapidshare.com/files/432521215/ioregs_collection.zip

MP_3_1_DSDT.dsl.zip

MBP_5_1_DSDT.dsl.zip

IM_5_1_DSDT.dsl.zip

MB_3_1_DSDT.dsl.zip

MB_4_1_DSDT.dsl.zip

IM_7_1_DSDT.dsl.zip

MB_2_1_DSDT.dsl.zip

MBA_1_1_DSDT.dsl.zip

ioregs.part01.sitx

ioregs.part02.sitx

IM_8_1_DSDT.dsl.zip

MachineInfo.rtf

Share this post


Link to post
Share on other sites
Advertisement

Hey!! Thanks for that Andy !

It's gonna be useful for sure !

 

Genuine Mac IORegistryExplorer saves could be great as well !

 

bye.

Share this post


Link to post
Share on other sites
Hi, go here (post #7) ... I´ve attached a few ssdt & dsdt tables from real macs. If you want the ioregs let me know...

 

Sure, I could use any of those IORegs...

Note: I'll be adding more stuff as I move along.

It's only gonna take a bit of time and right now I (unfortunetely) don't have any.

Thanks in advance

Share this post


Link to post
Share on other sites

Good stuff, thanks Andy and roisoft!

 

It would be nice if this data was logged somewhere for easy retrieval.

Share this post


Link to post
Share on other sites
These could be used for fixing up your devices.

I've used this to enable the Apple ACPI Power adapter to attach properly on the power supply of my Packard Bell EasyNote MZ-35 200 notebook.

You can also add for example the backlight control (APP0003 I think) and then it will enable the driver + control.

 

NOTE: Any other genuine Mac IORegistryExplorer saves (.ioreg files) are welcome, I can use these for more stuff like this...

 

I wonder if there was a guide for this, to know how did you enable Apple ACPI Power and backlight control... And many other tricks, i've searched a lot of times but never understand where you find those tricks (linux forums ?)

A little guide about the possibilities and a quick mini howto to let DSDT newbies on the good way could be great...

 

Have we just to add some mac ioreg entries in our DSDT ?

Share this post


Link to post
Share on other sites

hey andy, I already enabled the backlight control via dsdt (app0002). however, this only made the backlight control bar appear in system preferences/display, but it had no effect on the actual backlight control that btw actually works on my laptop, but without showing the backlight meter on the screen when I use it... when I increase it or decrease it via system preferences nothing happens

 

any idea on how to link the two things and make the backlight controllable in system preferences? I attach my already patched dsdt, cheers :)

 

PS: could you post the modifications you made to your dsdt? for example, I tried emulating smc device by copying and pasting the mbp code but it made the system unbootable, now I asked the code to fassl and it works but I wouldn't have been able to modify it by myself

hpet_fixed.txt

Share this post


Link to post
Share on other sites
I've recently decompiled the DSDTs of a:

- MacPro3,1

- MacBookPro5,1

- iMac5,1

 

These could be used for fixing up your devices.

I've used this to enable the Apple ACPI Power adapter to attach properly on the power supply of my Packard Bell EasyNote MZ-35 200 notebook.

You can also add for example the backlight control (APP0003 I think) and then it will enable the driver + control.

Many more is possible...

 

Like I say, a manual DSDT fix saves the day...

 

Enjoy and feast your eyes.

 

NOTE: Any other genuine Mac IORegistryExplorer saves (.ioreg files) are welcome, I can use these for more stuff like this...

 

 

At least let us your modded dsdt please...

Share this post


Link to post
Share on other sites

andy, I quote this from another topic.. do you think it could be possible to get these cameras to work via some mods in dsdt?

 

CHICONY WEBCAM USERS read this

 

I think we are looking at the wrong place. At least for chicony cameras. This is the deal. I have one of those viewsonic 22 inch monitors with the built in webcams. This thing works, Plug and play. I have a Gateway Laptop with a built in camera, this one doesn't work unless I use camtwist. This solution sort of okey, but there is one small problem. It introduces a 2-4 second lag on the video. Still from this I conclude that my camera CAN work in Leopard, and it is just a small detail that is keeping me from making it work. So why am I so excited? Continue reading.

 

I started comparing the working webcam from my viewsonic monitor, and my gateway laptop camera. Guess what they are basically the same chicony camera. Both of them are chicony Id Vendor "1226" or "0x042f" both have the same stats basically the only difference is the Product id Number: "45095" or "0xb027" for the gateway and "45089" or "0xb021" for the viewsonic. Usually such a small difference in id numbers means they are practically the same thing and the same driver. The only other difference is the bcdDevice number "37668" for gateway "852" for the viewsonic.

 

In other things I have hacked in Leopard to make things work, I basically go for the driver, modify the Ids to make them work, and presto I get a working device. Here is where I have hit a snag. According to ioreg, the drivers that are making the web cam work in the viewsonic are IOUSBCompositeDrvier.kext which is part of the the IOUSBFamily.kext and IOUSBLIb.bundle which is also under the IOUSBFamily.kext. The IOUSBCompositeDriver.kext has the correct ids. The problem is that the IOUSBLib.bundle has no ids to move or fix.

 

I feel I am so close to this, but I have hit a wall. Anyone know the difference between a bundle and a kext, and how would one go to modify ids on it. I am pretty sure this is the place to look at, at least for chicony (which is a large amount of the webcams in laptops)

 

Here are the relevant parts of the IOreg, to see if some one can make sense out of it.

 

For the working Viewsonic webcam

 

| | | +-o ViewSonic 1.3M, USB2.0 Webcam@fa200000 <class IOUSBDevice, registered, matched, active, busy 0, retain 9>
| | | | {
| | | | "PortNum" = 2
| | | | "Bus Power Available" = 250
| | | | "bNumConfigurations" = 1
| | | | "Device Speed" = 2
| | | | "sessionID" = 294705983020785
| | | | "USB Product Name" = "ViewSonic 1.3M, USB2.0 Webcam"
| | | | "bcdDevice" = 852
| | | | "locationID" = 18446744073610985472
| | | | "USB Vendor Name" = "Chicony Electronics Co., Ltd."
| | | | "USB Address" = 2
| | | | "idProduct" = 45089
| | | | "iProduct" = 1
| | | | "bDeviceProtocol" = 1
| | | | "iManufacturer" = 2
| | | | "IOCFPlugInTypes" = {"9dc7b780-9ec0-11d4-a54f-000a27052861"="IOUSBFamily.kext/Contents/PlugIns/IOUSBLib.bundle"}
| | | | "bDeviceClass" = 239
| | | | "iSerialNumber" = 3
| | | | "bMaxPacketSize0" = 64
| | | | "IOUserClientClass" = "IOUSBDeviceUserClientV2"
| | | | "bDeviceSubClass" = 2
| | | | "IOGeneralInterest" = "IOCommand is not serializable"
| | | | "idVendor" = 1266
| | | | "USB Serial Number" = "SN0001"
| | | | }
| | | |
| | | +-o IOUSBCompositeDriver <class IOUSBCompositeDriver, !registered, !matched, active, busy 0, retain 4>
| | | | {
| | | | "IOProviderClass" = "IOUSBDevice"
| | | | "IOProbeScore" = 60000
| | | | "bDeviceProtocol" = 1
| | | | "CFBundleIdentifier" = "com.apple.driver.AppleUSBComposite"
| | | | "bDeviceClass" = 239
| | | | "IOMatchCategory" = "IODefaultMatchCategory"
| | | | "bDeviceSubClass" = 2
| | | | "IOClass" = "IOUSBCompositeDriver"
| | | | }
| | | |
| | | +-o ViewSonic 1.3M, USB2.0 Webcam@0 <class IOUSBInterface, registered, matched, active, busy 0, retain 5>
| | | | {
| | | | "bInterfaceProtocol" = 0
| | | | "locationID" = 18446744073610985472
| | | | "bcdDevice" = 852
| | | | "bConfigurationValue" = 1
| | | | "iInterface" = 1
| | | | "idProduct" = 45089
| | | | "IOCFPlugInTypes" = {"2d9786c6-9ef3-11d4-ad51-000a27052861"="IOUSBFamily.kext/Contents/PlugIns/IOUSBLib.bundle"}
| | | | "bInterfaceSubClass" = 1
| | | | "bAlternateSetting" = 0
| | | | "IOUserClientClass" = "IOUSBInterfaceUserClientV2"
| | | | "bInterfaceClass" = 14
| | | | "bInterfaceNumber" = 0
| | | | "bNumEndpoints" = 1
| | | | "idVendor" = 1266
| | | | }
| | | |
| | | +-o IOUSBInterface@1 <class IOUSBInterface, registered, matched, active, busy 0, retain 5>
| | | {
| | | "bInterfaceProtocol" = 0
| | | "locationID" = 18446744073610985472
| | | "bcdDevice" = 852
| | | "bConfigurationValue" = 1
| | | "iInterface" = 0
| | | "idProduct" = 45089
| | | "IOCFPlugInTypes" = {"2d9786c6-9ef3-11d4-ad51-000a27052861"="IOUSBFamily.kext/Contents/PlugIns/IOUSBLib.bundle"}
| | | "bInterfaceSubClass" = 2
| | | "bAlternateSetting" = 0
| | | "IOUserClientClass" = "IOUSBInterfaceUserClientV2"
| | | "bInterfaceClass" = 14
| | | "bInterfaceNumber" = 1
| | | "bNumEndpoints" = 0
| | | "idVendor" = 1266
| | | }

 

For the none working Gateway laptop Webcam

 

| | | | +-o Gateway USB 2.0 Webcam@fa300000 <class IOUSBDevice, registered, matched, active, busy 0, retain 9>
| | | | | {
| | | | | "bNumConfigurations" = 1
| | | | | "sessionID" = 28830128290301
| | | | | "bcdDevice" = 37668
| | | | | "USB Address" = 2
| | | | | "iProduct" = 1
| | | | | "bDeviceClass" = 239
| | | | | "bMaxPacketSize0" = 64
| | | | | "IOUserClientClass" = "IOUSBDeviceUserClientV2"
| | | | | "idVendor" = 1266
| | | | | "PortNum" = 3
| | | | | "Bus Power Available" = 250
| | | | | "Device Speed" = 2
| | | | | "USB Product Name" = "Gateway USB 2.0 Webcam"
| | | | | "Requested Power" = 250
| | | | | "locationID" = 18446744073612034048
| | | | | "USB Vendor Name" = "Chicony Electronics Co., Ltd."
| | | | | "idProduct" = 45095
| | | | | "bDeviceProtocol" = 1
| | | | | "iManufacturer" = 2
| | | | | "IOCFPlugInTypes" = {"9dc7b780-9ec0-11d4-a54f-000a27052861"="IOUSBFamily.kext/Contents/PlugIns/IOUSBLib.bundle"}
| | | | | "iSerialNumber" = 3
| | | | | "IOGeneralInterest" = "IOCommand is not serializable"
| | | | | "bDeviceSubClass" = 2
| | | | | "Low Power Displayed" = No
| | | | | "USB Serial Number" = "SN0001"
| | | | | }
| | | | |
| | | | +-o IOUSBCompositeDriver <class IOUSBCompositeDriver, !registered, !matched, active, busy 0, retain 4>
| | | | | {
| | | | | "IOProviderClass" = "IOUSBDevice"
| | | | | "IOProbeScore" = 60000
| | | | | "bDeviceProtocol" = 1
| | | | | "CFBundleIdentifier" = "com.apple.driver.AppleUSBComposite"
| | | | | "bDeviceClass" = 239
| | | | | "IOMatchCategory" = "IODefaultMatchCategory"
| | | | | "bDeviceSubClass" = 2
| | | | | "IOClass" = "IOUSBCompositeDriver"
| | | | | }
| | | | |
| | | | +-o Gateway USB 2.0 Webcam@0 <class IOUSBInterface, registered, matched, active, busy 0, retain 5>
| | | | | {
| | | | | "IOUserClientCrossEndianCompatible" = No
| | | | | "bInterfaceProtocol" = 0
| | | | | "bcdDevice" = 37668
| | | | | "locationID" = 18446744073612034048
| | | | | "bConfigurationValue" = 1
| | | | | "iInterface" = 1
| | | | | "idProduct" = 45095
| | | | | "IOCFPlugInTypes" = {"2d9786c6-9ef3-11d4-ad51-000a27052861"="IOUSBFamily.kext/Contents/PlugIns/IOUSBLib.bundle"}
| | | | | "bInterfaceSubClass" = 1
| | | | | "bAlternateSetting" = 0
| | | | | "IOUserClientClass" = "IOUSBInterfaceUserClientV2"
| | | | | "IOGeneralInterest" = "IOCommand is not serializable"
| | | | | "USB Interface Name" = "Gateway USB 2.0 Webcam"
| | | | | "bInterfaceClass" = 14
| | | | | "bInterfaceNumber" = 0
| | | | | "bNumEndpoints" = 1
| | | | | "idVendor" = 1266
| | | | | }
| | | | |

 

Here is hoping for someone that can make sense of this, we are closer than we think.

Share this post


Link to post
Share on other sites
At least let us your modded dsdt please...

Here, not complete yet though...

It's for a Packard Bell EasyNote MZ-35 200...

Use as template...

DSDT.dsl.zip

Share this post


Link to post
Share on other sites
I've used this to enable the Apple ACPI Power adapter to attach properly on the power supply of my Packard Bell EasyNote MZ-35 200 notebook.

 

Thanks for the file... Don't know what you have change to enable ACPI Power adapter, just in BAT0 ???

Share this post


Link to post
Share on other sites
Here, not complete yet though...

It's for a Packard Bell EasyNote MZ-35 200...

Use as template...

 

Andy,

 

Thanks for the DSDT file, but if you could post your unmodified one here we could see exactly what you have done ! An ioreg in addition to that will be great.

 

I'm actualy working on the DSDT of the MSi Wind. I now have GFX and HDA injection via DSDT and i've also fixed the "LID0" in order to replace ClamShellDisplay.kext. :)

 

I'm now trying to get rid VoodooBattery.kext. Is it what you've meant when you say :

 

I've used this to enable the Apple ACPI Power adapter to attach properly on the power supply of my Packard Bell EasyNote MZ-35 200 notebook.

 

Bye.

Share this post


Link to post
Share on other sites
i've also fixed the "LID0" in order to replace ClamShellDisplay.kext. :)

 

Wow how did you do that ???? I've watched MPB dsdt, there si LID0 but not LID as in my dsdt, do i have just to change LID to LID0 to make it work ???

 

EDIT:No change.

 

I'm now trying to get rid VoodooBattery.kext.

 

Same combat.

Share this post


Link to post
Share on other sites

Wiwi,

 

It's not a matter of device name, i think it's only cosmetics. This is what i have done :

 

- Original DSDT

		Device (LID0)
	{
		Name (_HID, EisaId ("PNP0C0D"))
		Name (_PRW, Package (0x02)
		{
			0x12, 
			0x03
		})
		Method (_LID, 0, NotSerialized)
		{
			Return (LIDS)
		}

		Method (_PSW, 1, NotSerialized)
		{
			If (\_SB.PCI0.LPCB.EC.ECOK)
			{
				If (Arg0)
				{
					Store (0x01, \_SB.PCI0.LPCB.EC.LWAK)
				}
				Else
				{
					Store (0x00, \_SB.PCI0.LPCB.EC.LWAK)
				}
			}
		}

 

 

Modded to this :

			Device (LID0)
		{
			Name (_HID, EisaId ("PNP0C0D"))
			Method (_LID, 0, NotSerialized)
			{
			XOr (LIDS, One, Local0)
			IF (Local0)									 
			{ 
			Notify (SLPB, 0x80)						 
			} 
			Return (LIDS)
			}
		}

 

According to this guide : http://ipis-osx.wikidot.com/forum/t-121404...t-fix-for-1000h

 

Bye.

Share this post


Link to post
Share on other sites

Trauma!

 

Would appreciate the DSDT code for Wind HDA - have been playing with that one for a while and not yet cracked it. Had already the GFX and have just done the LID0 & clamshell kext removal. Works great thanks.

Share this post


Link to post
Share on other sites
Modded to this :

Device (LID0)

{

Name (_HID, EisaId ("PNP0C0D"))

Method (_LID, 0, NotSerialized)

{

XOr (LIDS, One, Local0)

IF (Local0)

{

Notify (SLPB, 0x80)

}

Return (LIDS)

}

}

 

I know that method, but it hardcode sleep : does it allow to disable clamshell if needed ?

Share this post


Link to post
Share on other sites

well, enabling appleACPIadapter had strange results on my system. by the way, the thing is done by modding AC0 or whatever you have instead of that. It fixed my 'no restart after sleep' issue, but it messed up a lot of things: after wake, I don't have 'lid sleep', which always works fine without this mod; my wireless card doesn't wake from sleep and if I use lid sleep before normal sleeping it works, but on wake my screen goes black and I have to restart... I also added 'gmux' device emulation which really does nothing I guess. here's my dsdt without ac0 patch and with it, if anybody has suggestions on what to fix I'll really appreciate

DSDTs.zip

Share this post


Link to post
Share on other sites
I know that method, but it hardcode sleep : does it allow to disable clamshell if needed ?

 

I dont think so, by the way you can't disable it with ClamShellDisplay to ! Does real Mac can disable this clamshell fonction ?

 

If i understand well, you want to use your laptop with the lid closed and monitor on another display ?

 

Trauma!

Would appreciate the DSDT code for Wind HDA - have been playing with that one for a while and not yet cracked it. Had already the GFX and have just done the LID0 & clamshell kext removal. Works great thanks.

 

Thanks,

 

about the HDA string : i'm not able, at the moment to use AppleHDA.kext as a sound driver. I've just hadded the missing "Device (HDEF)" in my DSDT for future use.... I'm working on the HDA driver at the moment, but until now with no success !

 

Has an exemple you could add that to your DSDT a see what's happen (ADR is the correct one for the wind):

Device (HDEF)
{
Name (_ADR, 0x001B0000)
}

 

Then you can follow TheKing's tutorial about HDA Injection.

 

Bye.

Share this post


Link to post
Share on other sites

Trauma!

 

Have for a long time had the HDEF device in dsdt on wind (exactly as code you provided and as is on most apple box's) and have wrestled with the King and others tutorials re HDA injection without any real success to date. For one reason or another there is a complexity about ICH7 & ALC codecs which many devs seem not to date be able to resolve.

 

I have been successful with on my P5k-vm Asus board resolving HDEF in dsdt but the ICH7 chipset seems to be a bridge to far so guess will stay with the Azalia solution.

 

Thanks anyway.

Share this post


Link to post
Share on other sites
I dont think so, by the way you can't disable it with ClamShellDisplay to ! Does real Mac can disable this clamshell fonction ?

 

If i understand well, you want to use your laptop with the lid closed and monitor on another display ?

 

Yes !! need sleep LID only on battery, it's possible with insomniac on real mac, but i don't know what it disable...

 

the thing is done by modding AC0 or whatever you have instead of that

 

I will try it thanks !

 

EDIT to coconup :

 

You've just added

 

Name (_PRW, Package (0x02)
		{
			0x10, 
			0x03
		})

 

And modify Method PCL ??? (For me it's the same that MPB) That's all for acpi power ??? Does it allow you to see if laptop is on battery or AC with any kext ??

 

For me does'nt change anything....

Share this post


Link to post
Share on other sites

mm I don't know if it really does much but now I just have this under ioreg

 

post-269722-1234961014_thumb.png

 

btw it seems to be in conflict with voodoobattery since the battery meter doesn't show up properly, however without voodoobattery it doesn't show up at all...

 

all the problems I had with sleep/lid sleep etc were caused by this string under ac0

 

Method (_PSW, 1, NotSerialized)
					{
						If (^^PCI0.LPCB.EC0.FGEC)
						{
							If (Arg0)
							{
								Store (One, _WAK (Arg0))
							}
							Else
							{
								Store (Zero, _WAK (One))
							}
						 }
					}

 

which I copied and adapted by andy's dsdt. however, as I said, this enabled restart on my laptop after sleep. so there must be a way to fix everything here..

Share this post


Link to post
Share on other sites

look at this, emulating device smb0 (which controls the baettry in macbooks) resulted in:

 

post-269722-1234964110_thumb.png

post-269722-1234964191_thumb.png

 

without voodoobattery or whatever...

 

however no battery meter because the battery still tells nothing to the smb0 device. I'll try to add methods in both the devices and see if it works.. here's my dsdt with AC0 very little mod to enable appleACPIadapter and emulated devices hpet_fixed_gmux_ac0_smb0_little_mods3.txt

Share this post


Link to post
Share on other sites
look at this, emulating device smb0 (which controls the baettry in macbooks) resulted in:

 

post-269722-1234964110_thumb.png

post-269722-1234964191_thumb.png

 

without voodoobattery or whatever...

 

however no battery meter because the battery still tells nothing to the smb0 device. I'll try to add methods in both the devices and see if it works.. here's my dsdt with AC0 very little mod to enable appleACPIadapter and emulated devices hpet_fixed_gmux_ac0_smb0_little_mods3.txt

 

Superhai or Eureka could help us a lot, they have experience of Battery meters...

Good job !

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.

×