Commit 521d0d53 authored by Bryan O'Donoghue's avatar Bryan O'Donoghue Committed by Greg Kroah-Hartman

greybus: greybus_protocols.h Add SVC_TIMESYNC_PING

In order to verify TimeSync functionality we require a TimeSync-ping
operation where the AP can command the SVC to initiate a single strobe of
downstream TimeSync slaves, and report the FrameTime at the strobe. Ping
will only be valid after the system has transitioned to a TIMESYNC_ACTIVE
state.

In the active state each TimeSync slave will graph a single incoming SVC
strobe as a ping and will store its frame time. The AP will then gather
each last-event FrameTime for presentation to user-space in the AP and/or
further automation based on the reported FrameTimes at the SVC ping.

This patch adds the SVC ping command definition to greybus_protocols.h.
Signed-off-by: default avatarBryan O'Donoghue <bryan.odonoghue@linaro.org>
Reviewed-by: default avatarVaibhav Hiremath <vaibhav.hiremath@linaro.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@google.com>
parent 596e4a19
......@@ -837,6 +837,7 @@ struct gb_spi_transfer_response {
#define GB_SVC_TYPE_PWRMON_INTF_SAMPLE_GET 0x17
#define GB_SVC_TYPE_TIMESYNC_WAKE_PINS_ACQUIRE 0x18
#define GB_SVC_TYPE_TIMESYNC_WAKE_PINS_RELEASE 0x19
#define GB_SVC_TYPE_TIMESYNC_PING 0x1a
#define GB_SVC_TYPE_MODULE_INSERTED 0x1f
#define GB_SVC_TYPE_MODULE_REMOVED 0x20
#define GB_SVC_TYPE_INTF_ACTIVATE 0x27
......@@ -975,6 +976,11 @@ struct gb_svc_timesync_wake_pins_acquire_request {
/* timesync wake pins release request has no payload */
/* timesync wake pins release response has no payload */
/* timesync svc ping request has no payload */
struct gb_svc_timesync_ping_response {
__le64 frame_time;
} __packed;
#define GB_SVC_UNIPRO_FAST_MODE 0x01
#define GB_SVC_UNIPRO_SLOW_MODE 0x02
#define GB_SVC_UNIPRO_FAST_AUTO_MODE 0x04
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment