On Sat, 09 Jul 2016 at 16:32:15 -0700, Philip Guenther wrote: > No newer bios for this thing? :-(
It is actually the open-source Chrome EC found on the Chromebook Pixel (among others), and according to the source code for the version on this machine, it did not implement burst mode in its ACPI interface. They eventually added support for it later, but for any EC that does not support burst mode, I think this patch does the right thing by checking that burst mode actually turns on before waiting for the ack byte. > > That's why the diff also includes the change to acpiec_write_cmd to > > wait until IBF is 0, so it won't get to that new status check until > > the controller has processed the EC_CMD_BE fully. > > I don't think the spec guarantees that implication, though it may be > true in practice. > > <shurg> > > Wonder what Windows and Linux do on this thing. Linux doesn't even enable burst mode unless busy polling is enabled (which is only turned on when passed as a kernel boot flag), or when the read/write length is more than 8. https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/drivers/acpi/ec.c#n1195 (I think this is why they didn't bother implementing burst mode in the ACPI interface of the Chrome EC, since it usually just runs Linux and Linux doesn't usually try burst mode (and most other device interfaces for this machine use direct I2C/LPC interfaces to the EC instead of through ACPI.)) Also, I just checked FreeBSD and they appear to do something similar to my patch, where they check that the EC burst mode flag is set in the status after trying to enable it: https://github.com/freebsd/freebsd/blob/master/sys/dev/acpica/acpi_ec.c#L933 before actually trying to read the ACK: https://github.com/freebsd/freebsd/blob/master/sys/dev/acpica/acpi_ec.c#L775 > Anyway, this diff would need to be tested broadly on *unaffected* > hardware to gain confidence it doesn't hurt some box that doesn't have > this brokeness. Yeah, I'll probably just disable acpicbkbd for the 6.0 release because it requires talking to the EC and will just hang the kernel on Chromebooks with a Chrome EC.