Loading drivers/soc/qcom/qdsp6v2/apr.c +7 −4 Original line number Diff line number Diff line Loading @@ -325,6 +325,7 @@ struct apr_svc *apr_register(char *dest, char *svc_name, apr_fn svc_fn, int temp_port = 0; struct apr_svc *svc = NULL; int rc = 0; bool can_open_channel = true; if (!dest || !svc_name || !svc_fn) return NULL; Loading @@ -332,9 +333,11 @@ struct apr_svc *apr_register(char *dest, char *svc_name, apr_fn svc_fn, if (!strcmp(dest, "ADSP")) domain_id = APR_DOMAIN_ADSP; else if (!strcmp(dest, "MODEM")) { /* Register voice services if destination permits */ if (!apr_register_voice_svc()) goto done; /* Don't request for SMD channels if destination is MODEM, * as these channels are no longer used and these clients * are to listen only for MODEM SSR events */ can_open_channel = false; domain_id = APR_DOMAIN_MODEM; } else { pr_err("APR: wrong destination\n"); Loading Loading @@ -373,7 +376,7 @@ struct apr_svc *apr_register(char *dest, char *svc_name, apr_fn svc_fn, clnt = &client[dest_id][client_id]; mutex_lock(&clnt->m_lock); if (!clnt->handle) { if (!clnt->handle && can_open_channel) { clnt->handle = apr_tal_open(client_id, dest_id, APR_DL_SMD, apr_cb_func, NULL); if (!clnt->handle) { Loading drivers/soc/qcom/qdsp6v2/apr_v2.c +1 −6 Original line number Diff line number Diff line /* * Copyright (c) 2012-2014 The Linux Foundation. All rights reserved. * Copyright (c) 2012-2015 The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -63,8 +63,3 @@ uint16_t apr_get_reset_domain(uint16_t proc) { return proc; } bool apr_register_voice_svc() { return true; } drivers/soc/qcom/qdsp6v2/apr_v3.c +1 −6 Original line number Diff line number Diff line /* * Copyright (c) 2013-2014, The Linux Foundation. All rights reserved. * Copyright (c) 2013-2015, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -46,8 +46,3 @@ uint16_t apr_get_reset_domain(uint16_t proc) { return APR_DEST_QDSP6; } bool apr_register_voice_svc() { return false; } include/linux/qdsp6v2/apr.h +1 −2 Original line number Diff line number Diff line /* Copyright (c) 2010-2014, The Linux Foundation. All rights reserved. /* Copyright (c) 2010-2015, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -174,6 +174,5 @@ enum apr_subsys_state apr_get_q6_state(void); int apr_set_q6_state(enum apr_subsys_state state); void apr_set_subsys_state(void); const char *apr_get_lpass_subsys_name(void); bool apr_register_voice_svc(void); uint16_t apr_get_reset_domain(uint16_t proc); #endif Loading
drivers/soc/qcom/qdsp6v2/apr.c +7 −4 Original line number Diff line number Diff line Loading @@ -325,6 +325,7 @@ struct apr_svc *apr_register(char *dest, char *svc_name, apr_fn svc_fn, int temp_port = 0; struct apr_svc *svc = NULL; int rc = 0; bool can_open_channel = true; if (!dest || !svc_name || !svc_fn) return NULL; Loading @@ -332,9 +333,11 @@ struct apr_svc *apr_register(char *dest, char *svc_name, apr_fn svc_fn, if (!strcmp(dest, "ADSP")) domain_id = APR_DOMAIN_ADSP; else if (!strcmp(dest, "MODEM")) { /* Register voice services if destination permits */ if (!apr_register_voice_svc()) goto done; /* Don't request for SMD channels if destination is MODEM, * as these channels are no longer used and these clients * are to listen only for MODEM SSR events */ can_open_channel = false; domain_id = APR_DOMAIN_MODEM; } else { pr_err("APR: wrong destination\n"); Loading Loading @@ -373,7 +376,7 @@ struct apr_svc *apr_register(char *dest, char *svc_name, apr_fn svc_fn, clnt = &client[dest_id][client_id]; mutex_lock(&clnt->m_lock); if (!clnt->handle) { if (!clnt->handle && can_open_channel) { clnt->handle = apr_tal_open(client_id, dest_id, APR_DL_SMD, apr_cb_func, NULL); if (!clnt->handle) { Loading
drivers/soc/qcom/qdsp6v2/apr_v2.c +1 −6 Original line number Diff line number Diff line /* * Copyright (c) 2012-2014 The Linux Foundation. All rights reserved. * Copyright (c) 2012-2015 The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -63,8 +63,3 @@ uint16_t apr_get_reset_domain(uint16_t proc) { return proc; } bool apr_register_voice_svc() { return true; }
drivers/soc/qcom/qdsp6v2/apr_v3.c +1 −6 Original line number Diff line number Diff line /* * Copyright (c) 2013-2014, The Linux Foundation. All rights reserved. * Copyright (c) 2013-2015, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -46,8 +46,3 @@ uint16_t apr_get_reset_domain(uint16_t proc) { return APR_DEST_QDSP6; } bool apr_register_voice_svc() { return false; }
include/linux/qdsp6v2/apr.h +1 −2 Original line number Diff line number Diff line /* Copyright (c) 2010-2014, The Linux Foundation. All rights reserved. /* Copyright (c) 2010-2015, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -174,6 +174,5 @@ enum apr_subsys_state apr_get_q6_state(void); int apr_set_q6_state(enum apr_subsys_state state); void apr_set_subsys_state(void); const char *apr_get_lpass_subsys_name(void); bool apr_register_voice_svc(void); uint16_t apr_get_reset_domain(uint16_t proc); #endif