Jump to content

DSDT disass+compile: newest iASLme / IASL :, Juli 11th 2012


mitch_de
 Share

265 posts in this topic

Recommended Posts

DL link to newest iasl at end of this post.

LASTEST NOW: , Juli 11th 2012 : 32Bit/64 Bit : by Rednous & others

 

NEW SCRIPT:

Downloads Acpica latest source from GitHub and compiles

 

Always have latest version...

DL: end of the page

 

 

 

Also sometimes compiled an 32 Bit Version for 32 Bit CPUs (AMD & co) (up to version 28_05)

INFO:since 28_04_2010 and up Versions does some lenght checks which may give errors if your dsdt has some wrong lenght parameters, whereas older versions didnt ! This helps to get dsdt bugfree.

Read therefor latest postings about that new check errors and maybe fixes for (sure wrong lenght definitions in your dsdt!)

 

 

SOLUTION found to edit real wrong length found ny new iasl version , look at my postings !

 

 

---------

SUMMARY of why using newer iasl:

Newer versions of iasl (and iaslMe with newer iasl) help to get dsdt.dsl source complied or getting much less compile errors.

EDIT: Even more interesting as "optimisations" : Newer iasl compiler may also find more bugs (errors) in your bios/dsdt ! So you can fix them .

It will NOT help to avoid os x specidic problems like sleep, usb, cpu=1 : therefore you need adding known dsdt source patching by changes of dsdt source and/or dsdt device injection code.

 

Hi,

i was a bit ??? as i see in an DSDT of an other users didnt have the well known _WAK compile error fix in his _WAK part of dsdt.

The fix adds some return values at the end to avoid the "has no return values error" on compiling the .dsl to .aml

My _WAK part can look now :

....
[size=1]	  }
	Notify (\_SB.PCI0.USB0, Zero)
	Notify (\_SB.PCI0.USB1, Zero)
	Notify (\_SB.PCI0.USB2, Zero)
	Notify (\_SB.PCI0.USB3, Zero)
	Notify (\_SB.PCI0.USB4, Zero)
	Notify (\_SB.PCI0.USB5, Zero)[/size]	}

 

No more compile error (needed return .... after last notify..)

So i used an newer iasl version - and : really no more _WAK fix needed to avoid compile error = only warning (=you get an dsdt.aml)!

iasl itself gets updated often (by intel) so you may update yours also .

Lots of fixes between newer and older (2007/2008 versions most here will use!)

iaslme tool, which is really easy to use:

drag&drop your .dsl on iaslme = compiled .aml in an session subfolder with errorlog

drag&drop your .aml on iaslme = disassembled .dsl

 

If you want the iasl as commandline itself you can simple show packadge content / ressources and use that .

 

DL: (i update here the dl links if needed)

 

iaslme (newest with iasl ), from some kind dev: an really easy to to use that iasl commandline tool: drag&drop .dsl on it > .aml (or error ;) ), drag&drop an .aml > dsl

 

DL: , at Posting 242

http://www.insanelymac.com/forum/index.php?showtopic=189272&st=240&p=1833645&&do=findComment&comment=1833645

AcpicaTool.command.zip

  • Like 4
Link to comment
Share on other sites

No more compile error (needed return .... after last notify..)

Maybe no errors, but still a warning?

 

/Users/Admin/Hackintosh/DSDT tools and info/dsdt.dsl 255: Method (_WAK, 1, NotSerialized)

Warning 1080 - Reserved method must return a value ^ (_WAK)

 

Can I ignore that or am I doing something wrong?

dsdt.aml was generated with patcher02b5 and disassembled/compiled with cVaD's linked update.

Link to comment
Share on other sites

If you want iASL binary only, get here below, or compile it yourself.

 

1. You need xCode installed

2. Get the current source from http://www.acpica.org/downloads/unix_source_code.php

3. Get the 20081031 source from http://www.acpica.org/downloads/acpica-unix-20081031.php

4. Open Terminal, change dir to where you want to have your source code.

5. Extract the source tarballs into separate directories by running

tar xf ~/Downloads/iasl-20090521/acpica-unix-20090521.tar
tar xf ~/Downloads/iasl-20090521/acpica-unix-20081031.tar

6. Define shorthands for later use:

export WORKING="`pwd`/acpica-unix-20081031"
export CURRENT="`pwd`/acpica-unix-20090521"

7. Run

cp -p "$WORKING/osunixxf.c" "$CURRENT/osunixxf.c"

8. Edit "$CURRENT/include/platform/aclinux.h": Replace line 163, which reads

 

#define ACPI_THREAD_ID			  pthread_t

by

#define ACPI_THREAD_ID			  void *

9. Change directory to "$CURRENT/compiler" and run the following command.

make LDLIBS=''

10. Now you should have a file called "iasl" in "$CURRENT/compiler". This is your ASL compiler :P .

