Jump to content
6 posts in this topic

Recommended Posts

Hi,

 

Been trying to make my nvme drives appear as Internal using SSDT patches. The problem is I can do it for a single disk behind a single bridge but having trouble writing to code for this layout:

 

ACPI(_SB_)#ACPI(PCI0)#ACPI(PEG0)#ACPI(PEGP)#PCI(0900)#PCI(0000)#PCI(1100)#PCI(0000)
ACPI(_SB_)#ACPI(PCI0)#ACPI(PEG0)#ACPI(PEGP)#PCI(0900)#PCI(0000)#PCI(1000)#PCI(0000)
ACPI(_SB_)#ACPI(PCI0)#ACPI(PEG0)#ACPI(PEGP)#PCI(0900)#PCI(0000)#PCI(0800)#PCI(0000)
ACPI(_SB_)#ACPI(PCI0)#ACPI(PEG0)#ACPI(PEGP)#PCI(0900)#PCI(0000)#PCI(0900)#PCI(0000)

 

 

DefinitionBlock ("", "SSDT", 2, "hack", "NVMe", 0x00000000)
{
    External (_SB_.PCI0.PEG0.PEGP, DeviceObj)

    Device (_SB.PCI0.PEG0.PEGP.HPC1)
    {
        Name (_ADR, 0x00090000)  // _ADR: Address
        Device (SSD0)
        {
            Name (_ADR, 0x00110000)  // _ADR: Address
        }
    }

    Method (_SB.PCI0.PEG0.PEGP.HPC1.SSD0._DSM, 4, NotSerialized)  // _DSM: Device-Specific Method
    {
        If (!Arg2)
        {
            Return (Buffer (One)
            {
                 0x03                                             // .
            })
        }

        Return (Package (0x04)
        {
            "built-in", 
            Buffer (0x0A)
            {
                "NVMe SSD"
            }
        })
    }
}

 

There are four drives which are installed in a highpoint raid controller

 

If I could only access then via SSDT I could make them appear as internal drives as opposed to external drives.

 

Maybe even get the raid card working. Wishful thinking.

 

Thanks


 

Edited by davidm71

Redid the code. At work and can't test:

DefinitionBlock ("", "SSDT", 2, "hack", "NVMe", 0x00000000)
{
    External (_SB_.PCI0.PEG0.PEGP, DeviceObj)

    Device (_SB.PCI0.PEG0.PEGP.PBR0)
    {
        Name (_ADR, 0x00900000)  // _ADR: Address
        Device (PBRA)
        {
            Name (_ADR, 0x00080000)  // _ADR: Address
            Device (SSD0)
            {
                Name (_ADR, Zero)  // _ADR: Address
            }
        }

        Device (PBRB)
        {
            Name (_ADR, 0x00090000)  // _ADR: Address
            Device (SSD0)
            {
                Name (_ADR, Zero)  // _ADR: Address
            }
        }

        Device (PBRC)
        {
            Name (_ADR, 0x00100000)  // _ADR: Address
            Device (SSD0)
            {
                Name (_ADR, Zero)  // _ADR: Address
            }
        }

        Device (PBRD)
        {
            Name (_ADR, 0x00100000)  // _ADR: Address
            Device (SSD0)
            {
                Name (_ADR, Zero)  // _ADR: Address
            }
        }
    }

    Method (_SB.PCI0.PEG0.PEGP.PBR0.PBRA.SSD0._DSM, 4, NotSerialized)  // _DSM: Device-Specific Method
    {
        If (!Arg2)
        {
            Return (Buffer (One)
            {
                 0x03                                             // .
            })
        }

        Return (Package (0x02)
        {
            "built-in", 
            Buffer (One)
            {
                 0x00                                             // .
            }
        })
    }

    Method (_SB.PCI0.PEG0.PEGP.PBR0.PBRB.SSD0._DSM, 4, NotSerialized)  // _DSM: Device-Specific Method
    {
        If (!Arg2)
        {
            Return (Buffer (One)
            {
                 0x03                                             // .
            })
        }

        Return (Package (0x02)
        {
            "built-in", 
            Buffer (One)
            {
                 0x00                                             // .
            }
        })
    }

    Method (_SB.PCI0.PEG0.PEGP.PBR0.PBRC.SSD0._DSM, 4, NotSerialized)  // _DSM: Device-Specific Method
    {
        If (!Arg2)
        {
            Return (Buffer (One)
            {
                 0x03                                             // .
            })
        }

        Return (Package (0x02)
        {
            "built-in", 
            Buffer (One)
            {
                 0x00                                             // .
            }
        })
    }

    Method (_SB.PCI0.PEG0.PEGP.PBR0.PBRD.SSD0._DSM, 4, NotSerialized)  // _DSM: Device-Specific Method
    {
        If (!Arg2)
        {
            Return (Buffer (One)
            {
                 0x03                                             // .
            })
        }

        Return (Package (0x02)
        {
            "built-in", 
            Buffer (One)
            {
                 0x00                                             // .
            }
        })
    }
}

 

