Skip to content

Commit

Permalink
RPi3: expose SDHost controller in DSDT
Browse files Browse the repository at this point in the history
Expose both SD controllers to HLOS. UEFI can
use either to route uSD slot to.

This merges #33

Signed-off-by: Andrei Warkentin <andrey.warkentin@gmail.com>
  • Loading branch information
andreiw committed Jun 16, 2018
1 parent 9c8bfb8 commit 3109eb9
Showing 1 changed file with 46 additions and 3 deletions.
49 changes: 46 additions & 3 deletions AcpiTables/Sdhc.asl
@@ -1,7 +1,7 @@
/*
* [DSDT] SD controller/card definition.
*
* UEFI uses Arasan today, so that's all we expose.
* UEFI can use either SDHost or Arasan. We expose both to HLOS.
*
* Copyright (c), 2018, Andrey Warkentin <andrey.warkentin@gmail.com>
* Copyright (c), Microsoft Corporation. All rights reserved.
Expand All @@ -16,7 +16,7 @@
*/

//
// Description: This is ArasanSD 3.0 SD Host Controller
// Description: This is ArasanSD 3.0 SD Host Controller.
//

Device (SDC1)
Expand All @@ -43,7 +43,7 @@ Device (SDC1)
//
// A child device that represents the
// sd card, which is marked as non-removable.
//
//
Device (SDMM)
{
Method (_ADR)
Expand All @@ -56,3 +56,46 @@ Device (SDC1)
}
}
}


//
// Description: This is Broadcom SDHost 2.0 SD Host Controller
//

Device (SDC2)
{
Name (_HID, "BCM2855")
Name (_CID, "SDHST")
Name (_UID, 0x0)
Name (_S1D, 0x1)
Name (_S2D, 0x1)
Name (_S3D, 0x1)
Name (_S4D, 0x1)
Method (_STA)
{
Return(0xf)
}
Method (_CRS, 0x0, NotSerialized) {
Name (RBUF, ResourceTemplate () {
MEMORY32FIXED(ReadWrite, 0x3F202000, 0x100, )
Interrupt(ResourceConsumer, Level, ActiveHigh, Exclusive) { 0x58 }
})
Return(RBUF)
}

//
// A child device that represents the
// sd card, which is marked as non-removable.
//
Device (SDMM)
{
Method (_ADR)
{
Return (0)
}
Method (_RMV) // Is removable
{
Return (0) // 0 - fixed
}
}
}

0 comments on commit 3109eb9

Please sign in to comment.