Intel ACPI Component Architecture
  ASL Optimizing Compiler version 20090521 [Jun 16 2009]
  Copyright © 2000 - 2009 Intel Corporation
  Supports ACPI Specification Revision 3.0a

 

For iasl Sept-03-2009 version need replace osunixxf.c instead of osunix.c ..

iasl_osx_20090903.zip

Link to comment
Share on other sites

8. Edit "$CURRENT/include/platform/aclinux.h": Replace line 163, which reads

 

or correct way

 

add after line 158 (#include <unisdt.h>)

#include <pthread.h>

 

and edit "osunixxf.c" function "AcpiOsGetThreadID()

 

replace line 1110 "return getpid());" with "return (pthread_self());"

 

 

rest same

Link to comment
Share on other sites

Thanks !

Hint point 6. export CURRENT="`pwd`/acpica-unix-20090521"

 

I did dump an export CURRENT="`pwd`/acpica-unix-20090521" - sure not working (Point 7 cp ... fails) , because that current source daily/weekly... changes - so change also that last 4 month+day numbers

 

"10. Now you should have a file called "iasl" in "$CURRENT/compiler". This is your ASL compiler :) "

YEAH! (screenshoot = compiled result = ready to rubmle :)

THANKS for that step by step how to dl + compile !

 

EDIT: I edited the second thread information line to : newest iasl here and also made an dl share for newest iasl (compiled) and that posted iaslme tool (within 0903 iasl) there.

So community must not search all postings for newest version.

Maybe useful to make that iasl (DSDT) thread sticky by someone of the mods.

Bild_370.jpg

Link to comment
Share on other sites

Hey, I would like to get my rtl 8139 family dsdt.dsl.

 

What should I modify ?

 

 

==============================================================
credit to mitch_de, I got from mitch_de's patched DSDT.


		Device (LAN0)
			{
				Name (_ADR, 0x00)
				Name (_PRW, Package (0x02)
				{
					0x0B, 
					0x04
				})
				Method (_DSM, 4, NotSerialized)
				{
					Store (Package (0x04)
						{
							"built-in", 
							Buffer (0x01)
							{
								0x01
							}, 

							"device_type", 
							Buffer (0x09)
							{
								"ethernet"
							}
						}, Local0)
					DTGP (Arg0, Arg1, Arg2, Arg3, RefOf (Local0))
					Return (Local0)
				}
			}


========================================================

Link to comment
Share on other sites

First you must know what name your LAN device has in the DSDT. You can look in the IORegistryExplorer and look where the lan drivers are listed.

 

Then you can use:

     [size=1]Method (_DSM, 4, NotSerialized)
                   {
                       Store (Package (0x04)
                           {
                               "built-in", 
                               Buffer (0x01)
                               {
                                   0x01
                               }, 

                               "device_type", 
                               Buffer (0x09)
                               {
                                   "ethernet"
                               }
                           }, Local0)
                       DTGP (Arg0, Arg1, Arg2, Arg3, RefOf (Local0))
                       Return (Local0)
                   }[/size]

 

In the Device (yours) part add that code above - thats all. There is no special code for exact lan chip device ID needed.

Also some PCI EFI bootloaders have on boot option to set lan to build in also (does same as that above).

If you already have that method DTGP in use (for other injextions) that all. If no DTGP you must first add this method into DSDT.

But for further Q&A please use one of the DSDT threads in the forum part Genuis (all how tos are there).

Link to comment
Share on other sites

Guys,

 

Thanks for the updated 'iasl'. I'm pretty new to DSDT hacking so please excuse my ignorance.

 

I extracted a unpatched DSDT.dsl using 'Patcher02Beta' applied the RTC fix for Snow Leopard and changed 'AZAL' to 'HDEF' (two places) just to start off. With the version of 'iasl' I had it returned over 200 error and didn't list them but with the new on it returned only 2 (Local0) errors and the _WAK warning.

 

While this is great because it won't take long to get a compilable DSDT.dsl should I be concerned about where the other 198+ errors went or is the new 'iasl' just that much better?

 

Thanks

Link to comment
Share on other sites

I would say (my opinion) that we must see two different things comparing newer iasl and older ones:

1. The fix of compiler errors, handling of "not good" dsdt source code = getting complied or not

and

2. The result in working / praktical way of an compiled dsdt

I think that if an dsdt source getting compiled (no errors by lots of workarounds: older iasl / less workarounds newer iasl) the result (woring) is the same.

 

So major benefit of newer iasl is getting dsdt compiled easier (less errors) and not getting an "better working" dsdt.aml. I dont think that problems with sleep,... getting fixed with newer iasl vs older one.

 

last but not least : UPDATED IASL + iaslME to 20091013 Version :blink:

Link to comment
Share on other sites

  • 2 weeks later...
 Share

×
×
  • Create New...