Edited by davidm71

Was able to finally access each solid state nvme drive on the Highpoint card. Depending on the method I used I can either hide them all or mark them all as internal.

 

The following is internal

DefinitionBlock ("", "SSDT", 2, "hack", "NVMe", 0x00000000)
{
    External (_SB_.PCI0.PEG0.PEGP, DeviceObj)

    Device (_SB.PCI0.PEG0.PEGP.PBR0)
    {
        Name (_ADR, 0x00090000)  // _ADR: Address
        Device (PBR1)
        {
            Name (_ADR, Zero)  // _ADR: Address
            Device (PBRA)
            {
                Name (_ADR, 0x00080000)  // _ADR: Address
                Device (SSD0)
                {
                    Name (_ADR, Zero)  // _ADR: Address
                }
            }

            Device (PBRB)
            {
                Name (_ADR, 0x00090000)  // _ADR: Address
                Device (SSD0)
                {
                    Name (_ADR, Zero)  // _ADR: Address
                }
            }

            Device (PBRC)
            {
                Name (_ADR, 0x00100000)  // _ADR: Address
                Device (SSD0)
                {
                    Name (_ADR, Zero)  // _ADR: Address
                }
            }

            Device (PBRD)
            {
                Name (_ADR, 0x00110000)  // _ADR: Address
                Device (SSD0)
                {
                    Name (_ADR, Zero)  // _ADR: Address
                }
            }
        }
    }

    Method (_SB.PCI0.PEG0.PEGP.PBR0.PBR1.PBRA.SSD0._DSM, 4, NotSerialized)  // _DSM: Device-Specific Method
    {
        If (!Arg2)
        {
            Return (Buffer (One)
            {
                 0x03                                             // .
            })
        }

        Return (Package (0x02)
        {
            "built-in", 
            Buffer (One)
            {
                 0x00                                             // .
            }
        })
    }

    Method (_SB.PCI0.PEG0.PEGP.PBR0.PBR1.PBRB.SSD0._DSM, 4, NotSerialized)  // _DSM: Device-Specific Method
    {
        If (!Arg2)
        {
            Return (Buffer (One)
            {
                 0x03                                             // .
            })
        }

        Return (Package (0x02)
        {
            "built-in", 
            Buffer (One)
            {
                 0x00                                             // .
            }
        })
    }

    Method (_SB.PCI0.PEG0.PEGP.PBR0.PBR1.PBRC.SSD0._DSM, 4, NotSerialized)  // _DSM: Device-Specific Method
    {
        If (!Arg2)
        {
            Return (Buffer (One)
            {
                 0x03                                             // .
            })
        }

        Return (Package (0x02)
        {
            "built-in", 
            Buffer (One)
            {
                 0x00                                             // .
            }
        })
    }

    Method (_SB.PCI0.PEG0.PEGP.PBR0.PBR1.PBRD.SSD0._DSM, 4, NotSerialized)  // _DSM: Device-Specific Method
    {
        If (!Arg2)
        {
            Return (Buffer (One)
            {
                 0x03                                             // .
            })
        }

        Return (Package (0x02)
        {
            "built-in", 
            Buffer (One)
            {
                 0x00                                             // .
            }
        })
    }
}

Changing the method code to this hides them which is fine considering I still can't get the highpoint card working and seeing four individual drives pop up for initialization at boot is annoying.

 

Hides them:

 If (!Arg2)
        {
            Return (Buffer (One)
            {
                 0x03                                             // .
            })
        }

        Return (Package (0x04)
        {
            "class-code", 
            Buffer (0x04)
            {
                 0xFF, 0x08, 0x01, 0x00                           // ....
            }, 

            "built-in", 
            Buffer (One)
            {
                 0x00                                             // .
            }
        })

 

This is up to personal preference, but I prefer to put device properties in my config.plist file. You can define the Devices without the _DSM method in the SSDTs and put all the device properties (Built-in or class code in this case) in one place in your config.plist.

  • Like 1

I originally did have them listed in config.plist using data from Hackintool but I probably didn't put in the correct code and maybe made a mistake with the acpi addressing. These drives were actually nested behind three switches from the motherboard onto the Highpoint card. I went with SSDTs thinking the reason the card doesn't work is related to ACPI. I am sure either or method works equally as well. Thank you for the suggestion.

 

 

×
×
  • Create New...