diff options
author | Srinivas Kandagatla <srinivas.kandagatla@linaro.org> | 2018-12-21 09:46:04 +0000 |
---|---|---|
committer | Srinivas Kandagatla <srinivas.kandagatla@linaro.org> | 2018-12-21 09:48:08 +0000 |
commit | 6551cce888e171d1640ae927e55c975e1a2cb4b6 (patch) | |
tree | bd91e27e69610f2932bb818920774e0676b4fad3 | |
parent | 1e42b7ad5bfb6d82bd3f997186194639c49714d4 (diff) |
apps_user: make open_dev non static
Make open non static so that rpcmem can use the same device to do dmabuf allocations.
Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
-rw-r--r-- | src/fastrpc_apps_user.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/fastrpc_apps_user.c b/src/fastrpc_apps_user.c index 4e8f509..19ea601 100644 --- a/src/fastrpc_apps_user.c +++ b/src/fastrpc_apps_user.c @@ -243,6 +243,7 @@ static void create_dev(void) dev = open(FASTRPC_DEVICE, O_NONBLOCK); VERIFY(dev >= 0); + gdev = dev; VERIFY(!apps_std_fopen_with_env("ADSP_LIBRARY_PATH", ";", "fastrpc_shell_0", "r", &fh)); VERIFY(!apps_std_flen(fh, &len)); VERIFY(len < INT_MAX); @@ -252,7 +253,6 @@ static void create_dev(void) VERIFY(!apps_std_fread(fh, ginit.file, len, &readlen, &eof)); VERIFY(ginit.filelen == readlen); ginit.filefd = rpcmem_to_fd((void *)ginit.file); - gdev = dev; VERIFY(0 == ioctl(dev, FASTRPC_IOCTL_INIT_CREATE, (unsigned long)&ginit)); dev = -1; } @@ -281,7 +281,7 @@ static void create_listener(void) glist = listener_init(); } -static int open_dev(int attach) +int open_dev(int attach) { if (gdev == -1) { |