diff options
author | Fabio Baltieri <fabiobaltieri@google.com> | 2021-08-09 09:37:45 +0000 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2021-08-10 21:53:38 +0000 |
commit | d38c5745d486004da1eb7b942b4ce3dbcf7a9be7 (patch) | |
tree | 66333c8dce1be812d5b2289f045a26fbaf1429eb /zephyr/shim | |
parent | 64cda0a13de4056c13c8a62b756008480be6b425 (diff) | |
download | chrome-ec-d38c5745d486004da1eb7b942b4ce3dbcf7a9be7.tar.gz |
zephyr: hooks: change priority to uint16_t
Priority field goes from 0 to HOOK_PRIO_LAST, so 16 bits are enough.
Switching to a 2 bytes field allows struct zephyr_shim_hook_list to pack
up in 12 bytes, saves a bit of ram.
BRANCH=none
BUG=b:195521227
TEST=build and run on volteer
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
Change-Id: Ia8899d3d47a3c38ed20dfa5121d375a4419567f4
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3080573
Reviewed-by: Keith Short <keithshort@chromium.org>
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Keith Short <keithshort@chromium.org>
Diffstat (limited to 'zephyr/shim')
-rw-r--r-- | zephyr/shim/include/zephyr_hooks_shim.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/zephyr/shim/include/zephyr_hooks_shim.h b/zephyr/shim/include/zephyr_hooks_shim.h index 7175b5a6af..c53d05de9e 100644 --- a/zephyr/shim/include/zephyr_hooks_shim.h +++ b/zephyr/shim/include/zephyr_hooks_shim.h @@ -52,7 +52,7 @@ int hook_call_deferred(const struct deferred_data *data, int us); */ struct zephyr_shim_hook_list { void (*routine)(void); - int priority; + uint16_t priority; /* HOOK_PRIO_LAST = 9999 */ enum hook_type type; struct zephyr_shim_hook_list *next; }; |