5 func FIXMEEC(ctx Context
) {
6 ap
:= Create(ctx
, "acpi/platform.asl")
9 hasKeyboard
:= ctx
.InfoSource
.HasPS2()
11 sbGPE
:= GuessECGPE(ctx
)
14 sbGPE
= SouthBridge
.EncodeGPE(1)
16 SouthBridge
.NeedRouteGPIOManually()
19 SouthBridge
.EnableGPE(SouthBridge
.DecodeGPE(sbGPE
))
22 Add_SPDX(ap
, ASL
, GPL2_only
)
26 /* FIXME: EC support */
27 Return(Package() {0, 0})
32 /* FIXME: EC support */
36 ecs
:= ctx
.InfoSource
.GetEC()
37 MainboardIncludes
= append(MainboardIncludes
, "ec/acpi/ec.h")
38 MainboardIncludes
= append(MainboardIncludes
, "console/console.h")
41 ` /* FIXME: trim this down or remove if necessary */
44 const u8 dmp[256] = {`
45 for i
:= 0; i
< 0x100; i
++ {
47 MainboardInit
+= fmt
.Sprintf("\n\t\t\t/* %02x */ ", i
)
49 MainboardInit
+= fmt
.Sprintf("0x%02x,", ecs
[i
])
54 MainboardInit
+= "\n\t\t};\n"
56 printk(BIOS_DEBUG, "Replaying EC dump ...");
57 for (i = 0; i < 256; i++)
59 printk(BIOS_DEBUG, "done\n");
63 KconfigBool
["EC_ACPI"] = true
64 si
:= Create(ctx
, "acpi/superio.asl")
68 Add_SPDX(si
, ASL
, GPL2_only
)
69 si
.WriteString("#include <drivers/pc80/pc/ps2_controller.asl>\n")
70 MainboardInit
+= fmt
.Sprintf("\tpc_keyboard_init(NO_AUX_DEVICE);\n")
71 MainboardIncludes
= append(MainboardIncludes
, "pc80/keyboard.h")
74 ec
:= Create(ctx
, "acpi/ec.asl")
77 Add_SPDX(ec
, ASL
, GPL2_only
)
78 ec
.WriteString(`Device(EC)
80 Name (_HID, EISAID("PNP0C09"))
84 ec
.WriteString("\t/* FIXME: Set GPE */\n")
85 ec
.WriteString("\t/* Name (_GPE, ?) */\n")
87 fmt
.Fprintf(ec
, "\tName (_GPE, %d)\n", sbGPE
)
89 ec
.WriteString("/* FIXME: EC support */\n")