diff options
author | Shawn Nematbakhsh <shawnn@chromium.org> | 2015-07-27 14:36:53 -0700 |
---|---|---|
committer | ChromeOS Commit Bot <chromeos-commit-bot@chromium.org> | 2015-07-28 21:31:38 +0000 |
commit | a9527fd686dcdd0b04c4eac6690531d945e7f221 (patch) | |
tree | b094ce4302d22dcff233e9738fc71105f70adaca /include/host_command.h | |
parent | 0183e3cc7ffc507bbb3fc7d4165b3b13a90b813e (diff) | |
download | chrome-ec-a9527fd686dcdd0b04c4eac6690531d945e7f221.tar.gz |
acpi: Ensure continuity of memmap data with a read cache
For multi-byte ACPI memmap reads, we previously had a mutex to ensure
data continuity. A better approach is to use a read cache. Since the
kernel will enable burst mode before reading a multi-byte memmap
variable and disable it afterward, we can populate the cache on the
first read after enabling burst. This solution removes deadlock bugs, is
contained entirely in acpi.c, and saves a deferred function.
BUG=chromium:514283
TEST=Manual on Glados. Add prints in acpi_read, verify that multi-byte
reads come from cache and non-burst reads continue to function as
before.
BRANCH=Cyan
Signed-off-by: Shawn Nematbakhsh <shawnn@chromium.org>
Change-Id: I74e4927bf2b433e31a9ff65d72820fa087c51722
Reviewed-on: https://chromium-review.googlesource.com/288871
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
Diffstat (limited to 'include/host_command.h')
-rw-r--r-- | include/host_command.h | 19 |
1 files changed, 0 insertions, 19 deletions
diff --git a/include/host_command.h b/include/host_command.h index 0d1ff998f3..08141e2204 100644 --- a/include/host_command.h +++ b/include/host_command.h @@ -124,25 +124,6 @@ struct host_command { uint8_t *host_get_memmap(int offset); /** - * Grab the memmap write mutex. This function should be called before - * multi-byte variable reads from ACPI, and before updating multi-byte - * memmap variables anywhere else. - */ -void host_lock_memmap(void); - -/* - * Returns status of host memmap lock. - */ -int host_memmap_is_locked(void); - -/** - * Release the memmap write mutex. This function should be called once - * a multi-byte variable read from ACPI is done, and when updating multi-byte - * memmap variables is done. - */ -void host_unlock_memmap(void); - -/** * Process a host command and return its response * * @param args Command handler args |