rednous Posted October 13, 2010 Share Posted October 13, 2010 oldnapalm, there's a new iasl version dated 20101013 which I compiled under SLx64. Hope it'll help further more Link to comment Share on other sites More sharing options...
oldnapalm Posted October 13, 2010 Author Share Posted October 13, 2010 Thanks rednous! Can you compile under Leopard? The last version I compiled under Snow Leopard simply would not run on Leopard (even compiled as i386). Link to comment Share on other sites More sharing options...
fbifido Posted October 13, 2010 Share Posted October 13, 2010 We need more information than the DSDT to suggest which patches should be applied. For example, to know if you need the LPC patch, you have to check if the original ID of your LPC device is listed under IONameMatch of AppleLPC.kext/Contents/Info.plist and if the kext is being loaded. I did not know this, I just though that if you have a pc and a lpc in your dsdt, then you need a fix, as to make it look like a mac. my problem is that there is a lot of dif. mac dsdt. As you already suggested, we would have to merge the "System Info" parser and grab some more info to do this. The initial idea of this editor was not to be a "click and you are done" app, but to help new users to understand the DSDT structure (tree view) and learn how to apply a patch by observing what the automated patches do (patcher preview/before/after). Surely we could implement some of your good suggestions, but it will take some time, since this is a hobby project for both me and my brother (el coniglio) who is the developper of this app. Maybe if he doesn't want to improve it anymore, I will ask him to release the source. I saw you did a good work with the renaming patch, it would be nice if you could help us with this. I won't work on renaming patches because I see no advantage renaming the devices, I'm satisfied with the OS running fine. Some friends reported faster boot using your patch, but I noticed no difference. Did you remove any devices? all i did was, ask the members of this forum to tell me the names and what to change them to. i have never seen a mac dsdt to look at the names use. Link to comment Share on other sites More sharing options...
rednous Posted October 14, 2010 Share Posted October 14, 2010 Thanks rednous! Can you compile under Leopard? The last version I compiled under Snow Leopard simply would not run on Leopard (even compiled as i386). I have only Snow Leopard installed, unfortunately I don't have Leopard Link to comment Share on other sites More sharing options...
Time2Retire Posted October 14, 2010 Share Posted October 14, 2010 Thanks rednous! Can you compile under Leopard? The last version I compiled under Snow Leopard simply would not run on Leopard (even compiled as i386). Let me make an educated guess: You didn't compile it against the MacOSX10.5.sdk /me runs like h&$)) because she has no clue how to do it herself Link to comment Share on other sites More sharing options...
oldnapalm Posted October 14, 2010 Author Share Posted October 14, 2010 Actually I think I didn't compile with -arch i386 For what I remember it was this same error http://www.insanelymac.com/forum/index.php...t&p=1506293 Anyone who has Leopard could try this please? I don't have it anymore. iasl.zip Link to comment Share on other sites More sharing options...
kerr Posted October 14, 2010 Share Posted October 14, 2010 features in this iasl version: Compiler now treats lower case in name space as non-hex letters and returns error. Example, i have this line in my DSDT: Name (_HID, "pnp0c14") And the error after compiling: /Volumes/MacStorage/DSDTMod/TEST/DSDT.dsl 8498: Name (_HID, "pnp0c14") Error 4124 - Non-hex letters must be upper case ^ (pnp0c14) simply fixed by changing to upper case - PNP0C14 Is lower case a problem at all ? Link to comment Share on other sites More sharing options...
kizwan Posted October 14, 2010 Share Posted October 14, 2010 Is lower case a problem at all ? It is not a problem. Its not going to influence how DSDT work though. Look like there are going to standardize it, using uppercase. Link to comment Share on other sites More sharing options...
Time2Retire Posted October 14, 2010 Share Posted October 14, 2010 features in this iasl version: Compiler now treats lower case in name space as non-hex letters and returns error. Example, i have this line in my DSDT: Name (_HID, "pnp0c14") And the error after compiling: /Volumes/MacStorage/DSDTMod/TEST/DSDT.dsl 8498: Name (_HID, "pnp0c14") Error 4124 - Non-hex letters must be upper case ^ (pnp0c14) simply fixed by changing to upper case - PNP0C14 Is lower case a problem at all ? Not if you fix it. BTW: The use of uppercase is enforced in the ACPI specification (on page 200 / 591) which reads, and I quote: "A valid PNP ID must be of the form “AAA####” where A is an uppercase letter and # is a hex digit. A valid ACPI ID must be of the form “ACPI####” where # is a hex digit." The correct syntax therefor should be: Name (_HID, EisaId ("PNP0C14")) I'm sure that oldernapalm can write up a simple, but effective, script for it. Link to comment Share on other sites More sharing options...
oldnapalm Posted October 14, 2010 Author Share Posted October 14, 2010 I will ask el coniglio to add this to the "auto fix" in next version, which will include the new IASL. @Zprood The bug you found is fixed in next release. If "editable text" is checked it was not parsing the manual changes before applying an automatic patch. Link to comment Share on other sites More sharing options...
Zprood Posted October 15, 2010 Share Posted October 15, 2010 @oldnapalm Thanks a lot . I`ll try new release version . Link to comment Share on other sites More sharing options...
fbifido Posted October 19, 2010 Share Posted October 19, 2010 I saw this in my DSDT file and would like to know, what is this for and how can i put "mac os x" in here or do i have to put "freebsd"? Method (OSYS, 0, NotSerialized) { Store (0x10, Local0) If (CondRefOf (_OSI, Local1)) { If (_OSI ("Windows 2000")) { Store (0x12, Local0) } If (_OSI ("Windows 2001")) { Store (0x13, Local0) } If (_OSI ("Windows 2001 SP1")) { Store (0x13, Local0) } If (_OSI ("Windows 2001 SP2")) { Store (0x13, Local0) } If (_OSI ("Windows 2001.1")) { Store (0x14, Local0) } If (_OSI ("Windows 2001.1 SP1")) { Store (0x14, Local0) } If (_OSI ("Windows 2006")) { Store (0x15, Local0) } } Else { If (MCTH (_OS, "Microsoft Windows NT")) { Store (0x12, Local0) } Else { If (MCTH (_OS, "Microsoft WindowsME: Millennium Edition")) { Store (0x11, Local0) } If (MCTH (_OS, "Linux")) { Store (One, Local0) } } } Return (Local0) } Thank you. Link to comment Share on other sites More sharing options...
oldnapalm Posted October 19, 2010 Author Share Posted October 19, 2010 DSDT Patcher by fassl has "OSI emulation by mackerintel" http://www.insanelymac.com/forum/index.php?showtopic=133683 You can try it and check what it does. Link to comment Share on other sites More sharing options...
Nameci Posted October 20, 2010 Share Posted October 20, 2010 Feature request; we should be able to open another window. For example, I have a real mac dsdt and I want to compare my dsdt with the dsdt from the real mac. Link to comment Share on other sites More sharing options...
Bungo Posted October 20, 2010 Share Posted October 20, 2010 Hi, I can't compile my dsdt even without modifications (more then 200 errors). Found that FPED is a problem but I don't know what it is. There is FPED in MBP6.1's dsdt and couldn't compile it also. Would you like to help me? (Posted here also) dsdts.zip Link to comment Share on other sites More sharing options...
Time2Retire Posted October 20, 2010 Share Posted October 20, 2010 I saw this in my DSDT file and would like to know, what is this for and how can i put "mac os x" in here or do i have to put "freebsd"? Thank you. You can remove all references to it. We don't need it on "Darwin" (0x2710). You will however have to patch all places where it is used. Sometimes it makes reading much more fun. Let's take one example: Method (_STA, 0, NotSerialized) { If (LGreaterEqual (OSYS, 0x07D1)) // Windows 2000 { If (HPAE) { Return (0x0F) } } Else { If (HPAE) { Return (0x0B) } } Return (Zero) } All that can basically be replaced with one single line: Name (_STA, 0x0f) Much more fun isn't it. Simply because the modified copy of our dsdt.aml will only be used for OS X. Easy. Link to comment Share on other sites More sharing options...
fbifido Posted October 20, 2010 Share Posted October 20, 2010 that's cool, thanks but if i am going to put the modify dsdt file back into my bios, then i will need the windows info, for dual-booting. will this be the way it looks: Method (_STA, 0, NotSerialized) { If (LGreaterEqual (OSYS, 0x07D1)) // Windows 2000 { If (HPAE) { Return (0x0F) } } Else { If (LGreaterEqual (OSYS, 0x2710)) // Darwin { Name (_STA, 0x0F) Return (0x0F) } Else { If (HPAE) { Return (0x0B) } } } Return (Zero) } Link to comment Share on other sites More sharing options...
Time2Retire Posted October 20, 2010 Share Posted October 20, 2010 that's cool, thanks but if i am going to put the modify dsdt file back into my bios, then i will need the windows info, for dual-booting. will this be the way it looks: Method (_STA, 0, NotSerialized) { If (LGreaterEqual (OSYS, 0x07D1)) // Windows 2000 { If (HPAE) { Return (0x0F) } } Else { If ([color="#FF0000"]LGreaterEqual[/color] (OSYS, 0x2710)) // Darwin { [color="#FF0000"]Name (_STA, 0x0F)[/color] Return (0x0F) } [color="#FF8C00"]Else { If (HPAE) { Return (0x0B) } }[/color] } Return (Zero) } Oh but that will make things much more complicated. And please note that my example was... well just an example. I've marked a few lines with red and orange. Red is an error (LGreaterEqual should be LEqual) and the orange section could be written as: ElseIf (HPAE) { Return (0x0B) } To reduce the number of opcodes (for optimization). And since my Name (_STA, 0x0F) was a full replacement for Method (_STA, 0, NotSerialized) it cannot be used like you did. Hence it being marked red. Link to comment Share on other sites More sharing options...
kizwan Posted October 20, 2010 Share Posted October 20, 2010 @fbifido, If you're going to put the modified DSDT back into BIOS, you may follow this example. I add Darwin entry like this:- Method (_INI, 0, NotSerialized) { Store (0x07D0, OSYS) If (CondRefOf (_OSI, Local0)) { If (_OSI ("Darwin")) { // Store (0x2710, OSYS) // change to:- Store (0x07D3, OSYS) } If (_OSI ("Linux")) { Store (One, LINX) } If (_OSI ("Windows 2001")) { Store (0x07D1, OSYS) } If (_OSI ("Windows 2001 SP1")) { Store (0x07D1, OSYS) } If (_OSI ("Windows 2001 SP2")) { Store (0x07D2, OSYS) } If (_OSI ("Windows 2006")) { Store (0x07D6, OSYS) } } This is an example for LID sleep fix in DSDT where when the LID is close, my notebook will go to sleep if it is in Mac OS X. While if it is in windows, it will use whatever we set in Control Panel (Power Options). Device (LID0) { Name (_HID, EisaId ("PNP0C0D")) Method (_LID, 0, NotSerialized) { If (ECON) { Store (^^PCI0.LPCB.EC0.KLID, Local0) } Else { And (RBEC (0x70), 0x02, Local0) } If (Local0) { Return (One) } Else { // check OS before sleep when LID closed if (LEqual (OSYS, 0x07D3)) { Store (OSYS, Debug) Notify (SLPB, 0x80) } Return (Zero) } } I set Darwin to 0x07D3 instead of 0x2710 because it is useful if you have entry like this in your DSDT (look for If (LOr (LGreater (OSYS, 0x07D0), LLess (OSYS, 0x07D6)))):- Method (HKDS, 1, NotSerialized) { If (LEqual (Zero, DSEN)) { Store (PHSR (0x2D, Zero), Local1) If (LNotEqual (Local1, LDTD)) { Store (Local1, LDTD) If (LOr (LGreater (OSYS, 0x07D0), LLess (OSYS, 0x07D6))) { Notify (PCI0, Zero) } Else { If (LEqual (IGDD, Zero)) { Notify (GFX0, Zero) } Else { Notify (^^^PEGP.VGA, Zero) } } Sleep (0x02EE) } This way you'll only need to do minimal changes to your DSDT (just OSYS). Link to comment Share on other sites More sharing options...
oldnapalm Posted October 20, 2010 Author Share Posted October 20, 2010 Hi, I can't compile my dsdt even without modifications (more then 200 errors). Found that FPED is a problem but I don't know what it is. There is FPED in MBP6.1's dsdt and couldn't compile it also. Would you like to help me? (Posted here also) Look for "syntax errors", if you fix them, all other errors will be fixed. dsdt_SamsungR780.dsl.zip (look for "commented out") Link to comment Share on other sites More sharing options...
Time2Retire Posted October 20, 2010 Share Posted October 20, 2010 @kizwan I don't think that you want to use: Notify (PCI0, Zero) Not for Darwin / Linux because only Windows wants to receive notifications on the PCI bus. This little fact can be found in the DSDT of a real Mac (example): If (LOr (LGreater (OSYS, 0x07D0), LLess (OSYS, 0x07D6))) { Notify (\_SB.PCI0, Arg1) // Windows } Else { Notify (\_SB.PCI0.IGPU, Arg1) // Linux and Darwin } Just to let you know. Link to comment Share on other sites More sharing options...
fbifido Posted October 20, 2010 Share Posted October 20, 2010 @dutchhockeypro @kizwan Thanks Link to comment Share on other sites More sharing options...
kizwan Posted October 20, 2010 Share Posted October 20, 2010 @dutchhockeypro, my method is simple, as long as it doesn't cause any problem, I won't touch the original code. Link to comment Share on other sites More sharing options...
Bungo Posted October 20, 2010 Share Posted October 20, 2010 Look for "syntax errors", if you fix them, all other errors will be fixed. dsdt_SamsungR780.dsl.zip (look for "commented out") I hit on that idea, but thanks for help. Are you sure a commented out section is not required for something, what is FPED? Link to comment Share on other sites More sharing options...
oldnapalm Posted October 20, 2010 Author Share Posted October 20, 2010 I hit on that idea, but thanks for help. Are you sure a commented out section is not required for something, what is FPED? I have no idea, there are 3 ocurrences, 2 commented out and External (FPED, MethodObj) // 0 Arguments The compiler won't accept an IF in that place, so the way I found to compile was removing it. Probably there's a better solution, but I don't know it. Maybe creating a method? You may find more about FPED in other ACPI tables, you can dump them using Linux. Link to comment Share on other sites More sharing options...
Recommended Posts