summaryrefslogtreecommitdiffstats
path: root/drivers/staging/greybus/greybus_protocols.h
diff options
context:
space:
mode:
authorBryan O'Donoghue <bryan.odonoghue@linaro.org>2016-03-02 16:51:08 +0000
committerGreg Kroah-Hartman <gregkh@google.com>2016-03-03 15:16:52 -0800
commit177d4a4d34bc81e220cc2ef4056df3da25ad6994 (patch)
treeca405db2aded0254e9c9de37cbd2b953a0818384 /drivers/staging/greybus/greybus_protocols.h
parentd6fefbe19327f4137360d7ab8af78f1d4d9b909e (diff)
downloadop-kernel-dev-177d4a4d34bc81e220cc2ef4056df3da25ad6994.zip
op-kernel-dev-177d4a4d34bc81e220cc2ef4056df3da25ad6994.tar.gz
greybus: timesync: Add Control and SVC TimeSync command/response data definitions
This patch adds the protocol command/response definitions for the SVC and Control protocols to the greybus_protocols definition header consistent with the greybus-spec. Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Diffstat (limited to 'drivers/staging/greybus/greybus_protocols.h')
-rw-r--r--drivers/staging/greybus/greybus_protocols.h28
1 files changed, 28 insertions, 0 deletions
diff --git a/drivers/staging/greybus/greybus_protocols.h b/drivers/staging/greybus/greybus_protocols.h
index b60c7dc..c0a7863 100644
--- a/drivers/staging/greybus/greybus_protocols.h
+++ b/drivers/staging/greybus/greybus_protocols.h
@@ -170,6 +170,20 @@ struct gb_control_interface_version_response {
__le16 minor;
} __packed;
+#define GB_TIMESYNC_MAX_STROBES 0x04
+
+struct gb_control_timesync_enable_request {
+ __u8 count;
+ __u64 frame_time;
+ __u32 strobe_delay;
+ __u32 refclk;
+} __packed;
+/* timesync enable response has no payload */
+
+struct gb_control_timesync_authoritative_request {
+ __u64 frame_time[GB_TIMESYNC_MAX_STROBES];
+} __packed;
+/* timesync authoritative response has no payload */
/* APBridge protocol */
@@ -900,6 +914,20 @@ struct gb_svc_route_destroy_request {
} __packed;
/* route destroy response has no payload */
+struct gb_svc_timesync_enable_request {
+ __u8 count;
+ __u64 frame_time;
+ __u32 strobe_delay;
+ __u32 strobe_mask;
+ __u32 refclk;
+} __packed;
+/* timesync enable response has no payload */
+
+/* timesync authoritative request has no payload */
+struct gb_svc_timesync_authoritative_response {
+ __u64 frame_time[GB_TIMESYNC_MAX_STROBES];
+};
+
#define GB_SVC_UNIPRO_FAST_MODE 0x01
#define GB_SVC_UNIPRO_SLOW_MODE 0x02
#define GB_SVC_UNIPRO_FAST_AUTO_MODE 0x04
OpenPOWER on IntegriCloud