Jump to content

Dsdt kills ps2 keyboard! Need fix?


  • Please log in to reply
15 replies to this topic

#1
davidm71

davidm71

    InsanelyMac Geek

  • Members
  • PipPipPip
  • 167 posts
  • Gender:Male
Hi,

I use to have my ps2 keyboard working fine through the voodoops2 controller driver included in ##### for lion 10.7.2, but found a dsdt to enable jmicron esata ports http://www.tonymacx8...47a4abcbb10db0c
And now my keyboard doesnt work while the dsdt is installed. Usb keyboards work fine and i could probably do without it but its my favorite keyboard!

Anyone know if i need a dsdt edit to get working again?

Thanks!

#2
Gringo Vermelho

Gringo Vermelho

    The Jan Bird fix

  • Supervisors
  • 6,064 posts
  • Gender:Male
  • Location:Brazil
Use diffmerge (it's free, and available for both Windows and OS X) to compare your unmodified DSDT (extract on Windows using Everest for example) to the patched DSDT. The PS2 devices were probably removed from the patched DSDT because the person who edited it didn't need them. Yet another reason why you should never use someone elses DSDT.

#3
juanerson

juanerson

    InsanelyMac Legend

  • Local Moderators
  • 1,422 posts
  • Gender:Male
  • Location:Tru, Venezuela
All you need (see IRQs are the most important thing) to load the keyboard "AND OPTIONALLY" if wants the mouse too:
[codebox] Device (PS2K) //Keyboard
{
Name (_HID, EisaId ("PNP0303"))
Name (_STA, 0x0F)
Name (_CRS, ResourceTemplate ()
{
IO (Decode16,
0x0060, // Range Minimum
0x0060, // Range Maximum
0x01, // Alignment
0x01, // Length
)
IO (Decode16,
0x0064, // Range Minimum
0x0064, // Range Maximum
0x01, // Alignment
0x01, // Length
)
IRQ (Edge, ActiveHigh, Exclusive, )
{1}
})
}

Device (PS2M) //Mouse
{
Name (_HID, EisaId ("PNP0F13"))
Name (_STA, 0x0F)
Name (_CRS, ResourceTemplate ()
{
IRQ (Edge, ActiveHigh, Exclusive, )
{12}
})
}[/codebox]
NOTE: Copy the above code in ANY PLACE inside the Big "Device (PCI0)". Good Luck.

#4
davidm71

davidm71

    InsanelyMac Geek

  • Members
  • PipPipPip
  • 167 posts
  • Gender:Male
You know I used DsteSe App to extract my dsdt file and I compared the PS2K section to the other dsdt and those sections were identical!

So guess I need to make my own you say?

Thanks.

#5
juanerson

juanerson

    InsanelyMac Legend

  • Local Moderators
  • 1,422 posts
  • Gender:Male
  • Location:Tru, Venezuela
:) "Maybe" by adding the PS2M device? I think the voodooPS2 driver need the two devices present in the DSDT to load-match with the itself functionality. Then reinstall the driver (use from This Topic), repair permissions and rebuilt caché.

#6
davidm71

davidm71

    InsanelyMac Geek

  • Members
  • PipPipPip
  • 167 posts
  • Gender:Male

:) "Maybe" by adding the PS2M device? I think the voodooPS2 driver need the two devices present in the DSDT to load-match with the itself functionality. Then reinstall the driver (use from This Topic), repair permissions and rebuilt caché.



Putting that code into the dsdt produces 255 errors. Are you sure that the code is correct?

Here is my PS2K code:

Device (PS2K)
				{
					Name (_HID, EisaId ("PNP0303"))
					Name (_CID, EisaId ("PNP030B"))
					Method (_STA, 0, NotSerialized)
					{
						If (And (IOST, 0x0400))
						{
							Return (0x0F)
						}
						Else
						{
							Return (Zero)
						}
					}

					Name (_CRS, ResourceTemplate ()
					{
						IO (Decode16,
							0x0060,			 // Range Minimum
							0x0060,			 // Range Maximum
							0x00,			   // Alignment
							0x01,			   // Length
							)
						IO (Decode16,
							0x0064,			 // Range Minimum
							0x0064,			 // Range Maximum
							0x00,			   // Alignment
							0x01,			   // Length
							)
						IRQNoFlags ()
							{1}
					})
					Name (_PRS, ResourceTemplate ()
					{
						StartDependentFn (0x00, 0x00)
						{
							FixedIO (
								0x0060,			 // Address
								0x01,			   // Length
								)
							FixedIO (
								0x0064,			 // Address
								0x01,			   // Length
								)
							IRQNoFlags ()
								{1}
						}
						EndDependentFn ()
					})
					Method (_PSW, 1, NotSerialized)
					{
						Store (Arg0, KBFG)
					}
				}

				Scope (\)
				{
					Name (KBFG, One)
				}

				Method (PS2K._PRW, 0, NotSerialized)
				{
					Return (GPRW (0x1D, 0x04))
				}

				Device (PS2M)
				{
					Name (_HID, EisaId ("PNP0F03"))
					Name (_CID, EisaId ("PNP0F13"))
					Method (_STA, 0, NotSerialized)
					{
						If (And (IOST, 0x4000))
						{
							Return (0x0F)
						}
						Else
						{
							Return (Zero)
						}
					}

					Name (CRS1, ResourceTemplate ()
					{
						IRQNoFlags ()
							{12}
					})
					Name (CRS2, ResourceTemplate ()
					{
						IO (Decode16,
							0x0060,			 // Range Minimum
							0x0060,			 // Range Maximum
							0x00,			   // Alignment
							0x01,			   // Length
							)
						IO (Decode16,
							0x0064,			 // Range Minimum
							0x0064,			 // Range Maximum
							0x00,			   // Alignment
							0x01,			   // Length
							)
						IRQNoFlags ()
							{12}
					})
					Method (_CRS, 0, NotSerialized)
					{
						If (And (IOST, 0x0400))
						{
							Return (CRS1)
						}
						Else
						{
							Return (CRS2)
						}
					}

					Name (_PRS, ResourceTemplate ()
					{
						StartDependentFn (0x00, 0x00)
						{
							IRQNoFlags ()
								{12}
						}
						EndDependentFn ()
					})
					Method (_PSW, 1, NotSerialized)
					{
						Store (Arg0, MSFG)
					}
				}

				Scope (\)
				{
					Name (MSFG, One)
				}

				Method (PS2M._PRW, 0, NotSerialized)
				{
					Return (GPRW (0x1D, 0x04))
				}


#7
juanerson

juanerson

    InsanelyMac Legend

  • Local Moderators
  • 1,422 posts
  • Gender:Male
  • Location:Tru, Venezuela

Putting that code into the dsdt produces 255 errors. Are you sure that the code is correct?

Yes, I am sure that code is correct... So, maybe your Disassembler/compiler (see IASL) is Old. BUT after all, seems it is NOT needed for your dsdt, because the IRQs (1 & 12, respectively) are present in both PS2 devices.

#8
davidm71

davidm71

    InsanelyMac Geek

  • Members
  • PipPipPip
  • 167 posts
  • Gender:Male
I was using Dsdt-SE and not sure what version, though will use iasl if I have to.

Thanks

#9
Gringo Vermelho

Gringo Vermelho

    The Jan Bird fix

  • Supervisors
  • 6,064 posts
  • Gender:Male
  • Location:Brazil
DSDTSE uses IASL to compile and decompile your DSDT. You can see which version it is using at the top of the DSDT.

It's easy to replace if you want, it's inside the app package - right click DSDTSE.app -> show package contents and look for it (resources folder?)

Not sure (not at my hack right now) but I think it also keeps a copy of IASL somewhere in the vicinity of the default DSDT save folder, replace that as well.

There's a topic by Mitch_DE around here somewhere with the latest IASL binary.

#10
juanerson

juanerson

    InsanelyMac Legend

  • Local Moderators
  • 1,422 posts
  • Gender:Male
  • Location:Tru, Venezuela
See the correct route (or path) to the binary: "/Users/yourUserAccount/Library/Application Support/EvOSoftware/DSDT"
Attached File  Captura_de_pantalla_2011_11_22_a_las_14.41.12.png   69.01KB   40 downloads
AND, the link to mitch_de topic (IASL updates) is in post 7. Good Luck.

#11
davidm71

davidm71

    InsanelyMac Geek

  • Members
  • PipPipPip
  • 167 posts
  • Gender:Male
Well it looks like an old version:

ASL Optimizing Compiler version 20091214 [Dec 16 2009]
Copyright © 2000 - 2009 Intel Corporation
Supports ACPI Specification Revision 4.0


2009! Thats really out of date! Anyhow I'll try your code again though if you say my IRQs are correct
what good will it do?!

Thanks.

Edit: Found iasl though not in the path you provided but somewhere inside the DSDT-SE App itself. Found a new version of iasl from that thread and dropped it into the dsdtse package contents resource folder replacing the old one but didn't do anything. It still compiles with version 2009. Tested the file and its a 2011 version. Couldn't find that path you metioned. What to do?!

#12
davidm71

davidm71

    InsanelyMac Geek

  • Members
  • PipPipPip
  • 167 posts
  • Gender:Male
Ok, Turns out the folder was hidden. Found it but now my original DSDT file that use to compile fine with just warnings is giving errors!

One step forward two steps back...

#13
Gringo Vermelho

Gringo Vermelho

    The Jan Bird fix

  • Supervisors
  • 6,064 posts
  • Gender:Male
  • Location:Brazil
Revisit mitch_de's IASL topic and you will learn what to do about those errors.

#14
davidm71

davidm71

    InsanelyMac Geek

  • Members
  • PipPipPip
  • 167 posts
  • Gender:Male
I did and I figured out the length error problem but I'm getting another error: Invalid object type for reserved name ^ (found BUFFER, requires Package)..

No idea how to fix that one!

#15
juanerson

juanerson

    InsanelyMac Legend

  • Local Moderators
  • 1,422 posts
  • Gender:Male
  • Location:Tru, Venezuela
Just change the word BUFFER To Package. That's it.
For example:
dsdt_fixed.asl  7850:         Name (_PLD, Buffer (0x10)Error    4080 -  Invalid object type for reserved name ^  (found BUFFER, requires Package)
Then, go to the line number 7850 to change it.

And of course do that in every instance which appear the same error.

#16
davidm71

davidm71

    InsanelyMac Geek

  • Members
  • PipPipPip
  • 167 posts
  • Gender:Male

Just change the word BUFFER To Package. That's it.
For example:

dsdt_fixed.asl  7850:         Name (_PLD, Buffer (0x10)Error    4080 -  Invalid object type for reserved name ^  (found BUFFER, requires Package)
Then, go to the line number 7850 to change it.

And of course do that in every instance which appear the same error.



I kind of renamed '_PLD' to 'PLD' and that fixed it, but after seeing your suggestion I made some changes. Anyhow PS2 Keyboard is now working. Had to make my own DSDT file from scratch pulled from under Ubuntu and worked out every error. Reset the kextcache which might have done the trick as well but the PS2 Keyboard is working now!

All thats left is to work out power management p states and build an SSDT if I even need one ...

Thanks.





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