This implements the SVC "ping" command. It's tiny and simple, but we
need something like this in order for us to "know" if all is working
well.
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Reviewed-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
#define GB_SVC_TYPE_INTF_SET_PWRM 0x10
#define GB_SVC_TYPE_INTF_EJECT 0x11
#define GB_SVC_TYPE_KEY_EVENT 0x12
+#define GB_SVC_TYPE_PING 0x13
/*
* SVC version request/response has the same payload as
}
EXPORT_SYMBOL_GPL(gb_svc_intf_set_power_mode);
+int gb_svc_ping(struct gb_svc *svc)
+{
+ return gb_operation_sync(svc->connection, GB_SVC_TYPE_PING,
+ NULL, 0, NULL, 0);
+}
+EXPORT_SYMBOL_GPL(gb_svc_ping);
+
static int gb_svc_version_request(struct gb_operation *op)
{
struct gb_connection *connection = op->connection;
u8 tx_mode, u8 tx_gear, u8 tx_nlanes,
u8 rx_mode, u8 rx_gear, u8 rx_nlanes,
u8 flags, u32 quirks);
+int gb_svc_ping(struct gb_svc *svc);
int gb_svc_protocol_init(void);
void gb_svc_protocol_exit(void);