summaryrefslogtreecommitdiff
path: root/include/motion_sense.h
diff options
context:
space:
mode:
authorYuval Peress <peress@chromium.org>2019-05-20 21:10:30 -0600
committerchrome-bot <chrome-bot@chromium.org>2019-05-23 02:14:20 -0700
commitf25a4cf2477a48fccce07047aaa3bb564c46e802 (patch)
treea6574e46f47e894d02342e32c3def569c0a595c9 /include/motion_sense.h
parent57aa1891be676b51fb43045a664f476d676948f1 (diff)
downloadchrome-ec-f25a4cf2477a48fccce07047aaa3bb564c46e802.tar.gz
motionsense: Convert in_spoof_mode to a more generic flags
BUG=b:129159505 BRANCH=arcada TEST=I ran `make buildall` since this change isn't used yet it doesn't affect run-time behavior. Change-Id: I01857d679b800f9b53762c659ebd9a018cbf16db Signed-off-by: Yuval Peress <peress@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/1612251 Legacy-Commit-Queue: Commit Bot <commit-bot@chromium.org>
Diffstat (limited to 'include/motion_sense.h')
-rw-r--r--include/motion_sense.h11
1 files changed, 8 insertions, 3 deletions
diff --git a/include/motion_sense.h b/include/motion_sense.h
index b5fc36dfe4..25e4e2fc7c 100644
--- a/include/motion_sense.h
+++ b/include/motion_sense.h
@@ -107,6 +107,12 @@ struct motion_data_t {
unsigned int ec_rate;
};
+/*
+ * When set, spoof mode will allow the EC to report arbitrary values for any of
+ * the components.
+ */
+#define MOTIONSENSE_FLAG_IN_SPOOF_MODE BIT(1)
+
struct motion_sensor_t {
/* RO fields */
uint32_t active_mask;
@@ -125,10 +131,9 @@ struct motion_sensor_t {
uint8_t addr;
/*
- * When non-zero, spoof mode will allow the EC to report arbitrary
- * values for any of the components.
+ * Various flags, see MOTIONSENSE_FLAG_*
*/
- uint8_t in_spoof_mode;
+ uint32_t flags;
const mat33_fp_t *rot_standard_ref;