We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent e0ca3d2 commit 692f9e4Copy full SHA for 692f9e4
VoodooGPIO/VoodooGPIOIntel.cpp
@@ -150,6 +150,17 @@ bool VoodooGPIOIntel::intel_pad_acpi_mode(unsigned pin) {
150
offset = community->hostown_offset + padgrp->reg_num * 4;
151
hostown = community->regs + offset;
152
153
+ UInt32 hostownval = readl(hostown);
154
+ if ((hostownval & BIT(gpp_offset)) == 0) {
155
+ IOLog("%s::Pin owned by ACPI...Attempting to take ownership\n", getName());
156
+
157
+ hostownval |= BIT(gpp_offset);
158
+ writel(hostownval, hostown);
159
+ } else {
160
+ return false;
161
+ }
162
163
+ // Second read to double check we actually got ownership
164
return !(readl(hostown) & BIT(gpp_offset));
165
}
166
0 commit comments