浏览代码

dsp-kernel: Unify error code when remote subsystem is not up

Currently, different error codes are returned if remote subsystem
is not up when client tries to open dynamic PD. Need to unify them
to -ECONNREFUSED.

Change-Id: Iee6925724a29a4ab265c50f68baa267150b4058d
Signed-off-by: Minghao Xue <[email protected]>
Minghao Xue 1 年之前
父节点
当前提交
ddf3406a0c
共有 1 个文件被更改,包括 3 次插入1 次删除
  1. 3 1
      dsp/adsprpc.c

+ 3 - 1
dsp/adsprpc.c

@@ -6396,8 +6396,10 @@ static int fastrpc_channel_open(struct fastrpc_file *fl, uint32_t flags)
 		goto bail;
 		goto bail;
 
 
 	err = verify_transport_device(cid, fl->tvm_remote_domain);
 	err = verify_transport_device(cid, fl->tvm_remote_domain);
-	if (err)
+	if (err) {
+		err = -ECONNREFUSED;
 		goto bail;
 		goto bail;
+	}
 
 
 	mutex_lock(&me->channel[cid].smd_mutex);
 	mutex_lock(&me->channel[cid].smd_mutex);
 	if (me->channel[cid].ssrcount !=
 	if (me->channel[cid].ssrcount !=