[trusty] Update ipc connect syscall

Add flags parameter to connect syscall with following options:
  IPC_CONNECT_ASYNC - initiate asyncronous connection.
     Asyncrounous connection might returns before server
     had a chance to accept it. Caller has to wait for
     IPC_POLL_HANDLE_READY event that indicates that
     connection is complete.
  IPC_CONNECT_WAIT_FOR_PORT - if specified allows an attempt to
  connect to not-yet-existing port vs. failing immediately
  if port is not available.

Remove timeout parameter from syscall. Callers should use
async connect if timeout is required.

Change-Id: Ie601cb4a66a3fe7f974509458f26f203af5b0408
diff --git a/include/trusty_ipc.h b/include/trusty_ipc.h
index 97b4cdd8..38d5d30 100644
--- a/include/trusty_ipc.h
+++ b/include/trusty_ipc.h
@@ -49,6 +49,14 @@
 };
 
 /*
+ * Options for connect syscall
+ */
+enum {
+	IPC_CONNECT_WAIT_FOR_PORT = 0x1,
+	IPC_CONNECT_ASYNC = 0x2,
+};
+
+/*
  *  IPC message
  */
 typedef struct iovec {
diff --git a/include/trusty_syscalls.h b/include/trusty_syscalls.h
index ca44bd3..6c37372 100644
--- a/include/trusty_syscalls.h
+++ b/include/trusty_syscalls.h
@@ -52,7 +52,7 @@
 long nanosleep (uint32_t clock_id, uint32_t flags, uint64_t sleep_time);
 long gettime (uint32_t clock_id, uint32_t flags, int64_t *time);
 long port_create (const char *path, uint num_recv_bufs, size_t recv_buf_size, uint32_t flags);
-long connect (const char *path, unsigned long timeout_msecs);
+long connect (const char *path, uint flags);
 long accept (uint32_t handle_id, uuid_t *peer_uuid);
 long close (uint32_t handle_id);
 long set_cookie (uint32_t handle, void *cookie);