Commit 735a8703 authored by Suman Anna's avatar Suman Anna Committed by Hari Kanigeri

SYSLINK: ipc - fixed the setup api issues with messageq

This patch fixes the issues with messageq_setup and messageq_transportshm_setup.
The issue is caused by incorrect BUG_ON and unlikely statements.
Signed-off-by: default avatarSuman Anna <s-anna@ti.com>
parent 10064643
......@@ -370,7 +370,7 @@ int messageq_setup(const struct messageq_config *cfg)
MULTIPROC_MAXPROCESSORS * \
MESSAGEQ_NUM_PRIORITY_QUEUES));
BUG_ON(status >= 0);
BUG_ON(status < 0);
goto exit;
queues_alloc_fail:
......
......@@ -317,7 +317,6 @@ exit:
static inline int messageq_ioctl_setup(struct messageq_cmd_args *cargs)
{
s32 retval = 0;
int status = 0;
unsigned long size;
struct messageq_config config;
......@@ -328,11 +327,8 @@ static inline int messageq_ioctl_setup(struct messageq_cmd_args *cargs)
goto exit;
}
status = messageq_setup(&config);
if (unlikely(status))
goto exit;
cargs->api_status = messageq_setup(&config);
cargs->api_status = status;
exit:
return retval;
}
......
......@@ -67,7 +67,6 @@ static inline int messageq_transportshm_ioctl_setup(
struct messageq_transportshm_cmd_args *cargs)
{
s32 retval = 0;
int status = 0;
unsigned long size;
struct messageq_transportshm_config config;
......@@ -78,11 +77,8 @@ static inline int messageq_transportshm_ioctl_setup(
goto exit;
}
status = messageq_transportshm_setup(&config);
if (unlikely(status))
goto exit;
cargs->api_status = messageq_transportshm_setup(&config);
cargs->api_status = status;
exit:
return retval;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment