From ec1519dd0198a24b3ffdcb207a6dae039af2d2f6 Mon Sep 17 00:00:00 2001 From: Tao Ye Date: Sat, 15 Jul 2017 16:30:35 -0700 Subject: Add support to probe if TA is available When connecting to Trusty via TIPC, linux kernel wants to know if the connection failure is caused by port_not_found issues such as the requested TA is not available. Bug 1896070 Jira APTS-731 Change-Id: I7fe9b895b79ba5fa82b15d2bfd90b1297fd7d017 Signed-off-by: Tao Ye Reviewed-on: https://git-master.nvidia.com/r/1523288 Reviewed-by: Varun Wadekar Reviewed-by: svccoveritychecker Reviewed-by: svc-mobile-coverity GVS: Gerrit_Virtual_Submit Reviewed-by: Stephen Warren Reviewed-by: Mitch Luban Tested-by: Mrutyunjay Sawant --- include/linux/trusty/trusty_ipc.h | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'include/linux') diff --git a/include/linux/trusty/trusty_ipc.h b/include/linux/trusty/trusty_ipc.h index beabc3f3e..da785e98d 100644 --- a/include/linux/trusty/trusty_ipc.h +++ b/include/linux/trusty/trusty_ipc.h @@ -1,5 +1,6 @@ /* * Copyright (C) 2015 Google, Inc. + * Copyright (c) 2016-2017, NVIDIA CORPORATION. All rights reserved. * * This software is licensed under the terms of the GNU General Public * License version 2, as published by the Free Software Foundation, and @@ -14,6 +15,13 @@ #ifndef __LINUX_TRUSTY_TRUSTY_IPC_H #define __LINUX_TRUSTY_TRUSTY_IPC_H +/* + * Errnos below must be in sync with the corresponding errnos + * defined in 3rdparty/trusty/external/lk/include/err.h + */ +#define NO_ERROR (0) +#define ERR_NOT_FOUND (-2) + struct tipc_chan; struct tipc_msg_buf { @@ -29,6 +37,7 @@ enum tipc_chan_event { TIPC_CHANNEL_CONNECTED = 1, TIPC_CHANNEL_DISCONNECTED, TIPC_CHANNEL_SHUTDOWN, + TIPC_CHANNEL_NOT_FOUND, }; struct tipc_chan_ops { -- cgit v1.2.2